|
|
|
@@ -71,62 +71,62 @@ public class WxProjectConfigServiceImpl implements WxProjectConfigService { |
|
|
|
@Override |
|
|
|
@Transactional |
|
|
|
public void initProjectConfig(Long id) { |
|
|
|
WxProjectConfig wxProjectConfig = wxProjectConfigMapper.selectById(id); |
|
|
|
if(wxProjectConfig!=null && wxProjectConfig.getDelType()<10000){ |
|
|
|
// 1. wx_mall 商场 |
|
|
|
String tenantId = wxMallService.wxMallInit(wxProjectConfig); |
|
|
|
// 2. wx_coupon_send_config |
|
|
|
wxCouponSendConfigService.wxCouponSendConfigInit(tenantId); |
|
|
|
// 3. wx_mall_building 商场楼座 |
|
|
|
wxMallBuildingService.wxMallBuildingInit(tenantId,wxProjectConfig.getMallBuilding()); |
|
|
|
//# --- 特殊商户号开通后,填写此数据 |
|
|
|
//# 5. wx_pay_account |
|
|
|
WxPayAccount wxPayAccount = wxPayAccountService.wxPayAccountInit(tenantId,wxProjectConfig); |
|
|
|
//# --- 特殊商户号开通后,填写此数据 |
|
|
|
//# 6. wx_pay_account_bill |
|
|
|
Long payBillId = wxPayAccountBillService.wxPayAccountInit(wxPayAccount); |
|
|
|
//# --- 小程序开通后,填写此数据,并设置域名及业务域名等 |
|
|
|
//# 7. wx_appinfo |
|
|
|
wxAppinfoService.wxAppinfoInit(tenantId,wxPayAccount.getId(),payBillId,wxProjectConfig); |
|
|
|
|
|
|
|
wxAuthorizerInfoService.wxAuthorizerInfoInit(tenantId,wxProjectConfig); |
|
|
|
|
|
|
|
wxAuthorizerInfoService.wxWeappExtSetInit(wxProjectConfig); |
|
|
|
// 9. mall_user_info |
|
|
|
// 10. mall_role |
|
|
|
// 11. mall_role_permission |
|
|
|
//# 12. mall_user_role |
|
|
|
Long mallUserInfoId = mallUserInfoService.MallUserInfoInit(tenantId, wxProjectConfig); |
|
|
|
//# 13. wx_msg_config |
|
|
|
wxMsgConfigService.WxMsgConfigInit(tenantId, wxProjectConfig); |
|
|
|
//# ETCP 设置完后再填写此数据 |
|
|
|
//# 14. wx_park |
|
|
|
wxParkService.wxParkInit(tenantId, wxProjectConfig); |
|
|
|
//# 积分成长值设置wx_score_rules |
|
|
|
wxScoreRulesService.wxScoreRulesInit(tenantId); |
|
|
|
//# 17. wx_template_msg |
|
|
|
//# 设置核销成功通知,核销失败通知 |
|
|
|
wxTemplateMsgService.wxTemplateMsgInit(tenantId); |
|
|
|
//# 18. wx_wiwide_info -- 迈外迪 服务商后台设置商户(点击获取商户bid),再找迈外迪初始化,收到激活邮件激活后,再在数据库中插入此数据 |
|
|
|
//# 数据格式如下 |
|
|
|
//# szld1086@iformall |
|
|
|
//# 1391054397 |
|
|
|
//# wuguoqiang@iformall.com |
|
|
|
|
|
|
|
// # 19. wx_question |
|
|
|
wxQuestionService.wxQuestionInit(tenantId); |
|
|
|
|
|
|
|
//# 20. wx_msg_validationcode_model, 数据重新一下 |
|
|
|
wxMsgValidationcodeModelService.wxMsgValidationcodeModelInit(tenantId, wxProjectConfig.getName(), wxProjectConfig.getImgUrlH()); |
|
|
|
//wx_flow_config |
|
|
|
wxFlowService.wxFlowConfigInit(tenantId); |
|
|
|
//初始化成功 删除标记 |
|
|
|
wxProjectConfig.setDelType(10000); |
|
|
|
wxProjectConfigMapper.updateById(wxProjectConfig); |
|
|
|
|
|
|
|
}else { |
|
|
|
logger.info("------数据已初始化"); |
|
|
|
} |
|
|
|
// WxProjectConfig wxProjectConfig = wxProjectConfigMapper.selectById(id); |
|
|
|
// if(wxProjectConfig!=null && wxProjectConfig.getDelType()<10000){ |
|
|
|
// // 1. wx_mall 商场 |
|
|
|
// String tenantId = wxMallService.wxMallInit(wxProjectConfig); |
|
|
|
// // 2. wx_coupon_send_config |
|
|
|
// wxCouponSendConfigService.wxCouponSendConfigInit(tenantId); |
|
|
|
// // 3. wx_mall_building 商场楼座 |
|
|
|
// wxMallBuildingService.wxMallBuildingInit(tenantId,wxProjectConfig.getMallBuilding()); |
|
|
|
// //# --- 特殊商户号开通后,填写此数据 |
|
|
|
// //# 5. wx_pay_account |
|
|
|
// WxPayAccount wxPayAccount = wxPayAccountService.wxPayAccountInit(tenantId,wxProjectConfig); |
|
|
|
// //# --- 特殊商户号开通后,填写此数据 |
|
|
|
// //# 6. wx_pay_account_bill |
|
|
|
// Long payBillId = wxPayAccountBillService.wxPayAccountInit(wxPayAccount); |
|
|
|
// //# --- 小程序开通后,填写此数据,并设置域名及业务域名等 |
|
|
|
// //# 7. wx_appinfo |
|
|
|
// wxAppinfoService.wxAppinfoInit(tenantId,wxPayAccount.getId(),payBillId,wxProjectConfig); |
|
|
|
// |
|
|
|
// wxAuthorizerInfoService.wxAuthorizerInfoInit(tenantId,wxProjectConfig); |
|
|
|
// |
|
|
|
// wxAuthorizerInfoService.wxWeappExtSetInit(wxProjectConfig); |
|
|
|
// // 9. mall_user_info |
|
|
|
// // 10. mall_role |
|
|
|
// // 11. mall_role_permission |
|
|
|
// //# 12. mall_user_role |
|
|
|
// Long mallUserInfoId = mallUserInfoService.MallUserInfoInit(tenantId, wxProjectConfig); |
|
|
|
// //# 13. wx_msg_config |
|
|
|
// wxMsgConfigService.WxMsgConfigInit(tenantId, wxProjectConfig); |
|
|
|
// //# ETCP 设置完后再填写此数据 |
|
|
|
// //# 14. wx_park |
|
|
|
// wxParkService.wxParkInit(tenantId, wxProjectConfig); |
|
|
|
// //# 积分成长值设置wx_score_rules |
|
|
|
// wxScoreRulesService.wxScoreRulesInit(tenantId); |
|
|
|
// //# 17. wx_template_msg |
|
|
|
// //# 设置核销成功通知,核销失败通知 |
|
|
|
// wxTemplateMsgService.wxTemplateMsgInit(tenantId); |
|
|
|
// //# 18. wx_wiwide_info -- 迈外迪 服务商后台设置商户(点击获取商户bid),再找迈外迪初始化,收到激活邮件激活后,再在数据库中插入此数据 |
|
|
|
// //# 数据格式如下 |
|
|
|
// //# szld1086@iformall |
|
|
|
// //# 1391054397 |
|
|
|
// //# wuguoqiang@iformall.com |
|
|
|
// |
|
|
|
// // # 19. wx_question |
|
|
|
// wxQuestionService.wxQuestionInit(tenantId); |
|
|
|
// |
|
|
|
// //# 20. wx_msg_validationcode_model, 数据重新一下 |
|
|
|
// wxMsgValidationcodeModelService.wxMsgValidationcodeModelInit(tenantId, wxProjectConfig.getName(), wxProjectConfig.getImgUrlH()); |
|
|
|
// //wx_flow_config |
|
|
|
// wxFlowService.wxFlowConfigInit(tenantId); |
|
|
|
// //初始化成功 删除标记 |
|
|
|
// wxProjectConfig.setDelType(10000); |
|
|
|
// wxProjectConfigMapper.updateById(wxProjectConfig); |
|
|
|
// |
|
|
|
// }else { |
|
|
|
// logger.info("------数据已初始化"); |
|
|
|
// } |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
@@ -197,7 +197,7 @@ public class WxProjectConfigServiceImpl implements WxProjectConfigService { |
|
|
|
wxPayAccountBill.setMchId(wxPayAccount.getMchId()); |
|
|
|
wxPayAccountBill.setSubMchId(wxPayAccount.getSubMchId()); |
|
|
|
wxPayAccountBill.setApiKey(wxPayAccount.getApiKey()); |
|
|
|
wxPayAccountBill.setNotifyUrl(wxPayAccount.getNotifyUrl()); |
|
|
|
wxPayAccountBill.setNotifyUrl(wxPayAccount.getNotifyUrl().replaceAll("/wxPay/","/wxPayBill/")); |
|
|
|
wxPayAccountBill.setCertPath(wxPayAccount.getCertPath()); |
|
|
|
wxPayAccountBill.setType(wxPayAccount.getType()); |
|
|
|
wxPayAccountBill.setShare(!(wxPayAccount.getShare() == 0)); |
|
|
|
@@ -216,6 +216,7 @@ public class WxProjectConfigServiceImpl implements WxProjectConfigService { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Transactional |
|
|
|
public void initUserInfo(MallUserInfo userInfo) { |
|
|
|
|