客服相关功能
This commit is contained in:
parent
045666041b
commit
a98e0e86a6
|
@ -43,8 +43,8 @@ public class Dept extends BaseEntity
|
||||||
/** 负责人 */
|
/** 负责人 */
|
||||||
private String leader;
|
private String leader;
|
||||||
|
|
||||||
/** 联系电话 */
|
/** 联系联系方式 */
|
||||||
@Size(min = 0, max = 11, message = "联系电话长度不能超过11个字符")
|
@Size(min = 0, max = 11, message = "联系联系方式长度不能超过11个字符")
|
||||||
private String phone;
|
private String phone;
|
||||||
|
|
||||||
/** 邮箱 */
|
/** 邮箱 */
|
||||||
|
|
|
@ -124,7 +124,7 @@ public final class RegexpUtils {
|
||||||
public static final String DATE_SLASH_REGEXP = "^[0-9]{4}\\.[0-9]{2}\\.[0-9]{2}$";
|
public static final String DATE_SLASH_REGEXP = "^[0-9]{4}\\.[0-9]{2}\\.[0-9]{2}$";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 匹配电话
|
* 匹配联系方式
|
||||||
* <p>
|
* <p>
|
||||||
* <p>
|
* <p>
|
||||||
* 格式为: 0XXX-XXXXXX(10-13位首位必须为0) 或0XXX XXXXXXX(10-13位首位必须为0) 或
|
* 格式为: 0XXX-XXXXXX(10-13位首位必须为0) 或0XXX XXXXXXX(10-13位首位必须为0) 或
|
||||||
|
|
|
@ -20,27 +20,27 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<sql id="selectAdVo">
|
<sql id="selectAdVo">
|
||||||
select
|
select
|
||||||
ad_id,
|
bad.ad_id,
|
||||||
type,
|
bad.type,
|
||||||
picture,
|
bad.picture,
|
||||||
url,
|
bad.url,
|
||||||
create_by,
|
bad.create_by,
|
||||||
create_time,
|
bad.create_time,
|
||||||
update_by,
|
bad.update_by,
|
||||||
update_time,
|
bad.update_time,
|
||||||
remark,
|
bad.remark,
|
||||||
deleted,
|
bad.deleted,
|
||||||
url_type
|
bad.url_type
|
||||||
from bst_ad
|
from bst_ad bad
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<sql id="searchCondition">
|
<sql id="searchCondition">
|
||||||
<if test="query.adId != null and query.adId != ''"> and ad_id = #{query.adId}</if>
|
<if test="query.adId != null and query.adId != ''"> and bad.ad_id = #{query.adId}</if>
|
||||||
<if test="query.type != null and query.type != ''"> and type = #{query.type}</if>
|
<if test="query.type != null and query.type != ''"> and bad.type = #{query.type}</if>
|
||||||
<if test="query.picture != null and query.picture != ''"> and picture = #{query.picture}</if>
|
<if test="query.picture != null and query.picture != ''"> and bad.picture = #{query.picture}</if>
|
||||||
<if test="query.url != null and query.url != ''"> and url = #{query.url}</if>
|
<if test="query.url != null and query.url != ''"> and bad.url = #{query.url}</if>
|
||||||
<if test="query.deleted != null "> and deleted = #{query.deleted}</if>
|
<if test="query.deleted != null "> and bad.deleted = #{query.deleted}</if>
|
||||||
<if test="query.urlType != null and query.urlType != ''"> and url_type = #{query.urlType}</if>
|
<if test="query.urlType != null and query.urlType != ''"> and bad.url_type = #{query.urlType}</if>
|
||||||
${query.params.dataScope}
|
${query.params.dataScope}
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
|
|
|
@ -59,8 +59,8 @@ public class Area extends BaseEntity
|
||||||
@ApiModelProperty("联系人")
|
@ApiModelProperty("联系人")
|
||||||
private String contact;
|
private String contact;
|
||||||
|
|
||||||
@Excel(name = "联系电话")
|
@Excel(name = "联系联系方式")
|
||||||
@ApiModelProperty("联系电话")
|
@ApiModelProperty("联系联系方式")
|
||||||
private String phone;
|
private String phone;
|
||||||
|
|
||||||
@Excel(name = "运营区状态:0-运营中;1-停运")
|
@Excel(name = "运营区状态:0-运营中;1-停运")
|
||||||
|
|
|
@ -34,8 +34,8 @@ public class CustomerService extends BaseEntity
|
||||||
@ApiModelProperty("客服姓名")
|
@ApiModelProperty("客服姓名")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
@Excel(name = "客服电话")
|
@Excel(name = "客服联系方式")
|
||||||
@ApiModelProperty("客服电话")
|
@ApiModelProperty("客服联系方式")
|
||||||
private String contact;
|
private String contact;
|
||||||
|
|
||||||
@JsonFormat(pattern = "HH:mm:ss")
|
@JsonFormat(pattern = "HH:mm:ss")
|
||||||
|
|
|
@ -1,9 +1,12 @@
|
||||||
package com.ruoyi.bst.customerService.domain;
|
package com.ruoyi.bst.customerService.domain;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
public class CustomerServiceVO extends CustomerService{
|
public class CustomerServiceVO extends CustomerService{
|
||||||
|
|
||||||
|
@ApiModelProperty("运营区名称")
|
||||||
|
private String areaName;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,19 +26,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
bcs.is_enabled,
|
bcs.is_enabled,
|
||||||
bcs.create_time,
|
bcs.create_time,
|
||||||
bcs.store_id,
|
bcs.store_id,
|
||||||
su.agent_id
|
bcs.deleted,
|
||||||
|
su.agent_id,
|
||||||
|
ba.name as area_name
|
||||||
from bst_customer_service bcs
|
from bst_customer_service bcs
|
||||||
left join sys_user su on bcs.store_id = su.user_id
|
left join sys_user su on bcs.store_id = su.user_id
|
||||||
|
left join bst_area ba on bcs.area_id = ba.id
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<sql id="searchCondition">
|
<sql id="searchCondition">
|
||||||
<if test="query.id != null "> and id = #{query.id}</if>
|
<if test="query.id != null "> and bcs.id = #{query.id}</if>
|
||||||
<if test="query.areaId != null "> and area_id = #{query.areaId}</if>
|
<if test="query.areaId != null "> and bcs.area_id = #{query.areaId}</if>
|
||||||
<if test="query.name != null and query.name != ''"> and name like concat('%', #{query.name}, '%')</if>
|
<if test="query.name != null and query.name != ''"> and bcs.name like concat('%', #{query.name}, '%')</if>
|
||||||
<if test="query.contact != null and query.contact != ''"> and contact = #{query.contact}</if>
|
<if test="query.contact != null and query.contact != ''"> and bcs.contact like concat('%',#{query.contact},'%')</if>
|
||||||
<if test="query.startTime != null "> and start_time = #{query.startTime}</if>
|
<if test="query.startTime != null "> and bcs.start_time = #{query.startTime}</if>
|
||||||
<if test="query.endTime != null "> and end_time = #{query.endTime}</if>
|
<if test="query.endTime != null "> and bcs.end_time = #{query.endTime}</if>
|
||||||
<if test="query.isEnabled != null "> and is_enabled = #{query.isEnabled}</if>
|
<if test="query.isEnabled != null "> and bcs.is_enabled = #{query.isEnabled}</if>
|
||||||
|
<if test="query.deleted != null "> and bcs.deleted = #{query.deleted}</if>
|
||||||
${@com.ruoyi.framework.util.DataScopeUtil@dataScope(
|
${@com.ruoyi.framework.util.DataScopeUtil@dataScope(
|
||||||
null,
|
null,
|
||||||
"bcs.store_id,su.agent_id",
|
"bcs.store_id,su.agent_id",
|
||||||
|
@ -59,7 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<select id="selectCustomerServiceById" parameterType="Long" resultMap="CustomerServiceResult">
|
<select id="selectCustomerServiceById" parameterType="Long" resultMap="CustomerServiceResult">
|
||||||
<include refid="selectCustomerServiceVo"/>
|
<include refid="selectCustomerServiceVo"/>
|
||||||
where id = #{id}
|
where bcs.id = #{id}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertCustomerService" parameterType="CustomerService" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insertCustomerService" parameterType="CustomerService" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
@ -219,6 +223,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
|
||||||
<sql id="updateColumns">
|
<sql id="updateColumns">
|
||||||
<if test="data.areaId != null">area_id = #{data.areaId},</if>
|
<if test="data.areaId != null">area_id = #{data.areaId},</if>
|
||||||
|
<if test="data.storeId != null">store_id = #{data.storeId},</if>
|
||||||
<if test="data.name != null">name = #{data.name},</if>
|
<if test="data.name != null">name = #{data.name},</if>
|
||||||
<if test="data.contact != null and data.contact != ''">contact = #{data.contact},</if>
|
<if test="data.contact != null and data.contact != ''">contact = #{data.contact},</if>
|
||||||
<if test="data.startTime != null">start_time = #{data.startTime},</if>
|
<if test="data.startTime != null">start_time = #{data.startTime},</if>
|
||||||
|
|
|
@ -53,6 +53,7 @@ public class CustomerServiceController extends BaseController
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
startOrderBy();
|
startOrderBy();
|
||||||
|
query.setScope(true);
|
||||||
List<CustomerServiceVO> list = customerServiceService.selectCustomerServiceList(query);
|
List<CustomerServiceVO> list = customerServiceService.selectCustomerServiceList(query);
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
@ -111,6 +112,7 @@ public class CustomerServiceController extends BaseController
|
||||||
if (!customerServiceValidator.canEdit(customerService.getId())) {
|
if (!customerServiceValidator.canEdit(customerService.getId())) {
|
||||||
return AjaxResult.error("您没有权限修改ID为" + customerService.getId() + "的客服信息");
|
return AjaxResult.error("您没有权限修改ID为" + customerService.getId() + "的客服信息");
|
||||||
}
|
}
|
||||||
|
customerService.setStoreId(areaService.selectAreaById(customerService.getAreaId()).getUserId());
|
||||||
return toAjax(customerServiceService.updateCustomerService(customerService));
|
return toAjax(customerServiceService.updateCustomerService(customerService));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user