Browse Source

达人截图

yumeng 11 tháng trước cách đây
mục cha
commit
afad43c7bf

+ 9 - 8
ruixuan-live/src/main/java/com/ruixuan/isc/controller/KuaishouPromoterController.java

@@ -92,14 +92,15 @@ public class KuaishouPromoterController extends BaseController {
                               @ApiParam("媒体") @RequestParam(value = "mediaId", required = false) String mediaId,
                               @ApiParam("排序参数") @RequestParam(value = "parameter", required = false) String parameter,
                               @ApiParam("正序倒叙") @RequestParam(value = "orderBy", required = false) String orderBy,
-                              @ApiParam("绑定人") @RequestParam(value = "bdUserId", required = false) Long bdUserId
+                              @ApiParam("绑定人") @RequestParam(value = "bdUserId", required = false) Long bdUserId,
+                              @ApiParam("地址筛选") @RequestParam(value = "searchPhone", required = false) Integer searchPhone
 
     ) {
 
         if (Check.isNotNull(promoterId)) {
             promoterId = promoterId.trim();
         }
-        List<KuaishouPromoter> list = kuaishouPromoterService.selectKuaishouPromoterList(userId, promoterId, promoterNickName, mediaId, parameter, orderBy, bdUserId);
+        List<KuaishouPromoter> list = kuaishouPromoterService.selectKuaishouPromoterList(userId, promoterId, promoterNickName, mediaId, parameter, orderBy, bdUserId,searchPhone);
         return getDataTable(list);
     }
 
@@ -151,9 +152,9 @@ public class KuaishouPromoterController extends BaseController {
     public JSONObject jyExpertBusiness() {
         JSONObject jsonObject = new JSONObject();
         List<JSONObject> list = kuaishouPromoterService.jyExpertBusiness();
-        jsonObject.put("code",200);
-        jsonObject.put("success",true);
-        jsonObject.put("data",list);
+        jsonObject.put("code", 200);
+        jsonObject.put("success", true);
+        jsonObject.put("data", list);
         return jsonObject;
     }
 
@@ -164,9 +165,9 @@ public class KuaishouPromoterController extends BaseController {
     public JSONObject jyExpertMentorList() {
         JSONObject jsonObject = new JSONObject();
         List<JSONObject> list = kuaishouPromoterService.jyExpertMentorList();
-        jsonObject.put("code",200);
-        jsonObject.put("success",true);
-        jsonObject.put("data",list);
+        jsonObject.put("code", 200);
+        jsonObject.put("success", true);
+        jsonObject.put("data", list);
         return jsonObject;
     }
 

+ 4 - 0
ruixuan-live/src/main/java/com/ruixuan/isc/entity/KuaishouPromoter.java

@@ -86,6 +86,7 @@ public class KuaishouPromoter {
      */
     @ApiModelProperty(name = "联系电话")
     private String phone;
+    private String imageUrl;
     /**
      * 总销售额
      */
@@ -195,6 +196,9 @@ public class KuaishouPromoter {
     @Transient
     private String ruleName;
 
+    @Transient
+    private Long tabName;
+
     public KuaishouPromoter() {
     }
 

+ 3 - 1
ruixuan-live/src/main/java/com/ruixuan/isc/mapper/KuaishouPromoterMapper.java

@@ -26,7 +26,9 @@ public interface KuaishouPromoterMapper {
                                                              @Param("promoterNickName") String promoterNickName,
                                                              @Param("mediaId") String mediaId,
                                                              @Param("parameter") String parameter, @Param("orderBy") String orderBy,
-                                                             @Param("bdUserId") Long bdUserId);
+                                                             @Param("bdUserId") Long bdUserId,
+                                                             @Param("searchPhone") Integer  searchPhone
+                                                             );
 
     public List<JYKuaishouPromoter> selectKuaishouPromoterList3(@Param("userList") List<Long> userList, @Param("promoterId") String promoterId,
                                                                 @Param("promoterNickName") String promoterNickName,

+ 1 - 1
ruixuan-live/src/main/java/com/ruixuan/isc/service/IKuaishouPromoterService.java

@@ -29,7 +29,7 @@ public interface IKuaishouPromoterService {
      *
      * @return 快手达人 信息集合
      */
-    public List<KuaishouPromoter> selectKuaishouPromoterList(Long userId, String promoterId, String promoterNickName, String mediaId, String parameter, String orderBy, Long bdUserId);
+    public List<KuaishouPromoter> selectKuaishouPromoterList(Long userId, String promoterId, String promoterNickName, String mediaId, String parameter, String orderBy, Long bdUserId,Integer searchPhone);
 
     public List<JYKuaishouPromoter> selectKuaishouPromoterList3(Long userId, String promoterId, String promoterNickName, String mediaId, String type, String parameter, String orderBy);
 

+ 2 - 2
ruixuan-live/src/main/java/com/ruixuan/isc/service/impl/KuaishouPromoterServiceImpl.java

@@ -94,7 +94,7 @@ public class KuaishouPromoterServiceImpl implements IKuaishouPromoterService {
      * @return 快手达人 信息
      */
     @Override
-    public List<KuaishouPromoter> selectKuaishouPromoterList(Long userId, String promoterId, String promoterNickName, String mediaId, String parameter, String orderBy, Long bdUserId) {
+    public List<KuaishouPromoter> selectKuaishouPromoterList(Long userId, String promoterId, String promoterNickName, String mediaId, String parameter, String orderBy, Long bdUserId, Integer searchPhone) {
         String roleKey = sysUserService.getRoleKeyByUserId(userId);
         List<Long> userList = new ArrayList<>();
         //角色:供应链管理员、招商、招商经理可以看到所有的达人信息
@@ -138,7 +138,7 @@ public class KuaishouPromoterServiceImpl implements IKuaishouPromoterService {
             orderBy = "desc";
         }
         PageUtils.startPage();
-        List<KuaishouPromoter> list = kuaishouPromoterMapper.selectKuaishouPromoterList(userList, promoterId, promoterNickName, mediaId, parameter, orderBy, bdUserId);
+        List<KuaishouPromoter> list = kuaishouPromoterMapper.selectKuaishouPromoterList(userList, promoterId, promoterNickName, mediaId, parameter, orderBy, bdUserId, searchPhone);
         list.forEach(ent -> {
             JSONObject follow = kuaishouPromoterMapper.getFollowUpRecordsByUserId(ent.getPromoterId(), ent.getUserId());
             ent.setFollowUpRecord(Check.isNull(follow) ? "-" : follow.getString("txt"));

+ 14 - 0
ruixuan-live/src/main/resources/mapper/isc/KuaishouPromoterMapper.xml

@@ -34,6 +34,7 @@
         <result property="awemeDiggFollowerRation" column="aweme_digg_follower_ration"/>
         <result property="liveAverageUser30" column="live_average_user_30"/>
         <result property="followUpRecord" column="txt"/>
+        <result property="imageUrl" column="image_url"/>
     </resultMap>
 
     <sql id="selectKuaishouPromoterVo">
@@ -55,6 +56,7 @@
                fans_number,
                avg_video_sales,
                video_sales,
+               image_url,
                create_time,
                update_time
         from kuaishou_promoter
@@ -76,6 +78,7 @@
         t1.phone,
         t1.consignee,
         t1.promoter_address,
+        t1.image_url,
         if(t1.media_id = 1, t1.total_sale,t3.total_sale ) as 'total_sale',
         if(t1.media_id = 1, t1.fans_number,t3.fans_number ) as 'fans_number',
         if(t1.media_id = 1, t1.avg_video_sales,t3.avg_video_sales ) as 'avg_video_sales',
@@ -123,6 +126,13 @@
             <if test="mediaId != null  and mediaId != ''">
                 and t1.media_id = #{mediaId}
             </if>
+
+            <if test="searchPhone != null  and searchPhone  == 1">
+                and t1.phone != ''
+            </if>
+            <if test="searchPhone != null  and searchPhone  == 2">
+                and t1.phone = ''
+            </if>
         </where>
         order by ${parameter} ${orderBy}
     </select>
@@ -485,6 +495,7 @@
             <if test="phone != null">phone,</if>
             <if test="consignee != null">consignee,</if>
             <if test="promoterAddress != null">promoter_address,</if>
+            <if test="imageUrl != null">image_url,</if>
         </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="userId != null">#{userId},</if>
@@ -504,6 +515,7 @@
             <if test="phone != null">#{phone},</if>
             <if test="consignee != null">#{consignee},</if>
             <if test="promoterAddress != null">#{promoterAddress},</if>
+            <if test="imageUrl != null">#{imageUrl},</if>
         </trim>
     </insert>
 
@@ -598,6 +610,7 @@
             <if test="categoryRequirement != null">category_requirement = #{categoryRequirement},</if>
             <if test="avgVideoSales != null">avg_video_sales = #{avgVideoSales},</if>
             <if test="videoSales != null">video_sales = #{videoSales},</if>
+            <if test="imageUrl != null">image_url = #{imageUrl},</if>
             <if test="createTime != null">create_time = #{createTime},</if>
             <if test="updateTime != null">update_time = #{updateTime},</if>
         </trim>
@@ -662,6 +675,7 @@
             <if test="awemeAvgDiggCount30 != null">aweme_avg_digg_count_30 = #{awemeAvgDiggCount30},</if>
             <if test="awemeDiggFollowerRation != null">aweme_digg_follower_ration = #{awemeDiggFollowerRation},</if>
             <if test="liveAverageUser30 != null">live_average_user_30 = #{liveAverageUser30},</if>
+            <if test="imageUrl != null">image_url = #{imageUrl},</if>
         </trim>
         where promoter_id = #{promoterId}
     </update>