|
@ -121,7 +121,6 @@ public class DeptMaCodeServiceImpl extends BaseServiceImpl<DeptMaCodeDao, DeptMa |
|
|
if (CollUtil.isEmpty(gridIdList)) { |
|
|
if (CollUtil.isEmpty(gridIdList)) { |
|
|
return new Result(); |
|
|
return new Result(); |
|
|
} |
|
|
} |
|
|
String scenePrefix = "gid="; |
|
|
|
|
|
String page = "pages/index/index"; |
|
|
String page = "pages/index/index"; |
|
|
|
|
|
|
|
|
Result<String> ossResult; |
|
|
Result<String> ossResult; |
|
@ -132,7 +131,7 @@ public class DeptMaCodeServiceImpl extends BaseServiceImpl<DeptMaCodeDao, DeptMa |
|
|
WxMaQrcodeService qrcodeService = wxMaService.getQrcodeService(); |
|
|
WxMaQrcodeService qrcodeService = wxMaService.getQrcodeService(); |
|
|
for (Long gridId : gridIdList) { |
|
|
for (Long gridId : gridIdList) { |
|
|
try { |
|
|
try { |
|
|
wxaCodeUnlimit = qrcodeService.createWxaCodeUnlimit(scenePrefix + gridId, page); |
|
|
wxaCodeUnlimit = qrcodeService.createWxaCodeUnlimit(String.valueOf(gridId), page); |
|
|
} catch (WxErrorException e) { |
|
|
} catch (WxErrorException e) { |
|
|
log.error("->initDeptMaCode::createWxaCodeUnlimit error::deptId={}", gridId); |
|
|
log.error("->initDeptMaCode::createWxaCodeUnlimit error::deptId={}", gridId); |
|
|
continue; |
|
|
continue; |
|
@ -157,7 +156,7 @@ public class DeptMaCodeServiceImpl extends BaseServiceImpl<DeptMaCodeDao, DeptMa |
|
|
public Result createDeptMaCode(String gridId) { |
|
|
public Result createDeptMaCode(String gridId) { |
|
|
File wxaCodeUnlimit; |
|
|
File wxaCodeUnlimit; |
|
|
try { |
|
|
try { |
|
|
wxaCodeUnlimit = wxMaService.getQrcodeService().createWxaCodeUnlimit("gid=" + gridId, "pages/index/index"); |
|
|
wxaCodeUnlimit = wxMaService.getQrcodeService().createWxaCodeUnlimit(gridId, "pages/index/index"); |
|
|
} catch (WxErrorException e) { |
|
|
} catch (WxErrorException e) { |
|
|
return new Result().error("请求微信接口失败"); |
|
|
return new Result().error("请求微信接口失败"); |
|
|
} |
|
|
} |
|
|