Parcourir la source

新增/编辑账号的时候 根据设置的任务开始日期 生成任务排期

lqc il y a 5 ans
Parent
commit
0a386dde19

+ 2 - 2
src/main/java/com/mokamrp/privates/controller/pangu/FosterwxStationController.java

@@ -80,7 +80,7 @@ public class FosterwxStationController extends BaseController<FosterwxStation> {
         if (res) {
             FosterwxStation fosterwxStation = new FosterwxStation();
             String response = coralApiService.getBoxToken("gh_e529abe24cce");
-            String qrcodeUrl = wechatApiService.BuildBoxUnlimited(response, fosterwxStationService.makeBoxShareUrl(String.valueOf(addHandle.getRaw().getId()), addHandle.getRaw().getStationName()), "pages/index/index");
+            String qrcodeUrl = wechatApiService.BuildBoxUnlimited(response, fosterwxStationService.makeBoxShareUrl(String.valueOf(addHandle.getRaw().getId())), "pages/index/index");
             fosterwxStation.setBoxShareUrl(qrcodeUrl);
             fosterwxStation.setId(addHandle.getRaw().getId());
             fosterwxStationService.updateById(fosterwxStation);
@@ -107,7 +107,7 @@ public class FosterwxStationController extends BaseController<FosterwxStation> {
     @GetMapping("/test")
     public Object test() {
         String res = coralApiService.getBoxToken("gh_e529abe24cce");
-        String qrcodeUrl = wechatApiService.BuildBoxUnlimited(res, "asd=123", "pages/index/index");
+        String qrcodeUrl = wechatApiService.BuildBoxUnlimited(res, fosterwxStationService.makeBoxShareUrl("7"), "pages/index/index");
         return AjaxResult.success(qrcodeUrl);
     }
 

+ 3 - 0
src/main/java/com/mokamrp/privates/mapper/pangu/pojo/FosterwxMobile.java

@@ -55,6 +55,7 @@ public class FosterwxMobile extends Model<FosterwxMobile> {
     /**
      * 手机开卡时间
      */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     private LocalDateTime mobileCreateAt;
 
     /**
@@ -110,6 +111,7 @@ public class FosterwxMobile extends Model<FosterwxMobile> {
     /**
      * 微信注册时间
      */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     private LocalDateTime wxRegisterAt;
 
     /**
@@ -130,6 +132,7 @@ public class FosterwxMobile extends Model<FosterwxMobile> {
     /**
      * 企业微信注册时间
      */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     private LocalDateTime workWxRegisterAt;
 
     /**

+ 2 - 1
src/main/java/com/mokamrp/privates/service/pangu/FosterwxStationService.java

@@ -18,6 +18,7 @@ import java.util.Map;
 public interface FosterwxStationService extends IService<FosterwxStation> {
     //.@leon 获取数据列表
     public Map<String, Object> getList(PostBasePageHandle handle);
+
     //.@leon 站点负责人后台登录
     public Map<String, Object> login(LoginStationHandle loginStationHandle);
 
@@ -25,5 +26,5 @@ public interface FosterwxStationService extends IService<FosterwxStation> {
     public FosterwxStation getAuthInfo(String token);
 
     //.@leon 加密小程序分享链接
-    public String makeBoxShareUrl(String stationId, String stationName);
+    public String makeBoxShareUrl(String stationId);
 }

+ 2 - 3
src/main/java/com/mokamrp/privates/service/pangu/impl/FosterwxStationServiceImpl.java

@@ -102,12 +102,11 @@ public class FosterwxStationServiceImpl extends ServiceImpl<FosterwxStationMappe
 
     /**
      * 加密小程序分享链接
-     * @param boxShareUrl
      * @param stationId
      * @return
      */
-    public String makeBoxShareUrl(String stationId, String stationName) {
-        String key = StringUtils.getRandomString(10) + stationId + "-" + stationName + StringUtils.getRandomString(5);
+    public String makeBoxShareUrl(String stationId) {
+        String key = StringUtils.getRandomString(5) + stationId + StringUtils.getRandomString(5);
         byte[] keyB = key.getBytes();
         // String newBoxShareUrl = boxShareUrl + "?station=" + Base64.encode(keyB) + "&stationName=" + Base64.encode(stationName.getBytes(StandardCharsets.UTF_8));
         return Base64.encode(keyB);