Commit be13eabb by 徐高华

订单拉取日期bug

parent 68c6abd5
...@@ -15,21 +15,17 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -15,21 +15,17 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.gic.api.base.commons.Page; import com.gic.api.base.commons.Page;
import com.gic.commons.util.EntityUtil; import com.gic.commons.util.EntityUtil;
import com.gic.commons.util.GICMQClientUtil; import com.gic.commons.util.GICMQClientUtil;
import com.gic.commons.util.UniqueIdUtils; import com.gic.commons.util.UniqueIdUtils;
import com.gic.dubbo.entity.ProviderLocalTag;
import com.gic.haoban.common.utils.PageUtil; import com.gic.haoban.common.utils.PageUtil;
import com.gic.haoban.manage.api.constants.Manage3Constants; import com.gic.haoban.manage.api.constants.Manage3Constants;
import com.gic.haoban.manage.api.dto.AlertMessageDTO;
import com.gic.haoban.manage.api.dto.WxEnterpriseDTO; import com.gic.haoban.manage.api.dto.WxEnterpriseDTO;
import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeAccountInterceptLogDTO; import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeAccountInterceptLogDTO;
import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeDTO; import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeDTO;
import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeDetailDTO; import com.gic.haoban.manage.api.dto.fee.HaobanQywxFeeDetailDTO;
import com.gic.haoban.manage.api.dto.qdto.QywxFeeListQDTO; import com.gic.haoban.manage.api.dto.qdto.QywxFeeListQDTO;
import com.gic.haoban.manage.api.enums.AlertTypeEnum;
import com.gic.haoban.manage.api.service.fee.HaobanQywxFeeApiService; import com.gic.haoban.manage.api.service.fee.HaobanQywxFeeApiService;
import com.gic.haoban.manage.service.config.Config; import com.gic.haoban.manage.service.config.Config;
import com.gic.haoban.manage.service.entity.TabHaobanStaff; import com.gic.haoban.manage.service.entity.TabHaobanStaff;
...@@ -85,7 +81,7 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -85,7 +81,7 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
@Autowired @Autowired
private HaobanQywxFeeAccountInterceptLogService haobanQywxFeeAccountInterceptLogService; private HaobanQywxFeeAccountInterceptLogService haobanQywxFeeAccountInterceptLogService;
@Autowired @Autowired
private WxEnterpriseActiveDataService wxEnterpriseActiveDataService ; private WxEnterpriseActiveDataService wxEnterpriseActiveDataService;
@Override @Override
public void run(String param) { public void run(String param) {
...@@ -104,12 +100,14 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -104,12 +100,14 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
List<String> orderIds = new ArrayList<>(); List<String> orderIds = new ArrayList<>();
FeeOrderListQDTO feeOrderListQDTO = new FeeOrderListQDTO(); FeeOrderListQDTO feeOrderListQDTO = new FeeOrderListQDTO();
feeOrderListQDTO.setCorpid(corpid); feeOrderListQDTO.setCorpid(corpid);
if(null == RedisUtil.getCache("qywx-order-search-date")) { if (null == RedisUtil.getCache("qywx-order-search-date")) {
feeOrderListQDTO.setStartTime(DateUtil.beginOfDay(new Date()).offsetNew(DateField.HOUR_OF_DAY, -1).getTime()); feeOrderListQDTO
feeOrderListQDTO.setEndTime(DateUtil.endOfDay(new Date()).offsetNew(DateField.HOUR_OF_DAY, -1).getTime()); .setStartTime(DateUtil.beginOfDay(new Date()).offsetNew(DateField.HOUR_OF_DAY, -24).getTime());
feeOrderListQDTO.setEndTime(new Date().getTime());
} }
feeOrderListQDTO.setLimit(Manage3Constants.QW_LIMIT); feeOrderListQDTO.setLimit(Manage3Constants.QW_LIMIT);
FeeOrderResponseList feeOrderResponseList = qywxUserApiService.listOrder(corpid, config.getCorpid(), feeOrderListQDTO); FeeOrderResponseList feeOrderResponseList = qywxUserApiService.listOrder(corpid, config.getCorpid(),
feeOrderListQDTO);
logger.error("查询激活码订单,{}", JSON.toJSONString(feeOrderResponseList)); logger.error("查询激活码订单,{}", JSON.toJSONString(feeOrderResponseList));
int errcode = feeOrderResponseList.getErrcode(); int errcode = feeOrderResponseList.getErrcode();
if (errcode == 0) { if (errcode == 0) {
...@@ -117,37 +115,39 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -117,37 +115,39 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
orderIds.add(orderListDTO.getOrderId()); orderIds.add(orderListDTO.getOrderId());
} }
} }
return orderIds ; return orderIds;
} }
// 查询订单下的激活码code列表 // 查询订单下的激活码code列表
private void getOrderAccount(String orderId , String corpid , String cursor , List<Map<String, String>> activeCodeList) { private void getOrderAccount(String orderId, String corpid, String cursor,
logger.info("处理订单激活码,orderid={}",orderId); List<Map<String, String>> activeCodeList) {
logger.info("处理订单激活码,orderid={}", orderId);
FeeOrderListQDTO feeOrderListQDTO = new FeeOrderListQDTO(); FeeOrderListQDTO feeOrderListQDTO = new FeeOrderListQDTO();
feeOrderListQDTO.setOrderId(orderId); feeOrderListQDTO.setOrderId(orderId);
feeOrderListQDTO.setCursor(cursor); feeOrderListQDTO.setCursor(cursor);
feeOrderListQDTO.setLimit(Manage3Constants.QW_LIMIT); feeOrderListQDTO.setLimit(Manage3Constants.QW_LIMIT);
AccountListResponseDTO accountListResponseDTO = qywxUserApiService.listOrderAccount(corpid, config.getCorpid(), feeOrderListQDTO); AccountListResponseDTO accountListResponseDTO = qywxUserApiService.listOrderAccount(corpid, config.getCorpid(),
feeOrderListQDTO);
if (accountListResponseDTO.getErrcode() != 0) { if (accountListResponseDTO.getErrcode() != 0) {
logger.info("订单账号列表报错:{}", accountListResponseDTO.getErrmsg()); logger.info("订单账号列表报错:{}", accountListResponseDTO.getErrmsg());
return ; return;
} }
// 只记录互通账号 // 只记录互通账号
for (AccountListDTO accountListDTO : accountListResponseDTO.getAccountList()) { for (AccountListDTO accountListDTO : accountListResponseDTO.getAccountList()) {
if(accountListDTO.getType()==2) { if (accountListDTO.getType() == 2) {
Map<String, String> map = new HashMap<>(); Map<String, String> map = new HashMap<>();
map.put("orderId", orderId); map.put("orderId", orderId);
map.put("activeCode", accountListDTO.getActiveCode()); map.put("activeCode", accountListDTO.getActiveCode());
activeCodeList.add(map); activeCodeList.add(map);
} }
} }
cursor = accountListResponseDTO.getNextCursor() ; cursor = accountListResponseDTO.getNextCursor();
Integer hasMore = accountListResponseDTO.getHasMore(); Integer hasMore = accountListResponseDTO.getHasMore();
if (hasMore == 1 && StringUtils.isNotBlank(cursor)) { if (hasMore == 1 && StringUtils.isNotBlank(cursor)) {
this.getOrderAccount(orderId, corpid, cursor, activeCodeList); this.getOrderAccount(orderId, corpid, cursor, activeCodeList);
} }
} }
@Override @Override
public void addFee(String wxEnterpriseId) { public void addFee(String wxEnterpriseId) {
logger.info("企微收费wxEnterpriseId={}", wxEnterpriseId); logger.info("企微收费wxEnterpriseId={}", wxEnterpriseId);
...@@ -157,15 +157,15 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -157,15 +157,15 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
} }
String serviceCorpid = config.getCorpid(); String serviceCorpid = config.getCorpid();
WxEnterpriseDTO wxEnterpriseDTO = wxEnterpriseService.selectById(wxEnterpriseId); WxEnterpriseDTO wxEnterpriseDTO = wxEnterpriseService.selectById(wxEnterpriseId);
if(wxEnterpriseDTO.getWxSecurityType()<=0) { if (wxEnterpriseDTO.getWxSecurityType() <= 0) {
logger.info("WxSecurityType=0,wxEnterpriseId={}",wxEnterpriseId); logger.info("WxSecurityType=0,wxEnterpriseId={}", wxEnterpriseId);
return ; return;
} }
String corpid = wxEnterpriseDTO.getOpenCorpid() ; String corpid = wxEnterpriseDTO.getOpenCorpid();
String corpName = wxEnterpriseDTO.getCorpName(); String corpName = wxEnterpriseDTO.getCorpName();
String autoActiveStatus = qywxUserApiService.getAutoActiveStatus(corpid, serviceCorpid); String autoActiveStatus = qywxUserApiService.getAutoActiveStatus(corpid, serviceCorpid);
if (!"1".equals(autoActiveStatus)) { if (!"1".equals(autoActiveStatus)) {
logger.info("未开启自动激活:{},wxeid={}", corpid,wxEnterpriseId); logger.info("未开启自动激活:{},wxeid={}", corpid, wxEnterpriseId);
this.wxEnterpriseService.updateAutoActiveFlagById(0, wxEnterpriseId); this.wxEnterpriseService.updateAutoActiveFlagById(0, wxEnterpriseId);
return; return;
} }
...@@ -173,14 +173,14 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -173,14 +173,14 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
if (autoActiveFlag != null && autoActiveFlag != 1) { if (autoActiveFlag != null && autoActiveFlag != 1) {
this.wxEnterpriseService.updateAutoActiveFlagById(1, wxEnterpriseId); this.wxEnterpriseService.updateAutoActiveFlagById(1, wxEnterpriseId);
} }
List<String> orderIdList = this.listOrderId(corpid) ; List<String> orderIdList = this.listOrderId(corpid);
for (String orderId : orderIdList) { for (String orderId : orderIdList) {
FeeOrderDeatilResponseDTO order = qywxUserApiService.getOrder(corpid, serviceCorpid, orderId); FeeOrderDeatilResponseDTO order = qywxUserApiService.getOrder(corpid, serviceCorpid, orderId);
if (order.getErrcode() != 0) { if (order.getErrcode() != 0) {
logger.error("请求企微失败:{}", orderId); logger.error("请求企微失败:{}", orderId);
continue; continue;
} }
//插入订单 // 插入订单
FeeOrderDeatilResponseDTO.OrderDTO orderDTO = order.getOrder(); FeeOrderDeatilResponseDTO.OrderDTO orderDTO = order.getOrder();
Integer orderStatus = orderDTO.getOrderStatus(); Integer orderStatus = orderDTO.getOrderStatus();
if (orderStatus != 1) { if (orderStatus != 1) {
...@@ -203,35 +203,35 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -203,35 +203,35 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
// 增加到订单表,如果存在不更新 // 增加到订单表,如果存在不更新
this.haobanQywxFeeOrderService.insert(tabHaobanQywxFeeOrder); this.haobanQywxFeeOrderService.insert(tabHaobanQywxFeeOrder);
} }
// 更新订单的激活码状态 // 更新订单的激活码状态
List<TabHaobanQywxFeeOrder> orderList = this.haobanQywxFeeOrderService.listOrder(wxEnterpriseId) ; List<TabHaobanQywxFeeOrder> orderList = this.haobanQywxFeeOrderService.listOrder(wxEnterpriseId);
if(CollectionUtils.isEmpty(orderList)) { if (CollectionUtils.isEmpty(orderList)) {
logger.error("无企微订单:{}", wxEnterpriseId); logger.error("无企微订单:{}", wxEnterpriseId);
return ; return;
} }
// 查询订单下的激活码code列表,记录到activeCodeList // 查询订单下的激活码code列表,记录到activeCodeList
for(TabHaobanQywxFeeOrder order : orderList) { for (TabHaobanQywxFeeOrder order : orderList) {
List<Map<String, String>> activeCodeList = new ArrayList<>(); List<Map<String, String>> activeCodeList = new ArrayList<>();
// 查询订单下的激活码code列表 // 查询订单下的激活码code列表
this.getOrderAccount(order.getOrderId(), corpid, null, activeCodeList); this.getOrderAccount(order.getOrderId(), corpid, null, activeCodeList);
// 保存激活码列表 // 保存激活码列表
this.addOrderAccount(wxEnterpriseId, serviceCorpid, corpid, activeCodeList); this.addOrderAccount(wxEnterpriseId, serviceCorpid, corpid, activeCodeList);
} }
// 成员的激活码信息 // 成员的激活码信息
this.staffService.activedAccountTimer(wxEnterpriseId); this.staffService.activedAccountTimer(wxEnterpriseId);
// 更新企业的激活数量统计 // 更新企业的激活数量统计
this.wxEnterpriseActiveDataService.saveOrUpdate(wxEnterpriseId) ; this.wxEnterpriseActiveDataService.saveOrUpdate(wxEnterpriseId);
//统计 haobanQywxFeeDetailDTO 30天内最新过期的时间和人数 // 统计 haobanQywxFeeDetailDTO 30天内最新过期的时间和人数
HaobanQywxFeeDetailDTO haobanQywxFeeDetailDTO = haobanQywxFeeAccountStaffService.feeIntercept(wxEnterpriseId); HaobanQywxFeeDetailDTO haobanQywxFeeDetailDTO = haobanQywxFeeAccountStaffService.feeIntercept(wxEnterpriseId);
// 未激活数(状态1) // 未激活数(状态1)
int permissionUserNum = haobanQywxFeeOrderAccountService.countOrderAccountStatus(1, wxEnterpriseId); int permissionUserNum = haobanQywxFeeOrderAccountService.countOrderAccountStatus(1, wxEnterpriseId);
// 待转移数(状态4) // 待转移数(状态4)
int transferUserNum = haobanQywxFeeOrderAccountService.countOrderAccountStatus(4, wxEnterpriseId); int transferUserNum = haobanQywxFeeOrderAccountService.countOrderAccountStatus(4, wxEnterpriseId);
int totalCount = this.haobanQywxFeeOrderService.countExternalContactCount(wxEnterpriseId) ; int totalCount = this.haobanQywxFeeOrderService.countExternalContactCount(wxEnterpriseId);
if (haobanQywxFeeDetailDTO != null && permissionUserNum > 0) { if (haobanQywxFeeDetailDTO != null && permissionUserNum > 0) {
TabHaobanQywxFee tabHaobanQywxFee = new TabHaobanQywxFee(); TabHaobanQywxFee tabHaobanQywxFee = new TabHaobanQywxFee();
tabHaobanQywxFee.setQwFeeId(UniqueIdUtils.uniqueLong()); tabHaobanQywxFee.setQwFeeId(UniqueIdUtils.uniqueLong());
...@@ -245,17 +245,22 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -245,17 +245,22 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
tabHaobanQywxFee.setBuyPermissionUserNum(totalCount); tabHaobanQywxFee.setBuyPermissionUserNum(totalCount);
tabHaobanQywxFee.setInterceptFlag(0); tabHaobanQywxFee.setInterceptFlag(0);
haobanQywxFeeService.insert(tabHaobanQywxFee); haobanQywxFeeService.insert(tabHaobanQywxFee);
//判断今天是否是本月最后一天 // 判断今天是否是本月最后一天
if (DateUtil.isSameDay(DateUtil.endOfMonth(new Date()), new Date())) { if (DateUtil.isSameDay(DateUtil.endOfMonth(new Date()), new Date())) {
// int monthWillInterceptNum = haobanQywxFeeAccountStaffService.monthWillInterceptNum(wxEnterpriseId); // int monthWillInterceptNum =
// String content = "30天将有" + monthWillInterceptNum + "个接口许可证即将过期,您总共还剩余" + permissionUserNum + "个可用的接口许可证,请保证数量充足,如需增加请及时联系相关人员续费,避免影响使用"; // haobanQywxFeeAccountStaffService.monthWillInterceptNum(wxEnterpriseId);
//告警 // String content = "30天将有" + monthWillInterceptNum +
// messageAlert(wxEnterpriseId, corpName, corpid, AlertTypeEnum.FEE_ALARM.getName(), content); // "个接口许可证即将过期,您总共还剩余" + permissionUserNum +
// "个可用的接口许可证,请保证数量充足,如需增加请及时联系相关人员续费,避免影响使用";
// 告警
// messageAlert(wxEnterpriseId, corpName, corpid,
// AlertTypeEnum.FEE_ALARM.getName(), content);
} }
} }
// 更加企微通知记录已拦截数 // 更加企微通知记录已拦截数
List<TabHaobanQywxFeeAccountInterceptLog> interceptLogs = haobanQywxFeeAccountInterceptLogService.queryByWxEnterpriseId(wxEnterpriseId); List<TabHaobanQywxFeeAccountInterceptLog> interceptLogs = haobanQywxFeeAccountInterceptLogService
.queryByWxEnterpriseId(wxEnterpriseId);
if (CollectionUtils.isNotEmpty(interceptLogs)) { if (CollectionUtils.isNotEmpty(interceptLogs)) {
TabHaobanQywxFee tabHaobanQywxFee = new TabHaobanQywxFee(); TabHaobanQywxFee tabHaobanQywxFee = new TabHaobanQywxFee();
tabHaobanQywxFee.setQwFeeId(UniqueIdUtils.uniqueLong()); tabHaobanQywxFee.setQwFeeId(UniqueIdUtils.uniqueLong());
...@@ -271,36 +276,38 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -271,36 +276,38 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
haobanQywxFeeService.insert(tabHaobanQywxFee); haobanQywxFeeService.insert(tabHaobanQywxFee);
} }
} }
// 保存订单下的激活码信息-tab_haoban_qywx_fee_order_account // 保存订单下的激活码信息-tab_haoban_qywx_fee_order_account
private void addOrderAccount(String wxEnterpriseId, String serviceCorpid, String corpid, List<Map<String, String>> activeCodeList) { private void addOrderAccount(String wxEnterpriseId, String serviceCorpid, String corpid,
List<Map<String, String>> activeCodeList) {
if (CollectionUtils.isEmpty(activeCodeList)) { if (CollectionUtils.isEmpty(activeCodeList)) {
logger.error("订单账号无激活码"); logger.error("订单账号无激活码");
return; return;
} }
List<String> codeList = new ArrayList<>(); List<String> codeList = new ArrayList<>();
Map<String,String> keyMap = new HashMap<>(); Map<String, String> keyMap = new HashMap<>();
for (Map<String, String> activeCodeMap : activeCodeList) { for (Map<String, String> activeCodeMap : activeCodeList) {
String activeCode = activeCodeMap.get("activeCode"); String activeCode = activeCodeMap.get("activeCode");
String orderId = activeCodeMap.get("orderId"); String orderId = activeCodeMap.get("orderId");
codeList.add(activeCode) ; codeList.add(activeCode);
keyMap.put(activeCode,orderId) ; keyMap.put(activeCode, orderId);
} }
TabHaobanQywxFeeOrderAccount activeAccount = new TabHaobanQywxFeeOrderAccount(); TabHaobanQywxFeeOrderAccount activeAccount = new TabHaobanQywxFeeOrderAccount();
// 查询激活码的详情 // 查询激活码的详情
List<ActiveInfoCodeResponseDTO> respList = qywxUserApiService.getActiveInfoByCodeList(corpid, serviceCorpid, codeList); List<ActiveInfoCodeResponseDTO> respList = qywxUserApiService.getActiveInfoByCodeList(corpid, serviceCorpid,
if(CollectionUtils.isNotEmpty(respList)) { codeList);
List<List<ActiveInfoCodeResponseDTO>> list = Lists.partition(respList, 800) ; if (CollectionUtils.isNotEmpty(respList)) {
for(int i=0;i<list.size();i++) { List<List<ActiveInfoCodeResponseDTO>> list = Lists.partition(respList, 800);
for (int i = 0; i < list.size(); i++) {
List<ActiveInfoCodeResponseDTO> subList = list.get(i); List<ActiveInfoCodeResponseDTO> subList = list.get(i);
for(ActiveInfoCodeResponseDTO activeDetail : subList) { for (ActiveInfoCodeResponseDTO activeDetail : subList) {
String userid = activeDetail.getUserid(); String userid = activeDetail.getUserid();
String activeCode = activeDetail.getActiveCode() ; String activeCode = activeDetail.getActiveCode();
activeAccount.setWxUserId(userid); activeAccount.setWxUserId(userid);
activeAccount.setStatus(activeDetail.getStatus()); activeAccount.setStatus(activeDetail.getStatus());
if(null != activeDetail.getExpireTime()) { if (null != activeDetail.getExpireTime()) {
activeAccount.setExpireTime(DateUtil.date(activeDetail.getExpireTime() * 1000)); activeAccount.setExpireTime(DateUtil.date(activeDetail.getExpireTime() * 1000));
activeAccount.setActiveTime(DateUtil.date(activeDetail.getActiveTime() * 1000)); activeAccount.setActiveTime(DateUtil.date(activeDetail.getActiveTime() * 1000));
} }
...@@ -328,24 +335,28 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService { ...@@ -328,24 +335,28 @@ public class HaobanQywxFeeApiServiceImpl implements HaobanQywxFeeApiService {
@Override @Override
public void addInterceptLog(String param) { public void addInterceptLog(String param) {
HaobanQywxFeeAccountInterceptLogDTO logDTO = JSON.toJavaObject(JSON.parseObject(param), HaobanQywxFeeAccountInterceptLogDTO.class); HaobanQywxFeeAccountInterceptLogDTO logDTO = JSON.toJavaObject(JSON.parseObject(param),
HaobanQywxFeeAccountInterceptLogDTO.class);
logDTO.setFeeAccountInterceptId(UniqueIdUtils.uniqueLong()); logDTO.setFeeAccountInterceptId(UniqueIdUtils.uniqueLong());
TabHaobanWxEnterprise haobanWxEnterprise = wxEnterpriseService.getEnterpriseBycorpId(logDTO.getCorpId()); TabHaobanWxEnterprise haobanWxEnterprise = wxEnterpriseService.getEnterpriseBycorpId(logDTO.getCorpId());
if(null == haobanWxEnterprise) { if (null == haobanWxEnterprise) {
return ; return;
} }
String wxEnterpriseId = haobanWxEnterprise.getWxEnterpriseId(); String wxEnterpriseId = haobanWxEnterprise.getWxEnterpriseId();
logDTO.setWxEnterpriseId(wxEnterpriseId); logDTO.setWxEnterpriseId(wxEnterpriseId);
TabHaobanStaff tabHaobanStaff = staffService.selectByUserIdAndEnterpriseId(logDTO.getWxUserId(), wxEnterpriseId); TabHaobanStaff tabHaobanStaff = staffService.selectByUserIdAndEnterpriseId(logDTO.getWxUserId(),
if(null == tabHaobanStaff) { wxEnterpriseId);
return ; if (null == tabHaobanStaff) {
return;
} }
logDTO.setStaffId(tabHaobanStaff.getStaffId()); logDTO.setStaffId(tabHaobanStaff.getStaffId());
haobanQywxFeeAccountInterceptLogService.insert(EntityUtil.changeEntityNew(TabHaobanQywxFeeAccountInterceptLog.class, logDTO)); haobanQywxFeeAccountInterceptLogService
.insert(EntityUtil.changeEntityNew(TabHaobanQywxFeeAccountInterceptLog.class, logDTO));
} }
@Override @Override
public HaobanQywxFeeDTO queryByWxEnterpriseId(String wxEnterpriseId) { public HaobanQywxFeeDTO queryByWxEnterpriseId(String wxEnterpriseId) {
return EntityUtil.changeEntityNew(HaobanQywxFeeDTO.class, haobanQywxFeeService.queryByWxEnterpriseId(wxEnterpriseId)); return EntityUtil.changeEntityNew(HaobanQywxFeeDTO.class,
haobanQywxFeeService.queryByWxEnterpriseId(wxEnterpriseId));
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment