| @@ -236,7 +236,7 @@ public class WxBillOtherDepositServiceImpl implements WxBillOtherDepositService | |||
| wxBillAction.setUserId(user.getId()); | |||
| wxBillAction.setUserName(user.getName()); | |||
| wxBillAction.setPhone(user.getPhone()); | |||
| wxBillAction.setTenantId(wxBillOtherDeposit.getTenantId()); | |||
| wxBillAction.updateTenantInfo(user); | |||
| wxBillAction.setPayDate(wxBillOtherDeposit.getPayDate()); | |||
| try { | |||
| wxBillActionService.save(wxBillAction); | |||
| @@ -156,7 +156,7 @@ public class WxBillOtherServiceImpl implements WxBillOtherService { | |||
| if (record.getId() == null) { | |||
| logger.info("新增其他押金账单"); | |||
| WxBillOther otherQuery = new WxBillOther(); | |||
| otherQuery.setTenantId(record.getTenantId()); | |||
| otherQuery.updateTenantInfo(user); | |||
| otherQuery.setMerchantId(record.getMerchantId()); | |||
| otherQuery.setReceiveDate(record.getReceiveDate()); | |||
| otherQuery.setName(record.getName()); | |||
| @@ -237,7 +237,7 @@ public class WxBillOtherServiceImpl implements WxBillOtherService { | |||
| wxBillAction.setUserId(user.getId()); | |||
| wxBillAction.setUserName(user.getName()); | |||
| wxBillAction.setPhone(user.getPhone()); | |||
| wxBillAction.setTenantId(wxBillOther.getTenantId()); | |||
| wxBillAction.updateTenantInfo(user); | |||
| wxBillAction.setPayDate(wxBillOther.getPayDate()); | |||
| try { | |||
| wxBillActionService.save(wxBillAction); | |||
| @@ -183,7 +183,7 @@ public class WxBillPropertyDepositServiceImpl implements WxBillPropertyDepositSe | |||
| wxBillAction.setUserId(user.getId()); | |||
| wxBillAction.setUserName(user.getName()); | |||
| wxBillAction.setPhone(user.getPhone()); | |||
| wxBillAction.setTenantId(wxBillDeposit.getTenantId()); | |||
| wxBillAction.updateTenantInfo(user); | |||
| wxBillAction.setPayDate(wxBillDeposit.getPayDate()); | |||
| try { | |||
| wxBillActionService.save(wxBillAction); | |||
| @@ -247,7 +247,7 @@ public class WxBillPropertyDepositServiceImpl implements WxBillPropertyDepositSe | |||
| wxBillAction.setUserId(user.getId()); | |||
| wxBillAction.setUserName(user.getName()); | |||
| wxBillAction.setPhone(user.getPhone()); | |||
| wxBillAction.setTenantId(wxBillDeposit.getTenantId()); | |||
| wxBillAction.updateTenantInfo(user); | |||
| try { | |||
| wxBillActionService.save(wxBillAction); | |||
| } catch (Exception e) { | |||
| @@ -230,7 +230,7 @@ public class WxBillPropertyServiceImpl implements WxBillPropertyService { | |||
| wxBillAction.setUserId(user.getId()); | |||
| wxBillAction.setUserName(user.getName()); | |||
| wxBillAction.setPhone(user.getPhone()); | |||
| wxBillAction.setTenantId(property.getTenantId()); | |||
| wxBillAction.updateTenantInfo(user); | |||
| wxBillAction.setPayDate(property.getPayDate()); | |||
| try { | |||
| wxBillActionService.save(wxBillAction); | |||
| @@ -109,7 +109,7 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||
| //加载账单列表 | |||
| WxBillSettleBill wxBillSettleBill = new WxBillSettleBill(); | |||
| wxBillSettleBill.setTenantId(billSettle.getTenantId()); | |||
| wxBillSettleBill.updateTenantInfo(merchant); | |||
| wxBillSettleBill.setSettleId(billSettle.getId()); | |||
| wxBillSettleBill.setType(EnumSettleBillType.R.getCode()); | |||
| billSettle.setReceiveBillIds(wxBillSettleBillMapper.findBySettleId(wxBillSettleBill)); | |||
| @@ -118,7 +118,7 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||
| //加载清算历史 | |||
| WxBillSettleRecord wxBillSettleRecord = new WxBillSettleRecord(); | |||
| wxBillSettleRecord.setTenantId(billSettle.getTenantId()); | |||
| wxBillSettleRecord.updateTenantInfo(merchant); | |||
| wxBillSettleRecord.setSettleId(billSettle.getId()); | |||
| billSettle.setSettleRecordList(wxBillSettleRecordMapper.findList(wxBillSettleRecord)); | |||
| @@ -497,14 +497,14 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||
| for (WxBillSettleBill bill:record.getReceiveBillIds()) { | |||
| bill.setId(idWorker.nextId()); | |||
| bill.setSettleId(record.getId()); | |||
| bill.setTenantId(record.getTenantId()); | |||
| bill.updateTenantInfo(userInfo); | |||
| bill.setType(EnumSettleBillType.R.getCode()); | |||
| wxBillSettleBillMapper.insert(bill); | |||
| } | |||
| for (WxBillSettleBill bill:record.getPayBillIds()) { | |||
| bill.setId(idWorker.nextId()); | |||
| bill.setSettleId(record.getId()); | |||
| bill.setTenantId(record.getTenantId()); | |||
| bill.updateTenantInfo(userInfo); | |||
| bill.setType(EnumSettleBillType.P.getCode()); | |||
| wxBillSettleBillMapper.insert(bill); | |||
| } | |||
| @@ -601,21 +601,21 @@ public class WxCUserBasicInfoServiceImpl implements WxCUserBasicInfoService { | |||
| public void updateObj(WxCUserBasicInfo record, WxCUser user) { | |||
| // 1. update c_user_tags | |||
| CUserTagNewIdVo userTagVo = new CUserTagNewIdVo(); | |||
| userTagVo.setTenantId(record.getTenantId()); | |||
| userTagVo.updateTenantInfo(record); | |||
| userTagVo.setUserId(record.getId()); | |||
| userTagVo.setNewUserId(user.getId()); | |||
| wxCUserTagsMapper.updateNewId(userTagVo); | |||
| // 2. update score history | |||
| WxScoreHistoryNewIdVo scoreHistoryNewIdVo = new WxScoreHistoryNewIdVo(); | |||
| scoreHistoryNewIdVo.setTenantId(record.getTenantId()); | |||
| scoreHistoryNewIdVo.updateTenantInfo(record); | |||
| scoreHistoryNewIdVo.setCUserId(record.getId()); | |||
| scoreHistoryNewIdVo.setNewUserId(user.getId()); | |||
| scoreHistoryMapper.updateNewId(scoreHistoryNewIdVo); | |||
| // 3. update credit history | |||
| WxCreditHistoryNewIdVo creditHistoryNewIdVo = new WxCreditHistoryNewIdVo(); | |||
| creditHistoryNewIdVo.setTenantId(record.getTenantId()); | |||
| creditHistoryNewIdVo.updateTenantInfo(record); | |||
| creditHistoryNewIdVo.setCUserId(record.getId()); | |||
| creditHistoryNewIdVo.setNewUserId(user.getId()); | |||
| creditHistoryMapper.updateNewId(creditHistoryNewIdVo); | |||
| @@ -107,7 +107,7 @@ public class WxCUserServiceImpl implements WxCUserService { | |||
| public int saveOrUpdateMpUser(WxMpUser mpUser, WxAuthorizerInfo authorizerInfo) { | |||
| // 1. check user exist | |||
| WxCUser userQ = new WxCUser(); | |||
| userQ.setTenantId(authorizerInfo.getTenantId()); | |||
| userQ.updateTenantInfo(authorizerInfo); | |||
| boolean bHaveUnionId = false; | |||
| if(StringUtils.isNotBlank(mpUser.getUnionId())) { | |||
| userQ.setUnionId(mpUser.getUnionId()); | |||
| @@ -226,7 +226,7 @@ public class WxCUserServiceImpl implements WxCUserService { | |||
| public void actionMsgAfterLogin(WxCUser user, Boolean findByUnionId) { | |||
| FmInsideCLoginMsg loginMsg = new FmInsideCLoginMsg(); | |||
| loginMsg.setMsgType(EnumMsgRecordType.INSIDE_C_LOGIN.getCode()); | |||
| loginMsg.setTenantId(user.getTenantId()); | |||
| loginMsg.updateTenantInfo(user); | |||
| loginMsg.setCUserId(user.getId()); | |||
| loginMsg.setFindByUnionId(findByUnionId); | |||
| mqBaseProducer.sendMessage(loginMsg, EnumMsgMqTopic.DEFAULT.getCode(), EnumMsgMqTag.DEFAULT.getCode(), EnumMsgMqKey.DEFAULT.getCode()); | |||
| @@ -300,7 +300,7 @@ public class WxCUserServiceImpl implements WxCUserService { | |||
| public WxCreditHistory addCredit(WxCUser user, EnumScoreType enumScoreType) { | |||
| WxCreditHistory wxCreditHistory = new WxCreditHistory(); | |||
| wxCreditHistory.setCUserId(user.getId()); | |||
| wxCreditHistory.setTenantId(user.getTenantId()); | |||
| wxCreditHistory.updateTenantInfo(user); | |||
| wxCreditHistory.setCreateDate(new Date()); | |||
| wxCreditHistory.setCreditType(enumScoreType.getCode()); | |||
| wxCreditHistory.setOperatorType(EnumUserType.CUSER.getCode()); | |||
| @@ -115,7 +115,7 @@ public class WxCUserTagsServiceImpl implements WxCUserTagsService { | |||
| return null; | |||
| WxCUserTags record = new WxCUserTags(); | |||
| record.setUserId(user.getId()); | |||
| record.setTenantId(user.getTenantId()); | |||
| record.updateTenantInfo(user); | |||
| List<WxCUserTags> cUserTagsList = wxCUserTagsMapper.findList(record); | |||
| if (cUserTagsList.size() > 0) { | |||
| record.setId(cUserTagsList.get(0).getId()); | |||
| @@ -165,7 +165,7 @@ public class WxCUserTagsServiceImpl implements WxCUserTagsService { | |||
| return null; | |||
| WxCUserTags record = new WxCUserTags(); | |||
| record.setUserId(user.getId()); | |||
| record.setTenantId(user.getTenantId()); | |||
| record.updateTenantInfo(user); | |||
| List<WxCUserTags> cUserTagsList = wxCUserTagsMapper.findList(record); | |||
| if (cUserTagsList.size() > 0) { | |||
| record.setId(cUserTagsList.get(0).getId()); | |||
| @@ -183,7 +183,7 @@ public class WxCampaignServiceImpl implements WxCampaignService { | |||
| public void delBatch(WxCampaign record) { | |||
| // couponChannel 下架 | |||
| WxCouponChannel wxCouponChannelQ = new WxCouponChannel(); | |||
| wxCouponChannelQ.setTenantId(record.getTenantId()); | |||
| wxCouponChannelQ.updateTenantInfo(record); | |||
| wxCouponChannelQ.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_CAMPAIN.getCode()); | |||
| wxCouponChannelQ.setSubTargetId(record.getId()); | |||
| wxCouponChannelQ.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| @@ -200,7 +200,7 @@ public class WxCampaignServiceImpl implements WxCampaignService { | |||
| public void addOrUpdateBatch(List<String> ids, WxCampaign record) { | |||
| // 获取已上架的CouponChannel | |||
| WxCouponChannel wxCouponChannelQ = new WxCouponChannel(); | |||
| wxCouponChannelQ.setTenantId(record.getTenantId()); | |||
| wxCouponChannelQ.updateTenantInfo(record); | |||
| wxCouponChannelQ.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_CAMPAIN.getCode()); | |||
| wxCouponChannelQ.setSubTargetId(record.getId()); | |||
| wxCouponChannelQ.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| @@ -620,7 +620,7 @@ public class WxCardSpendServiceImpl implements WxCardSpendService { | |||
| // 3. get pay account | |||
| WxPayAccount payAccount = null; | |||
| WxPayAccount payAccountQ = new WxPayAccount(); | |||
| payAccountQ.setTenantId(record.getTenantId()); | |||
| payAccountQ.updateTenantInfo(record); | |||
| try { | |||
| payAccount = payAccountMapper.selectOne(new QueryWrapper(payAccountQ)); | |||
| } catch (Exception e) { | |||
| @@ -717,7 +717,7 @@ public class WxCardSpendServiceImpl implements WxCardSpendService { | |||
| // 3. get pay account | |||
| WxPayAccount payAccount = null; | |||
| WxPayAccount payAccountQ = new WxPayAccount(); | |||
| payAccountQ.setTenantId(record.getTenantId()); | |||
| payAccountQ.updateTenantInfo(record); | |||
| try { | |||
| payAccount = payAccountMapper.selectOne(new QueryWrapper(payAccountQ)); | |||
| } catch (Exception e) { | |||
| @@ -189,9 +189,9 @@ public class WxCouponInjectServiceImpl implements WxCouponInjectService { | |||
| } | |||
| WxMsg wxmsg=new WxMsg(); | |||
| wxmsg.setTenantId(record.getTenantId()); | |||
| wxmsg.updateTenantInfo(record); | |||
| WxMsgConfig wxMsgConfig = new WxMsgConfig(); | |||
| wxMsgConfig.setTenantId(wxmsg.getTenantId()); | |||
| wxMsgConfig.updateTenantInfo(record); | |||
| wxMsgConfig = wxMsgConfigService.findObject(wxMsgConfig); | |||
| if (wxMsgConfig==null){ | |||
| return new ResultData(ErrorCode.MSG_SERVER_NOT_FIND); | |||
| @@ -390,7 +390,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| creditHistory.setOperatorId(bUser.getId()); | |||
| creditHistory.setCUserId(couponOrder.getcUserId()); | |||
| creditHistory.setCreateDate(new Date()); | |||
| creditHistory.setTenantId(couponOrder.getTenantId()); | |||
| creditHistory.updateTenantInfo(couponOrder); | |||
| creditHistory.setCreditType(EnumScoreType.CONSUMPTION.getCode()); | |||
| creditHistory.setCouponId(wxCoupon.getId()); | |||
| creditHistory.setBusinessId(wxCoupon.getBusiness()); | |||
| @@ -446,7 +446,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| public void actionAfterVerify(WxCouponOrder couponOrder, WxMerchantBUser bUser) { | |||
| WxPayAccount wxPayAccountQuery = new WxPayAccount(); | |||
| wxPayAccountQuery.setTenantId(couponOrder.getTenantId()); | |||
| wxPayAccountQuery.updateTenantInfo(couponOrder); | |||
| WxPayAccount wxPayAccount = wxPayAccountMapper.selectOne(new QueryWrapper<>(wxPayAccountQuery)); | |||
| if (wxPayAccount != null && wxPayAccount.getShare().equals(EnumPayShare.NO.getCode())) { | |||
| try { | |||
| @@ -509,7 +509,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| final IdWorker idWorker = IdWorker.get(); | |||
| Date curDate = new Date(); | |||
| merchantSubsidy.setId(idWorker.nextId()); | |||
| merchantSubsidy.setTenantId(couponOrder.getTenantId()); | |||
| merchantSubsidy.updateTenantInfo(couponOrder); | |||
| merchantSubsidy.setOrderId(couponOrder.getOrderId()); | |||
| merchantSubsidy.setOrderType(EnumOrderType.COUPON.getCode()); | |||
| merchantSubsidy.setMerchantId(merchantId); | |||
| @@ -533,7 +533,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| // 微信分账 | |||
| try { | |||
| WxPayOrder wxPayOrder = new WxPayOrder(); | |||
| wxPayOrder.setTenantId(couponOrder.getTenantId()); | |||
| wxPayOrder.updateTenantInfo(couponOrder); | |||
| wxPayOrder.setOrderId(couponOrder.getOrderId()); | |||
| wxPayOrder.setPayOrderStatus(EnumPayStatus.PAY_STATUS_SUCCESS.getCode()); | |||
| wxPayOrder = wxPayOrderMapper.selectOne(new QueryWrapper(wxPayOrder)); | |||
| @@ -547,7 +547,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| wxSharingOrderDto.setOrderId(wxPayOrder.getId()); | |||
| wxSharingOrderDto.setPayTimeStart(wxPayOrder.getPayTimeStart()); | |||
| wxSharingOrderDto.setPayTimeEnd(wxPayOrder.getPayTimeEnd()); | |||
| wxSharingOrderDto.setTenantId(wxPayOrder.getTenantId()); | |||
| wxSharingOrderDto.updateTenantInfo(wxPayOrder); | |||
| wxSharingOrderDto.setTransactionId(wxPayOrder.getTransactionId()); | |||
| wxSharingOrderDto.setShareAmount(wxPayOrder.getShareAmount()); | |||
| wxProfitSharingOrderService.createSharingOrder(wxSharingOrderDto); | |||
| @@ -613,7 +613,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| WxMerchantSubsidy merchantSubsidy = new WxMerchantSubsidy(); | |||
| merchantSubsidy.setId(idWorker.nextId()); | |||
| merchantSubsidy.setTenantId(couponOrder.getTenantId()); | |||
| merchantSubsidy.updateTenantInfo(couponOrder); | |||
| merchantSubsidy.setOrderId(couponOrder.getOrderId()); | |||
| merchantSubsidy.setOrderType(EnumOrderType.COUPON.getCode()); | |||
| merchantSubsidy.setMerchantId(merchantId); | |||
| @@ -746,7 +746,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| // formId为空,获取prepayId | |||
| WxPayOrder payOrder = null; | |||
| WxPayOrder payOrderQ = new WxPayOrder(); | |||
| payOrderQ.setTenantId(couponOrder.getTenantId()); | |||
| payOrderQ.updateTenantInfo(couponOrder); | |||
| payOrderQ.setOrderId(order.getId()); | |||
| payOrderQ.setPayOrderStatus(EnumPayStatus.PAY_STATUS_SUCCESS.getCode()); | |||
| List<WxPayOrder> payList = wxPayOrderMapper.selectList(new QueryWrapper(payOrderQ)); | |||
| @@ -779,7 +779,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| * 检查 小程序模板消息是否超限 | |||
| */ | |||
| WxMsgLimit msgLimit = new WxMsgLimit(); | |||
| msgLimit.setTenantId(user.getTenantId()); | |||
| msgLimit.updateTenantInfo(merchant); | |||
| msgLimit.setType(formType); | |||
| msgLimit.setLimitId(formId); | |||
| if (wxMsgLimitService.checkIsLimit(msgLimit)) { | |||
| @@ -813,7 +813,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| mpAppMsg.setTo(user.getMpOpenId()); | |||
| mpAppMsg.setMiniAppId(user.getAppId()); | |||
| mpAppMsg.setMiniPagePath(gotopage); | |||
| mpAppMsg.setTenantId(couponOrder.getTenantId()); | |||
| mpAppMsg.updateTenantInfo(couponOrder); | |||
| mpAppMsg.setTemplateType(EnumTemplateType.VERIFY_RESULT.getCode()); | |||
| mpAppMsg.setDataList(Lists.newArrayList( | |||
| merchant.getName(), | |||
| @@ -834,7 +834,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| private void doVerifyAppUniformMsg(WxCouponOrder couponOrder, WxCoupon coupon, WxMerchant merchant, WxCUser user, SimpleDateFormat dateFormat, String gotopage) { | |||
| WxAuthorizerInfo authQ = new WxAuthorizerInfo(); | |||
| authQ.setAuthorizerAppid(user.getAppId()); | |||
| authQ.setTenantId(user.getTenantId()); | |||
| authQ.updateTenantInfo(merchant); | |||
| WxAuthorizerInfo weappInfo = authorizerInfoMapper.findMp(authQ); | |||
| if (weappInfo != null) { | |||
| AppUniformMsg appUniformMsg = new AppUniformMsg(); | |||
| @@ -875,7 +875,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| smartAppMsg = new SmartAppMsg(); | |||
| smartAppMsg.setMsgType(EnumMsgRecordType.SMART_APP.getCode()); | |||
| smartAppMsg.setAppId(user.getAppId()); | |||
| smartAppMsg.setTenantId(couponOrder.getTenantId()); | |||
| smartAppMsg.updateTenantInfo(couponOrder); | |||
| smartAppMsg.setTemplateType(EnumTemplateType.VERIFY_SUCCESS.getCode()); | |||
| smartAppMsg.setGotopage(gotopage); | |||
| smartAppMsg.setTo(user.getOpenId()); | |||
| @@ -910,7 +910,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| smartAppMsg = new SmartAppMsg(); | |||
| smartAppMsg.setMsgType(EnumMsgRecordType.SMART_APP.getCode()); | |||
| smartAppMsg.setAppId(user.getAppId()); | |||
| smartAppMsg.setTenantId(couponOrder.getTenantId()); | |||
| smartAppMsg.updateTenantInfo(couponOrder); | |||
| smartAppMsg.setTemplateType(EnumTemplateType.VERIFY_FAIL.getCode()); | |||
| smartAppMsg.setGotopage(gotopage); | |||
| smartAppMsg.setTo(user.getOpenId()); | |||
| @@ -1233,7 +1233,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| // 1. insert posOrderId | |||
| PosCouponOrderVerify posCouponOrderVerify = new PosCouponOrderVerify(); | |||
| posCouponOrderVerify.setTenantId(couponOrder.getTenantId()); | |||
| posCouponOrderVerify.updateTenantInfo(couponOrder); | |||
| posCouponOrderVerify.setCouponOrderId(couponOrder.getId()); | |||
| posCouponOrderVerify.setPosOrderId(microOrder.getId()); | |||
| posCouponOrderVerify.setOrderFrom(EnumOrderFrom.INSIDE.getCode()); | |||
| @@ -1267,7 +1267,7 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||
| final IdWorker idWorker = IdWorker.get(); | |||
| Long id = idWorker.nextId(); | |||
| setId(id); | |||
| setTenantId(microOrder.getTenantId()); | |||
| updateTenantInfo(microOrder); | |||
| setCUserId(microOrder.getCUserId()); | |||
| setOrderId(microOrder.getId()); | |||
| setCreateTime(curDate); | |||
| @@ -443,7 +443,7 @@ public class WxCouponSendServiceImpl implements WxCouponSendService { | |||
| user.getMpSubscribe().equals(EnumUserIsSubscribe.YES.getCode())) { | |||
| // 检查是否超限 | |||
| WxMsgLimit msgLimit = new WxMsgLimit(); | |||
| msgLimit.setTenantId(user.getTenantId()); | |||
| msgLimit.updateTenantInfo(couponOrder); | |||
| msgLimit.setType(EnumMsgLimitType.WXCHAT_OPENID_SEND.getCode()); | |||
| msgLimit.setLimitId(user.getMpOpenId()); | |||
| if (wxMsgLimitService.checkIsLimit(msgLimit)) { | |||
| @@ -468,7 +468,7 @@ public class WxCouponSendServiceImpl implements WxCouponSendService { | |||
| mpAppMsg.setTo(user.getMpOpenId()); | |||
| mpAppMsg.setMiniAppId(user.getAppId()); | |||
| mpAppMsg.setMiniPagePath(gotopage); | |||
| mpAppMsg.setTenantId(couponOrder.getTenantId()); | |||
| mpAppMsg.updateTenantInfo(couponOrder); | |||
| mpAppMsg.setTemplateType(EnumTemplateType.GIFT_MESSAGE.getCode()); | |||
| mpAppMsg.setDataList(Lists.newArrayList( | |||
| user.getNickName(), | |||
| @@ -492,7 +492,7 @@ public class WxCouponSendServiceImpl implements WxCouponSendService { | |||
| // 8. 微信小程序-统一消息 | |||
| // 检查是否超限 | |||
| WxMsgLimit msgLimit = new WxMsgLimit(); | |||
| msgLimit.setTenantId(user.getTenantId()); | |||
| msgLimit.updateTenantInfo(user); | |||
| msgLimit.setType(EnumMsgLimitType.WEAPP_OPENID_SEND.getCode()); | |||
| msgLimit.setLimitId(user.getOpenId()); | |||
| if (wxMsgLimitService.checkIsLimit(msgLimit)) { | |||
| @@ -502,7 +502,7 @@ public class WxCouponSendServiceImpl implements WxCouponSendService { | |||
| // 获取小程序关联的服务号 | |||
| WxAuthorizerInfo authQ = new WxAuthorizerInfo(); | |||
| authQ.setAuthorizerAppid(user.getAppId()); | |||
| authQ.setTenantId(user.getTenantId()); | |||
| authQ.updateTenantInfo(user); | |||
| WxAuthorizerInfo weappInfo = authorizerInfoMapper.findMp(authQ); | |||
| if (weappInfo != null) { | |||
| AppUniformMsg appUniformMsg = new AppUniformMsg(); | |||
| @@ -108,7 +108,7 @@ import java.util.stream.Collectors; | |||
| List<Long> ids = wxCouponList.stream().map(p -> p.getId()).collect(Collectors.toList()); | |||
| WxCouponChannel wxCouponChannel = new WxCouponChannel(); | |||
| wxCouponChannel.setTenantId(wxCoupon.getTenantId()); | |||
| wxCouponChannel.updateTenantInfo(wxCoupon); | |||
| wxCouponChannel.setCouponIds(ids); | |||
| wxCouponChannel.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| //上架状态 | |||
| @@ -436,7 +436,7 @@ public class WxCreditHistoryServiceImpl implements WxCreditHistoryService { | |||
| private int checkCompleteInfoScoreCount(WxCUser cUser) { | |||
| WxCreditHistory wxCreditHistory = new WxCreditHistory(); | |||
| wxCreditHistory.setTenantId(cUser.getTenantId()); | |||
| wxCreditHistory.updateTenantInfo(cUser); | |||
| wxCreditHistory.setCUserId(cUser.getId()); | |||
| wxCreditHistory.setCreditType(EnumScoreType.COMPLETE_INFO.getCode()); | |||
| return wxCreditHistoryMapper.countList(wxCreditHistory); | |||
| @@ -53,7 +53,7 @@ public class WxDateAmountRecordServiceImpl implements WxDateAmountRecordService | |||
| WxDateAmountRecord record = new WxDateAmountRecord(); | |||
| record.setDate(amount.getDate()); | |||
| record.setTenantId(amount.getTenantId()); | |||
| record.updateTenantInfo(amount); | |||
| record.setMerchantId(amount.getMerchantId()); | |||
| record.setType(amount.getType()); | |||
| @@ -51,7 +51,7 @@ public class WxFloatingLayerServiceImpl implements WxFloatingLayerService { | |||
| return new ResultData(ErrorCode.SYS_PARAMETER_NOT_NULL.getCode(), "小程序跳转路径不能为空"); | |||
| } | |||
| WxFloatingLayer wxFloatingLayerQuery = new WxFloatingLayer(); | |||
| wxFloatingLayerQuery.setTenantId(wxFloatingLayer.getTenantId()); | |||
| wxFloatingLayerQuery.updateTenantInfo(wxFloatingLayer); | |||
| wxFloatingLayerQuery.setStatus(wxFloatingLayer.getStatus()); | |||
| Integer integer = wxFloatingLayerMapper.selectCount(new QueryWrapper<>(wxFloatingLayerQuery)); | |||
| if (integer > 0) { | |||
| @@ -293,7 +293,7 @@ public class WxFlowServiceImpl implements WxFlowService { | |||
| wxCoupon.setRemainInventory(remainInventory); | |||
| wxCoupon.setType(type); | |||
| wxCoupon.setValidType(validType); | |||
| wxCoupon.setTenantId(wxCoupon.getTenantId()); | |||
| wxCoupon.updateTenantInfo(wxCoupon); | |||
| wxCouponService.updateCouponStockAndEndTime(wxCoupon); | |||
| } | |||
| }else if(EnumCouponAppType.CANCLE.getCode().equals(operateType)){ | |||
| @@ -1516,7 +1516,7 @@ public class WxFlowServiceImpl implements WxFlowService { | |||
| @Override | |||
| public ResultData delModel(WxFlowModel wxFlowModel) { | |||
| WxFlowConfig query = new WxFlowConfig(); | |||
| query.setTenantId(wxFlowModel.getTenantId()); | |||
| query.updateTenantInfo(wxFlowModel); | |||
| query.setModelId(wxFlowModel.getId()); | |||
| if(CollectionUtils.isNotEmpty(wxFlowConfigMapper.findList(query))){ | |||
| return new ResultData(Result.ERROR, "该流程模板在使用中,须先停用正在\n" + | |||
| @@ -121,7 +121,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| final IdWorker idWorker = IdWorker.get(); | |||
| WxGameActionLog wxGameActionLog = new WxGameActionLog(); | |||
| wxGameActionLog.setUserId(userId); | |||
| wxGameActionLog.setTenantId(wxCouponOrder.getTenantId()); | |||
| wxGameActionLog.updateTenantInfo(wxCouponOrder); | |||
| wxGameActionLog.setGameId(gameId); | |||
| wxGameActionLog.setCouponOrderId(wxCouponOrder.getOrderId()); | |||
| wxGameActionLog.setId(idWorker.nextId()); | |||
| @@ -138,7 +138,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| return new ResultData(ErrorCode.GAME_NOT_FOUND); | |||
| WxGameActionLog wxGameActionLog = new WxGameActionLog(); | |||
| wxGameActionLog.setTenantId(wxGame.getTenantId()); | |||
| wxGameActionLog.updateTenantInfo(wxGame); | |||
| wxGameActionLog.setUserId(userId); | |||
| wxGameActionLog.setGameId(gameId); | |||
| @@ -163,7 +163,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| private List<Object> getParams(WxGame record) { | |||
| // 获取已上架的CouponChannel | |||
| WxCouponChannel couponChannelQ = new WxCouponChannel(); | |||
| couponChannelQ.setTenantId(record.getTenantId()); | |||
| couponChannelQ.updateTenantInfo(record); | |||
| couponChannelQ.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_GAME.getCode()); | |||
| couponChannelQ.setSubTargetId(record.getId()); | |||
| couponChannelQ.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| @@ -223,7 +223,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| private void delCouponChannelBatch(WxGame record) { | |||
| // couponChannel 下架 | |||
| WxCouponChannel wxCouponChannelQ = new WxCouponChannel(); | |||
| wxCouponChannelQ.setTenantId(record.getTenantId()); | |||
| wxCouponChannelQ.updateTenantInfo(record); | |||
| wxCouponChannelQ.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_GAME.getCode()); | |||
| wxCouponChannelQ.setSubTargetId(record.getId()); | |||
| wxCouponChannelQ.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| @@ -240,7 +240,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| private void addOrUpdateCouponChannelBatch(List couponIds, WxGame record) { | |||
| // 获取已上架的CouponChannel | |||
| WxCouponChannel wxCouponChannelQ = new WxCouponChannel(); | |||
| wxCouponChannelQ.setTenantId(record.getTenantId()); | |||
| wxCouponChannelQ.updateTenantInfo(record); | |||
| wxCouponChannelQ.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_GAME.getCode()); | |||
| wxCouponChannelQ.setSubTargetId(record.getId()); | |||
| wxCouponChannelQ.setStatus(EnumCouponChannelStatus.STATUS_THROW_IN.getCode()); | |||
| @@ -303,7 +303,7 @@ public class WxGameServiceImpl implements WxGameService { | |||
| wxCouponChannel.setCouponId(couponId); | |||
| wxCouponChannel.setType(wxCoupon.getType()); | |||
| wxCouponChannel.setTargetAd(EnumCouponChannelType.COUPON_CHANNEL_ID_GAME.getCode()); | |||
| wxCouponChannel.setTenantId(wxCoupon.getTenantId()); | |||
| wxCouponChannel.updateTenantInfo(wxCoupon); | |||
| wxCouponChannel.setBusiness(wxCoupon.getBusiness()); | |||
| wxCouponChannel.setSubBusiness(wxCoupon.getSubBusiness()); | |||
| wxCouponChannel.setTitle(wxCoupon.getTitle()); | |||
| @@ -56,7 +56,7 @@ public class WxLevelConfigServiceImpl implements WxLevelConfigService { | |||
| l.setScale(WxLevelConfig.DEFAULT_SCALE); | |||
| } | |||
| WxCUserBasicInfoDto dto = new WxCUserBasicInfoDto(); | |||
| dto.setTenantId(l.getTenantId()); | |||
| dto.updateTenantInfo(record); | |||
| dto.setLevelStartScore(l.getPoints()); | |||
| if (i + 1<page.getList().size()) | |||
| dto.setLevelEndScore(page.getList().get(i+1).getPoints()); | |||