Browse Source

1、各系统添加生产环境配置
2、前端项目添加生产环境接口地址

fuwb 1 month ago
parent
commit
6695d4f8a0
22 changed files with 295 additions and 130 deletions
  1. 1 0
      client/.env.dev
  2. 3 3
      zjugis-gateway/src/main/resources/bootstrap-prod.yaml
  3. 5 0
      zjugis-module-business/zjugis-module-business-biz/pom.xml
  4. 128 0
      zjugis-module-business/zjugis-module-business-biz/src/main/resources/application-prod.yaml
  5. 31 0
      zjugis-module-business/zjugis-module-business-biz/src/main/resources/bootstrap-prod.yaml
  6. 6 6
      zjugis-module-business/zjugis-module-business-biz/src/main/resources/mapper/OaEquipmentMapper.xml
  7. 4 4
      zjugis-module-business/zjugis-module-business-biz/src/main/resources/templates/ConsumablesSettlement/index.ftl
  8. 5 0
      zjugis-module-infra/zjugis-module-infra-biz/pom.xml
  9. 12 24
      zjugis-module-infra/zjugis-module-infra-biz/src/main/resources/application-prod.yaml
  10. 3 3
      zjugis-module-infra/zjugis-module-infra-biz/src/main/resources/bootstrap-prod.yaml
  11. 5 0
      zjugis-module-system/zjugis-module-system-biz/pom.xml
  12. 3 0
      zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/logger/LoginLogDO.java
  13. 2 5
      zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/oauth2/OAuth2AccessTokenDO.java
  14. 2 3
      zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/oauth2/OAuth2RefreshTokenDO.java
  15. 15 27
      zjugis-module-system/zjugis-module-system-biz/src/main/resources/application-prod.yaml
  16. 3 3
      zjugis-module-system/zjugis-module-system-biz/src/main/resources/bootstrap-prod.yaml
  17. 6 0
      zjugis-report/pom.xml
  18. 12 10
      zjugis-report/src/main/resources/application-prod.yaml
  19. 4 4
      zjugis-report/src/main/resources/bootstrap-prod.yaml
  20. 5 0
      zjugis-workflow/pom.xml
  21. 37 35
      zjugis-workflow/src/main/resources/application-prod.yaml
  22. 3 3
      zjugis-workflow/src/main/resources/bootstrap-prod.yaml

+ 1 - 0
client/.env.dev

@@ -6,6 +6,7 @@ VITE_DEV=false
 # 请求路径
 VITE_BASE_URL='http://60.191.110.205:28080'
 # VITE_BASE_URL='http://127.0.0.1:48080'
+# VITE_BASE_URL='http://172.17.130.61'
 
 # 上传路径
 VITE_UPLOAD_URL='/infra/file/upload'

+ 3 - 3
zjugis-gateway/src/main/resources/bootstrap-prod.yaml

@@ -1,11 +1,11 @@
 server:
-  port: 38080
+  port: 48080
 --- #################### 注册中心相关配置 ####################
 
 spring:
   cloud:
     nacos:
-      server-addr: 10.10.10.205:8848
+      server-addr: 127.0.0.1:8848
       discovery:
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 dev 开发环境
 
@@ -16,7 +16,7 @@ spring:
     nacos:
       # Nacos Config 配置项,对应 NacosConfigProperties 配置属性类
       config:
-        server-addr: 10.10.10.205:8848 # Nacos 服务器地址
+        server-addr: 127.0.0.1:8848 # Nacos 服务器地址
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 dev 开发环境
         group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
         name: # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name

+ 5 - 0
zjugis-module-business/zjugis-module-business-biz/pom.xml

@@ -172,6 +172,11 @@
             <artifactId>jtidy</artifactId>
             <version>r938</version>
         </dependency>
+        <dependency>
+            <groupId>cn.com.kingbase</groupId>
+            <artifactId>kingbase8</artifactId>
+            <version>8.6.0</version>
+        </dependency>
     </dependencies>
     <build>
         <!-- 设置构建的 jar 包名 -->

+ 128 - 0
zjugis-module-business/zjugis-module-business-biz/src/main/resources/application-prod.yaml

@@ -0,0 +1,128 @@
+--- #################### 数据库相关配置 ####################
+spring:
+  # 数据源配置项
+  autoconfigure:
+    exclude:
+      - com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure # 排除 Druid 的自动配置,使用 dynamic-datasource-spring-boot-starter 配置多数据源
+  datasource:
+    druid: # Druid 【监控】相关的全局配置
+      web-stat-filter:
+        enabled: true
+      stat-view-servlet:
+        enabled: true
+        allow: # 设置白名单,不填则允许所有访问
+        url-pattern: /druid/*
+        login-username: # 控制台管理用户名和密码
+        login-password:
+      filter:
+        stat:
+          enabled: true
+          log-slow-sql: true # 慢 SQL 记录
+          slow-sql-millis: 100
+          merge-sql: true
+        wall:
+          config:
+            multi-statement-allow: true
+    dynamic: # 多数据源配置
+      druid: # Druid 【连接池】相关的全局配置
+        initial-size: 1 # 初始连接数
+        min-idle: 1 # 最小连接池数量
+        max-active: 20 # 最大连接池数量
+        max-wait: 600000 # 配置获取连接等待超时的时间,单位:毫秒
+        time-between-eviction-runs-millis: 60000 # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位:毫秒
+        min-evictable-idle-time-millis: 300000 # 配置一个连接在池中最小生存的时间,单位:毫秒
+        max-evictable-idle-time-millis: 900000 # 配置一个连接在池中最大生存的时间,单位:毫秒
+        validation-query: SELECT 1 # 配置检测连接是否有效
+        test-while-idle: true
+        test-on-borrow: false
+        test-on-return: false
+      primary: master
+      datasource:
+        master:
+          driver-class-name: com.kingbase8.Driver
+          url: jdbc:kingbase8://172.17.150.182:54321/ruian_oa?currentSchema=ruian_oa # Oracle 连接的示例
+          username: postgres
+          password: zdww1402!
+
+  # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
+  redis:
+    host: localhost # 地址
+    port: 6379 # 端口
+    database: 1 # 数据库索引
+    password: zdww1402 # 密码,建议生产环境开启
+
+--- #################### MQ 消息队列相关配置 ####################
+
+
+--- #################### 定时任务相关配置 ####################
+
+xxl:
+  job:
+    enabled: false # 是否开启调度中心,默认为 true 开启
+    admin:
+      addresses:  # 调度中心部署跟地址
+
+--- #################### 服务保障相关配置 ####################
+
+# Lock4j 配置项
+lock4j:
+  acquire-timeout: 3000 # 获取分布式锁超时时间,默认为 3000 毫秒
+  expire: 30000 # 分布式锁的超时时间,默认为 30 毫秒
+
+--- #################### 监控相关配置 ####################
+
+# Actuator 监控端点的配置项
+management:
+  endpoints:
+    web:
+      base-path: /actuator # Actuator 提供的 API 接口的根目录。默认为 /actuator
+      exposure:
+        include: '*' # 需要开放的端点。默认值只打开 health 和 info 两个端点。通过设置 * ,可以开放所有端点。
+
+# Spring Boot Admin 配置项
+spring:
+  boot:
+    admin:
+      # Spring Boot Admin Client 客户端的相关配置
+      client:
+        instance:
+          service-host-type: IP # 注册实例时,优先使用 IP [IP, HOST_NAME, CANONICAL_HOST_NAME]
+
+# 日志文件配置
+logging:
+  level:
+    # 配置自己写的 MyBatis Mapper 打印日志
+    com.zjugis.module.business.dal.mysql: debug
+    com.zjugis.module.business: debug
+
+
+--- #################### 万维相关配置 ####################
+
+# 万维配置项,设置当前项目所有自定义的配置
+zjugis:
+  env: # 多环境的配置项
+  security:
+    mock-enable: true
+  xss:
+    enable: false
+    exclude-urls: # 如下两个 url,仅仅是为了演示,去掉配置也没关系
+      - ${spring.boot.admin.context-path}/** # 不处理 Spring Boot Admin 的请求
+      - ${management.endpoints.web.base-path}/** # 不处理 Actuator 的请求
+  access-log: # 访问日志的配置项
+    enable: false
+  error-code: # 错误码相关配置项
+    enable: false
+  demo: false # 关闭演示模式
+
+
+#  mybatis-plus配置控制台打印完整带参数SQL语句
+mybatis-plus:
+  configuration:
+    log-impl: org.apache.ibatis.logging.slf4j.Slf4jImpl
+
+serviceUrl:
+  sysUrl: http://172.17.130.61/business
+#  sysUrl: http://127.0.0.1:48083
+  UI: http://172.17.130.61/workflow
+  ui_version: http://172.17.130.61/UI
+  z_workflow: http://172.17.130.61/workflow

+ 31 - 0
zjugis-module-business/zjugis-module-business-biz/src/main/resources/bootstrap-prod.yaml

@@ -0,0 +1,31 @@
+server:
+  port: 48083
+--- #################### 注册中心相关配置 ####################
+
+spring:
+  cloud:
+    nacos:
+      server-addr: localhost:8848
+      discovery:
+        namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 prod 开发环境
+        metadata:
+          version: 1.0.0 # 服务实例的版本号,可用于灰度发布
+        weight: 100
+
+--- #################### 配置中心相关配置 ####################
+
+spring:
+  cloud:
+    nacos:
+      # Nacos Config 配置项,对应 NacosConfigProperties 配置属性类
+      config:
+        server-addr: localhost:8848 # Nacos 服务器地址
+        namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间 prod 的ID,不能直接使用 dev 名称。创建命名空间的时候需要指定ID为 dev,这里使用 dev 开发环境
+        group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
+        name: ${spring.application.name} # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name
+        file-extension: yaml # 使用的 Nacos 配置集的 dataId 的文件拓展名,同时也是 Nacos 配置集的配置格式,默认为 properties
+
+# 日志文件配置。注意,如果 logging.file.name 不放在 bootstrap.yaml 配置文件,而是放在 application.yaml 中,会导致出现 LOG_FILE_IS_UNDEFINED 文件
+logging:
+  file:
+    name: ${user.home}/logs/${spring.application.name}.log # 日志文件名,全路径

+ 6 - 6
zjugis-module-business/zjugis-module-business-biz/src/main/resources/mapper/OaEquipmentMapper.xml

@@ -2,31 +2,31 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.zjugis.module.business.mapper.OaEquipmentMapper">
     <select id="getDeviceNameList" resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT equipment_name AS value FROM oa_equipment WHERE equipment_name IS NOT NULL
+        SELECT DISTINCT equipment_name AS value FROM oa_equipment_inventory_list WHERE equipment_name IS NOT NULL
     </select>
 
     <select id="getDeviceTypeList"
             resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT equipment_type AS value FROM oa_equipment WHERE equipment_type IS NOT NULL
+        SELECT DISTINCT equipment_type AS value FROM oa_equipment_inventory_list WHERE equipment_type IS NOT NULL
     </select>
 
     <select id="getDeviceBrandList"
             resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT equipment_brand AS value FROM oa_equipment WHERE equipment_brand IS NOT NULL
+        SELECT DISTINCT equipment_brand AS value FROM oa_equipment_inventory_list WHERE equipment_brand IS NOT NULL
     </select>
 
     <select id="getDeviceModelList"
             resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT specification_model AS value FROM oa_equipment WHERE specification_model IS NOT NULL
+        SELECT DISTINCT specification_model AS value FROM oa_equipment_inventory_list WHERE specification_model IS NOT NULL
     </select>
 
     <select id="getDeviceDepartList"
             resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT original_department AS value FROM oa_equipment WHERE original_department IS NOT NULL
+        SELECT DISTINCT original_department AS value FROM oa_equipment_inventory_list WHERE original_department IS NOT NULL
     </select>
 
     <select id="getDeviceUserList"
             resultType="com.zjugis.module.business.flow.applicationform.vo.InputSelectVO">
-        SELECT DISTINCT original_user AS value FROM oa_equipment WHERE original_user IS NOT NULL
+        SELECT DISTINCT original_user AS value FROM oa_equipment_inventory_list WHERE original_user IS NOT NULL
     </select>
 </mapper>

+ 4 - 4
zjugis-module-business/zjugis-module-business-biz/src/main/resources/templates/ConsumablesSettlement/index.ftl

@@ -44,7 +44,7 @@ styles=[ '/flow/css/formCommon.css','/OwCommon/OwCommon.css','/css/pagination.cs
                             <td>
                                 <div class="form-group">
                                     <div class="form-item">
-                                        <div class="z-comp-input" name="createReqVO$settlementNumber">
+                                        <div class="z-comp-input z-readonly" name="createReqVO$settlementNumber">
                                             <input type="text" value="${formEntity.settlementNumber!}">
                                         </div>
                                     </div>
@@ -82,7 +82,7 @@ styles=[ '/flow/css/formCommon.css','/OwCommon/OwCommon.css','/css/pagination.cs
                             <td>
                                 <div class="form-group">
                                     <div class="form-item">
-                                        <div class="z-comp-input" name="createReqVO$contractDate">
+                                        <div class="z-comp-date" name="createReqVO$contractDate">
                                             <input type="text" value="${formEntity.contractDate!}">
                                         </div>
                                     </div>
@@ -162,7 +162,7 @@ styles=[ '/flow/css/formCommon.css','/OwCommon/OwCommon.css','/css/pagination.cs
                             <td>
                                 <div class="form-group">
                                     <div class="form-item">
-                                        <div class="z-comp-input" name="createReqVO$documentDate">
+                                        <div class="z-comp-date" name="createReqVO$documentDate">
                                             <input type="text" value="${(formEntity.documentDate?date)!}">
                                         </div>
                                     </div>
@@ -188,7 +188,7 @@ styles=[ '/flow/css/formCommon.css','/OwCommon/OwCommon.css','/css/pagination.cs
                             <td>
                                 <div class="form-group">
                                     <div class="form-item">
-                                        <div class="z-comp-input" name="createReqVO$reviewTime">
+                                        <div class="z-comp-date" name="createReqVO$reviewTime">
                                             <input type="text" value="${(formEntity.reviewTime?date)!}">
                                         </div>
                                     </div>

+ 5 - 0
zjugis-module-infra/zjugis-module-infra-biz/pom.xml

@@ -166,6 +166,11 @@
             <artifactId>joda-time</artifactId>
             <version>2.12.4</version>
         </dependency>
+        <dependency>
+            <groupId>cn.com.kingbase</groupId>
+            <artifactId>kingbase8</artifactId>
+            <version>8.6.0</version>
+        </dependency>
     </dependencies>
     <build>
         <!-- 设置构建的 jar 包名 -->

+ 12 - 24
zjugis-module-infra/zjugis-module-infra-biz/src/main/resources/application-prod.yaml

@@ -37,38 +37,21 @@ spring:
         time-between-eviction-runs-millis: 60000 # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位:毫秒
         min-evictable-idle-time-millis: 300000 # 配置一个连接在池中最小生存的时间,单位:毫秒
         max-evictable-idle-time-millis: 900000 # 配置一个连接在池中最大生存的时间,单位:毫秒
-        validation-query: SELECT 1 FROM DUAL # 配置检测连接是否有效
+        validation-query: SELECT 1 # 配置检测连接是否有效
         test-while-idle: true
         test-on-borrow: false
         test-on-return: false
       primary: master
       datasource:
         master:
-          name: zjugis-oa
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例
-          #          url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.master.name} # PostgreSQL 连接的示例
-          url: jdbc:oracle:thin:@10.10.10.8:1521:OA # Oracle 连接的示例
-          #          url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.master.name} # SQLServer 连接的示例
-          username: ZJUGIS_OA
+          driver-class-name: com.kingbase8.Driver
+          url: jdbc:kingbase8://172.17.150.182:54321/ruian_oa?currentSchema=ruian_oa
+          username: postgres
           password: zdww1402!
-        #          username: sa
-        #          password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W
-        slave: # 模拟从库,可根据自己需要修改
-          name: zjugis-oa
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例
-          #          url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例
-          url: jdbc:oracle:thin:@10.10.10.8:1521:OA # Oracle 连接的示例
-          #          url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.slave.name} # SQLServer 连接的示例
-          username: ZJUGIS_OA
-          password: zdww1402!
-  #          username: sa
-  #          password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W
 
   # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
   redis:
-    host: 10.10.10.8 # 地址
+    host: localhost # 地址
     port: 6379 # 端口
     database: 0 # 数据库索引
     password: zdww1402 # 密码,建议生产环境开启
@@ -76,7 +59,7 @@ spring:
 --- #################### MQ 消息队列相关配置 ####################
 spring:
   rabbitmq:
-    host: 10.10.10.7
+    host: 172.17.130.61
     port: 5672
     username: zjww
     password: zjww1402!
@@ -102,7 +85,7 @@ spring:
           environment:
             spring:
               rabbitmq:
-                host: 10.10.10.7
+                host: 172.17.130.61
                 port: 5672
                 username: zjww
                 password: zjww1402!
@@ -179,3 +162,8 @@ zjugis:
     agentid: 2755233050
     appkey: dingk0ggukejc4xacgku
     appsecret: 1Irqm3obWLCWTokhrCgbrcMIX7klSI3s_ljiBZrAzMfnpttJTUJHIBCi8C-2rD2O
+  zzd:
+    appkey: razg_oa-1r4wzTHFbdhjTB9zM363Mz
+    appsecret: TP7rfEsJp53gI5YOJnzpuvD2J2bkflLjxLgPkn49
+    domain: openplatform-pro.ding.zj.gov.cn
+    tenantId: 196729

+ 3 - 3
zjugis-module-infra/zjugis-module-infra-biz/src/main/resources/bootstrap-prod.yaml

@@ -1,11 +1,11 @@
 server:
-  port: 38082
+  port: 48082
 --- #################### 注册中心相关配置 ####################
 
 spring:
   cloud:
     nacos:
-      server-addr: 10.10.10.205:8848
+      server-addr: localhost:8848
       discovery:
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 dev 开发环境
         metadata:
@@ -19,7 +19,7 @@ spring:
     nacos:
       # Nacos Config 配置项,对应 NacosConfigProperties 配置属性类
       config:
-        server-addr: 10.10.10.205:8848 # Nacos 服务器地址
+        server-addr: localhost:8848 # Nacos 服务器地址
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间 dev 的ID,不能直接使用 dev 名称。创建命名空间的时候需要指定ID为 dev,这里使用 dev 开发环境
         group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
         name: ${spring.application.name} # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name

+ 5 - 0
zjugis-module-system/zjugis-module-system-biz/pom.xml

@@ -169,6 +169,11 @@
             <artifactId>joda-time</artifactId>
             <version>2.12.4</version>
         </dependency>
+        <dependency>
+            <groupId>cn.com.kingbase</groupId>
+            <artifactId>kingbase8</artifactId>
+            <version>8.6.0</version>
+        </dependency>
     </dependencies>
     <build>
         <!-- 设置构建的 jar 包名 -->

+ 3 - 0
zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/logger/LoginLogDO.java

@@ -1,5 +1,7 @@
 package com.zjugis.module.system.dal.dataobject.logger;
 
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
 import com.zjugis.framework.common.enums.UserTypeEnum;
 import com.zjugis.framework.mybatis.core.dataobject.BaseDO;
 import com.zjugis.module.system.enums.logger.LoginLogTypeEnum;
@@ -27,6 +29,7 @@ public class LoginLogDO extends BaseDO {
     /**
      * 日志主键
      */
+    @TableId(type = IdType.AUTO)
     private Long id;
     /**
      * 日志类型

+ 2 - 5
zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/oauth2/OAuth2AccessTokenDO.java

@@ -1,9 +1,6 @@
 package com.zjugis.module.system.dal.dataobject.oauth2;
 
-import com.baomidou.mybatisplus.annotation.KeySequence;
-import com.baomidou.mybatisplus.annotation.TableField;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.*;
 import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
 import com.zjugis.framework.common.enums.UserTypeEnum;
 import com.zjugis.framework.mybatis.core.dataobject.BaseDO;
@@ -30,7 +27,7 @@ public class OAuth2AccessTokenDO extends BaseDO {
     /**
      * 编号,数据库递增
      */
-    @TableId
+    @TableId(type = IdType.AUTO)
     private Long id;
     /**
      * 访问令牌

+ 2 - 3
zjugis-module-system/zjugis-module-system-biz/src/main/java/com/zjugis/module/system/dal/dataobject/oauth2/OAuth2RefreshTokenDO.java

@@ -1,10 +1,8 @@
 package com.zjugis.module.system.dal.dataobject.oauth2;
 
+import com.baomidou.mybatisplus.annotation.*;
 import com.zjugis.framework.common.enums.UserTypeEnum;
 import com.zjugis.framework.mybatis.core.dataobject.BaseDO;
-import com.baomidou.mybatisplus.annotation.KeySequence;
-import com.baomidou.mybatisplus.annotation.TableField;
-import com.baomidou.mybatisplus.annotation.TableName;
 import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
 import lombok.Data;
 import lombok.EqualsAndHashCode;
@@ -29,6 +27,7 @@ public class OAuth2RefreshTokenDO extends BaseDO {
     /**
      * 编号,数据库字典
      */
+    @TableId(type = IdType.AUTO)
     private Long id;
     /**
      * 刷新令牌

+ 15 - 27
zjugis-module-system/zjugis-module-system-biz/src/main/resources/application-prod.yaml

@@ -33,46 +33,29 @@ spring:
         time-between-eviction-runs-millis: 60000 # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位:毫秒
         min-evictable-idle-time-millis: 300000 # 配置一个连接在池中最小生存的时间,单位:毫秒
         max-evictable-idle-time-millis: 900000 # 配置一个连接在池中最大生存的时间,单位:毫秒
-        validation-query: SELECT 1 FROM DUAL # 配置检测连接是否有效
+        validation-query: SELECT 1 # 配置检测连接是否有效
         test-while-idle: true
         test-on-borrow: false
         test-on-return: false
       primary: master
       datasource:
         master:
-          name: zjugis-oa
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例
-          #          url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.master.name} # PostgreSQL 连接的示例
-          url: jdbc:oracle:thin:@10.10.10.8:1521:OA # Oracle 连接的示例
-          #          url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.master.name} # SQLServer 连接的示例
-          username: ZJUGIS_OA
+          driver-class-name: com.kingbase8.Driver
+          url: jdbc:kingbase8://172.17.150.182:54321/ruian_oa?currentSchema=ruian_oa
+          username: postgres
           password: zdww1402!
-        #          username: sa
-        #          password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W
-        slave: # 模拟从库,可根据自己需要修改
-          name: zjugis-oa
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例
-          #          url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例
-          #          url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例
-          url: jdbc:oracle:thin:@10.10.10.8:1521:OA # Oracle 连接的示例
-          #          url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.slave.name} # SQLServer 连接的示例
-          username: ZJUGIS_OA
-          password: zdww1402!
-  #          username: sa
-  #          password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W
 
   # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
   redis:
-    host: 10.10.10.8 # 地址
+    host: localhost # 地址
     port: 6379 # 端口
     database: 0 # 数据库索引
-    password: zdww1402 # 密码,建议生产环境开启
+    password: zdww1402
 
 --- #################### MQ 消息队列相关配置 ####################
 spring:
   rabbitmq:
-    host: 10.10.10.7
+    host: 172.17.130.61
     port: 5672
     username: zjww
     password: zjww1402!
@@ -98,7 +81,7 @@ spring:
           environment:
             spring:
               rabbitmq:
-                host: 10.10.10.7
+                host: 172.17.130.61
                 port: 5672
                 username: zjww
                 password: zjww1402!
@@ -183,8 +166,8 @@ justauth:
   enabled: true
   type:
     DINGTALK: # 钉钉
-      client-id: dingk0ggukejc4xacgku
-      client-secret: 1Irqm3obWLCWTokhrCgbrcMIX7klSI3s_ljiBZrAzMfnpttJTUJHIBCi8C-2rD2O
+      client-id: rzg_oauth2_dingoa
+      client-secret: 7BJ74Ke76e8lil84oZzd7gV9zX3zild3DBWxYj7u
       ignore-check-redirect-uri: true
     WECHAT_ENTERPRISE: # 企业微信
       client-id: wwd411c69a39ad2e54
@@ -201,3 +184,8 @@ deptId:
 roleId:
   bj: 3000021
   normal: 2
+
+dingding:
+  appKey: rzg_oauth2_dingoa-9bfp9xFraEbq
+  appSecret: fAWtnE86818kEx1BRS8367uo2KF5sv8uiHT5ldgD
+  domainName: openplatform-pro.ding.zj.gov.cn

+ 3 - 3
zjugis-module-system/zjugis-module-system-biz/src/main/resources/bootstrap-prod.yaml

@@ -1,11 +1,11 @@
 server:
-  port: 38081
+  port: 48081
 --- #################### 注册中心相关配置 ####################
 
 spring:
   cloud:
     nacos:
-      server-addr: 10.10.10.205:8848
+      server-addr: 127.0.0.1:8848
       discovery:
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 dev 开发环境
         metadata:
@@ -19,7 +19,7 @@ spring:
     nacos:
       # Nacos Config 配置项,对应 NacosConfigProperties 配置属性类
       config:
-        server-addr: 10.10.10.205:8848 # Nacos 服务器地址
+        server-addr: 127.0.0.1:8848 # Nacos 服务器地址
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间 dev 的ID,不能直接使用 dev 名称。创建命名空间的时候需要指定ID为 dev,这里使用 dev 开发环境
         group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
         name: ${spring.application.name} # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name

+ 6 - 0
zjugis-report/pom.xml

@@ -96,6 +96,12 @@
             <artifactId>spring-boot-starter-test</artifactId>
             <scope>test</scope>
         </dependency>
+
+        <dependency>
+            <groupId>cn.com.kingbase</groupId>
+            <artifactId>kingbase8</artifactId>
+            <version>8.6.0</version>
+        </dependency>
     </dependencies>
 
     <build>

+ 12 - 10
zjugis-report/src/main/resources/application-prod.yaml

@@ -1,17 +1,19 @@
 spring:
   redis:
-    host: 10.10.10.8
+    host: localhost
+    port: 6379
+    database: 1
     password: zdww1402
   datasource:
-    driverClassName: oracle.jdbc.OracleDriver
-    url: jdbc:oracle:thin:@10.10.10.8:1521:OA
-    username: ZJUGIS_REPORT
-    password: Zjugis1402
+    driver-class-name: com.kingbase8.Driver
+    url: jdbc:kingbase8://172.17.150.182:54321/ruian_oa?currentSchema=zjugis_report # Oracle 连接的示例
+    username: postgres
+    password: zdww1402!
     type: com.zaxxer.hikari.HikariDataSource
 
 serviceUrl:
-  sysUrl: https://oa.zjugis.com:28080/report
-  UI: https://oa.zjugis.com:28080/workflow
-  ui_version: https://oa.zjugis.com:28080/workflow
-  z_workflow: https://oa.zjugis.com:28080/workflow
-  report: https://oa.zjugis.com:28080/report
+  sysUrl: http://172.17.130.61:7001/report
+  UI: http://172.17.130.61:7001/workflow
+  ui_version: http://172.17.130.61:7001/workflow
+  z_workflow: http://172.17.130.61:7001/workflow
+  report: http://172.17.130.61:7001/report

+ 4 - 4
zjugis-report/src/main/resources/bootstrap-prod.yaml

@@ -1,5 +1,5 @@
 server:
-  port: 38086
+  port: 46080
 
 spring:
   application:
@@ -8,13 +8,13 @@ spring:
     inetutils:
       preferred-networks: 10.10
     nacos:
-      server-addr: 10.10.10.205:8848
+      server-addr: localhost:8848
       discovery:
         service: report
-        server-addr: 10.10.10.205:8848
+        server-addr: localhost:8848
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674
       config:
-        server-addr: 10.10.10.205:8848 # Nacos 服务器地址
+        server-addr: localhost:8848 # Nacos 服务器地址
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674       # 命名空间。这里使用 dev 开发环境
         group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
         name: # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name

+ 5 - 0
zjugis-workflow/pom.xml

@@ -195,6 +195,11 @@
             <artifactId>zjugis-spring-boot-starter-workflow</artifactId>
             <version>0.0.1-SNAPSHOT</version>
         </dependency>
+        <dependency>
+            <groupId>cn.com.kingbase</groupId>
+            <artifactId>kingbase8</artifactId>
+            <version>8.6.0</version>
+        </dependency>
     </dependencies>
 
     <build>

+ 37 - 35
zjugis-workflow/src/main/resources/application-prod.yaml

@@ -1,7 +1,9 @@
 spring:
   redis:
-    host: 10.10.10.8
-    password: zdww1402
+    host: localhost # 地址
+    port: 6379 # 端口
+    database: 1 # 数据库索引
+    password: zdww1402 # 密码,建议生产环境开启
   #多数据源配置
   datasource:
     druid:
@@ -13,52 +15,52 @@ spring:
         url-pattern: /druid/*
         login-username: workflow
         login-password: zjugis
-    dynamic:
-      druid:
-        initial-size: 1
-        min-idle: 1
-        max-active: 20
-        max-wait: 60000
-        time-between-eviction-runs-millis: 60000
-        min-evictable-idle-time-millis: 300000
-        max-evictable-idle-time-millis: 900000
-        validation-query: SELECT 1 FROM DUAL
-        test-while-idle: true
-        test-on-borrow: false
-        test-on-return: false
-        filters: stat,wall,slf4j,config
+      filter:
         stat:
           enabled: true
           log-slow-sql: true
           slow-sql-millis: 100
           merge-sql: true
-        use-global-data-source-stat: true
-      primary: oracle #设置默认的数据源
+        wall:
+          config:
+            multi-statement-allow: true
+    dynamic:
+      primary: master #设置默认的数据源
       strict: false #设置严格模式,默认不启动.启动后在未匹配到指定数据源时候会抛出异常,不启动则使用默认数据源
       datasource:
-        oracle:
-          driverClassName: oracle.jdbc.OracleDriver
-          url: jdbc:oracle:thin:@10.10.10.8:1521:OA
-          username: ZJUGIS_WORKFLOW
-          password: Zjugis1402
+        master:
+          driver-class-name: com.kingbase8.Driver
+          url: jdbc:kingbase8://172.17.150.182:54321/ruian_oa?currentSchema=zjugis_workflow
+          username: postgres
+          password: zdww1402!
+          initial-size: 1
+          min-idle: 1
+          max-active: 20
+          max-wait: 60000
+          time-between-eviction-runs-millis: 60000
+          min-evictable-idle-time-millis: 300000
+          max-evictable-idle-time-millis: 900000
+          validation-query: SELECT 1
+          test-while-idle: true
+          test-on-borrow: false
+          test-on-return: false
 websocket:
   post: 26091
   path: "/ws"
-  url: https://oa.zjugis.com:28080/ws/
+  url: ws://60.191.110.205:26091/ws/
 
 serviceUrl:
-  innerUrl: http://127.0.0.1:38084
-  sysUrl: https://oa.zjugis.com:28080/workflow
-  UI: https://oa.zjugis.com:28080/workflow
-  ui_version: https://oa.zjugis.com:28080/UI
-  z_workflow: https://oa.zjugis.com:28080/workflow
-  infra: https://oa.zjugis.com:28080/admin-api/infra
-  reportUrl: https://oa.zjugis.com:28080/report
-
-file:
-  client: 11
-
+  innerUrl: http://localhost:48089
+  sysUrl: http://172.17.130.61/workflow
+  UI: http://172.17.130.61/workflow
+  ui_version: http://172.17.130.61/UI
+  z_workflow: http://172.17.130.61/workflow
+  infra: http://172.17.130.61/admin-api/infra
+  reportUrl: http://172.17.130.61/report
 
 logging:
   level:
     com.zjugis.z_workflow.dao: WARN
+
+file:
+  client: 11

+ 3 - 3
zjugis-workflow/src/main/resources/bootstrap-prod.yaml

@@ -1,11 +1,11 @@
 server:
-  port: 38084
+  port: 48089
 --- #################### 注册中心相关配置 ####################
 
 spring:
   cloud:
     nacos:
-      server-addr: 10.10.10.205:8848
+      server-addr: localhost:8848
       discovery:
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间。这里使用 dev 开发环境
         metadata:
@@ -18,7 +18,7 @@ spring:
     nacos:
       # Nacos Config 配置项,对应 NacosConfigProperties 配置属性类
       config:
-        server-addr: 10.10.10.205:8848 # Nacos 服务器地址
+        server-addr: localhost:8848 # Nacos 服务器地址
         namespace: 8c7aedc2-e50b-4a49-8990-e3397e7e8674 # 命名空间 dev 的ID,不能直接使用 dev 名称。创建命名空间的时候需要指定ID为 dev,这里使用 dev 开发环境
         group: DEFAULT_GROUP # 使用的 Nacos 配置分组,默认为 DEFAULT_GROUP
         name: ${spring.application.name} # 使用的 Nacos 配置集的 dataId,默认为 spring.application.name