新增美颜&线索基本信息修改相关接口
This commit is contained in:
@@ -67,6 +67,7 @@ public enum ErrorCodeEnum {
|
|||||||
NO_TRANSFER_REQUIRED(500013, "招商经理现有私海线索无需转让,请检查后重试!", null),
|
NO_TRANSFER_REQUIRED(500013, "招商经理现有私海线索无需转让,请检查后重试!", null),
|
||||||
NO_BATCH_TRANSFER_REQUIRED(500014, "已选线索包含此招商经理现有私海线索,无需转让,请检查后重试!", null),
|
NO_BATCH_TRANSFER_REQUIRED(500014, "已选线索包含此招商经理现有私海线索,无需转让,请检查后重试!", null),
|
||||||
PARTNER_MOBILE_EXIST(500010, "手机号码已存在,请核实!", null),
|
PARTNER_MOBILE_EXIST(500010, "手机号码已存在,请核实!", null),
|
||||||
|
PARTNER_MOBILE_EXIST_0(500016, "手机号码已存在", null),
|
||||||
|
|
||||||
INTERVIEW_ENTER_FAIL(1021101, "进入面试间失败", null),
|
INTERVIEW_ENTER_FAIL(1021101, "进入面试间失败", null),
|
||||||
DINGDING_USER_NOT_EXIST(1021102, "用户钉钉信息不存在,无法发起资质审核!", null),
|
DINGDING_USER_NOT_EXIST(1021102, "用户钉钉信息不存在,无法发起资质审核!", null),
|
||||||
|
|||||||
@@ -0,0 +1,46 @@
|
|||||||
|
package com.cool.store.dao;
|
||||||
|
|
||||||
|
import com.cool.store.entity.BeautyCameraSettingDO;
|
||||||
|
import com.cool.store.mapper.BeautyCameraSettingMapper;
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: BeautyCameraSettingDAO
|
||||||
|
* @Description:
|
||||||
|
* @date 2023-09-11 14:46
|
||||||
|
*/
|
||||||
|
@Repository
|
||||||
|
public class BeautyCameraSettingDAO {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BeautyCameraSettingMapper beautyCameraSettingMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 插入或更新
|
||||||
|
* @param param
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Long insertOrUpdateBeautyCameraSetting(BeautyCameraSettingDO param){
|
||||||
|
if(StringUtils.isBlank(param.getUserId())){
|
||||||
|
return 0L;
|
||||||
|
}
|
||||||
|
return beautyCameraSettingMapper.insertOrUpdateBeautyCameraSetting(param);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取用户美颜配置
|
||||||
|
* @param userId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public BeautyCameraSettingDO getBeautyCameraSetting(String userId){
|
||||||
|
if(StringUtils.isBlank(userId)){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return beautyCameraSettingMapper.getBeautyCameraSetting(userId);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -71,4 +71,11 @@ public class HyPartnerIntentInfoDAO {
|
|||||||
return hyPartnerIntentInfoMapper.updateLineId(newPartnerId,newLineId, oldLineId);
|
return hyPartnerIntentInfoMapper.updateLineId(newPartnerId,newLineId, oldLineId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int updateByPartnerLineId(HyPartnerIntentInfoDO record){
|
||||||
|
if(Objects.isNull(record.getPartnerLineId())){
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return hyPartnerIntentInfoMapper.updateByPartnerLineId(record);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,5 +75,12 @@ public class HyPartnerUserInfoDAO {
|
|||||||
return hyPartnerUserInfoMapper.updateJoinKnowById(isWritePartnerKnow, id);
|
return hyPartnerUserInfoMapper.updateJoinKnowById(isWritePartnerKnow, id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int updateByPartnerId(HyPartnerUserInfoDO record){
|
||||||
|
if(StringUtils.isBlank(record.getPartnerId())){
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
return hyPartnerUserInfoMapper.updateByPartnerId(record);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.cool.store.mapper;
|
||||||
|
|
||||||
|
import com.cool.store.entity.BeautyCameraSettingDO;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import tk.mybatis.mapper.common.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @date 2023-09-11 02:20
|
||||||
|
*/
|
||||||
|
public interface BeautyCameraSettingMapper extends Mapper<BeautyCameraSettingDO> {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 插入或更新
|
||||||
|
* @param param
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
Long insertOrUpdateBeautyCameraSetting(@Param("record") BeautyCameraSettingDO param);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取美颜配置
|
||||||
|
* @param userId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
BeautyCameraSettingDO getBeautyCameraSetting(@Param("userId") String userId);
|
||||||
|
}
|
||||||
@@ -64,4 +64,7 @@ public interface HyPartnerIntentInfoMapper {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
int updateLineId(@Param("newPartnerId")String newPartnerId,@Param("newLineId") Long newLineId, @Param("oldLineId") Long oldLineId);
|
int updateLineId(@Param("newPartnerId")String newPartnerId,@Param("newLineId") Long newLineId, @Param("oldLineId") Long oldLineId);
|
||||||
|
|
||||||
|
|
||||||
|
int updateByPartnerLineId(@Param("record") HyPartnerIntentInfoDO record);
|
||||||
}
|
}
|
||||||
@@ -47,4 +47,6 @@ public interface HyPartnerUserInfoMapper {
|
|||||||
List<SyncEcCustomerDO> selectByHourDate(@Param("selectTime") String hourDayDate, @Param("now") String now,@Param("limit1")Integer limit1,@Param("limit2")Integer limit2);
|
List<SyncEcCustomerDO> selectByHourDate(@Param("selectTime") String hourDayDate, @Param("now") String now,@Param("limit1")Integer limit1,@Param("limit2")Integer limit2);
|
||||||
|
|
||||||
int selectByHourDateCount(@Param("selectTime") String hourDayDate, @Param("now") String now);
|
int selectByHourDateCount(@Param("selectTime") String hourDayDate, @Param("now") String now);
|
||||||
|
|
||||||
|
int updateByPartnerId(@Param("record") HyPartnerUserInfoDO record);
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.cool.store.mapper.BeautyCameraSettingMapper">
|
||||||
|
<resultMap id="BaseResultMap" type="com.cool.store.entity.BeautyCameraSettingDO">
|
||||||
|
<id column="id" jdbcType="BIGINT" property="id"/>
|
||||||
|
<result column="user_id" jdbcType="VARCHAR" property="userId"/>
|
||||||
|
<result column="beauty_status" jdbcType="BIT" property="beautyStatus"/>
|
||||||
|
<result column="beauty" jdbcType="INTEGER" property="beauty"/>
|
||||||
|
<result column="brightness" jdbcType="INTEGER" property="brightness"/>
|
||||||
|
<result column="ruddy" jdbcType="INTEGER" property="ruddy"/>
|
||||||
|
<result column="deleted" jdbcType="BIT" property="deleted"/>
|
||||||
|
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
|
||||||
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
|
||||||
|
</resultMap>
|
||||||
|
<sql id="Base_Column_List">
|
||||||
|
id, user_id, beauty_status, beauty, brightness, ruddy, deleted, create_time, update_time
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<insert id="insertOrUpdateBeautyCameraSetting" keyColumn="id" keyProperty="record.id" useGeneratedKeys="true">
|
||||||
|
insert into beauty_camera_setting
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="record.userId != null">
|
||||||
|
user_id,
|
||||||
|
</if>
|
||||||
|
<if test="record.beautyStatus != null">
|
||||||
|
beauty_status,
|
||||||
|
</if>
|
||||||
|
<if test="record.beauty != null">
|
||||||
|
beauty,
|
||||||
|
</if>
|
||||||
|
<if test="record.brightness != null">
|
||||||
|
brightness,
|
||||||
|
</if>
|
||||||
|
<if test="record.ruddy != null">
|
||||||
|
ruddy,
|
||||||
|
</if>
|
||||||
|
<if test="record.deleted != null">
|
||||||
|
deleted,
|
||||||
|
</if>
|
||||||
|
<if test="record.createTime != null">
|
||||||
|
create_time,
|
||||||
|
</if>
|
||||||
|
<if test="record.updateTime != null">
|
||||||
|
update_time,
|
||||||
|
</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="record.userId != null">
|
||||||
|
#{record.userId},
|
||||||
|
</if>
|
||||||
|
<if test="record.beautyStatus != null">
|
||||||
|
#{record.beautyStatus},
|
||||||
|
</if>
|
||||||
|
<if test="record.beauty != null">
|
||||||
|
#{record.beauty},
|
||||||
|
</if>
|
||||||
|
<if test="record.brightness != null">
|
||||||
|
#{record.brightness},
|
||||||
|
</if>
|
||||||
|
<if test="record.ruddy != null">
|
||||||
|
#{record.ruddy},
|
||||||
|
</if>
|
||||||
|
<if test="record.deleted != null">
|
||||||
|
#{record.deleted},
|
||||||
|
</if>
|
||||||
|
<if test="record.createTime != null">
|
||||||
|
#{record.createTime},
|
||||||
|
</if>
|
||||||
|
<if test="record.updateTime != null">
|
||||||
|
#{record.updateTime},
|
||||||
|
</if>
|
||||||
|
</trim>
|
||||||
|
ON DUPLICATE KEY UPDATE beauty_status = values(beauty_status), beauty = values(beauty), brightness = values(brightness), ruddy = values(ruddy)
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<select id="getBeautyCameraSetting" resultMap="BaseResultMap">
|
||||||
|
select <include refid="Base_Column_List"/> from beauty_camera_setting where user_id = #{userId} and deleted = 0
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
@@ -337,6 +337,71 @@
|
|||||||
where partner_line_id = #{oldLineId}
|
where partner_line_id = #{oldLineId}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPartnerLineId">
|
||||||
|
update hy_partner_intent_info
|
||||||
|
<set>
|
||||||
|
<if test="record.liveArea != null">
|
||||||
|
live_area = #{record.liveArea},
|
||||||
|
</if>
|
||||||
|
<if test="record.wantShopArea != null">
|
||||||
|
want_shop_area = #{record.wantShopArea},
|
||||||
|
</if>
|
||||||
|
<if test="record.acceptAdjustType != null">
|
||||||
|
accept_adjust_type = #{record.acceptAdjustType},
|
||||||
|
</if>
|
||||||
|
<if test="record.isHaveWantShop != null">
|
||||||
|
is_have_want_shop = #{record.isHaveWantShop},
|
||||||
|
</if>
|
||||||
|
<if test="record.wantShopInfo != null">
|
||||||
|
want_shop_info = #{record.wantShopInfo},
|
||||||
|
</if>
|
||||||
|
<if test="record.maxBudget != null">
|
||||||
|
max_budget = #{record.maxBudget},
|
||||||
|
</if>
|
||||||
|
<if test="record.moneySource != null">
|
||||||
|
money_source = #{record.moneySource},
|
||||||
|
</if>
|
||||||
|
<if test="record.moneyProve != null">
|
||||||
|
money_prove = #{record.moneyProve},
|
||||||
|
</if>
|
||||||
|
<if test="record.education != null">
|
||||||
|
education = #{record.education},
|
||||||
|
</if>
|
||||||
|
<if test="record.workYear != null">
|
||||||
|
work_year = #{record.workYear},
|
||||||
|
</if>
|
||||||
|
<if test="record.isHaveWorkExp != null">
|
||||||
|
is_have_work_exp = #{record.isHaveWorkExp},
|
||||||
|
</if>
|
||||||
|
<if test="record.workExp != null">
|
||||||
|
work_exp = #{record.workExp},
|
||||||
|
</if>
|
||||||
|
<if test="record.isConsumer != null">
|
||||||
|
is_consumer = #{record.isConsumer},
|
||||||
|
</if>
|
||||||
|
<if test="record.otherBand != null">
|
||||||
|
other_band = #{record.otherBand},
|
||||||
|
</if>
|
||||||
|
<if test="record.brandStrength != null">
|
||||||
|
brand_strength = #{record.brandStrength},
|
||||||
|
</if>
|
||||||
|
<if test="record.needImprove != null">
|
||||||
|
need_improve = #{record.needImprove},
|
||||||
|
</if>
|
||||||
|
<if test="record.strength != null">
|
||||||
|
strength = #{record.strength},
|
||||||
|
</if>
|
||||||
|
<if test="record.weakness != null">
|
||||||
|
weakness = #{record.weakness},
|
||||||
|
</if>
|
||||||
|
<if test="record.createTime != null">
|
||||||
|
create_time = #{record.createTime},
|
||||||
|
</if>
|
||||||
|
<if test="record.updateTime != null">
|
||||||
|
update_time = #{record.updateTime},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where partner_line_id = #{record.partnerLineId}
|
||||||
|
</update>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -282,4 +282,56 @@
|
|||||||
where id=#{id,jdbcType=BIGINT}
|
where id=#{id,jdbcType=BIGINT}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPartnerId">
|
||||||
|
update hy_partner_user_info
|
||||||
|
<set>
|
||||||
|
<if test="record.mobile != null">
|
||||||
|
mobile = #{record.mobile},
|
||||||
|
</if>
|
||||||
|
<if test="record.username != null">
|
||||||
|
username = #{record.username},
|
||||||
|
</if>
|
||||||
|
<if test="record.liveArea != null">
|
||||||
|
live_area = #{record.liveArea},
|
||||||
|
</if>
|
||||||
|
<if test="record.wantShopArea != null">
|
||||||
|
want_shop_area = #{record.wantShopArea},
|
||||||
|
</if>
|
||||||
|
<if test="record.acceptAdjustType != null">
|
||||||
|
accept_adjust_type = #{record.acceptAdjustType},
|
||||||
|
</if>
|
||||||
|
<if test="record.inviteCode != null">
|
||||||
|
invite_code = #{record.inviteCode},
|
||||||
|
</if>
|
||||||
|
<if test="record.isWritePartnerKnow != null">
|
||||||
|
is_write_partner_know = #{record.isWritePartnerKnow},
|
||||||
|
</if>
|
||||||
|
<if test="record.createTime != null">
|
||||||
|
create_time = #{record.createTime},
|
||||||
|
</if>
|
||||||
|
<if test="record.updateTime != null">
|
||||||
|
update_time = #{record.updateTime},
|
||||||
|
</if>
|
||||||
|
<if test="record.shopCode != null">
|
||||||
|
shop_code = #{record.shopCode},
|
||||||
|
</if>
|
||||||
|
<if test="record.shopName != null">
|
||||||
|
shop_name = #{record.shopName},
|
||||||
|
</if>
|
||||||
|
<if test="record.shopId != null">
|
||||||
|
shop_id = #{record.shopId},
|
||||||
|
</if>
|
||||||
|
<if test="record.recommendPartnerId != null">
|
||||||
|
recommend_partner_id = #{record.recommendPartnerId},
|
||||||
|
</if>
|
||||||
|
<if test="record.recommendPartnerName != null">
|
||||||
|
recommend_partner_name = #{record.recommendPartnerName},
|
||||||
|
</if>
|
||||||
|
<if test="record.recommendPartnerMobile != null">
|
||||||
|
recommend_partner_mobile = #{record.recommendPartnerMobile},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where partner_id = #{record.partnerId}
|
||||||
|
</update>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -0,0 +1,49 @@
|
|||||||
|
package com.cool.store.entity;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import javax.persistence.Table;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @date 2023-09-11 02:20
|
||||||
|
*/
|
||||||
|
@Table(name = "beauty_camera_setting")
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class BeautyCameraSettingDO implements Serializable {
|
||||||
|
@ApiModelProperty("主键id")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@ApiModelProperty("用户id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜状态0未开启,1开启")
|
||||||
|
private Boolean beautyStatus;
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜度")
|
||||||
|
private Integer beauty;
|
||||||
|
|
||||||
|
@ApiModelProperty("明亮度")
|
||||||
|
private Integer brightness;
|
||||||
|
|
||||||
|
@ApiModelProperty("红润")
|
||||||
|
private Integer ruddy;
|
||||||
|
|
||||||
|
@ApiModelProperty("删除标识")
|
||||||
|
private Boolean deleted;
|
||||||
|
|
||||||
|
@ApiModelProperty("用户创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
|
||||||
|
@ApiModelProperty("修改时间")
|
||||||
|
private Date updateTime;
|
||||||
|
}
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
package com.cool.store.request;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: EditBaseInfoRequest
|
||||||
|
* @Description:
|
||||||
|
* @date 2023-09-13 10:29
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class EditBaseInfoRequest {
|
||||||
|
|
||||||
|
@ApiModelProperty("线索id")
|
||||||
|
private Long partnerLineId;
|
||||||
|
|
||||||
|
@ApiModelProperty("姓名")
|
||||||
|
private String username;
|
||||||
|
|
||||||
|
@ApiModelProperty("手机号")
|
||||||
|
private String mobile;
|
||||||
|
|
||||||
|
@ApiModelProperty("意向区域")
|
||||||
|
private String wantShopArea;
|
||||||
|
|
||||||
|
@ApiModelProperty("调剂方式")
|
||||||
|
private Integer acceptAdjustType;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.cool.store.request.beauty;
|
||||||
|
|
||||||
|
import com.cool.store.entity.BeautyCameraSettingDO;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: AddBeautyCameraSettingRequest
|
||||||
|
* @Description: 新增美颜配置
|
||||||
|
* @date 2023-09-11 14:31
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class AddBeautyCameraSettingRequest {
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜状态0未开启,1开启")
|
||||||
|
private Boolean beautyStatus;
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜度")
|
||||||
|
private Integer beauty;
|
||||||
|
|
||||||
|
@ApiModelProperty("明亮度")
|
||||||
|
private Integer brightness;
|
||||||
|
|
||||||
|
@ApiModelProperty("红润")
|
||||||
|
private Integer ruddy;
|
||||||
|
|
||||||
|
|
||||||
|
public static BeautyCameraSettingDO convertDO(String userId, AddBeautyCameraSettingRequest request){
|
||||||
|
BeautyCameraSettingDO result = new BeautyCameraSettingDO();
|
||||||
|
result.setUserId(userId);
|
||||||
|
result.setBeautyStatus(request.getBeautyStatus());
|
||||||
|
result.setBeauty(request.getBeauty());
|
||||||
|
result.setBrightness(request.getBrightness());
|
||||||
|
result.setRuddy(request.getRuddy());
|
||||||
|
result.setCreateTime(new Date());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.cool.store.vo.beauty;
|
||||||
|
|
||||||
|
import com.cool.store.entity.BeautyCameraSettingDO;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: BeautyCameraSettingVO
|
||||||
|
* @Description:
|
||||||
|
* @date 2023-09-11 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class BeautyCameraSettingVO {
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜状态0未开启,1开启")
|
||||||
|
private Boolean beautyStatus;
|
||||||
|
|
||||||
|
@ApiModelProperty("美颜度")
|
||||||
|
private Integer beauty;
|
||||||
|
|
||||||
|
@ApiModelProperty("明亮度")
|
||||||
|
private Integer brightness;
|
||||||
|
|
||||||
|
@ApiModelProperty("红润")
|
||||||
|
private Integer ruddy;
|
||||||
|
|
||||||
|
public static BeautyCameraSettingVO convertVO(BeautyCameraSettingDO request){
|
||||||
|
if(Objects.isNull(request)){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
BeautyCameraSettingVO result = new BeautyCameraSettingVO();
|
||||||
|
result.setBeautyStatus(request.getBeautyStatus());
|
||||||
|
result.setBeauty(request.getBeauty());
|
||||||
|
result.setBrightness(request.getBrightness());
|
||||||
|
result.setRuddy(request.getRuddy());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
package com.cool.store.vo.partner;
|
||||||
|
|
||||||
|
import com.cool.store.dto.partner.UserPortraitDTO;
|
||||||
|
import com.cool.store.entity.HyPartnerUserInfoDO;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: PartnerBaseInfoVO
|
||||||
|
* @Description:
|
||||||
|
* @date 2023-09-13 16:47
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class PartnerSimpleBaseInfoVO {
|
||||||
|
|
||||||
|
@ApiModelProperty("线索id")
|
||||||
|
private Long partnerLineId;
|
||||||
|
|
||||||
|
@ApiModelProperty("姓名")
|
||||||
|
private String username;
|
||||||
|
|
||||||
|
@ApiModelProperty("手机号")
|
||||||
|
private String mobile;
|
||||||
|
|
||||||
|
@ApiModelProperty("意向区域")
|
||||||
|
private String wantShopArea;
|
||||||
|
|
||||||
|
@ApiModelProperty("调剂方式")
|
||||||
|
private Integer acceptAdjustType;
|
||||||
|
|
||||||
|
@ApiModelProperty("加盟申请基本信息ID")
|
||||||
|
private Long partnerBaseInfoId;
|
||||||
|
|
||||||
|
@ApiModelProperty("用户画像")
|
||||||
|
private List<UserPortraitDTO> userPortrait;
|
||||||
|
|
||||||
|
public static PartnerSimpleBaseInfoVO convertVO(Long partnerLineId, HyPartnerUserInfoDO partnerUserInfo){
|
||||||
|
if(Objects.isNull(partnerUserInfo)){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
PartnerSimpleBaseInfoVO result = new PartnerSimpleBaseInfoVO();
|
||||||
|
result.setPartnerLineId(partnerLineId);
|
||||||
|
result.setUsername(partnerUserInfo.getUsername());
|
||||||
|
result.setMobile(partnerUserInfo.getMobile());
|
||||||
|
result.setWantShopArea(partnerUserInfo.getWantShopArea());
|
||||||
|
result.setAcceptAdjustType(partnerUserInfo.getAcceptAdjustType());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
package com.cool.store.service;
|
||||||
|
|
||||||
|
import com.cool.store.request.beauty.AddBeautyCameraSettingRequest;
|
||||||
|
import com.cool.store.vo.beauty.BeautyCameraSettingVO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: BeautyCameraSettingService
|
||||||
|
* @Description: 美颜配置service
|
||||||
|
* @date 2023-09-11 14:23
|
||||||
|
*/
|
||||||
|
public interface BeautyCameraSettingService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* AddBeautyCameraSettingRequest request
|
||||||
|
* @param userId
|
||||||
|
* @param request
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
Long saveBeautyCameraSetting(String userId, AddBeautyCameraSettingRequest request);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取美颜配置
|
||||||
|
* @param userId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
BeautyCameraSettingVO queryBeautyCameraSetting(String userId);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -6,6 +6,7 @@ import com.cool.store.exception.ApiException;
|
|||||||
import com.cool.store.request.*;
|
import com.cool.store.request.*;
|
||||||
import com.cool.store.vo.*;
|
import com.cool.store.vo.*;
|
||||||
import com.cool.store.vo.interview.InterviewVO;
|
import com.cool.store.vo.interview.InterviewVO;
|
||||||
|
import com.cool.store.vo.partner.PartnerSimpleBaseInfoVO;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -162,4 +163,17 @@ public interface HyPartnerLineInfoService {
|
|||||||
|
|
||||||
Long checkGenerateNewLineId(Long lineId);
|
Long checkGenerateNewLineId(Long lineId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑加盟商基本信息
|
||||||
|
* @param request
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
Integer editBaseInfo(EditBaseInfoRequest request);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取加盟商基本信息
|
||||||
|
* @param partnerLineId
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
PartnerSimpleBaseInfoVO queryBaseInfo(Long partnerLineId);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,35 @@
|
|||||||
|
package com.cool.store.service.impl;
|
||||||
|
|
||||||
|
import com.cool.store.dao.BeautyCameraSettingDAO;
|
||||||
|
import com.cool.store.entity.BeautyCameraSettingDO;
|
||||||
|
import com.cool.store.request.beauty.AddBeautyCameraSettingRequest;
|
||||||
|
import com.cool.store.service.BeautyCameraSettingService;
|
||||||
|
import com.cool.store.vo.beauty.BeautyCameraSettingVO;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: BeautyCameraSettingServiceImpl
|
||||||
|
* @Description:
|
||||||
|
* @date 2023-09-11 14:23
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class BeautyCameraSettingServiceImpl implements BeautyCameraSettingService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BeautyCameraSettingDAO beautyCameraSettingDAO;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Long saveBeautyCameraSetting(String userId, AddBeautyCameraSettingRequest request) {
|
||||||
|
BeautyCameraSettingDO beautyCameraSettingDO = AddBeautyCameraSettingRequest.convertDO(userId, request);
|
||||||
|
return beautyCameraSettingDAO.insertOrUpdateBeautyCameraSetting(beautyCameraSettingDO);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BeautyCameraSettingVO queryBeautyCameraSetting(String userId) {
|
||||||
|
BeautyCameraSettingDO beautyCameraSetting = beautyCameraSettingDAO.getBeautyCameraSetting(userId);
|
||||||
|
return BeautyCameraSettingVO.convertVO(beautyCameraSetting);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -23,9 +23,9 @@ import com.cool.store.utils.RedisUtilPool;
|
|||||||
import com.cool.store.utils.StringUtil;
|
import com.cool.store.utils.StringUtil;
|
||||||
import com.cool.store.vo.*;
|
import com.cool.store.vo.*;
|
||||||
import com.cool.store.vo.interview.InterviewVO;
|
import com.cool.store.vo.interview.InterviewVO;
|
||||||
|
import com.cool.store.vo.partner.PartnerSimpleBaseInfoVO;
|
||||||
import com.github.pagehelper.PageHelper;
|
import com.github.pagehelper.PageHelper;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
import com.google.common.collect.Lists;
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
@@ -93,6 +93,8 @@ public class HyPartnerLineInfoServiceImpl implements HyPartnerLineInfoService {
|
|||||||
private SmsService smsService;
|
private SmsService smsService;
|
||||||
@Resource
|
@Resource
|
||||||
HyFollowTaskDAO hyFollowTaskDAO;
|
HyFollowTaskDAO hyFollowTaskDAO;
|
||||||
|
@Resource
|
||||||
|
private HyPartnerIntentInfoDAO hyPartnerIntentInfoDAO;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public StageCountVO selectStagePendingCount(String userId) {
|
public StageCountVO selectStagePendingCount(String userId) {
|
||||||
@@ -850,6 +852,54 @@ public class HyPartnerLineInfoServiceImpl implements HyPartnerLineInfoService {
|
|||||||
return hyPartnerLineInfoDO.getId();
|
return hyPartnerLineInfoDO.getId();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public Integer editBaseInfo(EditBaseInfoRequest request) {
|
||||||
|
HyPartnerLineInfoDO lineInfo = hyPartnerLineInfoDAO.selectByPrimaryKeySelective(request.getPartnerLineId());
|
||||||
|
if(Objects.isNull(lineInfo)){
|
||||||
|
throw new ServiceException(ErrorCodeEnum.LINE_ID_IS_NOT_EXIST);
|
||||||
|
}
|
||||||
|
HyPartnerUserInfoDO partnerUserInfo = hyPartnerUserInfoDAO.selectByMobile(request.getMobile());
|
||||||
|
if(Objects.nonNull(partnerUserInfo) && !lineInfo.getPartnerId().equals(partnerUserInfo.getPartnerId())){
|
||||||
|
throw new ServiceException(ErrorCodeEnum.PARTNER_MOBILE_EXIST_0);
|
||||||
|
}
|
||||||
|
HyPartnerUserInfoDO update = new HyPartnerUserInfoDO();
|
||||||
|
update.setPartnerId(lineInfo.getPartnerId());
|
||||||
|
update.setUsername(request.getUsername());
|
||||||
|
update.setMobile(request.getMobile());
|
||||||
|
update.setWantShopArea(request.getWantShopArea());
|
||||||
|
update.setAcceptAdjustType(request.getAcceptAdjustType());
|
||||||
|
hyPartnerUserInfoDAO.updateByPartnerId(update);
|
||||||
|
hyPartnerBaseInfoDAO.updateByPartnerId(request.getUsername(), request.getMobile(), lineInfo.getPartnerId());
|
||||||
|
HyPartnerIntentInfoDO updateIntentInfo = new HyPartnerIntentInfoDO();
|
||||||
|
updateIntentInfo.setPartnerLineId(request.getPartnerLineId());
|
||||||
|
updateIntentInfo.setAcceptAdjustType(request.getAcceptAdjustType());
|
||||||
|
updateIntentInfo.setWantShopArea(request.getWantShopArea());
|
||||||
|
hyPartnerIntentInfoDAO.updateByPartnerLineId(updateIntentInfo);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PartnerSimpleBaseInfoVO queryBaseInfo(Long partnerLineId) {
|
||||||
|
HyPartnerLineInfoDO lineInfo = hyPartnerLineInfoDAO.selectByPrimaryKeySelective(partnerLineId);
|
||||||
|
if(Objects.isNull(lineInfo)){
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
HyPartnerUserInfoDO partnerUserInfo = hyPartnerUserInfoDAO.selectByPartnerId(lineInfo.getPartnerId());
|
||||||
|
HyPartnerBaseInfoDO partnerBaseInfo = hyPartnerBaseInfoDAO.getByPartnerLineId(partnerLineId);
|
||||||
|
PartnerSimpleBaseInfoVO result = PartnerSimpleBaseInfoVO.convertVO(partnerLineId, partnerUserInfo);
|
||||||
|
String userPortrait = Optional.ofNullable(partnerBaseInfo).map(o->o.getUserPortrait()).orElse(null);
|
||||||
|
if (StringUtils.isNotEmpty(userPortrait) && Objects.nonNull(result)){
|
||||||
|
Map<Long, String> userPortraitMap = labelService.getUserPortraitMap(Arrays.asList(userPortrait));
|
||||||
|
List<UserPortraitDTO> userPortraitList = userPortraitMap.entrySet().stream()
|
||||||
|
.map(entry -> new UserPortraitDTO(entry.getKey(), entry.getValue()))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
result.setPartnerBaseInfoId(partnerBaseInfo.getId());
|
||||||
|
result.setUserPortrait(userPortraitList);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* convertPartnerBlackListDTOToVo
|
* convertPartnerBlackListDTOToVo
|
||||||
|
|||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package com.cool.store.controller;
|
||||||
|
|
||||||
|
import com.cool.store.context.CurrentUserHolder;
|
||||||
|
import com.cool.store.request.beauty.AddBeautyCameraSettingRequest;
|
||||||
|
import com.cool.store.response.ResponseResult;
|
||||||
|
import com.cool.store.service.BeautyCameraSettingService;
|
||||||
|
import com.cool.store.vo.beauty.BeautyCameraSettingVO;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author zhangchenbiao
|
||||||
|
* @FileName: BeautyCameraSettingController
|
||||||
|
* @Description: 美颜配置
|
||||||
|
* @date 2023-09-11 14:21
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@Api(tags = "美颜配置")
|
||||||
|
public class BeautyCameraSettingController {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BeautyCameraSettingService beautyCameraSettingService;
|
||||||
|
|
||||||
|
|
||||||
|
@PostMapping("/saveBeautyCameraSetting")
|
||||||
|
public ResponseResult<Long> saveBeautyCameraSetting(@RequestBody AddBeautyCameraSettingRequest request){
|
||||||
|
Long result = beautyCameraSettingService.saveBeautyCameraSetting(CurrentUserHolder.getUserId(), request);
|
||||||
|
return ResponseResult.success(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/queryBeautyCameraSetting")
|
||||||
|
public ResponseResult<BeautyCameraSettingVO> queryBeautyCameraSetting(){
|
||||||
|
return ResponseResult.success(beautyCameraSettingService.queryBeautyCameraSetting(CurrentUserHolder.getUserId()));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -11,6 +11,7 @@ import com.cool.store.response.ResponseResult;
|
|||||||
import com.cool.store.service.*;
|
import com.cool.store.service.*;
|
||||||
import com.cool.store.vo.*;
|
import com.cool.store.vo.*;
|
||||||
import com.cool.store.vo.interview.InterviewVO;
|
import com.cool.store.vo.interview.InterviewVO;
|
||||||
|
import com.cool.store.vo.partner.PartnerSimpleBaseInfoVO;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
import io.swagger.annotations.ApiImplicitParam;
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
import io.swagger.annotations.ApiImplicitParams;
|
import io.swagger.annotations.ApiImplicitParams;
|
||||||
@@ -314,4 +315,16 @@ public class DeskController {
|
|||||||
@RequestParam(value = "needDevelopmentDirector",required = false)Boolean needDevelopmentDirector) throws ApiException {
|
@RequestParam(value = "needDevelopmentDirector",required = false)Boolean needDevelopmentDirector) throws ApiException {
|
||||||
return ResponseResult.success(hyPartnerLineInfoService.getInterviewInfo(lineId,needDevelopmentDirector));
|
return ResponseResult.success(hyPartnerLineInfoService.getInterviewInfo(lineId,needDevelopmentDirector));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@PostMapping(path = "/editBaseInfo")
|
||||||
|
@ApiOperation("修改接口")
|
||||||
|
public ResponseResult<Integer> editBaseInfo(@RequestBody EditBaseInfoRequest request){
|
||||||
|
return ResponseResult.success(hyPartnerLineInfoService.editBaseInfo(request));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping(path = "/queryBaseInfo")
|
||||||
|
@ApiOperation("获取数据接口")
|
||||||
|
public ResponseResult<PartnerSimpleBaseInfoVO> queryBaseInfo(@RequestParam(value = "partnerLineId")Long partnerLineId){
|
||||||
|
return ResponseResult.success(hyPartnerLineInfoService.queryBaseInfo(partnerLineId));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user