|
@@ -7,6 +7,7 @@ import com.example.opc_common.enums.ModelEnum;
|
|
import com.example.opc_common.enums.OperationEnum;
|
|
import com.example.opc_common.enums.OperationEnum;
|
|
import com.example.opc_common.enums.ResultEnum;
|
|
import com.example.opc_common.enums.ResultEnum;
|
|
import com.example.opc_common.enums.ServerEnum;
|
|
import com.example.opc_common.enums.ServerEnum;
|
|
|
|
+import com.example.opc_common.util.DateUtil;
|
|
import com.example.opc_common.util.Result;
|
|
import com.example.opc_common.util.Result;
|
|
import com.example.opc_da.annotation.WebLog;
|
|
import com.example.opc_da.annotation.WebLog;
|
|
import com.example.opc_da.service.PageAnimationService;
|
|
import com.example.opc_da.service.PageAnimationService;
|
|
@@ -57,12 +58,20 @@ public class PageAnimationController {
|
|
@GetMapping("getPageAnimationStatusByType")
|
|
@GetMapping("getPageAnimationStatusByType")
|
|
// @PermissionControl
|
|
// @PermissionControl
|
|
@WebLog(ServerEnum = ServerEnum.SERVER, ModelEnum = ModelEnum.PAGEANIMATION, OperationEnum = OperationEnum.SELECT)
|
|
@WebLog(ServerEnum = ServerEnum.SERVER, ModelEnum = ModelEnum.PAGEANIMATION, OperationEnum = OperationEnum.SELECT)
|
|
- public Result getPageAnimationStatusByType(@RequestParam("type") String type,Date startTime) {
|
|
|
|
|
|
+ public Result getPageAnimationStatusByType(@RequestParam("type") String type,String startTime) {
|
|
Boolean flag = ListUtil.toList(StrUtil.split("ztfj,ztfjqql,ztzcql,ztzcqlys,fjzxtzfj,fjzxtyfj,ydgdx_L,ydgdx_C,ydgdx_R", ",")).contains(type);
|
|
Boolean flag = ListUtil.toList(StrUtil.split("ztfj,ztfjqql,ztzcql,ztzcqlys,fjzxtzfj,fjzxtyfj,ydgdx_L,ydgdx_C,ydgdx_R", ",")).contains(type);
|
|
if (!flag) {
|
|
if (!flag) {
|
|
return Result.no(ResultEnum.REQUEST_WRONGPARAMS);
|
|
return Result.no(ResultEnum.REQUEST_WRONGPARAMS);
|
|
}
|
|
}
|
|
- return pageAnimationService.getPageAnimationStatusByType(type,startTime);
|
|
|
|
|
|
+ Date startTimeDate = new Date();
|
|
|
|
+ if(StrUtil.isNotEmpty(startTime)){
|
|
|
|
+ try {
|
|
|
|
+ startTimeDate = DateUtil.strYmdhmsChangeDate(startTime);
|
|
|
|
+ }catch (Exception e){
|
|
|
|
+ log.warn(e.getMessage());
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return pageAnimationService.getPageAnimationStatusByType(type, startTimeDate);
|
|
}
|
|
}
|
|
/**
|
|
/**
|
|
* 查看
|
|
* 查看
|
|
@@ -70,11 +79,19 @@ public class PageAnimationController {
|
|
@GetMapping("getPageAnimationValueByType")
|
|
@GetMapping("getPageAnimationValueByType")
|
|
// @PermissionControl
|
|
// @PermissionControl
|
|
@WebLog(ServerEnum = ServerEnum.SERVER, ModelEnum = ModelEnum.PAGEANIMATION, OperationEnum = OperationEnum.SELECT)
|
|
@WebLog(ServerEnum = ServerEnum.SERVER, ModelEnum = ModelEnum.PAGEANIMATION, OperationEnum = OperationEnum.SELECT)
|
|
- public Result getPageAnimationValueByType(@RequestParam("type") String type, Date startTime) {
|
|
|
|
|
|
+ public Result getPageAnimationValueByType(@RequestParam("type") String type, String startTime) {
|
|
Boolean flag = ListUtil.toList(StrUtil.split("ztfj,ztfjqql,ztzcql,ztzcqlys,fjzxtzfj,fjzxtyfj,ydgdx_L,ydgdx_C,ydgdx_R", ",")).contains(type);
|
|
Boolean flag = ListUtil.toList(StrUtil.split("ztfj,ztfjqql,ztzcql,ztzcqlys,fjzxtzfj,fjzxtyfj,ydgdx_L,ydgdx_C,ydgdx_R", ",")).contains(type);
|
|
if (!flag) {
|
|
if (!flag) {
|
|
return Result.no(ResultEnum.REQUEST_WRONGPARAMS);
|
|
return Result.no(ResultEnum.REQUEST_WRONGPARAMS);
|
|
}
|
|
}
|
|
- return pageAnimationService.getPageAnimationValueByType(type,startTime);
|
|
|
|
|
|
+ Date startTimeDate = new Date();
|
|
|
|
+ if(StrUtil.isNotEmpty(startTime)){
|
|
|
|
+ try {
|
|
|
|
+ startTimeDate = DateUtil.strYmdhmsChangeDate(startTime);
|
|
|
|
+ }catch (Exception e){
|
|
|
|
+ log.warn(e.getMessage());
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return pageAnimationService.getPageAnimationValueByType(type,startTimeDate);
|
|
}
|
|
}
|
|
}
|
|
}
|