|
@@ -65,6 +65,7 @@ public class WxAlertLogController extends ApiBaseController {
|
|
|
|
|
|
if (alertConfiguration1!=null){
|
|
|
//有启动
|
|
|
+ alertConfiguration1.setIsClearCache(false);
|
|
|
Date date = new Date();
|
|
|
int i = date.compareTo(alertConfiguration1.getAlertStartTime());
|
|
|
int i1 = date.compareTo(alertConfiguration1.getAlertEndTime());
|
|
@@ -75,7 +76,11 @@ public class WxAlertLogController extends ApiBaseController {
|
|
|
|
|
|
if ((strings.contains("1") || strings.contains("2")) &&sysUserExt.getSalesLevel().equals("customer_level")){
|
|
|
//满足类型对应a
|
|
|
- AlertLog alertLog = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId());
|
|
|
+ AlertLog alertLog = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId(),"0");
|
|
|
+ AlertLog log = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId(),null);
|
|
|
+ if(log == null){
|
|
|
+ alertConfiguration1.setIsClearCache(true);
|
|
|
+ }
|
|
|
if (alertLog!=null){
|
|
|
if (alertLog.getAlertNum()<alertConfiguration1.getAlertNum()){
|
|
|
alertLog.setAlertNum(alertLog.getAlertNum()+1);
|
|
@@ -96,8 +101,11 @@ public class WxAlertLogController extends ApiBaseController {
|
|
|
}
|
|
|
}
|
|
|
if((strings.contains("0") || strings.contains("2")) && !sysUserExt.getSalesLevel().equals("customer_level")){
|
|
|
- System.out.println(userId);
|
|
|
- AlertLog alertLog = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId());
|
|
|
+ AlertLog alertLog = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId(),"0");
|
|
|
+ AlertLog log = alertLogService.selectAlertLogByUserIdAndAlertId(userId, alertConfiguration1.getAlertId(),null);
|
|
|
+ if(log == null){
|
|
|
+ alertConfiguration1.setIsClearCache(true);
|
|
|
+ }
|
|
|
if (alertLog!=null){
|
|
|
if (alertLog.getAlertNum()<alertConfiguration1.getAlertNum()){
|
|
|
alertLog.setAlertNum(alertLog.getAlertNum()+1);
|