Forráskód Böngészése

更改我的欢迎语、部门欢迎语
增加我的欢迎语,部门欢迎语字段参数

yfh 1 hete
szülő
commit
58b9c422ef

+ 7 - 0
fs-company/src/main/java/com/fs/company/controller/qw/QwUserController.java

@@ -1,5 +1,6 @@
 package com.fs.company.controller.qw;
 
+import cn.hutool.core.util.ObjectUtil;
 import com.alibaba.fastjson.JSON;
 import com.fs.common.annotation.Log;
 import com.fs.common.annotation.RepeatSubmit;
@@ -392,6 +393,12 @@ public class QwUserController extends BaseController
         startPage();
         LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
         qwUser.setCompanyId(loginUser.getCompany().getCompanyId());
+        if (ObjectUtil.isNotEmpty(qwUser.getIsRemark())&&qwUser.getIsRemark().equals("1")){
+            qwUser.setCompanyUserId(loginUser.getUser().getUserId());
+        }else if (ObjectUtil.isNotEmpty(qwUser.getIsRemark())&&qwUser.getIsRemark().equals("2")){
+            qwUser.setDeptId(loginUser.getUser().getDeptId());
+            qwUser.setCorpId(null);
+        }
 
         List<QwUserVO> list = qwUserService.selectQwUserListVO(qwUser);
         return getDataTable(list);

+ 6 - 0
fs-service/src/main/java/com/fs/qw/domain/QwFriendWelcome.java

@@ -45,6 +45,12 @@ public class QwFriendWelcome extends BaseEntity
     @Excel(name = "开启分时段之后的存储")
     private String daypartingItemlist;
 
+    /**
+     * 欢迎语标题
+     */
+    @Excel(name = "欢迎语标题")
+    private String welcomeTitle;
+
     /** 公司id */
     @Excel(name = "公司id")
     private Long companyId;

+ 1 - 0
fs-service/src/main/java/com/fs/qw/mapper/QwUserMapper.java

@@ -206,6 +206,7 @@ public interface QwUserMapper extends BaseMapper<QwUser>
             "            <if test=\"qwUserName != null  and qwUserName != ''\"> and qu.qw_user_uame like concat( #{qwUserName}, '%') </if>\n" +
             "            <if test=\"companyUserId != null \"> and qu.company_user_id = #{companyUserId}</if>\n" +
             "            <if test=\"corpId != null \"> and qu.corp_id = #{corpId}</if>\n" +
+            "            <if test=\"deptId != null \"> and qd.dept_id = #{deptId}</if>\n" +
             "            <if test=\"status != null \"> and qu.status = #{status}</if>\n" +
             "            <if test=\"type != null and sendType !=null and type==2 and (sendType==2 or sendType==4 or sendType==11) \"> and qu.app_key IS NOT NULL  </if>\n" +
             "</script>"})

+ 7 - 0
fs-service/src/main/java/com/fs/qw/param/QwFriendWelcomeParam.java

@@ -72,4 +72,11 @@ public class QwFriendWelcomeParam extends BaseEntity {
      */
     private String userType;
 
+    /**
+     * 欢迎语标题
+     * ALTER TABLE qw_friend_welcome ADD welcome_title varchar(100) NULL COMMENT '标题';
+     */
+    private String welcomeTitle;
+
+
 }

+ 7 - 0
fs-service/src/main/java/com/fs/qw/param/QwUserListParam.java

@@ -62,4 +62,11 @@ public class QwUserListParam {
      */
     private String userType;
 
+    /**
+     * 0:好友欢迎语
+     * 1:我的欢迎语
+     * 2、部门欢迎语
+     */
+    private String isRemark;
+
 }

+ 6 - 1
fs-service/src/main/java/com/fs/qw/vo/QwFriendWelcomeVO.java

@@ -10,7 +10,7 @@ import java.util.List;
 
 /**
  * 好友欢迎语对象 qw_friend_welcome
- * 
+ *
  * @author fs
  * @date 2024-07-20
  */
@@ -60,6 +60,11 @@ public class QwFriendWelcomeVO extends BaseEntity
     /** 分时段欢迎语 */
     private String daypartingItemlist;
 
+    /**
+     * 欢迎语标题
+     */
+    private String welcomeTitle;
+
     public List<QwUserVO> userSelectList;
 
 }

+ 10 - 13
fs-service/src/main/resources/application-druid-cqtyt.yml

@@ -8,12 +8,10 @@ spring:
         host: r-2zexagt5g4z7arviu5.redis.rds.aliyuncs.com
         # 端口,默认为6379
         port: 6379
-        # 数据库索引
-        database: 0
         # 密码
         password: Ylrz_c123232014^$
         # 连接超时时间
-        timeout: 20s
+        timeout: 30s
         lettuce:
             pool:
                 # 连接池中的最小空闲连接
@@ -24,17 +22,8 @@ spring:
                 max-active: 8
                 # #连接池最大阻塞等待时间(使用负值表示没有限制)
                 max-wait: -1ms
+        database: 0
     datasource:
-        #        clickhouse:
-        #            type: com.alibaba.druid.pool.DruidDataSource
-        #            driverClassName: com.clickhouse.jdbc.ClickHouseDriver
-        #            url: jdbc:clickhouse://cc-2vc8zzo26w0l7m2l6.public.clickhouse.ads.aliyuncs.com/sop?compress=0&use_server_time_zone=true&use_client_time_zone=false&timezone=Asia/Shanghai
-        #            username: rt_2024
-        #            password: Yzx_19860213
-        #            initialSize: 10
-        #            maxActive: 100
-        #            minIdle: 10
-        #            maxWait: 6000
         mysql:
             type: com.alibaba.druid.pool.DruidDataSource
             driverClassName: com.mysql.cj.jdbc.Driver
@@ -142,6 +131,14 @@ spring:
                     wall:
                         config:
                             multi-statement-allow: true
+redisson:
+    config: |
+        singleServerConfig:
+          address: "redis://r-2zexagt5g4z7arviu5.redis.rds.aliyuncs.com:6379"
+          password: "Ylrz_c123232014^$"
+          database: 0
+        checkKeysEventsConfig: false
+
 rocketmq:
     name-server: rmq-1243b25nj.rocketmq.gz.public.tencenttdmq.com:8080 # RocketMQ NameServer 地址
     producer:

+ 1 - 1
fs-service/src/main/resources/application-druid-jnmy-test.yml

@@ -41,7 +41,7 @@ spring:
             druid:
                 # 主库数据源
                 master:
-                    url: jdbc:mysql://120.46.174.121:2345/fs_his_test?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
+                    url: jdbc:mysql://120.46.174.121:2345/fs_his?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
                     username: root
                     password: Ylrztek250218!3@.
                 # 从库数据源

+ 6 - 1
fs-service/src/main/resources/mapper/qw/QwFriendWelcomeMapper.xml

@@ -16,10 +16,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="createTime"    column="create_time"    />
         <result property="updateTime"    column="update_time"    />
         <result property="corpId"    column="corp_id"    />
+        <result property="welcomeTitle"    column="welcome_title"    />
     </resultMap>
 
     <sql id="selectQwFriendWelcomeVo">
-        select id, qw_user_ids,corp_id, is_send_msg, welcome_text, attachments, is_dayparting, dayparting_ItemList, company_id, create_time, update_time from qw_friend_welcome
+        select id, qw_user_ids,corp_id,welcome_title, is_send_msg, welcome_text, attachments, is_dayparting, dayparting_ItemList, company_id, create_time, update_time from qw_friend_welcome
     </sql>
 
     <select id="selectQwFriendWelcomeListVO" parameterType="QwFriendWelcome" resultMap="QwFriendWelcomeResult">
@@ -33,6 +34,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="createTime != null "> and create_time = #{createTime}</if>
             <if test="corpId != null "> and corp_id = #{corpId}</if>
             <if test="updateTime != null "> and update_time = #{updateTime}</if>
+            <if test="welcomeTitle != null "> and welcome_title = #{welcomeTitle}</if>
         </where>
     </select>
 
@@ -77,6 +79,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     <insert id="insertQwFriendWelcomeVO" parameterType="QwFriendWelcome" useGeneratedKeys="true" keyProperty="id">
         insert into qw_friend_welcome
         <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="welcomeTitle != null">welcome_title,</if>
             <if test="qwUserIds != null">qw_user_ids,</if>
             <if test="isSendMsg != null">is_send_msg,</if>
             <if test="welcomeText != null">welcome_text,</if>
@@ -91,6 +94,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="corpId != null">corp_id,</if>
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="welcomeTitle != null">#{welcomeTitle},</if>
             <if test="qwUserIds != null">#{qwUserIds},</if>
             <if test="isSendMsg != null">#{isSendMsg},</if>
             <if test="welcomeText != null">#{welcomeText},</if>
@@ -109,6 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     <update id="updateQwFriendWelcome" parameterType="QwFriendWelcome">
         update qw_friend_welcome
         <trim prefix="SET" suffixOverrides=",">
+            <if test="welcomeTitle != null">welcome_title = #{welcomeTitle},</if>
             <if test="qwUserIds != null">qw_user_ids = #{qwUserIds},</if>
             <if test="isSendMsg != null">is_send_msg = #{isSendMsg},</if>
             <if test="welcomeText != null">welcome_text = #{welcomeText},</if>