Commit 19185d42 by 墨竹

feat:删除活码wxUserId

parent ebaffebd
......@@ -15,9 +15,7 @@ public class HmClerkRelationDTO implements Serializable {
private Long relationId;
private Long hmId;
private String wxUserId;
private String wxEnterpriseId;
private String enterpriseId;
......@@ -64,14 +62,6 @@ public class HmClerkRelationDTO implements Serializable {
this.hmId = hmId;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getWxEnterpriseId() {
return wxEnterpriseId;
}
......
......@@ -68,9 +68,7 @@ public class HmQrcodeDTO implements Serializable {
* 微信联系我二维码
*/
private String wxQrcode;
private String wxUserId;
private String storeId;
private String storeName;
......@@ -262,14 +260,6 @@ public class HmQrcodeDTO implements Serializable {
this.wxQrcode = wxQrcode;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getStoreId() {
return storeId;
}
......
......@@ -17,8 +17,6 @@ public class HmClerkRelationQDTO implements Serializable {
private Long hmId;
private String wxUserId;
private String wxEnterpriseId;
private String enterpriseId;
......@@ -69,14 +67,6 @@ public class HmClerkRelationQDTO implements Serializable {
this.hmId = hmId;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getWxEnterpriseId() {
return wxEnterpriseId;
}
......
......@@ -70,9 +70,7 @@ public class HmQrcodeQDTO implements Serializable {
* 微信联系我二维码
*/
private String wxQrcode;
private String wxUserId;
private String storeId;
private String storeName;
......@@ -270,14 +268,6 @@ public class HmQrcodeQDTO implements Serializable {
this.wxQrcode = wxQrcode;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getStoreId() {
return storeId;
}
......
......@@ -133,7 +133,7 @@ public class PayController extends WebBaseController {
StaffClerkRelationDTO relationDTO = maps.get(wxClerkInfoVO.getClerkId());
if (null!=relationDTO) {
wxClerkInfoVO.setStaffId(relationDTO.getStaffId());
wxClerkInfoVO.setWxUserId(relationDTO.getWxUserId());
wxClerkInfoVO.setWxUserId(relationDTO.getQwUserId());
}
});
}
......
......@@ -15,9 +15,7 @@ public class TabHaobanHmClerkRelation implements Serializable {
private Long relationId;
private Long hmId;
private String wxUserId;
private String wxEnterpriseId;
private String enterpriseId;
......@@ -67,14 +65,6 @@ public class TabHaobanHmClerkRelation implements Serializable {
this.hmId = hmId;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getWxEnterpriseId() {
return wxEnterpriseId;
}
......
......@@ -68,8 +68,6 @@ public class TabHaobanHmQrcode implements Serializable {
*/
private String wxQrcode;
private String wxUserId;
private String storeId;
private String storeName;
......@@ -253,14 +251,6 @@ public class TabHaobanHmQrcode implements Serializable {
this.wxQrcode = wxQrcode;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getStoreId() {
return storeId;
}
......
......@@ -15,9 +15,7 @@ public class HmClerkRelationBO implements Serializable {
private Long relationId;
private Long hmId;
private String wxUserId;
private String wxEnterpriseId;
private String enterpriseId;
......@@ -65,14 +63,6 @@ public class HmClerkRelationBO implements Serializable {
this.hmId = hmId;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getWxEnterpriseId() {
return wxEnterpriseId;
}
......
......@@ -71,9 +71,7 @@ public class HmQrcodeBO implements Serializable {
* 微信联系我二维码
*/
private String wxQrcode;
private String wxUserId;
private String storeId;
private String storeName;
......@@ -263,14 +261,6 @@ public class HmQrcodeBO implements Serializable {
this.wxQrcode = wxQrcode;
}
public String getWxUserId() {
return wxUserId;
}
public void setWxUserId(String wxUserId) {
this.wxUserId = wxUserId;
}
public String getStoreId() {
return storeId;
}
......
package com.gic.haoban.manage.service.service.out.impl.hm;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Random;
import java.util.stream.Collectors;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.redisson.api.RRateLimiter;
import org.redisson.api.RateIntervalUnit;
import org.redisson.api.RateType;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.gic.api.base.commons.BasePageInfo;
......@@ -31,16 +14,13 @@ import com.gic.enterprise.api.service.StoreService;
import com.gic.haoban.common.utils.DingUtils;
import com.gic.haoban.manage.api.dto.WxEnterpriseDTO;
import com.gic.haoban.manage.api.dto.WxEnterpriseQwDTO;
import com.gic.haoban.manage.api.dto.hm.HmLinkDTO;
import com.gic.haoban.manage.api.dto.hm.HmLinkStoreDTO;
import com.gic.haoban.manage.api.dto.hm.HmLinkStoreSettingDTO;
import com.gic.haoban.manage.api.dto.hm.HmLinkWxaDTO;
import com.gic.haoban.manage.api.dto.hm.HmPageDTO;
import com.gic.haoban.manage.api.dto.hm.*;
import com.gic.haoban.manage.api.dto.qdto.hm.HmLinkSearchQDTO;
import com.gic.haoban.manage.api.service.hm.HmLinkApiService;
import com.gic.haoban.manage.service.config.Config;
import com.gic.haoban.manage.service.dao.mapper.TabHaobanExternalClerkRelatedMapper;
import com.gic.haoban.manage.service.entity.TabHaobanExternalClerkRelated;
import com.gic.haoban.manage.service.entity.TabHaobanStaff;
import com.gic.haoban.manage.service.errorcode.HaoBanErrCode;
import com.gic.haoban.manage.service.pojo.bo.hm.HmLinkBO;
import com.gic.haoban.manage.service.pojo.bo.hm.HmPageBO;
......@@ -49,12 +29,9 @@ import com.gic.haoban.manage.service.pojo.bo.hm.KeyDataLinkBO;
import com.gic.haoban.manage.service.pojo.qo.HmQrcodeTempQO;
import com.gic.haoban.manage.service.service.KeyDataService;
import com.gic.haoban.manage.service.service.MemberQueryService;
import com.gic.haoban.manage.service.service.StaffService;
import com.gic.haoban.manage.service.service.WxEnterpriseService;
import com.gic.haoban.manage.service.service.hm.HmLinkService;
import com.gic.haoban.manage.service.service.hm.HmLinkStoreService;
import com.gic.haoban.manage.service.service.hm.HmPageService;
import com.gic.haoban.manage.service.service.hm.HmQrcodeService;
import com.gic.haoban.manage.service.service.hm.HmQrcodeTempService;
import com.gic.haoban.manage.service.service.hm.*;
import com.gic.member.api.dto.es.MemberDataDTO;
import com.gic.member.api.dto.es.MemberStoreClerkDataDTO;
import com.gic.member.api.service.MemberService;
......@@ -62,6 +39,17 @@ import com.gic.redis.data.util.RedisUtil;
import com.gic.wechat.api.dto.qywx.welcome.QywxExternalcontactDTO;
import com.gic.wechat.api.dto.qywx.welcome.QywxExternalcontactResultDTO;
import com.gic.wechat.api.service.qywx.QywxUserApiService;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.redisson.api.RRateLimiter;
import org.redisson.api.RateIntervalUnit;
import org.redisson.api.RateType;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.*;
import java.util.stream.Collectors;
@Service("hmLinkApiService")
public class HmLinkApiServiceImpl implements HmLinkApiService {
......@@ -96,6 +84,8 @@ public class HmLinkApiServiceImpl implements HmLinkApiService {
private HmPageService hmPageService;
@Autowired
private StoreService storeService;
@Autowired
private StaffService staffService;
@Override
public ServiceResponse<String> getHmLinkUrl() {
......@@ -447,7 +437,10 @@ public class HmLinkApiServiceImpl implements HmLinkApiService {
paramsDTO.setRemark(hm.getName());
paramsDTO.setSkipVerify(hm.getPassFlag() == 1);
paramsDTO.setState("DT" + key);
paramsDTO.setUser(Arrays.asList(hm.getWxUserId()));
TabHaobanStaff tabHaobanStaff = staffService.selectById(hm.getStaffId());
if (tabHaobanStaff != null) {
paramsDTO.setUser(Arrays.asList(tabHaobanStaff.getWxUserId()));
}
QywxExternalcontactResultDTO wxResp = qywxUserApiService.addContactWay(corpid, config.getWxSuiteid(),
paramsDTO);
log.info("创建动态活码参数corpid={},app={},param={},返回={}", corpid, config.getWxSuiteid(), JSON.toJSONString(paramsDTO),
......
......@@ -518,7 +518,6 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
TabHaobanStaff tabHaobanStaff = staffService.selectById(staffClerkRelationDTO.getStaffId());
if (tabHaobanStaff != null) {
hmQrcodeQDTO.setStaffName(tabHaobanStaff.getStaffName());
hmQrcodeQDTO.setWxUserId(tabHaobanStaff.getWxUserId());
}
}
}
......
......@@ -5,7 +5,6 @@
<resultMap type="com.gic.haoban.manage.service.entity.hm.TabHaobanHmClerkRelation" id="TabHaobanHmClerkRelationMap">
<result property="relationId" column="relation_id" jdbcType="INTEGER"/>
<result property="hmId" column="hm_id" jdbcType="INTEGER"/>
<result property="wxUserId" column="wx_user_id" jdbcType="VARCHAR"/>
<result property="wxEnterpriseId" column="wx_enterprise_id" jdbcType="VARCHAR"/>
<result property="enterpriseId" column="enterprise_id" jdbcType="VARCHAR"/>
<result property="storeId" column="store_id" jdbcType="VARCHAR"/>
......@@ -24,7 +23,7 @@
</resultMap>
<sql id="Base_Column_List">
relation_id,hm_id, wx_user_id, wx_enterprise_id, enterprise_id, store_id,
relation_id,hm_id, wx_enterprise_id, enterprise_id, store_id,
store_name, store_code, clerk_id, clerk_name, clerk_code, status,
create_time, update_time, over_flag, add_num,staff_id,staff_name
</sql>
......@@ -38,19 +37,19 @@
<!--新增所有列-->
<insert id="insert" keyProperty="relationId" useGeneratedKeys="true">
insert into tab_haoban_hm_clerk_relation(relation_id,hm_id, wx_user_id, wx_enterprise_id, enterprise_id, store_id,
insert into tab_haoban_hm_clerk_relation(relation_id,hm_id, wx_enterprise_id, enterprise_id, store_id,
store_name, store_code, clerk_id, clerk_name, clerk_code, status,
create_time, update_time, over_flag, add_num,staff_id,staff_name)
values (#{relationId},#{hmId}, #{wxUserId}, #{wxEnterpriseId}, #{enterpriseId}, #{storeId}, #{storeName}, #{storeCode},
values (#{relationId},#{hmId}, #{wxEnterpriseId}, #{enterpriseId}, #{storeId}, #{storeName}, #{storeCode},
#{clerkId}, #{clerkName}, #{clerkCode}, #{status}, #{createTime}, #{updateTime}, #{overFlag}, #{addNum},#{staffId},#{staffName})
</insert>
<insert id="insertBatch" keyProperty="relationId" useGeneratedKeys="true">
insert into tab_haoban_hm_clerk_relation(relation_id,hm_id, wx_user_id, wx_enterprise_id, enterprise_id, store_id,
insert into tab_haoban_hm_clerk_relation(relation_id,hm_id, wx_enterprise_id, enterprise_id, store_id,
store_name, store_code, clerk_id, clerk_name, clerk_code, status, create_time, update_time, over_flag,add_num,staff_id,staff_name)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.relationId},#{entity.hmId}, #{entity.wxUserId}, #{entity.wxEnterpriseId}, #{entity.enterpriseId}, #{entity.storeId},
(#{entity.relationId},#{entity.hmId}, #{entity.wxEnterpriseId}, #{entity.enterpriseId}, #{entity.storeId},
#{entity.storeName}, #{entity.storeCode}, #{entity.clerkId}, #{entity.clerkName}, #{entity.clerkCode},
#{entity.status}, #{entity.createTime}, #{entity.updateTime}, #{entity.overFlag},#{entity.addNum},
#{entity.staffId},#{entity.staffName})
......@@ -64,9 +63,6 @@
<if test="hmId != null">
hm_id = #{hmId},
</if>
<if test="wxUserId != null and wxUserId != ''">
wx_user_id = #{wxUserId},
</if>
<if test="wxEnterpriseId != null and wxEnterpriseId != ''">
wx_enterprise_id = #{wxEnterpriseId},
</if>
......
......@@ -23,7 +23,6 @@
<result property="overFlag" column="over_flag" jdbcType="INTEGER"/>
<result property="wxConfigId" column="wx_config_id" jdbcType="VARCHAR"/>
<result property="wxQrcode" column="wx_qrcode" jdbcType="VARCHAR"/>
<result property="wxUserId" column="wx_user_id" jdbcType="VARCHAR"/>
<result property="storeId" column="store_id" jdbcType="VARCHAR"/>
<result property="storeName" column="store_name" jdbcType="VARCHAR"/>
<result property="storeCode" column="store_code" jdbcType="VARCHAR"/>
......@@ -40,7 +39,7 @@
hm_id, hm_code, hm_type, wx_enterprise_id, enterprise_id, name, creator_id,
creator_name, modifier_id, modifier_name, create_time, update_time,
member_label_id, pass_flag, welcome_id, status_flag, add_num, over_flag,
wx_config_id, wx_qrcode, wx_user_id, store_id, store_name, store_code,
wx_config_id, wx_qrcode, store_id, store_name, store_code,
clerk_id, clerk_name, clerk_code, hm_user_num, hm_group_id,staff_id,staff_name
</sql>
......@@ -111,12 +110,12 @@
insert into tab_haoban_hm_qrcode(hm_id, hm_code, hm_type, wx_enterprise_id, enterprise_id, name, creator_id,
creator_name, modifier_id, modifier_name, create_time, update_time,
member_label_id, pass_flag, welcome_id, status_flag, add_num, over_flag,
wx_config_id, wx_qrcode, wx_user_id, store_id, store_name, store_code,
wx_config_id, wx_qrcode, store_id, store_name, store_code,
clerk_id, clerk_name, clerk_code, hm_user_num, hm_group_id,staff_id,staff_name)
values (#{hmId}, #{hmCode}, #{hmType}, #{wxEnterpriseId}, #{enterpriseId}, #{name}, #{creatorId},
#{creatorName},
#{modifierId}, #{modifierName}, #{createTime}, #{updateTime}, #{memberLabelId}, #{passFlag},
#{welcomeId}, #{statusFlag}, #{addNum}, #{overFlag}, #{wxConfigId}, #{wxQrcode}, #{wxUserId},
#{welcomeId}, #{statusFlag}, #{addNum}, #{overFlag}, #{wxConfigId}, #{wxQrcode},
#{storeId}, #{storeName}, #{storeCode}, #{clerkId}, #{clerkName}, #{clerkCode}, #{hmUserNum},
#{hmGroupId},#{staffId},#{staffName})
</insert>
......@@ -124,7 +123,7 @@
<insert id="insertBatch" keyProperty="hmId" useGeneratedKeys="true">
insert into tab_haoban_hm_qrcode(hm_id,hm_code, hm_type, wx_enterprise_id, enterprise_id, name, creator_id,
creator_name, modifier_id, modifier_name, create_time, update_time, member_label_id, pass_flag, welcome_id,
status_flag, add_num, over_flag, wx_config_id, wx_qrcode, wx_user_id, store_id, store_name, store_code,
status_flag, add_num, over_flag, wx_config_id, wx_qrcode, store_id, store_name, store_code,
clerk_id, clerk_name, clerk_code, hm_user_num, hm_group_id,staff_id,staff_name)
values
<foreach collection="entities" item="entity" separator=",">
......@@ -133,7 +132,7 @@
#{entity.creatorId}, #{entity.creatorName}, #{entity.modifierId}, #{entity.modifierName},
#{entity.createTime}, #{entity.updateTime}, #{entity.memberLabelId}, #{entity.passFlag},
#{entity.welcomeId}, #{entity.statusFlag}, #{entity.addNum}, #{entity.overFlag}, #{entity.wxConfigId},
#{entity.wxQrcode}, #{entity.wxUserId}, #{entity.storeId}, #{entity.storeName}, #{entity.storeCode},
#{entity.wxQrcode}, #{entity.storeId}, #{entity.storeName}, #{entity.storeCode},
#{entity.clerkId}, #{entity.clerkName}, #{entity.clerkCode}, #{entity.hmUserNum}, #{entity.hmGroupId},
#{entity.staffId},#{entity.staffName})
</foreach>
......@@ -201,9 +200,6 @@
<if test="wxQrcode != null and wxQrcode != ''">
wx_qrcode = #{wxQrcode},
</if>
<if test="wxUserId != null and wxUserId != ''">
wx_user_id = #{wxUserId},
</if>
<if test="storeId != null and storeId != ''">
store_id = #{storeId},
</if>
......
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