|
|
@@ -3502,4 +3502,36 @@ public class Task {
|
|
|
log.info("飞书链接创建失败已记录,videoId={}, link={}, error={}", videoId, link, errorInfo);
|
|
|
}
|
|
|
|
|
|
+ public void checkQwCompanyAppId(){
|
|
|
+ QwCompany qwCompany = qwCompanyService.selectQwCompanyByCorpId("ww7aa878854aaf6ca9");
|
|
|
+ if (qwCompany == null) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ if (qwCompany.getMiniAppId() == null) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+
|
|
|
+ try {
|
|
|
+ final WxMaService wxMaService = WxMaConfiguration.getMaService(qwCompany.getMiniAppId());
|
|
|
+ String scene="collectionId";
|
|
|
+ wxMaService.getQrcodeService().createWxaCodeUnlimitBytes(
|
|
|
+ scene,
|
|
|
+ "pages/home/index",
|
|
|
+ true,
|
|
|
+ "release",//trial - 体验版 release - 正式版 develop - 开发版
|
|
|
+ 430,
|
|
|
+ true,
|
|
|
+ null,
|
|
|
+ false);
|
|
|
+ logger.info("小程序未封禁,小程序APPID:{}",qwCompany.getMiniAppId());
|
|
|
+ } catch (WxErrorException e) {
|
|
|
+ int errorCode = e.getError().getErrorCode();
|
|
|
+ if (errorCode == 50002) {
|
|
|
+ logger.info("小程序被封禁,小程序APPID:{}",qwCompany.getMiniAppId());
|
|
|
+ // 50002 业务逻辑处理 封禁后清空全部关联的小程序
|
|
|
+ qwCompanyMapper.updateQwCompanyMiniAppIdSetNull();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
}
|