|
@@ -133,11 +133,13 @@ public class FosterwxMobileController extends BaseController<FosterwxMobile> {
|
|
|
// 更新个微池个微二维码及企微appid
|
|
// 更新个微池个微二维码及企微appid
|
|
|
FosterwxMobile finalFosterwxMobile = fosterwxMobile;
|
|
FosterwxMobile finalFosterwxMobile = fosterwxMobile;
|
|
|
Corp corp = corpService.getById(fosterwxMobile.getWorkWxCorpId());
|
|
Corp corp = corpService.getById(fosterwxMobile.getWorkWxCorpId());
|
|
|
- fosterwxMobilePoolService.update(new FosterwxMobilePool() {{
|
|
|
|
|
- setCodeUrl(finalFosterwxMobile.getCodeUrl());
|
|
|
|
|
- setWxAppid(corp.getWxCorpid());
|
|
|
|
|
- setUpdateAt(LocalDateTime.now());
|
|
|
|
|
- }}, new QueryWrapper<FosterwxMobilePool>().eq("pool_index", fosterwxMobile.getMobileUnioCode()));
|
|
|
|
|
|
|
+ if (null != corp) {
|
|
|
|
|
+ fosterwxMobilePoolService.update(new FosterwxMobilePool() {{
|
|
|
|
|
+ setCodeUrl(finalFosterwxMobile.getCodeUrl());
|
|
|
|
|
+ setWxAppid(corp.getWxCorpid());
|
|
|
|
|
+ setUpdateAt(LocalDateTime.now());
|
|
|
|
|
+ }}, new QueryWrapper<FosterwxMobilePool>().eq("pool_index", fosterwxMobile.getMobileUnioCode()));
|
|
|
|
|
+ }
|
|
|
// 判断开始做任务时间是否设置了
|
|
// 判断开始做任务时间是否设置了
|
|
|
AjaxResult ajaxResult = null;
|
|
AjaxResult ajaxResult = null;
|
|
|
if (null != fosterwxMobile.getTaskStartAt() && oldVO.getTaskStartAt() == null) {
|
|
if (null != fosterwxMobile.getTaskStartAt() && oldVO.getTaskStartAt() == null) {
|
|
@@ -319,14 +321,14 @@ public class FosterwxMobileController extends BaseController<FosterwxMobile> {
|
|
|
feild.put(22, "workWxCorp|default");
|
|
feild.put(22, "workWxCorp|default");
|
|
|
feild.put(23, "workWxRegisterAt|default");
|
|
feild.put(23, "workWxRegisterAt|default");
|
|
|
List<Map<String, String>> row = new ArrayList<>();
|
|
List<Map<String, String>> row = new ArrayList<>();
|
|
|
- VoltaHandle<ArrayList<Map<String,String>>> voltaRes = Analysis.analysis(file, feild);
|
|
|
|
|
- if (voltaRes.getErr() != null){
|
|
|
|
|
|
|
+ VoltaHandle<ArrayList<Map<String, String>>> voltaRes = Analysis.analysis(file, feild);
|
|
|
|
|
+ if (voltaRes.getErr() != null) {
|
|
|
return AjaxResult.error(voltaRes.getErr());
|
|
return AjaxResult.error(voltaRes.getErr());
|
|
|
}
|
|
}
|
|
|
row = voltaRes.getData();
|
|
row = voltaRes.getData();
|
|
|
- try{
|
|
|
|
|
|
|
+ try {
|
|
|
VoltaHandle<Boolean> res = fosterwxMobileService.importData(row, authUser);
|
|
VoltaHandle<Boolean> res = fosterwxMobileService.importData(row, authUser);
|
|
|
- }catch (Exception e){
|
|
|
|
|
|
|
+ } catch (Exception e) {
|
|
|
return AjaxResult.error(e.getMessage());
|
|
return AjaxResult.error(e.getMessage());
|
|
|
}
|
|
}
|
|
|
return AjaxResult.success(HttpMsg.importSuccess);
|
|
return AjaxResult.success(HttpMsg.importSuccess);
|
|
@@ -438,8 +440,8 @@ public class FosterwxMobileController extends BaseController<FosterwxMobile> {
|
|
|
field.put(1, "codeUrl");
|
|
field.put(1, "codeUrl");
|
|
|
field.put(2, "wxAppid");
|
|
field.put(2, "wxAppid");
|
|
|
List<Map<String, String>> row;
|
|
List<Map<String, String>> row;
|
|
|
- VoltaHandle<ArrayList<Map<String,String>>> voltaRes = Analysis.analysis(file, field);
|
|
|
|
|
- if (voltaRes.getErr() != null){
|
|
|
|
|
|
|
+ VoltaHandle<ArrayList<Map<String, String>>> voltaRes = Analysis.analysis(file, field);
|
|
|
|
|
+ if (voltaRes.getErr() != null) {
|
|
|
return AjaxResult.error(voltaRes.getErr());
|
|
return AjaxResult.error(voltaRes.getErr());
|
|
|
}
|
|
}
|
|
|
row = voltaRes.getData();
|
|
row = voltaRes.getData();
|