Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 9929bbe5
authored
Dec 07, 2020
by
danmo
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
客户流失参数查询,员工活码查询参数校验
1 parent
94f8c3e8
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
60 additions
and
20 deletions
linkwe-admin/src/main/java/com/linkwechat/web/controller/wecom/WeEmpleCodeController.java
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/WeCustomer.java
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/WeEmpleCode.java
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/dto/customer/ExternalUserDetail.java
linkwe-wecom/src/main/resources/mapper/wecom/WeCustomerMapper.xml
linkwe-admin/src/main/java/com/linkwechat/web/controller/wecom/WeEmpleCodeController.java
View file @
9929bbe
...
...
@@ -15,6 +15,7 @@ import com.linkwechat.wecom.service.IWeEmpleCodeService;
import
com.linkwechat.wecom.service.IWeFlowerCustomerRelService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.*
;
import
javax.servlet.http.HttpServletRequest
;
...
...
@@ -70,7 +71,7 @@ public class WeEmpleCodeController extends BaseController {
@PreAuthorize
(
"@ss.hasPermi('wecom:code:add')"
)
@Log
(
title
=
"员工活码"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/add"
)
public
AjaxResult
add
(
@RequestBody
WeEmpleCode
weEmpleCode
)
{
public
AjaxResult
add
(
@RequestBody
@Validated
WeEmpleCode
weEmpleCode
)
{
try
{
weEmpleCodeService
.
insertWeEmpleCode
(
weEmpleCode
);
return
AjaxResult
.
success
();
...
...
@@ -91,7 +92,7 @@ public class WeEmpleCodeController extends BaseController {
@PreAuthorize
(
"@ss.hasPermi('wecom:code:batchAdd')"
)
@Log
(
title
=
"批量新增员工活码"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
(
"/batchAdd"
)
public
AjaxResult
batchAdd
(
@RequestBody
WeEmpleCode
weEmpleCode
)
{
public
AjaxResult
batchAdd
(
@RequestBody
@Validated
WeEmpleCode
weEmpleCode
)
{
try
{
weEmpleCodeService
.
insertWeEmpleCodeBatch
(
weEmpleCode
);
return
AjaxResult
.
success
();
...
...
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/WeCustomer.java
View file @
9929bbe
...
...
@@ -3,6 +3,7 @@ package com.linkwechat.wecom.domain;
import
java.util.Date
;
import
java.util.List
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
...
...
@@ -86,4 +87,8 @@ public class WeCustomer extends BaseEntity
@TableField
(
exist
=
false
)
private
String
tagIds
;
@TableField
(
exist
=
false
)
@JSONField
(
defaultValue
=
"0"
)
private
Integer
status
;
}
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/WeEmpleCode.java
View file @
9929bbe
...
...
@@ -6,67 +6,93 @@ import com.linkwechat.common.core.domain.BaseEntity;
import
com.linkwechat.common.utils.SnowFlakeUtil
;
import
lombok.Data
;
import
javax.validation.constraints.NotEmpty
;
import
java.util.List
;
/**
* 员工活码对象 we_emple_code
*
*
* @author ruoyi
* @date 2020-10-04
*/
@Data
@TableName
(
"we_emple_code"
)
public
class
WeEmpleCode
extends
BaseEntity
{
public
class
WeEmpleCode
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/** $column.columnComment */
/**
* $column.columnComment
*/
private
Long
id
=
SnowFlakeUtil
.
nextId
();
/** 活码类型:1:单人;2:多人;3:批量; */
/**
* 活码类型:1:单人;2:多人;3:批量;
*/
private
Integer
codeType
;
/** 客户添加时无需经过确认自动成为好友:1:是;0:否 */
/**
* 客户添加时无需经过确认自动成为好友:1:是;0:否
*/
private
Boolean
isJoinConfirmFriends
;
/** 活动场景 */
/**
* 活动场景
*/
private
String
activityScene
;
/** 欢迎语 */
/**
* 欢迎语
*/
private
String
welcomeMsg
;
/** 素材的id */
/**
* 素材的id
*/
private
Long
mediaId
;
/** 0:正常;1:删除; */
private
Integer
delFlag
=
new
Integer
(
0
);
/**
* 0:正常;1:删除;
*/
private
Integer
delFlag
=
new
Integer
(
0
);
@NotEmpty
(
message
=
"员工信息不能为空"
)
/** 使用员工 */
@TableField
(
exist
=
false
)
private
List
<
WeEmpleCodeUseScop
>
weEmpleCodeUseScops
;
/** 扫码标签 */
/**
* 扫码标签
*/
@TableField
(
exist
=
false
)
private
List
<
WeEmpleCodeTag
>
weEmpleCodeTags
;
/** 扫码标签 */
/**
* 扫码标签
*/
@TableField
(
exist
=
false
)
private
WeMaterial
weMaterial
;
/** 新增联系方式的配置id */
/**
* 新增联系方式的配置id
*/
private
String
configId
;
/** 二维码链接 */
/**
* 二维码链接
*/
private
String
qrCode
;
/** 使用员工姓名 */
/**
* 使用员工姓名
*/
@TableField
(
exist
=
false
)
private
String
useUserName
;
/** 使用员工手机号 */
/**
* 使用员工手机号
*/
@TableField
(
exist
=
false
)
private
String
mobile
;
}
linkwe-wecom/src/main/java/com/linkwechat/wecom/domain/dto/customer/ExternalUserDetail.java
View file @
9929bbe
...
...
@@ -65,6 +65,8 @@ public class ExternalUserDetail extends WeResultDto {
private
Integer
add_way
;
/**发起添加的userid,如果成员主动添加,为成员的userid;如果是客户主动添加,则为客户的外部联系人userid;如果是内部成员共享/管理员分配,则为对应的成员/管理员userid*/
private
String
oper_userid
;
/** 企业自定义的state参数,用于区分客户具体是通过哪个「联系我」添加,由企业通过创建「联系我」方式指定 */
private
String
state
;
/**标签**/
private
List
<
ExternalUserTag
>
tags
;
}
...
...
linkwe-wecom/src/main/resources/mapper/wecom/WeCustomerMapper.xml
View file @
9929bbe
...
...
@@ -25,6 +25,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result
property=
"operUserid"
column=
"oper_userid"
/>
<result
property=
"addWay"
column=
"add_way"
/>
<result
property=
"state"
column=
"state"
/>
<result
property=
"status"
column=
"status"
/>
<result
property=
"userName"
column=
"user_name"
/>
<result
property=
"department"
column=
"department"
/>
<collection
property=
"weFlowerCustomerTagRels"
ofType=
"com.linkwechat.wecom.domain.WeFlowerCustomerTagRel"
>
...
...
@@ -61,6 +62,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
wfcr.oper_userid,
wfcr.add_way,
wfcr.state,
wfcr.status,
wu.user_name,
wfcrf.flower_customer_rel_id,
wt.tag_id,
...
...
@@ -107,6 +109,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if
test=
"endTime != null and endTime != ''"
>
<!-- 结束时间检索 -->
AND date_format(wfcr.create_time,'%y%m%d')
<
= date_format(#{endTime},'%y%m%d')
</if>
<if
test=
"status != null and status !=''"
>
AND wfcr.status = #{status}
</if>
</where>
</select>
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment