Commit fd8d7090 by 1539136324@qq.com

开发分支合并修改素材分类不可编辑bug;修改个人活码添加设置和标签不可编辑bug;修改实体null值时属性不返回bug;

1 parent 8e762153
...@@ -19,7 +19,7 @@ public class JsonSerializerManage { ...@@ -19,7 +19,7 @@ public class JsonSerializerManage {
@Bean @Bean
public ObjectMapper jacksonObjectMapper(Jackson2ObjectMapperBuilder builder) { public ObjectMapper jacksonObjectMapper(Jackson2ObjectMapperBuilder builder) {
ObjectMapper objectMapper = builder.createXmlMapper(false).build(); ObjectMapper objectMapper = builder.createXmlMapper(false).build();
objectMapper.setSerializationInclusion(JsonInclude.Include.NON_NULL); // objectMapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
SimpleModule module = new SimpleModule(); SimpleModule module = new SimpleModule();
module.addSerializer(Long.class, ToStringSerializer.instance); module.addSerializer(Long.class, ToStringSerializer.instance);
module.addSerializer(Long.TYPE, ToStringSerializer.instance); module.addSerializer(Long.TYPE, ToStringSerializer.instance);
......
...@@ -107,4 +107,9 @@ public class WeEmpleCode extends BaseEntity { ...@@ -107,4 +107,9 @@ public class WeEmpleCode extends BaseEntity {
*/ */
@TableField(exist = false) @TableField(exist = false)
private String mobile; private String mobile;
/**
* 客户添加时是否需要经过确认自动成为好友 1:是 0:否
*/
private Integer isJoinConfirmFriends;
} }
...@@ -168,11 +168,11 @@ public class WeEmpleCodeServiceImpl extends ServiceImpl<WeEmpleCodeMapper, WeEmp ...@@ -168,11 +168,11 @@ public class WeEmpleCodeServiceImpl extends ServiceImpl<WeEmpleCodeMapper, WeEmp
if (this.baseMapper.updateWeEmpleCode(weEmpleCode) == 1) { if (this.baseMapper.updateWeEmpleCode(weEmpleCode) == 1) {
if (CollectionUtil.isNotEmpty(weEmpleCode.getWeEmpleCodeUseScops())) { if (CollectionUtil.isNotEmpty(weEmpleCode.getWeEmpleCodeUseScops())) {
weEmpleCode.getWeEmpleCodeUseScops().forEach(item -> item.setEmpleCodeId(weEmpleCode.getId())); weEmpleCode.getWeEmpleCodeUseScops().forEach(item -> item.setEmpleCodeId(weEmpleCode.getId()));
iWeEmpleCodeUseScopService.updateBatchById(weEmpleCode.getWeEmpleCodeUseScops()); iWeEmpleCodeUseScopService.saveOrUpdateBatch(weEmpleCode.getWeEmpleCodeUseScops());
} }
if (CollectionUtil.isNotEmpty(weEmpleCode.getWeEmpleCodeTags())) { if (CollectionUtil.isNotEmpty(weEmpleCode.getWeEmpleCodeTags())) {
weEmpleCode.getWeEmpleCodeTags().forEach(item -> item.setEmpleCodeId(weEmpleCode.getId())); weEmpleCode.getWeEmpleCodeTags().forEach(item -> item.setEmpleCodeId(weEmpleCode.getId()));
weEmpleCodeTagService.updateBatchById(weEmpleCode.getWeEmpleCodeTags()); weEmpleCodeTagService.saveOrUpdateBatch(weEmpleCode.getWeEmpleCodeTags());
} }
} }
} }
......
...@@ -35,14 +35,13 @@ ...@@ -35,14 +35,13 @@
<update id="updateWeCategory"> <update id="updateWeCategory">
UPDATE we_category UPDATE we_category
<trim prefix="set" suffixOverrides=","> <trim prefix="set" suffixOverrides=",">
<if test="id != null">id,</if> <if test="mediaType != null">media_type=#{mediaType},</if>
<if test="mediaType != null">media_type,</if> <if test="name != null">name=#{name},</if>
<if test="name != null">name,</if> <if test="parentId != null">parent_id=#{parentId},</if>
<if test="parentId != null">parent_id,</if> <if test="createBy != null">create_by=#{createBy},</if>
<if test="createBy != null">create_by,</if> <if test="createTime != null">create_time=#{createTime},</if>
<if test="createTime != null">create_time,</if> <if test="updateBy != null">update_by=#{updateBy},</if>
<if test="updateBy != null">update_by,</if> <if test="updateTime != null">update_time=#{updateTime},</if>
<if test="updateTime != null">update_time,</if>
</trim> </trim>
<where> <where>
id=#{id} id=#{id}
......
...@@ -18,6 +18,7 @@ ...@@ -18,6 +18,7 @@
<result property="mediaId" column="media_id"/> <result property="mediaId" column="media_id"/>
<result property="scanTimes" column="scan_times" /> <result property="scanTimes" column="scan_times" />
<result property="state" column="state" /> <result property="state" column="state" />
<result property="isJoinConfirmFriends" column="is_join_confirm_friends" />
<collection property="weEmpleCodeUseScops" ofType="com.linkwechat.wecom.domain.WeEmpleCodeUseScop"> <collection property="weEmpleCodeUseScops" ofType="com.linkwechat.wecom.domain.WeEmpleCodeUseScop">
<result property="businessId" column="business_id"/> <result property="businessId" column="business_id"/>
<result property="businessName" column="business_name"/> <result property="businessName" column="business_name"/>
...@@ -35,26 +36,26 @@ ...@@ -35,26 +36,26 @@
<sql id="getQrcodeByUserIdVo"> <sql id="getQrcodeByUserIdVo">
select select
wec.id, wec.id,
wec.code_type, wec.code_type,
wec.skip_verify, wec.skip_verify,
wec.scenario, wec.scenario,
wec.welcome_msg, wec.welcome_msg,
wec.create_by, wec.create_by,
wec.create_time, wec.create_time,
wec.del_flag, wec.del_flag,
wec.config_id, wec.config_id,
wec.state, wec.state,
wec.qr_code, wec.qr_code,
wec.scan_times wec.scan_times
from we_emple_code wec from we_emple_code wec
left join we_emple_code_use_scop wecus on wec.id = wecus.emple_code_id left join we_emple_code_use_scop wecus on wec.id = wecus.emple_code_id
and wecus.business_id_type = 2 and wecus.business_id_type = 2
and wecus.del_flag = 0 and wecus.del_flag = 0
</sql> </sql>
<sql id="selectWeEmpleCodeLsit"> <sql id="selectWeEmpleCodeLsit">
select select
wecode.id, wecode.id,
wecode.code_type, wecode.code_type,
wecode.media_id, wecode.media_id,
...@@ -72,24 +73,25 @@ ...@@ -72,24 +73,25 @@
wecusn.business_name, wecusn.business_name,
wecusn.mobile, wecusn.mobile,
wect.tag_id, wect.tag_id,
wect.tag_name wect.tag_name,
wecode.is_join_confirm_friends
from from
we_emple_code wecode we_emple_code wecode
left join ( left join (
SELECT SELECT
wecus.emple_code_id, wecus.business_id, wecus.business_name,wu.mobile wecus.emple_code_id, wecus.business_id, wecus.business_name,wu.mobile
FROM FROM
we_emple_code_use_scop wecus we_emple_code_use_scop wecus
LEFT JOIN we_user wu ON LEFT JOIN we_user wu ON
wu.user_id = wecus.business_id wu.user_id = wecus.business_id
WHERE WHERE
wecus.del_flag = 0 wecus.del_flag = 0
) as wecusn on ) as wecusn on
wecode.id = wecusn.emple_code_id wecode.id = wecusn.emple_code_id
left join we_emple_code_tag wect on left join we_emple_code_tag wect on
wecode.id = wect.emple_code_id wecode.id = wect.emple_code_id
where 1=1 and wecode.del_flag = 0 where 1=1 and wecode.del_flag = 0
</sql> </sql>
<select id="selectWeEmpleCodeList" parameterType="WeEmpleCode" resultType="com.linkwechat.wecom.domain.WeEmpleCode"> <select id="selectWeEmpleCodeList" parameterType="WeEmpleCode" resultType="com.linkwechat.wecom.domain.WeEmpleCode">
<include refid="selectWeEmpleCodeLsit"/> <include refid="selectWeEmpleCodeLsit"/>
...@@ -149,7 +151,8 @@ ...@@ -149,7 +151,8 @@
<if test="qrCode != null">qr_code,</if> <if test="qrCode != null">qr_code,</if>
<if test="mediaId != null">media_id,</if> <if test="mediaId != null">media_id,</if>
<if test="state != null">state,</if> <if test="state != null">state,</if>
<if test="scanTimes != null">scan_times</if> <if test="scanTimes != null">scan_times,</if>
<if test="isJoinConfirmFriends != null">is_join_confirm_friends,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if> <if test="id != null">#{id},</if>
...@@ -164,7 +167,8 @@ ...@@ -164,7 +167,8 @@
<if test="qrCode != null">#{qrCode},</if> <if test="qrCode != null">#{qrCode},</if>
<if test="mediaId != null">#{mediaId},</if> <if test="mediaId != null">#{mediaId},</if>
<if test="state != null">#{state},</if> <if test="state != null">#{state},</if>
<if test="scanTimes != null">#{scanTimes}</if> <if test="scanTimes != null">#{scanTimes},</if>
<if test="isJoinConfirmFriends != null">#{isJoinConfirmFriends},</if>
</trim> </trim>
</insert> </insert>
...@@ -182,7 +186,8 @@ ...@@ -182,7 +186,8 @@
<if test="qrCode != null">qr_code = #{qrCode},</if> <if test="qrCode != null">qr_code = #{qrCode},</if>
<if test="mediaId != null">media_id = #{mediaId},</if> <if test="mediaId != null">media_id = #{mediaId},</if>
<if test="state != null">state = #{state},</if> <if test="state != null">state = #{state},</if>
<if test="scanTimes != null">scan_times = #{scanTimes}</if> <if test="scanTimes != null">scan_times = #{scanTimes},</if>
<if test="isJoinConfirmFriends != null"> is_join_confirm_friends =#{isJoinConfirmFriends},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!