用户完善信息,发送消息给用户

master
382696293@qq.com 3 years ago
parent 3a4164368d
commit f7bb2826da

@ -9,7 +9,8 @@ public enum MessageTypeEnum {
USER_REGISTRATION(1, "用户注册"), USER_REGISTRATION(1, "用户注册"),
SUBMIT_MESSAGE(2, "提交留言"), SUBMIT_MESSAGE(2, "提交留言"),
BINDING_INSTRUMENTS(3, "绑定仪器"); BINDING_INSTRUMENTS(3, "绑定仪器"),
COMPLETE_USER_INFORMATION(4, "完善用户信息");
private final Integer code; private final Integer code;
private final String info; private final String info;

@ -3,7 +3,7 @@ package com.flossom.common.core.enums;
/** /**
* wx_user_script_log * wx_user_script_log
* <p> * <p>
* 消息类型:0、未知,1、用户注册,2、绑定仪器,3、打卡活动,4、护理计划,5、问卷活动,6、会员管理,7、消息模板 * 消息类型:0、未知,1、用户注册,2、绑定仪器,3、打卡活动,4、护理计划,5、问卷活动,6、会员管理,7、消息模板,8、留言,9、完善用户信息
*/ */
public enum WxUserIntegralMessageTypeEnum { public enum WxUserIntegralMessageTypeEnum {
@ -15,7 +15,8 @@ public enum WxUserIntegralMessageTypeEnum {
QUESTIONNAIRE_ACTIVITY(5, "问卷活动"), QUESTIONNAIRE_ACTIVITY(5, "问卷活动"),
MEMBER_MANAGEMENT(6, "会员管理"), MEMBER_MANAGEMENT(6, "会员管理"),
MESSAGE_TEMPLATE(7, "消息模板"), MESSAGE_TEMPLATE(7, "消息模板"),
LEAVE_MESSAGE(8, "留言"); LEAVE_MESSAGE(8, "留言"),
COMPLETE_USER_INFORMATION(9, "完善用户信息");
private final Integer code; private final Integer code;
private final String info; private final String info;

@ -206,6 +206,24 @@ public class WxUserMemberServiceImpl implements IWxUserMemberService {
wxUserIntegralLog.setRemarkContent("首次完善用户信息"); wxUserIntegralLog.setRemarkContent("首次完善用户信息");
wxUserIntegralLogMapper.insertWxUserIntegralLog(wxUserIntegralLog); wxUserIntegralLogMapper.insertWxUserIntegralLog(wxUserIntegralLog);
// 2.4、用户注册成功发送消息
WxScriptMessage wxScriptMessage = wxScriptMessageMapper.selectOneByMessageType(MessageTypeEnum.COMPLETE_USER_INFORMATION.getCode());
if (wxScriptMessage != null) {
WxUserScriptLog wxUserScriptLog = new WxUserScriptLog();
BeanUtils.copyProperties(wxScriptMessage, wxUserScriptLog);
wxUserScriptLog.setId(null);
wxUserScriptLog.setWxUserId(SecurityUtils.getLoginUser().getWxUserMember().getId());
wxUserScriptLog.setMessageType(WxUserIntegralMessageTypeEnum.COMPLETE_USER_INFORMATION.getCode());
wxUserScriptLog.setIsCustom(0);
wxUserScriptLog.setTitile(wxScriptMessage.getMessageTitle());
wxUserScriptLog.setContent(wxScriptMessage.getMessageContent());
wxUserScriptLog.setCreateTime(DateUtils.getNowDate());
wxUserScriptLog.setCreateBy(null);
wxUserScriptLog.setUpdateTime(null);
wxUserScriptLog.setUpdateBy(null);
wxUserScriptLogMapper.insertWxUserScriptLog(wxUserScriptLog);
}
// TODO: 首次完善,增加加分 (对接数云未完成) // TODO: 首次完善,增加加分 (对接数云未完成)
} }
BeanUtils.copyProperties(userMemberUpdateVo, wxUserMember); BeanUtils.copyProperties(userMemberUpdateVo, wxUserMember);

@ -606,6 +606,8 @@
<span v-show="scope.row.messageType == 5">问卷活动</span> <span v-show="scope.row.messageType == 5">问卷活动</span>
<span v-show="scope.row.messageType == 6">会员管理</span> <span v-show="scope.row.messageType == 6">会员管理</span>
<span v-show="scope.row.messageType == 7">消息模板</span> <span v-show="scope.row.messageType == 7">消息模板</span>
<span v-show="scope.row.messageType == 8">用户留言</span>
<span v-show="scope.row.messageType == 9">完善用户信息</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="titile" label="标题" width="200"></el-table-column> <el-table-column prop="titile" label="标题" width="200"></el-table-column>

@ -133,6 +133,7 @@
<span v-show="scope.row.messageType == 1">用户注册</span> <span v-show="scope.row.messageType == 1">用户注册</span>
<span v-show="scope.row.messageType == 2">提交留言</span> <span v-show="scope.row.messageType == 2">提交留言</span>
<span v-show="scope.row.messageType == 3">仪器绑定</span> <span v-show="scope.row.messageType == 3">仪器绑定</span>
<span v-show="scope.row.messageType == 4">完善用户信息</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="消息标题" align="center" prop="messageTitle" /> <el-table-column label="消息标题" align="center" prop="messageTitle" />
@ -207,6 +208,7 @@
<el-option label="用户注册" :value="1" :key="1"></el-option> <el-option label="用户注册" :value="1" :key="1"></el-option>
<el-option label="提交留言" :value="2" :key="2"></el-option> <el-option label="提交留言" :value="2" :key="2"></el-option>
<el-option label="仪器绑定" :value="3" :key="3"></el-option> <el-option label="仪器绑定" :value="3" :key="3"></el-option>
<el-option label="完善用户信息" :value="4" :key="4"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>

Loading…
Cancel
Save