浏览代码

公众号筛选

wangyunpeng 2 月之前
父节点
当前提交
3c481eba92

+ 9 - 0
api-module/src/main/java/com/tzld/piaoquan/api/model/param/contentplatform/CooperateAccountListParam.java

@@ -9,4 +9,13 @@ import lombok.Data;
 public class CooperateAccountListParam extends PageParam {
 
 
+    @ApiModelProperty(value = "公众号名称")
+    private String name;
+
+    @ApiModelProperty(value = "ghId")
+    private String ghId;
+
+    @ApiModelProperty(value = "账号类型 0-公众号 1-服务号")
+    private Integer type;
+
 }

+ 18 - 0
api-module/src/main/resources/mapper/contentplatform/ext/ContentPlatformGzhAccountMapperExt.xml

@@ -17,6 +17,15 @@
     from content_platform_gzh_account
     where create_account_id = #{createAccountId}
     and status = 1
+    <if test="param.name!= null and param.name!= ''">
+      and name like concat('%', #{param.name}, '%')
+    </if>
+    <if test="param.ghId!= null and param.ghId!= ''">
+      and gh_id = #{param.ghId}
+    </if>
+    <if test="param.type!= null">
+      and type = #{param.type}
+    </if>
   </select>
 
   <select id="getCooperateAccountList"
@@ -25,6 +34,15 @@
     from content_platform_gzh_account
     where create_account_id = #{createAccountId}
       and status = 1
+    <if test="param.name!= null and param.name!= ''">
+      and name like concat('%', #{param.name}, '%')
+    </if>
+    <if test="param.ghId!= null and param.ghId!= ''">
+      and gh_id = #{param.ghId}
+    </if>
+    <if test="param.type!= null">
+      and type = #{param.type}
+    </if>
     order by create_timestamp desc
     limit #{offset}, #{pageSize}
   </select>