已添加381个文件
已修改339个文件
已删除129个文件
| | |
| | | application-my.yaml |
| | | |
| | | /yudao-ui-app/unpackage/ |
| | | **/.DS_Store |
| | | .DS_Store |
| | | **/.DS_Store |
| | |
| | | <p align="center"> |
| | | <img src="https://img.shields.io/badge/Spring%20Boot-3.4.5-blue.svg" alt="Downloads"> |
| | | <img src="https://img.shields.io/badge/Spring%20Boot-4.1.0-blue.svg" alt="Downloads"> |
| | | <img src="https://img.shields.io/badge/Vue-3.2-blue.svg" alt="Downloads"> |
| | | <img src="https://img.shields.io/github/license/YunaiV/ruoyi-vue-pro" alt="Downloads" /> |
| | | </p> |
| | |
| | | |
| | | ## ð° çæ¬è¯´æ |
| | | |
| | | | çæ¬ | JDK 8 + Spring Boot 2.7 | JDK 17/21 + Spring Boot 3.2 | |
| | | |---------------------------------------------------------------------|---------------------------------------------------------------------------|---------------------------------------------------------------------------------------| |
| | | | ã宿´çã[ruoyi-vue-pro](https://gitee.com/zhijiantianya/ruoyi-vue-pro) | [`master`](https://gitee.com/zhijiantianya/ruoyi-vue-pro/tree/master/) 忝 | [`master-jdk17`](https://gitee.com/zhijiantianya/ruoyi-vue-pro/tree/master-jdk17/) 忝 | |
| | | | ãç²¾ç®çã[yudao-boot-mini](https://gitee.com/yudaocode/yudao-boot-mini) | [`master`](https://gitee.com/yudaocode/yudao-boot-mini/tree/master/) 忝 | [`master-jdk17`](https://gitee.com/yudaocode/yudao-boot-mini/tree/master-jdk17/) 忝 | |
| | | | çæ¬ | JDK 8 + Spring Boot 2.7 | JDK 17/21 + Spring Boot 3.5 | JDK 25 + Spring Boot 4.x | |
| | | |---------------------------------------------------------------------|---------------------------------------------------------------------------|---------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------| |
| | | | ã宿´çã[ruoyi-vue-pro](https://gitee.com/zhijiantianya/ruoyi-vue-pro) | [`master`](https://gitee.com/zhijiantianya/ruoyi-vue-pro/tree/master/) 忝 | [`master-jdk17`](https://gitee.com/zhijiantianya/ruoyi-vue-pro/tree/master-jdk17/) 忝 | [`master-jdk25`](https://gitee.com/zhijiantianya/ruoyi-vue-pro/tree/master-jdk25/) 忝 | |
| | | | ãç²¾ç®çã[yudao-boot-mini](https://gitee.com/yudaocode/yudao-boot-mini) | [`master`](https://gitee.com/yudaocode/yudao-boot-mini/tree/master/) 忝 | [`master-jdk17`](https://gitee.com/yudaocode/yudao-boot-mini/tree/master-jdk17/) 忝 | [`master-jdk25`](https://gitee.com/yudaocode/yudao-boot-mini/tree/master-jdk25/) 忝 | |
| | | |
| | | * ã宿´çãï¼å
æ¬ç³»ç»åè½ãåºç¡è®¾æ½ãä¼åä¸å¿ãæ°æ®æ¥è¡¨ã工使µç¨ãååç³»ç»ã微信å
¬ä¼å·ãCRMãERPãWMSãMESãAI 大模åãIoT ç©èç½ çåè½ |
| | | * ãç²¾ç®çãï¼åªå
æ¬ç³»ç»åè½ãåºç¡è®¾æ½åè½ï¼ä¸å
æ¬ä¼åä¸å¿ãæ°æ®æ¥è¡¨ã工使µç¨ãååç³»ç»ã微信å
¬ä¼å·ãCRMãERPãWMSãMESãAI 大模åãIoT ç©èç½ çåè½ |
| | | * ã宿´çãï¼å
æ¬ç³»ç»åè½ãåºç¡è®¾æ½ãä¼åä¸å¿ãæ°æ®æ¥è¡¨ã工使µç¨ãååç³»ç»ã微信å
¬ä¼å·ãCRMãERPãWMSãMESãIM 峿¶é讯ãAI 大模åãIoT ç©èç½çåè½ |
| | | * ãç²¾ç®çãï¼åªå
æ¬ç³»ç»åè½ãåºç¡è®¾æ½åè½ï¼ä¸å
æ¬ä¼åä¸å¿ãæ°æ®æ¥è¡¨ã工使µç¨ãååç³»ç»ã微信å
¬ä¼å·ãCRMãERPãWMSãMESãIM 峿¶é讯ãAI 大模åãIoT ç©èç½çåè½ |
| | | |
| | | å¯åè [ãè¿ç§»ææ¡£ã](https://doc.iocoder.cn/migrate-module/) ï¼åªéè¦ 5-10 åéï¼å³å¯å°ã宿´çãæéè¿ç§»å°ãç²¾ç®çã |
| | | |
| | |
| | | |
| | |  |
| | | |
| | | * Java å端ï¼`master` åæ¯ä¸º JDK 8 + Spring Boot 2.7ï¼`master-jdk17` åæ¯ä¸º JDK 17/21 + Spring Boot 3.2 |
| | | * Java å端ï¼`master` åæ¯ä¸º JDK 8 + Spring Boot 2.7ï¼`master-jdk17` åæ¯ä¸º JDK 17/21 + Spring Boot 3.5ï¼`master-jdk25` åæ¯ä¸º JDK 25 + Spring Boot 4.x |
| | | * 管çåå°ççµè端ï¼Vue3 æä¾ `element-plus`ã`vben(ant-design-vue)` ä¸¤ä¸ªçæ¬ï¼Vue2 æä¾ `element-ui` çæ¬ |
| | | * 管çåå°çç§»å¨ç«¯ï¼éç¨ `uni-app` æ¹æ¡ï¼ä¸ä»½ä»£ç å¤ç»ç«¯éé
ï¼åæ¶æ¯æ APPãå°ç¨åºãH5ï¼ |
| | | * å端éç¨ Spring Boot 夿¨¡åæ¶æãMySQL + MyBatis PlusãRedis + Redisson |
| | |
| | | |
| | | å¢éå
å«ä¸ä¸ç项ç®ç»çãæ¶æå¸ãå端工ç¨å¸ãå端工ç¨å¸ãæµè¯å·¥ç¨å¸ãè¿ç»´å·¥ç¨å¸ï¼å¯ä»¥æä¾å
¨æµç¨çå¤å
æå¡ã |
| | | |
| | | 项ç®å¯ä»¥æ¯ååãSCRM ç³»ç»ãOA ç³»ç»ãç©æµç³»ç»ãERP ç³»ç»ãCMS ç³»ç»ãHIS ç³»ç»ãæ¯ä»ç³»ç»ãIM è天ã微信å
¬ä¼å·ã微信å°ç¨åºççã |
| | | 项ç®å¯ä»¥æ¯ååãSCRM ç³»ç»ãOA ç³»ç»ãç©æµç³»ç»ãERP ç³»ç»ãCMS ç³»ç»ãHIS ç³»ç»ãæ¯ä»ç³»ç»ãIM 峿¶é讯ã微信å
¬ä¼å·ã微信å°ç¨åºççã |
| | | |
| | | ## ð¼ å
ç½®åè½ |
| | | |
| | |
| | | |
| | |  |
| | | |
| | | ### IM 峿¶é讯 |
| | | |
| | | æ¼ç¤ºå°åï¼Bootï¼ï¼<https://doc.iocoder.cn/im-preview/> |
| | | |
| | | æ¼ç¤ºå°åï¼Vue3 + Element Plusï¼ï¼<http://dashboard-vue3.yudao.iocoder.cn> |
| | | |
| | | |
| | |  |
| | | |
| | | | è天çé¢ | è天管ç | |
| | | | --- | --- | |
| | | |  |  | |
| | | |
| | | ## ð¨ ææ¯æ |
| | | |
| | | ### 模å |
| | |
| | | | `yudao-module-crm` | CRM ç³»ç»ç Module 模å | |
| | | | `yudao-module-mes` | MES ç³»ç»ç Module 模å | |
| | | | `yudao-module-wms` | WMS ç³»ç»ç Module 模å | |
| | | | `yudao-module-im` | IM 峿¶é讯ç Module 模å | |
| | | | `yudao-module-ai` | AI 大模åç Module 模å | |
| | | | `yudao-module-iot` | IoT ç©èç½ç Module 模å | |
| | | | `yudao-module-mp` | 微信å
¬ä¼å·ç Module 模å | |
| | |
| | | |
| | | | æ¡æ¶ | 说æ | çæ¬ | å¦ä¹ æå | |
| | | |---------------------------------------------------------------------------------------------|------------------|----------------|----------------------------------------------------------------| |
| | | | [Spring Boot](https://spring.io/projects/spring-boot) | åºç¨å¼åæ¡æ¶ | 3.5.5 | [ææ¡£](https://github.com/YunaiV/SpringBoot-Labs) | |
| | | | [Spring Boot](https://spring.io/projects/spring-boot) | åºç¨å¼åæ¡æ¶ | 4.1.0 | [ææ¡£](https://github.com/YunaiV/SpringBoot-Labs) | |
| | | | [MySQL](https://www.mysql.com/cn/) | æ°æ®åºæå¡å¨ | 5.7 / 8.0+ | | |
| | | | [Druid](https://github.com/alibaba/druid) | JDBC è¿æ¥æ± ãçæ§ç»ä»¶ | 1.2.27 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/datasource-pool/?yudao) | |
| | | | [MyBatis Plus](https://mp.baomidou.com/) | MyBatis å¢å¼ºå·¥å
·å
| 3.5.12 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/MyBatis/?yudao) | |
| | | | [Dynamic Datasource](https://dynamic-datasource.com/) | å¨ææ°æ®æº | 4.3.1 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/datasource-pool/?yudao) | |
| | | | [Druid](https://github.com/alibaba/druid) | JDBC è¿æ¥æ± ãçæ§ç»ä»¶ | 1.2.28 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/datasource-pool/?yudao) | |
| | | | [MyBatis Plus](https://mp.baomidou.com/) | MyBatis å¢å¼ºå·¥å
·å
| 3.5.16 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/MyBatis/?yudao) | |
| | | | [Dynamic Datasource](https://dynamic-datasource.com/) | å¨ææ°æ®æº | 4.5.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/datasource-pool/?yudao) | |
| | | | [Redis](https://redis.io/) | key-value æ°æ®åº | 5.0 / 6.0 /7.0 | | |
| | | | [Redisson](https://github.com/redisson/redisson) | Redis 客æ·ç«¯ | 3.35.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Redis/?yudao) | |
| | | | [Spring MVC](https://github.com/spring-projects/spring-framework/tree/master/spring-webmvc) | MVC æ¡æ¶ | 6.2.9 | [ææ¡£](http://www.iocoder.cn/SpringMVC/MVC/?yudao) | |
| | | | [Spring Security](https://github.com/spring-projects/spring-security) | Spring å®å
¨æ¡æ¶ | 6.5.2 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Spring-Security/?yudao) | |
| | | | [Hibernate Validator](https://github.com/hibernate/hibernate-validator) | åæ°æ ¡éªç»ä»¶ | 8.0.2 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Validation/?yudao) | |
| | | | [Flowable](https://github.com/flowable/flowable-engine) | 工使µå¼æ | 7.0.0 | [ææ¡£](https://doc.iocoder.cn/bpm/) | |
| | | | [Quartz](https://github.com/quartz-scheduler) | ä»»å¡è°åº¦ç»ä»¶ | 2.5.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Job/?yudao) | |
| | | | [Springdoc](https://springdoc.org/) | Swagger ææ¡£ | 2.8.9 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Swagger/?yudao) | |
| | | | [SkyWalking](https://skywalking.apache.org/) | åå¸å¼åºç¨è¿½è¸ªç³»ç» | 9.5.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/SkyWalking/?yudao) | |
| | | | [Spring Boot Admin](https://github.com/codecentric/spring-boot-admin) | Spring Boot çæ§å¹³å° | 3.5.2 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Admin/?yudao) | |
| | | | [Jackson](https://github.com/FasterXML/jackson) | JSON å·¥å
ጼ | 2.30.14 | | |
| | | | [Redisson](https://github.com/redisson/redisson) | Redis 客æ·ç«¯ | 4.6.1 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Redis/?yudao) | |
| | | | [Spring MVC](https://github.com/spring-projects/spring-framework/tree/master/spring-webmvc) | MVC æ¡æ¶ | 7.0.8 | [ææ¡£](http://www.iocoder.cn/SpringMVC/MVC/?yudao) | |
| | | | [Spring Security](https://github.com/spring-projects/spring-security) | Spring å®å
¨æ¡æ¶ | 7.1.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Spring-Security/?yudao) | |
| | | | [Hibernate Validator](https://github.com/hibernate/hibernate-validator) | åæ°æ ¡éªç»ä»¶ | 9.1.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Validation/?yudao) | |
| | | | [Flowable](https://github.com/flowable/flowable-engine) | 工使µå¼æ | 8.0.0 | [ææ¡£](https://doc.iocoder.cn/bpm/) | |
| | | | [Quartz](https://github.com/quartz-scheduler) | ä»»å¡è°åº¦ç»ä»¶ | 2.5.2 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Job/?yudao) | |
| | | | [Springdoc](https://springdoc.org/) | Swagger ææ¡£ | 3.0.3 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Swagger/?yudao) | |
| | | | [SkyWalking](https://skywalking.apache.org/) | åå¸å¼åºç¨è¿½è¸ªç³»ç» | 9.6.0 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/SkyWalking/?yudao) | |
| | | | [Spring Boot Admin](https://github.com/codecentric/spring-boot-admin) | Spring Boot çæ§å¹³å° | 4.0.4 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Admin/?yudao) | |
| | | | [Jackson](https://github.com/FasterXML/jackson) | JSON å·¥å
ጼ | 3.1.4 | | |
| | | | [MapStruct](https://mapstruct.org/) | Java Bean è½¬æ¢ | 1.6.3 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/MapStruct/?yudao) | |
| | | | [Lombok](https://projectlombok.org/) | æ¶é¤åé¿ç Java 代ç | 1.18.38 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Lombok/?yudao) | |
| | | | [JUnit](https://junit.org/junit5/) | Java åå
æµè¯æ¡æ¶ | 5.12.2 | - | |
| | | | [Mockito](https://github.com/mockito/mockito) | Java Mock æ¡æ¶ | 5.17.0 | - | |
| | | | [Lombok](https://projectlombok.org/) | æ¶é¤åé¿ç Java 代ç | 1.18.46 | [ææ¡£](http://www.iocoder.cn/Spring-Boot/Lombok/?yudao) | |
| | | | [JUnit](https://junit.org/junit5/) | Java åå
æµè¯æ¡æ¶ | 6.0.3 | - | |
| | | | [Mockito](https://github.com/mockito/mockito) | Java Mock æ¡æ¶ | 5.23.0 | - | |
| | | |
| | | ## ð· æ¼ç¤ºå¾ |
| | | |
| | | ### ç³»ç»åè½ |
| | | |
| | | | 模å | biu | biu | biu | |
| | | |----------|-----------------------------|---------------------------|--------------------------| |
| | | | 模å | biu | biu | biu | |
| | | |----------|-----------------------------|---------------------------|---------------------------| |
| | | | ç»å½ & é¦é¡µ |  |  |  | |
| | | | ç¨æ· & åºç¨ |  |  |  | |
| | | | ç§æ· & å¥é¤ |  |  | - | |
| | | | é¨é¨ & å²ä½ |  |  | - | |
| | | | èå & è§è² |  |  | - | |
| | | | 审计æ¥å¿ |  |  | - | |
| | | | ç§æ· & å¥é¤ |  |  | - | |
| | | | é¨é¨ & å²ä½ |  |  | - | |
| | | | èå & è§è² |  |  | - | |
| | | | 审计æ¥å¿ |  |  | - | |
| | | | çä¿¡ |  |  |  | |
| | | | åå
¸ & ææè¯ |  |  |  | |
| | | | é误ç & éç¥ |  |  | - | |
| | | | åå
¸ & ææè¯ |  |  |  | |
| | | | é误ç & éç¥ |  |  | - | |
| | | |
| | | ### 工使µç¨ |
| | | |
| | |
| | | <module>yudao-module-infra</module> |
| | | <module>yudao-module-member</module> |
| | | <module>yudao-module-bpm</module> |
| | | <module>yudao-module-report</module> |
| | | <module>yudao-module-mp</module> |
| | | <module>yudao-module-pay</module> |
| | | <module>yudao-module-mall</module> |
| | | <!-- <module>yudao-module-report</module>--> |
| | | <!-- <module>yudao-module-mp</module>--> |
| | | <!-- <module>yudao-module-pay</module>--> |
| | | <!-- <module>yudao-module-mall</module>--> |
| | | <module>yudao-module-crm</module> |
| | | <module>yudao-module-erp</module> |
| | | <module>yudao-module-iot</module> |
| | | <!-- <module>yudao-module-iot</module>--> |
| | | <module>yudao-module-mes</module> |
| | | <module>yudao-module-wms</module> |
| | | <module>yudao-module-mdm</module> |
| | | <module>yudao-module-mdm-api</module> |
| | | <!-- 请åè https://doc.iocoder.cn/ai/build/ ææ¡£ï¼å®æ AI 模åçå¯å¨ï¼ï¼ï¼ --> |
| | | <module>yudao-module-ai</module> |
| | | <module>yudao-module-im</module> |
| | | <!-- 请åè https://doc.iocoder.cn/ai/build/ ææ¡£ï¼å®æ AI 模åçå¯å¨ï¼ï¼ï¼ --> |
| | | <!-- <module>yudao-module-ai</module>--> |
| | | </modules> |
| | | |
| | | <name>${project.artifactId}</name> |
| | |
| | | <url>https://github.com/YunaiV/ruoyi-vue-pro</url> |
| | | |
| | | <properties> |
| | | <revision>2026.04-SNAPSHOT</revision> |
| | | <revision>2026.06-jdk25-SNAPSHOT</revision> |
| | | <!-- Maven ç¸å
³ --> |
| | | <java.version>21</java.version> |
| | | <java.version>25</java.version> |
| | | <maven.compiler.source>${java.version}</maven.compiler.source> |
| | | <maven.compiler.target>${java.version}</maven.compiler.target> |
| | | <maven-surefire-plugin.version>3.5.3</maven-surefire-plugin.version> |
| | |
| | | <flatten-maven-plugin.version>1.7.2</flatten-maven-plugin.version> |
| | | <!-- maven-surefire-plugin ææ¶æ æ³éè¿ bom çä¾èµè¯»åï¼å
¼å®¹èçæ¬ IDEA 2024 å以åçæ¬ï¼ --> |
| | | <lombok.version>1.18.46</lombok.version> |
| | | <spring.boot.version>4.0.6</spring.boot.version> |
| | | <spring.boot.version>4.1.0</spring.boot.version> |
| | | <mapstruct.version>1.6.3</mapstruct.version> |
| | | <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| | | </properties> |
| | |
| | | </path> |
| | | <path> |
| | | <!-- ç¡®ä¿ Lombok çæç getter/setter æ¹æ³è½è¢« MapStruct æ£ç¡®è¯å«ï¼ |
| | | é¿å
åºç° No property named âxxx" exists çç¼è¯é误 --> |
| | | é¿å
åºç° No property named "xxx" exists çç¼è¯é误 --> |
| | | <groupId>org.projectlombok</groupId> |
| | | <artifactId>lombok-mapstruct-binding</artifactId> |
| | | <version>0.2.0</version> |
| | |
| | | |
| | | <!-- ä½¿ç¨ huawei / aliyun ç Maven æºï¼æåä¸è½½é度 --> |
| | | <repositories> |
| | | <repository> |
| | | <id>spring-milestones</id> |
| | | <name>Spring Milestones</name> |
| | | <url>https://repo.spring.io/milestone</url> |
| | | <snapshots> |
| | | <enabled>false</enabled> |
| | | </snapshots> |
| | | </repository> |
| | | <repository> |
| | | <id>huaweicloud</id> |
| | | <name>huawei</name> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | # LiveKit Server PoC |
| | | |
| | | æå°å¯ç¨ç LiveKit Server èªé¨ç½²éªè¯ç¯å¢ï¼ç¨äºé¶æ PoCã |
| | | |
| | | ## å¯å¨ |
| | | |
| | | ```bash |
| | | cd tools/livekit-poc |
| | | docker compose up -d |
| | | bash verify.sh |
| | | ``` |
| | | |
| | | ## ç«¯å£ |
| | | |
| | | - 7880ï¼HTTP / WebSocket ä¿¡ä»¤ï¼ |
| | | - 7881ï¼WebRTC TCP fallbackï¼ |
| | | - 7882/UDPï¼WebRTC åªä½ï¼ |
| | | - macOS / Windowsï¼å½å `docker-compose.yml` èµ°ç«¯å£æ å°æ¨¡å¼ï¼webhook URL ç¨ `host.docker.internal:48080` 让容å¨è®¿é®å°å®¿ä¸»æº yudao åç«¯ï¼ |
| | | - macOS ä¸ host networkï¼`network_mode: host`ï¼éè¦ Docker Desktop 4.34+ å¹¶å¨ Settings â Resources â Network å¾éãEnable host networkingãï¼èçæ¬éé»å¤±è´¥ï¼å®¹å¨è·å¾èµ·æ¥ä½ç«¯å£å®å
¨ä¸éï¼ï¼ |
| | | - Linuxï¼å¯ä»¥æ `docker-compose.yml` æ¹æ `network_mode: host` + å `ports:` 段ï¼å¹¶æ `livekit.yaml` ç webhook URL æ¹ä¸º `http://127.0.0.1:48080/admin-api/im/livekit/webhook`ã |
| | | |
| | | ## åæ® (ä»
PoCï¼å¿ç¨äºç产) |
| | | |
| | | - `LIVEKIT_KEYS=devkey: secret-poc-key-min-32-chars-required-here` |
| | | - API Keyï¼`devkey` |
| | | - API Secretï¼`secret-poc-key-min-32-chars-required-here` |
| | | |
| | | ç产ç¯å¢å¿
é¡»æ¹ç¨å¼ºéæº secretï¼å¹¶éè¿ `--config /etc/livekit.yaml` å è½½ã |
| | | |
| | | ## æµè§å¨èè° |
| | | |
| | | `verify.sh` è·å®ä¼è¾åºä¸ä¸ª `meet.livekit.io` 龿¥ï¼ç¨ä¸¤ä¸ªæµè§å¨ï¼æä¸¤å°æºå¨ï¼æå¼åä¸é¾æ¥å³å¯çå°å¯¹æ¹ç»é¢ã |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | services: |
| | | livekit: |
| | | image: docker.m.daocloud.io/livekit/livekit-server:latest |
| | | container_name: yudao-livekit-dev |
| | | restart: unless-stopped |
| | | # ç«¯å£æ å°æ¨¡å¼ |
| | | # macOS / Windows å¿
èµ°è¿ç§æ¹å¼ï¼Docker Desktop 4.34 以䏿²¡æ host network |
| | | # Linux å¯ä»¥æ¹ network_mode: host ç廿 å°ï¼å¹¶æ livekit.yaml ç webhook url æ¢æ 127.0.0.1 |
| | | ports: |
| | | - "7880:7880" # HTTP / WebSocket 信令 |
| | | - "7881:7881" # WebRTC TCP fallback |
| | | - "7882:7882/udp" # WebRTC UDP (dev æ¨¡å¼ UDP mux å端å£) |
| | | volumes: |
| | | # æè½½ config æä»¶ï¼webhook é
ç½®å¨ livekit.yaml é |
| | | - ./livekit.yaml:/etc/livekit.yaml:ro |
| | | command: |
| | | - --config |
| | | - /etc/livekit.yaml |
| | | - --bind |
| | | - 0.0.0.0 |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | # LiveKit Server æ¬å°å¼åé
ç½®ï¼PoC ç¨ï¼å¿ç¨äºçäº§ï¼ |
| | | # æ¿ä»£ docker --dev 模å¼ï¼ä¸ºæ¯æ webhook å¿
é¡»ç¨ config æä»¶èé env |
| | | |
| | | keys: |
| | | devkey: secret-poc-key-min-32-chars-required-here |
| | | |
| | | # ç«¯å£ |
| | | port: 7880 |
| | | rtc: |
| | | tcp_port: 7881 |
| | | udp_port: 7882 |
| | | use_external_ip: false |
| | | |
| | | # Webhookï¼æåç¦»å¼ / æ¿é´ç»æçäºä»¶åè°å° yudao å端åä¸å¡æå
åºæ¸
ç |
| | | # host.docker.internal 让容å¨è®¿é®å®¿ä¸»æº macOS / Windows ä¸ç yudao å端 |
| | | # Linux ä¸ docker compose 坿¹ network_mode: hostï¼è¿éåæ¥æ¹æ 127.0.0.1 |
| | | # api_key ç¨äºç¾å JWTï¼yudao å端ç¨ç¸å secret éªè¯ç¾å |
| | | webhook: |
| | | api_key: devkey |
| | | urls: |
| | | - http://host.docker.internal:48080/admin-api/im/livekit/webhook |
| | | |
| | | # æ¿é´æ 人æ¶å¤ä¹
鿝ï¼ç§ï¼ä¹å PoC é»è®¤ 300ï¼ç»ä½äºæ¹ä¾¿ææ¥ |
| | | room: |
| | | empty_timeout: 300 |
| | | departure_timeout: 20 |
| | | |
| | | # å¼å模å¼ï¼æ¾å®½ secret é¿åº¦éå¶ + å
ç½® TURN æå¡ |
| | | development: true |
| | | log_level: info |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | #!/usr/bin/env bash |
| | | # LiveKit Server PoC éªè¯èæ¬ï¼ |
| | | # ç¨æ³ï¼ bash verify.sh |
| | | set -e |
| | | |
| | | API_KEY="${LIVEKIT_API_KEY:-devkey}" |
| | | API_SECRET="${LIVEKIT_API_SECRET:-secret-poc-key-min-32-chars-required-here}" |
| | | HOST="${LIVEKIT_HOST:-localhost:7880}" |
| | | ROOM="${LIVEKIT_ROOM:-poc-room}" |
| | | |
| | | ok() { printf "[OK] %s\n" "$1"; } |
| | | fail() { printf "[FAIL] %s\n" "$1"; exit 1; } |
| | | |
| | | echo "==> 1/5 çå¾
HTTP 端ç¹å°±ç»ª (http://${HOST}/)" |
| | | for i in $(seq 1 20); do |
| | | code=$(curl -s -o /dev/null -w "%{http_code}" "http://${HOST}/" || echo "000") |
| | | [ "$code" = "200" ] && { ok "HTTP 200"; break; } |
| | | [ $i -eq 20 ] && fail "20 ç§å
æªå°±ç»ª (last code=${code})" |
| | | sleep 1 |
| | | done |
| | | |
| | | echo "==> 2/5 ç¾å管ç + 客æ·ç«¯æé Token" |
| | | TOKEN=$(API_KEY="$API_KEY" API_SECRET="$API_SECRET" ROOM="$ROOM" python3 - <<'PY' |
| | | import json, time, hmac, hashlib, base64, os |
| | | def b64u(b): return base64.urlsafe_b64encode(b).rstrip(b'=').decode() |
| | | header = b64u(json.dumps({"alg":"HS256","typ":"JWT"}, separators=(',',':')).encode()) |
| | | payload = b64u(json.dumps({ |
| | | "iss": os.environ["API_KEY"], |
| | | "sub": "poc-tester", |
| | | "name": "PoC Tester", |
| | | "video": { |
| | | "roomJoin": True, "room": os.environ["ROOM"], |
| | | "canPublish": True, "canSubscribe": True, "canPublishData": True, |
| | | "roomCreate": True, "roomList": True, "roomAdmin": True |
| | | }, |
| | | "exp": int(time.time()) + 3600, |
| | | "nbf": int(time.time()) |
| | | }, separators=(',',':')).encode()) |
| | | sig = b64u(hmac.new(os.environ["API_SECRET"].encode(), |
| | | f"{header}.{payload}".encode(), |
| | | hashlib.sha256).digest()) |
| | | print(f"{header}.{payload}.{sig}") |
| | | PY |
| | | ) |
| | | [ -n "$TOKEN" ] || fail "Token çæå¤±è´¥" |
| | | ok "Token å·²çæ (${#TOKEN} chars)" |
| | | |
| | | echo "==> 3/5 å建æ¿é´ ${ROOM} (CreateRoom RPC)" |
| | | create_resp=$(curl -s -X POST "http://${HOST}/twirp/livekit.RoomService/CreateRoom" \ |
| | | -H "Authorization: Bearer ${TOKEN}" \ |
| | | -H "Content-Type: application/json" \ |
| | | -d "{\"name\":\"${ROOM}\",\"empty_timeout\":300,\"max_participants\":10}") |
| | | echo " ååº: $create_resp" |
| | | echo "$create_resp" | jq -e '.sid' >/dev/null 2>&1 \ |
| | | && ok "æ¿é´å·²å建" \ |
| | | || fail "CreateRoom 失败" |
| | | |
| | | echo "==> 4/5 ååºæ¿é´ (ListRooms RPC)" |
| | | list_resp=$(curl -s -X POST "http://${HOST}/twirp/livekit.RoomService/ListRooms" \ |
| | | -H "Authorization: Bearer ${TOKEN}" \ |
| | | -H "Content-Type: application/json" \ |
| | | -d '{}') |
| | | room_count=$(echo "$list_resp" | jq '.rooms | length' 2>/dev/null || echo "0") |
| | | ok "å½åæ¿é´æ°: ${room_count}" |
| | | echo "$list_resp" | jq '.' |
| | | |
| | | echo "==> 5/5 å 餿¿é´ (DeleteRoom RPC) ââ æ¸
ç" |
| | | del_resp=$(curl -s -X POST "http://${HOST}/twirp/livekit.RoomService/DeleteRoom" \ |
| | | -H "Authorization: Bearer ${TOKEN}" \ |
| | | -H "Content-Type: application/json" \ |
| | | -d "{\"room\":\"${ROOM}\"}") |
| | | ok "å é¤ååº: $del_resp" |
| | | |
| | | # éæ°ç¾ä¸ä¸ªä»
client æéç tokenï¼ç¨äºæµè§å¨è¿ä¼ |
| | | CLIENT_TOKEN=$(API_KEY="$API_KEY" API_SECRET="$API_SECRET" ROOM="$ROOM" python3 - <<'PY' |
| | | import json, time, hmac, hashlib, base64, os |
| | | def b64u(b): return base64.urlsafe_b64encode(b).rstrip(b'=').decode() |
| | | header = b64u(json.dumps({"alg":"HS256","typ":"JWT"}, separators=(',',':')).encode()) |
| | | payload = b64u(json.dumps({ |
| | | "iss": os.environ["API_KEY"], |
| | | "sub": "browser-tester", |
| | | "name": "Browser", |
| | | "video": { |
| | | "roomJoin": True, "room": os.environ["ROOM"], |
| | | "canPublish": True, "canSubscribe": True, "canPublishData": True |
| | | }, |
| | | "exp": int(time.time()) + 7200 |
| | | }, separators=(',',':')).encode()) |
| | | sig = b64u(hmac.new(os.environ["API_SECRET"].encode(), |
| | | f"{header}.{payload}".encode(), |
| | | hashlib.sha256).digest()) |
| | | print(f"{header}.{payload}.{sig}") |
| | | PY |
| | | ) |
| | | |
| | | echo "" |
| | | echo "============================================================" |
| | | echo " LiveKit Server éªè¯éè¿" |
| | | echo "============================================================" |
| | | echo " æµè§å¨æµè¯ (å¼ä¸¤ä¸ªçªå£è½äºé)ï¼" |
| | | echo " https://meet.livekit.io/?liveKitUrl=ws%3A%2F%2F${HOST}&token=${CLIENT_TOKEN}" |
| | | echo "" |
| | | echo " 忢æå¡ï¼" |
| | | echo " docker compose -f tools/livekit-poc/docker-compose.yml down" |
| | | echo "============================================================" |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_api_access_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | trace_id varchar(64) DEFAULT '' NULL, |
| | | trace_id varchar(64 char) DEFAULT '' NULL, |
| | | user_id bigint DEFAULT 0 NOT NULL, |
| | | user_type smallint DEFAULT 0 NOT NULL, |
| | | application_name varchar(50) NOT NULL, |
| | | request_method varchar(16) DEFAULT '' NULL, |
| | | request_url varchar(255) DEFAULT '' NULL, |
| | | application_name varchar(50 char) NOT NULL, |
| | | request_method varchar(16 char) DEFAULT '' NULL, |
| | | request_url varchar(255 char) DEFAULT '' NULL, |
| | | request_params text NULL, |
| | | response_body text NULL, |
| | | user_ip varchar(50) NOT NULL, |
| | | user_agent varchar(512) NOT NULL, |
| | | operate_module varchar(50) DEFAULT NULL NULL, |
| | | operate_name varchar(50) DEFAULT NULL NULL, |
| | | user_ip varchar(50 char) NOT NULL, |
| | | user_agent varchar(512 char) NOT NULL, |
| | | operate_module varchar(50 char) DEFAULT NULL NULL, |
| | | operate_name varchar(50 char) DEFAULT NULL NULL, |
| | | operate_type smallint DEFAULT 0 NULL, |
| | | begin_time datetime NOT NULL, |
| | | end_time datetime NOT NULL, |
| | | duration int NOT NULL, |
| | | result_code int DEFAULT 0 NOT NULL, |
| | | result_msg varchar(512) DEFAULT '' NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | result_msg varchar(512 char) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_api_error_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | trace_id varchar(64) NOT NULL, |
| | | trace_id varchar(64 char) NOT NULL, |
| | | user_id bigint DEFAULT 0 NOT NULL, |
| | | user_type smallint DEFAULT 0 NOT NULL, |
| | | application_name varchar(50) NOT NULL, |
| | | request_method varchar(16) NOT NULL, |
| | | request_url varchar(255) NOT NULL, |
| | | request_params varchar(8000) NOT NULL, |
| | | user_ip varchar(50) NOT NULL, |
| | | user_agent varchar(512) NOT NULL, |
| | | application_name varchar(50 char) NOT NULL, |
| | | request_method varchar(16 char) NOT NULL, |
| | | request_url varchar(255 char) NOT NULL, |
| | | request_params varchar(8000 char) NOT NULL, |
| | | user_ip varchar(50 char) NOT NULL, |
| | | user_agent varchar(512 char) NOT NULL, |
| | | exception_time datetime NOT NULL, |
| | | exception_name varchar(128) DEFAULT '' NULL, |
| | | exception_name varchar(128 char) DEFAULT '' NULL, |
| | | exception_message text NOT NULL, |
| | | exception_root_cause_message text NOT NULL, |
| | | exception_stack_trace text NOT NULL, |
| | | exception_class_name varchar(512) NOT NULL, |
| | | exception_file_name varchar(512) NOT NULL, |
| | | exception_method_name varchar(512) NOT NULL, |
| | | exception_class_name varchar(512 char) NOT NULL, |
| | | exception_file_name varchar(512 char) NOT NULL, |
| | | exception_method_name varchar(512 char) NOT NULL, |
| | | exception_line_number int NOT NULL, |
| | | process_status smallint NOT NULL, |
| | | process_time datetime DEFAULT NULL NULL, |
| | | process_user_id int DEFAULT 0 NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE infra_codegen_column ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | table_id bigint NOT NULL, |
| | | column_name varchar(200) NOT NULL, |
| | | data_type varchar(100) NOT NULL, |
| | | column_comment varchar(500) NOT NULL, |
| | | column_name varchar(200 char) NOT NULL, |
| | | data_type varchar(100 char) NOT NULL, |
| | | column_comment varchar(500 char) NOT NULL, |
| | | nullable bit NOT NULL, |
| | | primary_key bit NOT NULL, |
| | | ordinal_position int NOT NULL, |
| | | java_type varchar(32) NOT NULL, |
| | | java_field varchar(64) NOT NULL, |
| | | dict_type varchar(200) DEFAULT '' NULL, |
| | | example varchar(64) DEFAULT NULL NULL, |
| | | java_type varchar(32 char) NOT NULL, |
| | | java_field varchar(64 char) NOT NULL, |
| | | dict_type varchar(200 char) DEFAULT '' NULL, |
| | | example varchar(64 char) DEFAULT NULL NULL, |
| | | create_operation bit NOT NULL, |
| | | update_operation bit NOT NULL, |
| | | list_operation bit NOT NULL, |
| | | list_operation_condition varchar(32) DEFAULT '=' NOT NULL, |
| | | list_operation_condition varchar(32 char) DEFAULT '=' NOT NULL, |
| | | list_operation_result bit NOT NULL, |
| | | html_type varchar(32) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | html_type varchar(32 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | data_source_config_id bigint NOT NULL, |
| | | scene smallint DEFAULT 1 NOT NULL, |
| | | table_name varchar(200) DEFAULT '' NULL, |
| | | table_comment varchar(500) DEFAULT '' NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | module_name varchar(30) NOT NULL, |
| | | business_name varchar(30) NOT NULL, |
| | | class_name varchar(100) DEFAULT '' NULL, |
| | | class_comment varchar(50) NOT NULL, |
| | | author varchar(50) NOT NULL, |
| | | table_name varchar(200 char) DEFAULT '' NULL, |
| | | table_comment varchar(500 char) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | module_name varchar(30 char) NOT NULL, |
| | | business_name varchar(30 char) NOT NULL, |
| | | class_name varchar(100 char) DEFAULT '' NULL, |
| | | class_comment varchar(50 char) NOT NULL, |
| | | author varchar(50 char) NOT NULL, |
| | | template_type smallint DEFAULT 1 NOT NULL, |
| | | front_type smallint NOT NULL, |
| | | parent_menu_id bigint DEFAULT NULL NULL, |
| | |
| | | sub_join_many bit DEFAULT NULL NULL, |
| | | tree_parent_column_id bigint DEFAULT NULL NULL, |
| | | tree_name_column_id bigint DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_config ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | category varchar(50) NOT NULL, |
| | | category varchar(50 char) NOT NULL, |
| | | type smallint NOT NULL, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | config_key varchar(100) DEFAULT '' NULL, |
| | | value varchar(500) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | config_key varchar(100 char) DEFAULT '' NULL, |
| | | value varchar(500 char) DEFAULT '' NULL, |
| | | visible bit NOT NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_data_source_config ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | url varchar(1024) NOT NULL, |
| | | username varchar(255) NOT NULL, |
| | | password varchar(255) DEFAULT '' NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | url varchar(1024 char) NOT NULL, |
| | | username varchar(255 char) NOT NULL, |
| | | password varchar(255 char) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | CREATE TABLE infra_file ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | config_id bigint DEFAULT NULL NULL, |
| | | name varchar(256) DEFAULT NULL NULL, |
| | | path varchar(512) NOT NULL, |
| | | url varchar(1024) NOT NULL, |
| | | type varchar(128) DEFAULT NULL NULL, |
| | | name varchar(256 char) DEFAULT NULL NULL, |
| | | path varchar(512 char) NOT NULL, |
| | | url varchar(1024 char) NOT NULL, |
| | | type varchar(128 char) DEFAULT NULL NULL, |
| | | size int NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_file_config ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(63) NOT NULL, |
| | | name varchar(63 char) NOT NULL, |
| | | storage smallint NOT NULL, |
| | | remark varchar(255) DEFAULT NULL NULL, |
| | | remark varchar(255 char) DEFAULT NULL NULL, |
| | | master bit NOT NULL, |
| | | config varchar(4096) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | config varchar(4096 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | CREATE TABLE infra_file_content ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | config_id bigint NOT NULL, |
| | | path varchar(512) NOT NULL, |
| | | path varchar(512 char) NOT NULL, |
| | | content blob NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE infra_job ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(32) NOT NULL, |
| | | name varchar(32 char) NOT NULL, |
| | | status smallint NOT NULL, |
| | | handler_name varchar(64) NOT NULL, |
| | | handler_param varchar(255) DEFAULT NULL NULL, |
| | | cron_expression varchar(32) NOT NULL, |
| | | handler_name varchar(64 char) NOT NULL, |
| | | handler_param varchar(255 char) DEFAULT NULL NULL, |
| | | cron_expression varchar(32 char) NOT NULL, |
| | | retry_count int DEFAULT 0 NOT NULL, |
| | | retry_interval int DEFAULT 0 NOT NULL, |
| | | monitor_timeout int DEFAULT 0 NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | CREATE TABLE infra_job_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | job_id bigint NOT NULL, |
| | | handler_name varchar(64) NOT NULL, |
| | | handler_param varchar(255) DEFAULT NULL NULL, |
| | | handler_name varchar(64 char) NOT NULL, |
| | | handler_param varchar(255 char) DEFAULT NULL NULL, |
| | | execute_index smallint DEFAULT 1 NOT NULL, |
| | | begin_time datetime NOT NULL, |
| | | end_time datetime DEFAULT NULL NULL, |
| | | duration int DEFAULT NULL NULL, |
| | | status smallint NOT NULL, |
| | | result varchar(4000) DEFAULT '' NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | result varchar(4000 char) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_dept ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(30) DEFAULT '' NULL, |
| | | name varchar(30 char) DEFAULT '' NULL, |
| | | parent_id bigint DEFAULT 0 NOT NULL, |
| | | sort int DEFAULT 0 NOT NULL, |
| | | leader_user_id bigint DEFAULT NULL NULL, |
| | | phone varchar(11) DEFAULT NULL NULL, |
| | | email varchar(50) DEFAULT NULL NULL, |
| | | phone varchar(11 char) DEFAULT NULL NULL, |
| | | email varchar(50 char) DEFAULT NULL NULL, |
| | | status smallint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE system_dict_data ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | sort int DEFAULT 0 NOT NULL, |
| | | label varchar(100) DEFAULT '' NULL, |
| | | value varchar(100) DEFAULT '' NULL, |
| | | dict_type varchar(100) DEFAULT '' NULL, |
| | | label varchar(100 char) DEFAULT '' NULL, |
| | | value varchar(100 char) DEFAULT '' NULL, |
| | | dict_type varchar(100 char) DEFAULT '' NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | color_type varchar(100) DEFAULT '' NULL, |
| | | css_class varchar(100) DEFAULT '' NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | color_type varchar(100 char) DEFAULT '' NULL, |
| | | css_class varchar(100 char) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', '2025-09-06 00:02:21', '1', '2025-09-06 00:02:31', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', '2023-11-04 13:05:38', '1', '2023-11-04 13:07:16', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', '2025-12-16 19:25:51', '1', '2025-12-17 09:46:15', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', '2026-02-04 00:32:47', '1', '2026-02-04 00:32:47', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | COMMIT; |
| | | SET IDENTITY_INSERT system_dict_data OFF; |
| | | -- @formatter:on |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_dict_type ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | type varchar(100) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | type varchar(100 char) DEFAULT '' NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | deleted_time datetime DEFAULT NULL NULL |
| | |
| | | CREATE TABLE system_login_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | log_type bigint NOT NULL, |
| | | trace_id varchar(64) DEFAULT '' NULL, |
| | | trace_id varchar(64 char) DEFAULT '' NULL, |
| | | user_id bigint DEFAULT 0 NOT NULL, |
| | | user_type smallint DEFAULT 0 NOT NULL, |
| | | username varchar(50) DEFAULT '' NULL, |
| | | username varchar(50 char) DEFAULT '' NULL, |
| | | result smallint NOT NULL, |
| | | user_ip varchar(50) NOT NULL, |
| | | user_agent varchar(512) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | user_ip varchar(50 char) NOT NULL, |
| | | user_agent varchar(512 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_mail_account ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | mail varchar(255) NOT NULL, |
| | | username varchar(255) NOT NULL, |
| | | password varchar(255) NOT NULL, |
| | | host varchar(255) NOT NULL, |
| | | mail varchar(255 char) NOT NULL, |
| | | username varchar(255 char) NOT NULL, |
| | | password varchar(255 char) NOT NULL, |
| | | host varchar(255 char) NOT NULL, |
| | | port int NOT NULL, |
| | | ssl_enable bit DEFAULT '0' NOT NULL, |
| | | starttls_enable bit DEFAULT '0' NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint DEFAULT NULL NULL, |
| | | user_type smallint DEFAULT NULL NULL, |
| | | to_mails varchar(1024) NOT NULL, |
| | | cc_mails varchar(1024) DEFAULT NULL NULL, |
| | | bcc_mails varchar(1024) DEFAULT NULL NULL, |
| | | to_mails varchar(1024 char) NOT NULL, |
| | | cc_mails varchar(1024 char) DEFAULT NULL NULL, |
| | | bcc_mails varchar(1024 char) DEFAULT NULL NULL, |
| | | account_id bigint NOT NULL, |
| | | from_mail varchar(255) NOT NULL, |
| | | from_mail varchar(255 char) NOT NULL, |
| | | template_id bigint NOT NULL, |
| | | template_code varchar(63) NOT NULL, |
| | | template_nickname varchar(255) DEFAULT NULL NULL, |
| | | template_title varchar(255) NOT NULL, |
| | | template_code varchar(63 char) NOT NULL, |
| | | template_nickname varchar(255 char) DEFAULT NULL NULL, |
| | | template_title varchar(255 char) NOT NULL, |
| | | template_content text NOT NULL, |
| | | template_params varchar(255) NOT NULL, |
| | | template_params varchar(255 char) NOT NULL, |
| | | send_status smallint DEFAULT 0 NOT NULL, |
| | | send_time datetime DEFAULT NULL NULL, |
| | | send_message_id varchar(255) DEFAULT NULL NULL, |
| | | send_exception varchar(4096) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | send_message_id varchar(255 char) DEFAULT NULL NULL, |
| | | send_exception varchar(4096 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_mail_template ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(63) NOT NULL, |
| | | code varchar(63) NOT NULL, |
| | | name varchar(63 char) NOT NULL, |
| | | code varchar(63 char) NOT NULL, |
| | | account_id bigint NOT NULL, |
| | | nickname varchar(255) DEFAULT NULL NULL, |
| | | title varchar(255) NOT NULL, |
| | | content varchar(10240) NOT NULL, |
| | | params varchar(255) NOT NULL, |
| | | nickname varchar(255 char) DEFAULT NULL NULL, |
| | | title varchar(255 char) NOT NULL, |
| | | content varchar(10240 char) NOT NULL, |
| | | params varchar(255 char) NOT NULL, |
| | | status smallint NOT NULL, |
| | | remark varchar(255) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(255 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_menu ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(50) NOT NULL, |
| | | permission varchar(100) DEFAULT '' NULL, |
| | | name varchar(50 char) NOT NULL, |
| | | permission varchar(100 char) DEFAULT '' NULL, |
| | | type smallint NOT NULL, |
| | | sort int DEFAULT 0 NOT NULL, |
| | | parent_id bigint DEFAULT 0 NOT NULL, |
| | | path varchar(200) DEFAULT '' NULL, |
| | | icon varchar(100) DEFAULT '#' NULL, |
| | | component varchar(255) DEFAULT NULL NULL, |
| | | component_name varchar(255) DEFAULT NULL NULL, |
| | | path varchar(200 char) DEFAULT '' NULL, |
| | | icon varchar(100 char) DEFAULT '#' NULL, |
| | | component varchar(255 char) DEFAULT NULL NULL, |
| | | component_name varchar(255 char) DEFAULT NULL NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | visible bit DEFAULT '1' NOT NULL, |
| | | keep_alive bit DEFAULT '1' NOT NULL, |
| | | always_show bit DEFAULT '1' NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_notice ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | title varchar(50) NOT NULL, |
| | | title varchar(50 char) NOT NULL, |
| | | content text NOT NULL, |
| | | type smallint NOT NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | user_id bigint NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | template_id bigint NOT NULL, |
| | | template_code varchar(64) NOT NULL, |
| | | template_nickname varchar(63) NOT NULL, |
| | | template_content varchar(1024) NOT NULL, |
| | | template_code varchar(64 char) NOT NULL, |
| | | template_nickname varchar(63 char) NOT NULL, |
| | | template_content varchar(1024 char) NOT NULL, |
| | | template_type int NOT NULL, |
| | | template_params varchar(255) NOT NULL, |
| | | template_params varchar(255 char) NOT NULL, |
| | | read_status bit NOT NULL, |
| | | read_time datetime DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_notify_template ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(63) NOT NULL, |
| | | code varchar(64) NOT NULL, |
| | | nickname varchar(255) NOT NULL, |
| | | content varchar(1024) NOT NULL, |
| | | name varchar(63 char) NOT NULL, |
| | | code varchar(64 char) NOT NULL, |
| | | nickname varchar(255 char) NOT NULL, |
| | | content varchar(1024 char) NOT NULL, |
| | | type smallint NOT NULL, |
| | | params varchar(255) DEFAULT NULL NULL, |
| | | params varchar(255 char) DEFAULT NULL NULL, |
| | | status smallint NOT NULL, |
| | | remark varchar(255) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(255 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | user_info varchar(512) NOT NULL, |
| | | access_token varchar(255) NOT NULL, |
| | | refresh_token varchar(32) NOT NULL, |
| | | client_id varchar(255) NOT NULL, |
| | | scopes varchar(255) DEFAULT NULL NULL, |
| | | user_info varchar(512 char) NOT NULL, |
| | | access_token varchar(255 char) NOT NULL, |
| | | refresh_token varchar(32 char) NOT NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | scopes varchar(255 char) DEFAULT NULL NULL, |
| | | expires_time datetime NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | client_id varchar(255) NOT NULL, |
| | | scope varchar(255) DEFAULT '' NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | scope varchar(255 char) DEFAULT '' NULL, |
| | | approved bit DEFAULT '0' NOT NULL, |
| | | expires_time datetime NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_oauth2_client ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | client_id varchar(255) NOT NULL, |
| | | secret varchar(255) NOT NULL, |
| | | name varchar(255) NOT NULL, |
| | | logo varchar(255) NOT NULL, |
| | | description varchar(255) DEFAULT NULL NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | secret varchar(255 char) NOT NULL, |
| | | name varchar(255 char) NOT NULL, |
| | | logo varchar(255 char) NOT NULL, |
| | | description varchar(255 char) DEFAULT NULL NULL, |
| | | status smallint NOT NULL, |
| | | access_token_validity_seconds int NOT NULL, |
| | | refresh_token_validity_seconds int NOT NULL, |
| | | redirect_uris varchar(255) NOT NULL, |
| | | authorized_grant_types varchar(255) NOT NULL, |
| | | scopes varchar(255) DEFAULT NULL NULL, |
| | | auto_approve_scopes varchar(255) DEFAULT NULL NULL, |
| | | authorities varchar(255) DEFAULT NULL NULL, |
| | | resource_ids varchar(255) DEFAULT NULL NULL, |
| | | additional_information varchar(4096) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | redirect_uris varchar(255 char) NOT NULL, |
| | | authorized_grant_types varchar(255 char) NOT NULL, |
| | | scopes varchar(255 char) DEFAULT NULL NULL, |
| | | auto_approve_scopes varchar(255 char) DEFAULT NULL NULL, |
| | | authorities varchar(255 char) DEFAULT NULL NULL, |
| | | resource_ids varchar(255 char) DEFAULT NULL NULL, |
| | | additional_information varchar(4096 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | code varchar(32) NOT NULL, |
| | | client_id varchar(255) NOT NULL, |
| | | scopes varchar(255) DEFAULT '' NULL, |
| | | code varchar(32 char) NOT NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | scopes varchar(255 char) DEFAULT '' NULL, |
| | | expires_time datetime NOT NULL, |
| | | redirect_uri varchar(255) DEFAULT NULL NULL, |
| | | state varchar(255) DEFAULT '' NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | redirect_uri varchar(255 char) DEFAULT NULL NULL, |
| | | state varchar(255 char) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE system_oauth2_refresh_token ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint NOT NULL, |
| | | refresh_token varchar(32) NOT NULL, |
| | | refresh_token varchar(32 char) NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | client_id varchar(255) NOT NULL, |
| | | scopes varchar(255) DEFAULT NULL NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | scopes varchar(255 char) DEFAULT NULL NULL, |
| | | expires_time datetime NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_operate_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | trace_id varchar(64) DEFAULT '' NULL, |
| | | trace_id varchar(64 char) DEFAULT '' NULL, |
| | | user_id bigint NOT NULL, |
| | | user_type smallint DEFAULT 0 NOT NULL, |
| | | type varchar(50) NOT NULL, |
| | | sub_type varchar(50) NOT NULL, |
| | | type varchar(50 char) NOT NULL, |
| | | sub_type varchar(50 char) NOT NULL, |
| | | biz_id bigint NOT NULL, |
| | | action varchar(2000) DEFAULT '' NULL, |
| | | action varchar(2000 char) DEFAULT '' NULL, |
| | | success bit DEFAULT '1' NOT NULL, |
| | | extra varchar(2000) DEFAULT '' NULL, |
| | | request_method varchar(16) DEFAULT '' NULL, |
| | | request_url varchar(255) DEFAULT '' NULL, |
| | | user_ip varchar(50) DEFAULT NULL NULL, |
| | | user_agent varchar(512) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | extra varchar(2000 char) DEFAULT '' NULL, |
| | | request_method varchar(16 char) DEFAULT '' NULL, |
| | | request_url varchar(255 char) DEFAULT '' NULL, |
| | | user_ip varchar(50 char) DEFAULT NULL NULL, |
| | | user_agent varchar(512 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_post ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | code varchar(64) NOT NULL, |
| | | name varchar(50) NOT NULL, |
| | | code varchar(64 char) NOT NULL, |
| | | name varchar(50 char) NOT NULL, |
| | | sort int NOT NULL, |
| | | status smallint NOT NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_role ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(30) NOT NULL, |
| | | code varchar(100) NOT NULL, |
| | | name varchar(30 char) NOT NULL, |
| | | code varchar(100 char) NOT NULL, |
| | | sort int NOT NULL, |
| | | data_scope smallint DEFAULT 1 NOT NULL, |
| | | data_scope_dept_ids varchar(500) DEFAULT '' NULL, |
| | | data_scope_dept_ids varchar(500 char) DEFAULT '' NULL, |
| | | status smallint NOT NULL, |
| | | type smallint NOT NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | role_id bigint NOT NULL, |
| | | menu_id bigint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_sms_channel ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | signature varchar(12) NOT NULL, |
| | | code varchar(63) NOT NULL, |
| | | signature varchar(12 char) NOT NULL, |
| | | code varchar(63 char) NOT NULL, |
| | | status smallint NOT NULL, |
| | | remark varchar(255) DEFAULT NULL NULL, |
| | | api_key varchar(128) NOT NULL, |
| | | api_secret varchar(128) DEFAULT NULL NULL, |
| | | callback_url varchar(255) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(255 char) DEFAULT NULL NULL, |
| | | api_key varchar(128 char) NOT NULL, |
| | | api_secret varchar(128 char) DEFAULT NULL NULL, |
| | | callback_url varchar(255 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_sms_code ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | mobile varchar(11) NOT NULL, |
| | | code varchar(6) NOT NULL, |
| | | create_ip varchar(15) NOT NULL, |
| | | mobile varchar(11 char) NOT NULL, |
| | | code varchar(6 char) NOT NULL, |
| | | create_ip varchar(15 char) NOT NULL, |
| | | scene smallint NOT NULL, |
| | | today_index smallint NOT NULL, |
| | | used smallint NOT NULL, |
| | | used_time datetime DEFAULT NULL NULL, |
| | | used_ip varchar(255) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | used_ip varchar(255 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE system_sms_log ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | channel_id bigint NOT NULL, |
| | | channel_code varchar(63) NOT NULL, |
| | | channel_code varchar(63 char) NOT NULL, |
| | | template_id bigint NOT NULL, |
| | | template_code varchar(63) NOT NULL, |
| | | template_code varchar(63 char) NOT NULL, |
| | | template_type smallint NOT NULL, |
| | | template_content varchar(255) NOT NULL, |
| | | template_params varchar(255) NOT NULL, |
| | | api_template_id varchar(63) NOT NULL, |
| | | mobile varchar(11) NOT NULL, |
| | | template_content varchar(255 char) NOT NULL, |
| | | template_params varchar(255 char) NOT NULL, |
| | | api_template_id varchar(63 char) NOT NULL, |
| | | mobile varchar(11 char) NOT NULL, |
| | | user_id bigint DEFAULT NULL NULL, |
| | | user_type smallint DEFAULT NULL NULL, |
| | | send_status smallint DEFAULT 0 NOT NULL, |
| | | send_time datetime DEFAULT NULL NULL, |
| | | api_send_code varchar(63) DEFAULT NULL NULL, |
| | | api_send_msg varchar(255) DEFAULT NULL NULL, |
| | | api_request_id varchar(255) DEFAULT NULL NULL, |
| | | api_serial_no varchar(255) DEFAULT NULL NULL, |
| | | api_send_code varchar(63 char) DEFAULT NULL NULL, |
| | | api_send_msg varchar(255 char) DEFAULT NULL NULL, |
| | | api_request_id varchar(255 char) DEFAULT NULL NULL, |
| | | api_serial_no varchar(255 char) DEFAULT NULL NULL, |
| | | receive_status smallint DEFAULT 0 NOT NULL, |
| | | receive_time datetime DEFAULT NULL NULL, |
| | | api_receive_code varchar(63) DEFAULT NULL NULL, |
| | | api_receive_msg varchar(255) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | api_receive_code varchar(63 char) DEFAULT NULL NULL, |
| | | api_receive_msg varchar(255 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | type smallint NOT NULL, |
| | | status smallint NOT NULL, |
| | | code varchar(63) NOT NULL, |
| | | name varchar(63) NOT NULL, |
| | | content varchar(255) NOT NULL, |
| | | params varchar(255) NOT NULL, |
| | | remark varchar(255) DEFAULT NULL NULL, |
| | | api_template_id varchar(63) NOT NULL, |
| | | code varchar(63 char) NOT NULL, |
| | | name varchar(63 char) NOT NULL, |
| | | content varchar(255 char) NOT NULL, |
| | | params varchar(255 char) NOT NULL, |
| | | remark varchar(255 char) DEFAULT NULL NULL, |
| | | api_template_id varchar(63 char) NOT NULL, |
| | | channel_id bigint NOT NULL, |
| | | channel_code varchar(63) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | channel_code varchar(63 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_social_client ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(255) NOT NULL, |
| | | name varchar(255 char) NOT NULL, |
| | | social_type smallint NOT NULL, |
| | | user_type smallint NOT NULL, |
| | | client_id varchar(255) NOT NULL, |
| | | client_secret varchar(255) NOT NULL, |
| | | agent_id varchar(255) DEFAULT NULL NULL, |
| | | public_key varchar(2048) DEFAULT NULL NULL, |
| | | client_id varchar(255 char) NOT NULL, |
| | | client_secret varchar(255 char) NOT NULL, |
| | | agent_id varchar(255 char) DEFAULT NULL NULL, |
| | | public_key varchar(2048 char) DEFAULT NULL NULL, |
| | | status smallint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE system_social_user ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | type smallint NOT NULL, |
| | | openid varchar(32) NOT NULL, |
| | | token varchar(256) DEFAULT NULL NULL, |
| | | raw_token_info varchar(1024) NOT NULL, |
| | | nickname varchar(32) NOT NULL, |
| | | avatar varchar(255) DEFAULT NULL NULL, |
| | | raw_user_info varchar(1024) NOT NULL, |
| | | code varchar(256) NOT NULL, |
| | | state varchar(256) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | openid varchar(32 char) NOT NULL, |
| | | token varchar(256 char) DEFAULT NULL NULL, |
| | | raw_token_info varchar(1024 char) NOT NULL, |
| | | nickname varchar(32 char) NOT NULL, |
| | | avatar varchar(255 char) DEFAULT NULL NULL, |
| | | raw_user_info varchar(1024 char) NOT NULL, |
| | | code varchar(256 char) NOT NULL, |
| | | state varchar(256 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | user_type smallint NOT NULL, |
| | | social_type smallint NOT NULL, |
| | | social_user_id bigint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_tenant ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(30) NOT NULL, |
| | | name varchar(30 char) NOT NULL, |
| | | contact_user_id bigint DEFAULT NULL NULL, |
| | | contact_name varchar(30) NOT NULL, |
| | | contact_mobile varchar(500) DEFAULT NULL NULL, |
| | | contact_name varchar(30 char) NOT NULL, |
| | | contact_mobile varchar(500 char) DEFAULT NULL NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | websites varchar(1024) DEFAULT '' NULL, |
| | | websites varchar(1024 char) DEFAULT '' NULL, |
| | | package_id bigint NOT NULL, |
| | | expire_time datetime NOT NULL, |
| | | account_count int NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_tenant_package ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(30) NOT NULL, |
| | | name varchar(30 char) NOT NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | remark varchar(256) DEFAULT '' NULL, |
| | | menu_ids varchar(4096) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | remark varchar(256 char) DEFAULT '' NULL, |
| | | menu_ids varchar(4096 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL |
| | | ); |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint DEFAULT 0 NOT NULL, |
| | | post_id bigint DEFAULT 0 NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | user_id bigint NOT NULL, |
| | | role_id bigint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NULL, |
| | | deleted bit DEFAULT '0' NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE system_users ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | username varchar(30) NOT NULL, |
| | | password varchar(100) DEFAULT '' NULL, |
| | | nickname varchar(30) NOT NULL, |
| | | remark varchar(500) DEFAULT NULL NULL, |
| | | username varchar(30 char) NOT NULL, |
| | | password varchar(100 char) DEFAULT '' NULL, |
| | | nickname varchar(30 char) NOT NULL, |
| | | remark varchar(500 char) DEFAULT NULL NULL, |
| | | dept_id bigint DEFAULT NULL NULL, |
| | | post_ids varchar(255) DEFAULT NULL NULL, |
| | | email varchar(50) DEFAULT '' NULL, |
| | | mobile varchar(11) DEFAULT '' NULL, |
| | | post_ids varchar(255 char) DEFAULT NULL NULL, |
| | | email varchar(50 char) DEFAULT '' NULL, |
| | | mobile varchar(11 char) DEFAULT '' NULL, |
| | | sex smallint DEFAULT 0 NULL, |
| | | avatar varchar(512) DEFAULT '' NULL, |
| | | avatar varchar(512 char) DEFAULT '' NULL, |
| | | status smallint DEFAULT 0 NOT NULL, |
| | | login_ip varchar(50) DEFAULT '' NULL, |
| | | login_ip varchar(50 char) DEFAULT '' NULL, |
| | | login_date datetime DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE yudao_demo01_contact ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | sex smallint NOT NULL, |
| | | birthday datetime NOT NULL, |
| | | description varchar(255) NOT NULL, |
| | | avatar varchar(512) DEFAULT NULL NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | description varchar(255 char) NOT NULL, |
| | | avatar varchar(512 char) DEFAULT NULL NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE yudao_demo02_category ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | parent_id bigint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE yudao_demo03_course ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | student_id bigint NOT NULL, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | score smallint NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | CREATE TABLE yudao_demo03_grade ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | student_id bigint NOT NULL, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | teacher varchar(255) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | teacher varchar(255 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | -- ---------------------------- |
| | | CREATE TABLE yudao_demo03_student ( |
| | | id bigint NOT NULL PRIMARY KEY IDENTITY, |
| | | name varchar(100) DEFAULT '' NULL, |
| | | name varchar(100 char) DEFAULT '' NULL, |
| | | sex smallint NOT NULL, |
| | | birthday datetime NOT NULL, |
| | | description varchar(255) NOT NULL, |
| | | creator varchar(64) DEFAULT '' NULL, |
| | | description varchar(255 char) NOT NULL, |
| | | creator varchar(64 char) DEFAULT '' NULL, |
| | | create_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | updater varchar(64) DEFAULT '' NULL, |
| | | updater varchar(64 char) DEFAULT '' NULL, |
| | | update_time datetime DEFAULT CURRENT_TIMESTAMP NOT NULL, |
| | | deleted bit DEFAULT '0' NOT NULL, |
| | | tenant_id bigint DEFAULT 0 NOT NULL |
| | |
| | | COMMIT; |
| | | SET IDENTITY_INSERT yudao_demo03_student OFF; |
| | | -- @formatter:on |
| | | |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | -- https://github.com/quartz-scheduler/quartz/blob/main/quartz/src/main/resources/org/quartz/impl/jdbcjobstore/tables_postgres.sql |
| | | -- Thanks to Patrick Lightbody for submitting this... |
| | | -- |
| | | -- In your Quartz properties file, you'll need to set |
| | | -- org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.PostgreSQLDelegate |
| | | |
| | | DROP TABLE IF EXISTS QRTZ_FIRED_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_PAUSED_TRIGGER_GRPS; |
| | | DROP TABLE IF EXISTS QRTZ_SCHEDULER_STATE; |
| | | DROP TABLE IF EXISTS QRTZ_LOCKS; |
| | | DROP TABLE IF EXISTS QRTZ_SIMPLE_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_CRON_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_SIMPROP_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_BLOB_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_TRIGGERS; |
| | | DROP TABLE IF EXISTS QRTZ_JOB_DETAILS; |
| | | DROP TABLE IF EXISTS QRTZ_CALENDARS; |
| | | |
| | | CREATE TABLE QRTZ_JOB_DETAILS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | JOB_NAME VARCHAR(200) NOT NULL, |
| | | JOB_GROUP VARCHAR(200) NOT NULL, |
| | | DESCRIPTION VARCHAR(250) NULL, |
| | | JOB_CLASS_NAME VARCHAR(250) NOT NULL, |
| | | IS_DURABLE BOOL NOT NULL, |
| | | IS_NONCONCURRENT BOOL NOT NULL, |
| | | IS_UPDATE_DATA BOOL NOT NULL, |
| | | REQUESTS_RECOVERY BOOL NOT NULL, |
| | | JOB_DATA BYTEA NULL, |
| | | PRIMARY KEY (SCHED_NAME, JOB_NAME, JOB_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | JOB_NAME VARCHAR(200) NOT NULL, |
| | | JOB_GROUP VARCHAR(200) NOT NULL, |
| | | DESCRIPTION VARCHAR(250) NULL, |
| | | NEXT_FIRE_TIME BIGINT NULL, |
| | | PREV_FIRE_TIME BIGINT NULL, |
| | | PRIORITY INTEGER NULL, |
| | | TRIGGER_STATE VARCHAR(16) NOT NULL, |
| | | TRIGGER_TYPE VARCHAR(8) NOT NULL, |
| | | START_TIME BIGINT NOT NULL, |
| | | END_TIME BIGINT NULL, |
| | | CALENDAR_NAME VARCHAR(200) NULL, |
| | | MISFIRE_INSTR SMALLINT NULL, |
| | | JOB_DATA BYTEA NULL, |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP), |
| | | FOREIGN KEY (SCHED_NAME, JOB_NAME, JOB_GROUP) |
| | | REFERENCES QRTZ_JOB_DETAILS (SCHED_NAME, JOB_NAME, JOB_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_SIMPLE_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | REPEAT_COUNT BIGINT NOT NULL, |
| | | REPEAT_INTERVAL BIGINT NOT NULL, |
| | | TIMES_TRIGGERED BIGINT NOT NULL, |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP), |
| | | FOREIGN KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | REFERENCES QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_CRON_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | CRON_EXPRESSION VARCHAR(120) NOT NULL, |
| | | TIME_ZONE_ID VARCHAR(80), |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP), |
| | | FOREIGN KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | REFERENCES QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_SIMPROP_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | STR_PROP_1 VARCHAR(512) NULL, |
| | | STR_PROP_2 VARCHAR(512) NULL, |
| | | STR_PROP_3 VARCHAR(512) NULL, |
| | | INT_PROP_1 INT NULL, |
| | | INT_PROP_2 INT NULL, |
| | | LONG_PROP_1 BIGINT NULL, |
| | | LONG_PROP_2 BIGINT NULL, |
| | | DEC_PROP_1 NUMERIC(13, 4) NULL, |
| | | DEC_PROP_2 NUMERIC(13, 4) NULL, |
| | | BOOL_PROP_1 BOOL NULL, |
| | | BOOL_PROP_2 BOOL NULL, |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP), |
| | | FOREIGN KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | REFERENCES QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_BLOB_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | BLOB_DATA BYTEA NULL, |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP), |
| | | FOREIGN KEY (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | REFERENCES QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_CALENDARS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | CALENDAR_NAME VARCHAR(200) NOT NULL, |
| | | CALENDAR BYTEA NOT NULL, |
| | | PRIMARY KEY (SCHED_NAME, CALENDAR_NAME) |
| | | ); |
| | | |
| | | |
| | | CREATE TABLE QRTZ_PAUSED_TRIGGER_GRPS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | PRIMARY KEY (SCHED_NAME, TRIGGER_GROUP) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_FIRED_TRIGGERS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | ENTRY_ID VARCHAR(95) NOT NULL, |
| | | TRIGGER_NAME VARCHAR(200) NOT NULL, |
| | | TRIGGER_GROUP VARCHAR(200) NOT NULL, |
| | | INSTANCE_NAME VARCHAR(200) NOT NULL, |
| | | FIRED_TIME BIGINT NOT NULL, |
| | | SCHED_TIME BIGINT NOT NULL, |
| | | PRIORITY INTEGER NOT NULL, |
| | | STATE VARCHAR(16) NOT NULL, |
| | | JOB_NAME VARCHAR(200) NULL, |
| | | JOB_GROUP VARCHAR(200) NULL, |
| | | IS_NONCONCURRENT BOOL NULL, |
| | | REQUESTS_RECOVERY BOOL NULL, |
| | | PRIMARY KEY (SCHED_NAME, ENTRY_ID) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_SCHEDULER_STATE |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | INSTANCE_NAME VARCHAR(200) NOT NULL, |
| | | LAST_CHECKIN_TIME BIGINT NOT NULL, |
| | | CHECKIN_INTERVAL BIGINT NOT NULL, |
| | | PRIMARY KEY (SCHED_NAME, INSTANCE_NAME) |
| | | ); |
| | | |
| | | CREATE TABLE QRTZ_LOCKS |
| | | ( |
| | | SCHED_NAME VARCHAR(120) NOT NULL, |
| | | LOCK_NAME VARCHAR(40) NOT NULL, |
| | | PRIMARY KEY (SCHED_NAME, LOCK_NAME) |
| | | ); |
| | | |
| | | CREATE INDEX IDX_QRTZ_J_REQ_RECOVERY |
| | | ON QRTZ_JOB_DETAILS (SCHED_NAME, REQUESTS_RECOVERY); |
| | | CREATE INDEX IDX_QRTZ_J_GRP |
| | | ON QRTZ_JOB_DETAILS (SCHED_NAME, JOB_GROUP); |
| | | |
| | | CREATE INDEX IDX_QRTZ_T_J |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, JOB_NAME, JOB_GROUP); |
| | | CREATE INDEX IDX_QRTZ_T_JG |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, JOB_GROUP); |
| | | CREATE INDEX IDX_QRTZ_T_C |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, CALENDAR_NAME); |
| | | CREATE INDEX IDX_QRTZ_T_G |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_GROUP); |
| | | CREATE INDEX IDX_QRTZ_T_STATE |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_STATE); |
| | | CREATE INDEX IDX_QRTZ_T_N_STATE |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP, TRIGGER_STATE); |
| | | CREATE INDEX IDX_QRTZ_T_N_G_STATE |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_GROUP, TRIGGER_STATE); |
| | | CREATE INDEX IDX_QRTZ_T_NEXT_FIRE_TIME |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, NEXT_FIRE_TIME); |
| | | CREATE INDEX IDX_QRTZ_T_NFT_ST |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, TRIGGER_STATE, NEXT_FIRE_TIME); |
| | | CREATE INDEX IDX_QRTZ_T_NFT_MISFIRE |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, MISFIRE_INSTR, NEXT_FIRE_TIME); |
| | | CREATE INDEX IDX_QRTZ_T_NFT_ST_MISFIRE |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, MISFIRE_INSTR, NEXT_FIRE_TIME, TRIGGER_STATE); |
| | | CREATE INDEX IDX_QRTZ_T_NFT_ST_MISFIRE_GRP |
| | | ON QRTZ_TRIGGERS (SCHED_NAME, MISFIRE_INSTR, NEXT_FIRE_TIME, TRIGGER_GROUP, TRIGGER_STATE); |
| | | |
| | | CREATE INDEX IDX_QRTZ_FT_TRIG_INST_NAME |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, INSTANCE_NAME); |
| | | CREATE INDEX IDX_QRTZ_FT_INST_JOB_REQ_RCVRY |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, INSTANCE_NAME, REQUESTS_RECOVERY); |
| | | CREATE INDEX IDX_QRTZ_FT_J_G |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, JOB_NAME, JOB_GROUP); |
| | | CREATE INDEX IDX_QRTZ_FT_JG |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, JOB_GROUP); |
| | | CREATE INDEX IDX_QRTZ_FT_T_G |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, TRIGGER_NAME, TRIGGER_GROUP); |
| | | CREATE INDEX IDX_QRTZ_FT_TG |
| | | ON QRTZ_FIRED_TRIGGERS (SCHED_NAME, TRIGGER_GROUP); |
| | | |
| | | |
| | | COMMIT; |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', '2025-09-06 00:02:21', '1', '2025-09-06 00:02:31', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', '2023-11-04 13:05:38', '1', '2023-11-04 13:07:16', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', '2025-12-16 19:25:51', '1', '2025-12-17 09:46:15', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', '2026-02-04 00:32:47', '1', '2026-02-04 00:32:47', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | COMMIT; |
| | | -- @formatter:on |
| | | |
| | |
| | | DROP SEQUENCE IF EXISTS yudao_demo03_student_seq; |
| | | CREATE SEQUENCE yudao_demo03_student_seq |
| | | START 10; |
| | | |
| | |
| | | Target Server Version : 80200 (8.2.0) |
| | | File Encoding : 65001 |
| | | |
| | | Date: 16/05/2026 06:24:32 |
| | | Date: 29/06/2026 17:18:58 |
| | | */ |
| | | |
| | | SET NAMES utf8mb4; |
| | |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_create_time`(`create_time` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 36301 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'API è®¿é®æ¥å¿è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 36346 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'API è®¿é®æ¥å¿è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of infra_api_access_log |
| | |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_create_time`(`create_time` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 23883 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç³»ç»å¼å¸¸æ¥å¿'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 24453 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç³»ç»å¼å¸¸æ¥å¿'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of infra_api_error_log |
| | |
| | | `update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'æ´æ°æ¶é´', |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 2216 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä»¶è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 2260 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä»¶è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of infra_file |
| | |
| | | -- Records of infra_file_config |
| | | -- ---------------------------- |
| | | BEGIN; |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (4, 'æ°æ®åºï¼ç¤ºä¾ï¼', 1, 'ææ¯æ°æ®åº', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.db.DBFileClientConfig\",\"domain\":\"http://127.0.0.1:48080\"}', '1', '2022-03-15 23:56:24', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (22, 'ä¸çåå¨å¨ï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ èªå·±çå¯é¥ï¼ï¼ï¼', b'1', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"s3.cn-south-1.qiniucs.com\",\"domain\":\"http://test.yudao.iocoder.cn\",\"bucket\":\"ruoyi-vue-pro\",\"accessKey\":\"3TvrJ70gl2Gt6IBe7_IZT1F6i_k0iMuRtyEv4EyS\",\"accessSecret\":\"wd0tbVBYlp0S-ihA8Qg2hPLncoP83wyrIq24OZuY\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-01-13 22:11:12', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (24, 'è
¾è®¯äºåå¨ï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ çå¯é¥ï¼ï¼ï¼', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"https://cos.ap-shanghai.myqcloud.com\",\"domain\":\"http://tengxun-oss.iocoder.cn\",\"bucket\":\"aoteman-1255880240\",\"accessKey\":\"AKIDAF6WSh1uiIjwqtrOsGSN3WryqTM6cTMt\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:03:22', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (25, 'é¿éäºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"oss-cn-beijing.aliyuncs.com\",\"domain\":\"http://ali-oss.iocoder.cn\",\"bucket\":\"yunai-aoteman\",\"accessKey\":\"LTAI5tEQLgnDyjh3WpNcdMKA\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:47:08', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (26, 'ç«å±±äºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"tos-s3-cn-beijing.volces.com\",\"domain\":null,\"bucket\":\"yunai\",\"accessKey\":\"AKLTZjc3Zjc4MzZmMjU3NDk0ZTgxYmIyMmFkNTIwMDI1ZGE\",\"accessSecret\":\"X==\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:56:42', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (27, 'å为äºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"obs.cn-east-3.myhuaweicloud.com\",\"domain\":\"\",\"bucket\":\"yudao\",\"accessKey\":\"PVDONDEIOTW88LF8DC4U\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 17:18:41', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (28, 'MinIO åå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"http://127.0.0.1:9000\",\"domain\":\"http://127.0.0.1:9000/yudao\",\"bucket\":\"yudao\",\"accessKey\":\"admin\",\"accessSecret\":\"password\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 17:43:10', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (29, 'æ¬å°åå¨ï¼ç¤ºä¾ï¼', 10, 'mac/linux ä½¿ç¨ /ï¼windows ä½¿ç¨ \\', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.local.LocalFileClientConfig\",\"basePath\":\"/Users/yunai/tmp/file\",\"domain\":\"http://127.0.0.1:48080\"}', '1', '2025-05-02 11:25:45', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (30, 'SFTP åå¨ï¼ç¤ºä¾ï¼', 12, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.sftp.SftpFileClientConfig\",\"basePath\":\"/upload\",\"domain\":\"http://127.0.0.1:48080\",\"host\":\"127.0.0.1\",\"port\":2222,\"username\":\"foo\",\"password\":\"pass\"}', '1', '2025-05-02 16:34:10', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (34, 'ä¸çäºåå¨ãç§æãï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ èªå·±çå¯é¥ï¼ï¼ï¼', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"s3.cn-south-1.qiniucs.com\",\"domain\":\"http://t151glocd.hn-bkt.clouddn.com\",\"bucket\":\"ruoyi-vue-pro-private\",\"accessKey\":\"3TvrJ70gl2Gt6IBe7_IZT1F6i_k0iMuRtyEv4EyS\",\"accessSecret\":\"wd0tbVBYlp0S-ihA8Qg2hPLncoP83wyrIq24OZuY\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":false}', '1', '2025-08-17 21:22:00', '1', '2025-11-24 20:57:14', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (35, '1', 20, '1', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"http://www.baidu.com\",\"domain\":\"http://www.xxx.com\",\"bucket\":\"1\",\"accessKey\":\"2\",\"accessSecret\":\"3\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":false,\"region\":\"1\"}', '1', '2025-10-02 14:32:12', '1', '2025-11-29 15:59:39', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (4, 'æ°æ®åºï¼ç¤ºä¾ï¼', 1, 'ææ¯æ°æ®åº', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.db.DBFileClientConfig\",\"domain\":\"http://127.0.0.1:48080\"}', '1', '2022-03-15 23:56:24', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (22, 'ä¸çåå¨å¨ï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ èªå·±çå¯é¥ï¼ï¼ï¼', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"s3.cn-south-1.qiniucs.com\",\"domain\":\"http://test.yudao.iocoder.cn\",\"bucket\":\"ruoyi-vue-pro\",\"accessKey\":\"3TvrJ70gl2Gt6IBe7_IZT1F6i_k0iMuRtyEv4EyS\",\"accessSecret\":\"wd0tbVBYlp0S-ihA8Qg2hPLncoP83wyrIq24OZuY\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-01-13 22:11:12', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (24, 'è
¾è®¯äºåå¨ï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ çå¯é¥ï¼ï¼ï¼', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"https://cos.ap-shanghai.myqcloud.com\",\"domain\":\"http://tengxun-oss.iocoder.cn\",\"bucket\":\"aoteman-1255880240\",\"accessKey\":\"AKIDAF6WSh1uiIjwqtrOsGSN3WryqTM6cTMt\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:03:22', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (25, 'é¿éäºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"oss-cn-beijing.aliyuncs.com\",\"domain\":\"http://ali-oss.iocoder.cn\",\"bucket\":\"yunai-aoteman\",\"accessKey\":\"LTAI5tEQLgnDyjh3WpNcdMKA\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:47:08', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (26, 'ç«å±±äºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"tos-s3-cn-beijing.volces.com\",\"domain\":null,\"bucket\":\"yunai\",\"accessKey\":\"AKLTZjc3Zjc4MzZmMjU3NDk0ZTgxYmIyMmFkNTIwMDI1ZGE\",\"accessSecret\":\"X==\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 16:56:42', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (27, 'å为äºåå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"obs.cn-east-3.myhuaweicloud.com\",\"domain\":\"\",\"bucket\":\"yudao\",\"accessKey\":\"PVDONDEIOTW88LF8DC4U\",\"accessSecret\":\"X\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 17:18:41', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (28, 'MinIO åå¨ï¼ç¤ºä¾ï¼', 20, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"http://127.0.0.1:9000\",\"domain\":\"http://127.0.0.1:9000/yudao\",\"bucket\":\"yudao\",\"accessKey\":\"admin\",\"accessSecret\":\"password\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":true}', '1', '2024-11-09 17:43:10', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (29, 'æ¬å°åå¨ï¼ç¤ºä¾ï¼', 10, 'mac/linux ä½¿ç¨ /ï¼windows ä½¿ç¨ \\', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.local.LocalFileClientConfig\",\"basePath\":\"/Users/yunai/tmp/file\",\"domain\":\"http://127.0.0.1:48080\"}', '1', '2025-05-02 11:25:45', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (30, 'SFTP åå¨ï¼ç¤ºä¾ï¼', 12, '', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.sftp.SftpFileClientConfig\",\"basePath\":\"/upload\",\"domain\":\"http://127.0.0.1:48080\",\"host\":\"127.0.0.1\",\"port\":2222,\"username\":\"foo\",\"password\":\"pass\"}', '1', '2025-05-02 16:34:10', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (34, 'ä¸çäºåå¨ãç§æãï¼ç¤ºä¾ï¼', 20, 'è¯·æ¢æä½ èªå·±çå¯é¥ï¼ï¼ï¼', b'0', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"s3.cn-south-1.qiniucs.com\",\"domain\":\"http://t151glocd.hn-bkt.clouddn.com\",\"bucket\":\"ruoyi-vue-pro-private\",\"accessKey\":\"3TvrJ70gl2Gt6IBe7_IZT1F6i_k0iMuRtyEv4EyS\",\"accessSecret\":\"wd0tbVBYlp0S-ihA8Qg2hPLncoP83wyrIq24OZuY\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":false}', '1', '2025-08-17 21:22:00', '1', '2026-06-26 12:23:25', b'0'); |
| | | INSERT INTO `infra_file_config` (`id`, `name`, `storage`, `remark`, `master`, `config`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (35, '1', 20, '1', b'1', '{\"@class\":\"cn.iocoder.yudao.module.infra.framework.file.core.client.s3.S3FileClientConfig\",\"endpoint\":\"http://www.baidu.com\",\"domain\":\"http://www.xxx.com\",\"bucket\":\"1\",\"accessKey\":\"2\",\"accessSecret\":\"3\",\"enablePathStyleAccess\":false,\"enablePublicAccess\":false,\"region\":\"1\"}', '1', '2025-10-02 14:32:12', '1', '2026-06-26 12:23:25', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_config_id_path`(`config_id` ASC, `path` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 286 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä»¶è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 288 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä»¶è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of infra_file_content |
| | |
| | | `update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'æ´æ°æ¶é´', |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1061096 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'åå
¸æ°æ®è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1061137 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'åå
¸æ°æ®è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_dict_data |
| | |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', '2025-09-06 00:02:21', '1', '2025-09-06 00:02:31', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', '2023-11-04 13:05:38', '1', '2023-11-04 13:07:16', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', '2025-12-16 19:25:51', '1', '2025-12-17 09:46:15', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', '2026-05-23 13:52:25', '1', '2026-05-23 13:52:25', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', '2026-05-23 13:52:25', '1', '2026-05-23 13:52:25', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', '2026-02-04 00:32:47', '1', '2026-02-04 00:32:47', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', b'0'); |
| | |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3520, 1, 'æªè¯»', '0', 'im_private_message_status', 0, 'warning', '', 'ç§è=æªè¯»ï¼ç¾¤è=æ£å¸¸', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 15:14:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3521, 2, 'å·²æ¤å', '2', 'im_private_message_status', 0, 'danger', '', 'RECALL', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 15:14:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3522, 3, '已读', '3', 'im_private_message_status', 0, 'success', '', 'READï¼ä»
ç§èï¼', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 15:14:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3525, 1, 'æ£å¸¸', '0', 'im_group_message_status', 0, 'success', '', 'ç¾¤èæ£å¸¸ï¼åå§ç¶æï¼', 'admin', '2026-04-30 15:14:36', 'admin', '2026-04-30 15:14:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3526, 2, 'å·²æ¤å', '2', 'im_group_message_status', 0, 'danger', '', '群èå·²æ¤å', 'admin', '2026-04-30 15:14:36', 'admin', '2026-04-30 15:14:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3530, 1, 'ä¸éè¦åæ§', '0', 'im_group_message_receipt_status', 0, 'info', '', 'NO_RECEIPT', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3531, 2, 'å¾
宿', '1', 'im_group_message_receipt_status', 0, 'warning', '', 'PENDING', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3532, 3, '已宿', '2', 'im_group_message_receipt_status', 0, 'success', '', 'DONE', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, 'default', '', 'PREPARE', '1', '2026-04-16 09:47:00', '1', '2026-06-13 10:32:58', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, 'success', '', 'FINISHED', '1', '2026-04-16 09:47:00', '1', '2026-06-13 10:32:58', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, 'danger', '', 'CANCELED', '1', '2026-04-16 09:47:00', '1', '2026-06-13 10:32:58', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3525, 1, 'æ£å¸¸', '0', 'im_message_status', 0, 'success', '', 'æ£å¸¸ï¼åå§ç¶æï¼', 'admin', '2026-04-30 15:14:36', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3526, 2, 'å·²æ¤å', '2', 'im_message_status', 0, 'danger', '', 'å·²æ¤å', 'admin', '2026-04-30 15:14:36', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3530, 1, 'ä¸éè¦åæ§', '0', 'im_message_receipt_status', 0, 'info', '', 'NO_RECEIPT', 'admin', '2026-04-30 11:35:07', 'admin', '2026-06-14 00:32:47', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3531, 2, 'å¾
宿', '1', 'im_message_receipt_status', 0, 'warning', '', 'PENDING', 'admin', '2026-04-30 11:35:07', 'admin', '2026-06-14 00:32:47', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3532, 3, '已宿', '2', 'im_message_receipt_status', 0, 'success', '', 'DONE', 'admin', '2026-04-30 11:35:07', 'admin', '2026-06-14 00:32:47', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3540, 1, 'æ£å¸¸', '0', 'im_friend_status', 0, 'success', '', 'æ£å¸¸å¥½åå
³ç³»', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3541, 2, 'å·²å é¤', '1', 'im_friend_status', 0, 'danger', '', 'å·²å é¤å¥½åå
³ç³»', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3550, 1, 'æ£å¸¸', '0', 'im_group_status', 0, 'success', '', '群æ£å¸¸', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0'); |
| | |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3559, 1, 'çå¾
éªè¯', '0', 'im_friend_request_handle_result', 0, 'warning', '', NULL, '1', '2026-05-04 02:43:41', '1', '2026-05-04 02:43:41', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3560, 2, '已添å ', '1', 'im_friend_request_handle_result', 0, 'success', '', NULL, '1', '2026-05-04 02:43:41', '1', '2026-05-04 02:43:41', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3561, 3, 'å·²æç»', '2', 'im_friend_request_handle_result', 0, 'info', '', NULL, '1', '2026-05-04 02:43:41', '1', '2026-05-04 02:43:41', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3562, 101, 'ææ¬', '101', 'im_message_type', 0, '', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3563, 102, 'å¾ç', '102', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3564, 103, 'è¯é³', '103', 'im_message_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3565, 104, 'è§é¢', '104', 'im_message_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3566, 105, 'æä»¶', '105', 'im_message_type', 0, 'info', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3568, 2101, 'æ¤å', '2101', 'im_message_type', 0, 'danger', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3569, 2200, 'åæ§', '2200', 'im_message_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3570, 2201, '已读', '2201', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3571, 1501, '群å建', '1501', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3572, 1502, '群信æ¯åæ´', '1502', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3573, 1503, 'å
¥ç¾¤ç³è¯·', '1503', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3574, 1504, 'æåé群', '1504', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3575, 1505, 'å
¥ç¾¤ç³è¯·éè¿', '1505', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3576, 1506, 'å
¥ç¾¤ç³è¯·æç»', '1506', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3577, 1507, '群主转让', '1507', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3578, 1508, 'æå被移åº', '1508', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3579, 1509, 'æåå å
¥', '1509', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3580, 1510, 'èªç±è¿ç¾¤', '1510', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3581, 1511, '群解æ£', '1511', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3582, 1512, 'æåç¦è¨', '1512', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3583, 1513, 'æååæ¶ç¦è¨', '1513', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3584, 1514, 'å
¨ç¾¤ç¦è¨', '1514', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3585, 1515, 'å
¨ç¾¤åæ¶ç¦è¨', '1515', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3586, 1516, 'æåæµç§°åæ´', '1516', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3587, 1517, 'æ·»å 管çå', '1517', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3588, 1518, 'æ¤é管çå', '1518', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3589, 1519, '群å
¬ååæ´', '1519', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3590, 1520, '群ååæ´', '1520', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3591, 1531, 'ç¾¤æ¶æ¯ç½®é¡¶', '1531', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3592, 1532, 'ç¾¤æ¶æ¯åæ¶ç½®é¡¶', '1532', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3593, 1533, '群å°ç¦åæ´', '1533', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-05-05 11:52:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3594, 1204, 'æ°å¢å¥½å', '1204', 'im_message_type', 0, 'success', '', NULL, 'admin', '2026-05-05 13:26:53', 'admin', '2026-05-05 13:26:53', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3595, 1205, '好å被å é¤', '1205', 'im_message_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 13:26:53', 'admin', '2026-05-05 13:26:53', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3562, 101, 'ææ¬', '101', 'im_content_type', 0, '', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3563, 102, 'å¾ç', '102', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3564, 103, 'è¯é³', '103', 'im_content_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3565, 104, 'è§é¢', '104', 'im_content_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3566, 105, 'æä»¶', '105', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3568, 2101, 'æ¤å', '2101', 'im_content_type', 0, 'danger', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3569, 2200, 'åæ§', '2200', 'im_content_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3570, 2201, '已读', '2201', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3571, 1501, '群å建', '1501', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3572, 1502, '群信æ¯åæ´', '1502', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3573, 1503, 'æ¶å°æ°çå
¥ç¾¤ç³è¯·', '1503', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3574, 1504, 'æåé群', '1504', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3575, 1505, 'å
¥ç¾¤ç³è¯·è¢«åæ', '1505', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3576, 1506, 'å
¥ç¾¤ç³è¯·è¢«æç»', '1506', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3577, 1507, '群主转让', '1507', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3578, 1508, 'æå被移åº', '1508', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3579, 1509, 'æåå å
¥', '1509', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3580, 1510, 'èªç±è¿ç¾¤', '1510', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3581, 1511, '群解æ£', '1511', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3582, 1512, 'æåç¦è¨', '1512', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3583, 1513, 'æååæ¶ç¦è¨', '1513', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3584, 1514, 'å
¨ç¾¤ç¦è¨', '1514', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3585, 1515, 'å
¨ç¾¤åæ¶ç¦è¨', '1515', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3586, 1516, 'æåæµç§°åæ´', '1516', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3587, 1517, 'æ·»å 管çå', '1517', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3588, 1518, 'æ¤é管çå', '1518', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3589, 1519, '群å
¬ååæ´', '1519', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3590, 1520, '群ååæ´', '1520', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3591, 1531, 'ç¾¤æ¶æ¯ç½®é¡¶', '1531', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3592, 1532, 'ç¾¤æ¶æ¯åæ¶ç½®é¡¶', '1532', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3593, 1533, '群å°ç¦åæ´', '1533', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 11:52:30', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3594, 1204, 'æ°å¢å¥½å', '1204', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-05-05 13:26:53', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3595, 1205, '好å被å é¤', '1205', 'im_content_type', 0, 'warning', '', NULL, 'admin', '2026-05-05 13:26:53', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3596, 1, 'æç´¢', '1', 'im_group_add_source', 0, '', '', NULL, '', '2026-05-06 09:26:36', '', '2026-05-06 09:26:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3597, 2, 'é请', '2', 'im_group_add_source', 0, '', '', NULL, '', '2026-05-06 09:26:36', '', '2026-05-06 09:26:36', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (3598, 3, 'æ«ç ', '3', 'im_group_add_source', 0, '', '', NULL, '', '2026-05-06 09:26:36', '', '2026-05-06 09:26:36', b'0'); |
| | |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061091, 1, 'éè´§åºåº', '200', 'wms_shipment_order_type', 0, 'warning', '', 'éè´§åºåº', '1', '2026-05-12 17:48:35', '1', '2026-05-12 17:48:35', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061092, 2, 'éå®åºåº', '201', 'wms_shipment_order_type', 0, 'primary', '', 'éå®åºåº', '1', '2026-05-12 17:48:35', '1', '2026-05-12 17:48:35', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061093, 3, 'ç产åºåº', '202', 'wms_shipment_order_type', 0, 'success', '', 'ç产åºåº', '1', '2026-05-12 17:48:35', '1', '2026-05-12 17:48:35', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061094, 1, 'è¯Â音', '1', 'im_rtc_call_media_type', 0, '', '', 'è¯Â音éâ¬Å¡Ã¨Â¯Â', 'admin', '2026-05-14 13:48:31', 'admin', '2026-05-14 13:48:31', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061095, 2, 'è§â é¢â', '2', 'im_rtc_call_media_type', 0, '', '', 'è§â é¢âéâ¬Å¡Ã¨Â¯Â', 'admin', '2026-05-14 13:48:31', 'admin', '2026-05-14 13:48:31', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061096, 1, 'è¯é³', '1', 'im_rtc_call_media_type', 0, '', '', 'è¯é³éè¯', 'admin', '2026-05-16 11:34:50', 'admin', '2026-05-16 11:34:50', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061097, 2, 'è§é¢', '2', 'im_rtc_call_media_type', 0, '', '', 'è§é¢éè¯', 'admin', '2026-05-16 11:34:50', 'admin', '2026-05-16 11:34:50', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061098, 1, 'ç§è', '1', 'im_rtc_call_conversation_type', 0, 'primary', '', 'ä¸å¯¹ä¸ç§èéè¯', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061099, 2, '群è', '2', 'im_rtc_call_conversation_type', 0, 'success', '', '群å
å¤äººéè¯', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061100, 1, 'å建', '10', 'im_rtc_call_status', 0, 'info', '', 'éè¯å·²å建ï¼çå¾
æ¥é', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061101, 2, 'è¿è¡ä¸', '20', 'im_rtc_call_status', 0, 'primary', '', 'å·²æäººæ¥éï¼éè¯ä¸', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061102, 3, 'å·²ç»æ', '30', 'im_rtc_call_status', 0, 'success', '', 'éè¯ç»æ', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061103, 1, 'éè¯ç»æ', '1', 'im_rtc_call_end_reason', 0, 'success', '', 'æ¥éå任䏿¹ä¸»å¨ææ', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061104, 2, 'å·²æç»', '2', 'im_rtc_call_end_reason', 0, 'warning', '', 'è¢«å«æ¥éåç¹ææ¥', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061105, 3, '已忶', '3', 'im_rtc_call_end_reason', 0, 'info', '', '䏻嫿¥éå主å¨åæ¶', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061106, 4, 'æ 人æ¥å¬', '4', 'im_rtc_call_end_reason', 0, 'info', '', 'æ¯éè¶
æ¶æªæ¥é', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061107, 5, 'å¯¹æ¹æ£å¿', '5', 'im_rtc_call_end_reason', 0, 'warning', '', '对æ¹å¨å¦ä¸éè¯ä¸', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061108, 6, 'éè¯å¼å¸¸', '9', 'im_rtc_call_end_reason', 0, 'danger', '', 'ç½ç»ä¸æã设å¤å¤±è´¥ç', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061109, 1, 'å起人', '1', 'im_rtc_participant_role', 0, 'primary', '', 'éè¯åèµ·è
', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061110, 2, '被é请è
', '2', 'im_rtc_participant_role', 0, 'info', '', '被é请å å
¥', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061111, 3, '主å¨å å
¥è
', '3', 'im_rtc_participant_role', 0, 'success', '', '群éè¯åºæ¯ï¼æè§è
主å¨å å
¥', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061112, 1, 'é请ä¸', '10', 'im_rtc_participant_status', 0, 'info', '', 'å·²ååº inviteï¼çå¾
ååº', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061113, 2, 'å·²å å
¥', '20', 'im_rtc_participant_status', 0, 'primary', '', 'å·²æ¥éå¹¶è¿å
¥æ¿é´', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061114, 3, 'å·²æç»', '30', 'im_rtc_participant_status', 0, 'warning', '', 'æ¥éåç¹ææ¥', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061115, 4, 'æªåºç', '40', 'im_rtc_participant_status', 0, 'info', '', 'éè¯å·²ç»æä»æªåºç', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061116, 5, '已离å¼', '50', 'im_rtc_participant_status', 0, 'success', '', 'æ¥éåææ / 离å¼', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061117, 1610, 'éè¯å¼å§', '1610', 'im_content_type', 0, 'info', '', 'å
¥æ¶æ¯æµï¼ç§èå®åéç¥ï¼ç¾¤èå
¨å广æ', 'admin', '2026-05-18 03:36:12', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061118, 1611, 'éè¯ç»æ', '1611', 'im_content_type', 0, 'info', '', 'å
¥æ¶æ¯æµï¼ç§èåæ°æ³¡ï¼ç¾¤èç³»ç» tip', 'admin', '2026-05-18 03:36:12', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061119, 125, 'ç´ æ', '125', 'im_content_type', 0, 'success', '', 'é¢éè¿è¥æ¨éç徿å¡çæ¶æ¯', '1', '2026-05-18 13:14:34', 'admin', '2026-06-16 03:41:55', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061120, 1, '坿æ¬', '1', 'im_channel_material_type', 0, 'primary', '', '', '1', '2026-05-19 14:09:25', '1', '2026-05-19 14:09:25', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061121, 2, 'å¤é¾', '2', 'im_channel_material_type', 0, 'info', '', '', '1', '2026-05-19 14:09:25', '1', '2026-05-19 14:09:25', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061122, 7, 'SN ç ', '109', 'mes_wm_barcode_biz_type', 0, 'default', '', 'SN', '1', '2026-06-13 10:30:30', '1', '2026-06-13 10:30:30', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061123, 107, 'å并转å', '107', 'im_content_type', 0, '', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061124, 108, 'åç', '108', 'im_content_type', 0, '', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061125, 115, '表æ
', '115', 'im_content_type', 0, '', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061126, 1201, '好åç³è¯·è¢«åæ', '1201', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061127, 1202, '好åç³è¯·è¢«æç»', '1202', 'im_content_type', 0, 'warning', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061128, 1203, 'æ¶å°æ°ç好åç³è¯·', '1203', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061129, 1207, 'å å
¥é»åå', '1207', 'im_content_type', 0, 'danger', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061130, 1208, 'ç§»åºé»åå', '1208', 'im_content_type', 0, 'success', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061131, 1209, '好åèµæåæ´', '1209', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061132, 1210, '好åä¿¡æ¯æ¹éæ´æ°', '1210', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061133, 1530, '群æåä¸ªäººè®¾ç½®åæ´', '1530', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061134, 1601, 'éè¯ä¿¡ä»¤', '1601', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061135, 1602, 'éè¯åä¸è
å å
¥', '1602', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | INSERT INTO `system_dict_data` (`id`, `sort`, `label`, `value`, `dict_type`, `status`, `color_type`, `css_class`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1061136, 1603, 'éè¯åä¸è
离å¼', '1603', 'im_content_type', 0, 'info', '', NULL, 'admin', '2026-06-16 03:47:00', 'admin', '2026-06-16 03:47:00', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | `deleted_time` datetime NULL DEFAULT NULL COMMENT 'å 餿¶é´', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1061092 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'åå
¸ç±»å表'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1061099 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'åå
¸ç±»å表'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_dict_type |
| | |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2029, 'MES å·¥åç±»å', 'mes_pro_work_order_type', 0, 'MES ç产管ç - å·¥åç±»åï¼1=èªè¡ç产ï¼2=代工ï¼3=éè´ï¼', '1', '2026-02-17 11:43:47', '1', '2026-02-17 11:43:47', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2036, 'MES å·¥åºå
³ç³»ç±»å', 'mes_pro_link_type', 0, 'å·¥èºè·¯çº¿ä¸å·¥åºä¹é´çå
³ç³»ç±»å', '1', '2026-02-19 04:24:53', '1', '2026-04-05 15:05:07', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2037, 'MES æ¶é´åä½', 'mes_time_unit_type', 0, 'ç产æ¶é´ç计éåä½', '1', '2026-02-19 04:24:53', '1', '2026-04-05 15:04:57', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2038, 'MES ç产任å¡ç¶æ', 'mes_pro_task_status', 0, 'MES ç产管ç - ä»»å¡ç¶æï¼0=è稿ï¼1=è¿è¡ä¸ï¼2=æåï¼3=已宿ï¼4=已忶ï¼', '1', '2026-02-19 15:25:27', '1', '2026-02-19 15:25:27', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2038, 'MES ç产任å¡ç¶æ', 'mes_pro_task_status', 0, 'MES ç产管ç - ä»»å¡ç¶æï¼0=è稿ï¼4=已宿ï¼5=已忶ï¼', '1', '2026-02-19 15:25:27', '1', '2026-06-13 10:32:58', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2039, 'MES ç¹æ£ä¿å
»é¡¹ç®ç±»å', 'mes_dv_subject_type', 0, 'MES 设å¤ç®¡ç - ç¹æ£ä¿å
»é¡¹ç®ç±»åï¼1=设å¤ç¹æ£ï¼2=设å¤ä¿å
»ï¼', '1', '2026-02-20 01:42:58', '1', '2026-02-20 01:42:58', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2040, 'MES ä¿å
»è®°å½ç¶æ', 'mes_mainten_record_status', 0, NULL, 'admin', '2026-02-20 02:59:55', 'admin', '2026-02-20 02:59:55', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2041, 'MES ä¿å
ȍȾ', 'mes_mainten_status', 0, NULL, 'admin', '2026-02-20 02:59:55', 'admin', '2026-02-20 02:59:55', b'0', NULL); |
| | |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2133, 'MES éå®éè´§åç¶æ', 'mes_wm_return_sales_status', 0, 'MES éå®éè´§åç¶ææä¸¾', '1', '2026-04-03 17:20:25', '1', '2026-04-05 15:05:39', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2135, 'MES ä¸ä¸å·¥ç¶æç±»å', 'mes_pro_work_record_type', 0, 'MES ä¸ä¸å·¥ç¶æç±»å', '1', '2026-04-05 14:07:27', '1', '2026-04-05 14:07:27', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2138, 'MES ç产å
¥åºåç¶æ', 'mes_wm_product_produce_status', 0, 'MES ç产å
¥åºåç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', b'0', '1970-01-01 00:00:00'); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2200, 'IM æ¶æ¯ç±»å', 'im_message_type', 0, 'å¯¹åº ImMessageTypeEnum', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2201, 'IM ç§èæ¶æ¯ç¶æ', 'im_private_message_status', 0, 'å¯¹åº ImMessageStatusEnumï¼ç§è 0=æªè¯» / 2=å·²æ¤å / 3=已读', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 15:14:36', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2202, 'IM ç¾¤æ¶æ¯åæ§ç¶æ', 'im_group_message_receipt_status', 0, 'å¯¹åº ImGroupMessageReceiptStatusEnum', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2200, 'IM å
容类å', 'im_content_type', 0, 'å¯¹åº ImContentTypeEnum', 'admin', '2026-04-30 11:35:07', 'admin', '2026-06-16 03:41:55', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2202, 'IM æ¶æ¯åæ§ç¶æ', 'im_message_receipt_status', 0, 'å¯¹åº ImMessageReceiptStatusEnum', 'admin', '2026-04-30 11:35:07', 'admin', '2026-06-16 03:41:55', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2203, 'IM 好åç¶æ', 'im_friend_status', 0, '0=æ£å¸¸ / 1=å·²å é¤', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2204, 'IM ç¾¤ç¶æ', 'im_group_status', 0, '0=æ£å¸¸ / 1=已解æ£', 'admin', '2026-04-30 11:35:07', 'admin', '2026-04-30 11:35:07', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2205, 'IM ç¾¤èæ¶æ¯ç¶æ', 'im_group_message_status', 0, 'å¯¹åº ImMessageStatusEnumï¼ç¾¤è 0=æ£å¸¸ / 2=å·²æ¤åï¼æ æªè¯»æ¦å¿µï¼', 'admin', '2026-04-30 15:14:36', 'admin', '2026-04-30 15:14:36', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2205, 'IM æ¶æ¯ç¶æ', 'im_message_status', 0, 'å¯¹åº ImMessageStatusEnumï¼0=æ£å¸¸ / 2=å·²æ¤åï¼ç§è / 群èå
±ç¨ï¼', 'admin', '2026-04-30 15:14:36', 'admin', '2026-06-16 03:41:55', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2206, 'IM 群æåè§è²', 'im_group_member_role', 0, NULL, '1', '2026-05-02 02:14:12', '1', '2026-05-02 02:14:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2207, 'IM 好忷»å æ¥æº', 'im_friend_add_source', 0, NULL, '1', '2026-05-04 02:43:41', '1', '2026-05-04 02:43:41', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (2208, 'IM 好åç³è¯·å¤çç»æ', 'im_friend_request_handle_result', 0, NULL, '1', '2026-05-04 02:43:41', '1', '2026-05-04 02:43:41', b'0', NULL); |
| | |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061070, 'WMS åæ®ç¶æ', 'wms_order_status', 0, 'WMS åæ®ç¶æ', '1', '2026-05-12 13:40:29', '1', '2026-05-12 13:40:29', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061080, 'å
¥åºåç±»å', 'wms_receipt_order_type', 0, 'WMS å
¥åºåç±»å', '1', '2026-05-11 11:21:49', '1', '2026-05-12 13:40:29', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061090, 'åºåºåç±»å', 'wms_shipment_order_type', 0, 'WMS åºåºåç±»å', '1', '2026-05-12 17:48:35', '1', '2026-05-12 17:48:35', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061091, 'IM éâ¬Å¡Ã¨Â¯Âåªâä½âç±»åžâ¹', 'im_rtc_call_media_type', 0, NULL, 'admin', '2026-05-14 13:48:31', 'admin', '2026-05-14 13:48:31', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061092, 'IM éè¯åªä½ç±»å', 'im_rtc_call_media_type', 0, NULL, 'admin', '2026-05-16 11:34:50', 'admin', '2026-05-16 11:34:50', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061093, 'IM éè¯ä¼è¯ç±»å', 'im_rtc_call_conversation_type', 0, '1=ç§èï¼2=群è', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061094, 'IM éè¯ç¶æ', 'im_rtc_call_status', 0, '10=å建ï¼20=è¿è¡ä¸ï¼30=å·²ç»æ', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061095, 'IM éè¯ç»æåå ', 'im_rtc_call_end_reason', 0, '1=éè¯ç»æï¼2=å·²æç»ï¼3=已忶ï¼4=æ 人æ¥å¬ï¼5=å¯¹æ¹æ£å¿ï¼9=éè¯å¼å¸¸', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061096, 'IM éè¯åä¸è§è²', 'im_rtc_participant_role', 0, '1=å起人ï¼2=被é请è
ï¼3=主å¨å å
¥è
', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061097, 'IM éè¯åä¸ç¶æ', 'im_rtc_participant_status', 0, '10=é请ä¸ï¼20=å·²å å
¥ï¼30=å·²æç»ï¼40=æªåºçï¼50=已离å¼', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0', NULL); |
| | | INSERT INTO `system_dict_type` (`id`, `name`, `type`, `status`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `deleted_time`) VALUES (1061098, 'IM é¢éç´ æå
容类å', 'im_channel_material_type', 0, '1=ç«å
å¯ææ¬ / 2=å¤é¾', '1', '2026-05-19 14:09:25', '1', '2026-05-19 14:09:25', b'0', NULL); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_username`(`username` ASC) USING BTREE, |
| | | INDEX `idx_create_time`(`create_time` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 4557 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç³»ç»è®¿é®è®°å½'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 5367 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç³»ç»è®¿é®è®°å½'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_login_log |
| | |
| | | `update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'æ´æ°æ¶é´', |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 6611 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'èåæé表'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 6735 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'èåæé表'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_menu |
| | |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2156, 'æ¥è¯¢é¡¹ç®', 'report:go-view-project:query', 3, 0, 2153, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2023-02-07 19:25:53', '1', '2023-02-07 19:25:53', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2157, 'ä½¿ç¨ SQL æ¥è¯¢æ°æ®', 'report:go-view-data:get-by-sql', 3, 3, 2153, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2023-02-07 19:26:15', '1', '2023-02-07 19:26:15', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2158, 'ä½¿ç¨ HTTP æ¥è¯¢æ°æ®', 'report:go-view-data:get-by-http', 3, 4, 2153, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2023-02-07 19:26:35', '1', '2023-02-07 19:26:35', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2159, 'Boot å¼åææ¡£', '', 1, 1, 0, 'https://doc.iocoder.cn/', 'ep:document', NULL, NULL, 0, b'1', b'1', b'1', '1', '2023-02-10 22:46:28', '1', '2026-01-05 19:31:07', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2159, 'Boot å¼åææ¡£', '', 1, 1, 0, 'https://doc.iocoder.cn/', 'ep:document', NULL, NULL, 0, b'1', b'1', b'1', '1', '2023-02-10 22:46:28', '1', '2026-06-12 00:05:19', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2160, 'Cloud å¼åææ¡£', '', 1, 2, 0, 'https://cloud.iocoder.cn', 'ep:document-copy', NULL, NULL, 0, b'1', b'1', b'1', '1', '2023-02-10 22:47:07', '1', '2023-12-02 21:32:29', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2161, 'æ¥å
¥ç¤ºä¾', '', 1, 99, 1117, 'demo', 'fa-solid:dragon', 'pay/demo/index', NULL, 0, b'1', b'1', b'1', '', '2023-02-11 14:21:42', '1', '2024-01-18 23:50:00', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (2162, 'åå导åº', 'product:spu:export', 3, 5, 2014, '', '', '', NULL, 0, b'1', b'1', b'1', '', '2022-07-30 14:22:58', '', '2022-07-30 14:22:58', b'0'); |
| | |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5034, 'OTA åºä»¶å建', 'iot:ota-firmware:create', 3, 2, 5032, '', '', '', '', 0, b'1', b'1', b'1', '', '2025-06-30 07:50:29', '\"1\"', '2025-06-30 17:38:21', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5035, 'OTA åºä»¶æ´æ°', 'iot:ota-firmware:update', 3, 3, 5032, '', '', '', '', 0, b'1', b'1', b'1', '', '2025-06-30 07:50:29', '\"1\"', '2025-06-30 17:38:29', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5036, 'OTA åºä»¶å é¤', 'iot:ota-firmware:delete', 3, 4, 5032, '', '', '', '', 0, b'1', b'1', b'1', '', '2025-06-30 07:50:29', '\"1\"', '2025-06-30 17:38:37', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5037, 'OTA åçº§ä»»å¡æ¥è¯¢', 'iot:ota-task:create', 3, 11, 5032, '', '', '', '', 0, b'1', b'1', b'1', '1', '2025-07-02 23:56:56', '1', '2025-07-02 23:56:56', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5037, 'OTA åçº§ä»»å¡æ¥è¯¢', 'iot:ota-task:query', 3, 11, 5032, '', '', '', '', 0, b'1', b'1', b'1', '1', '2025-07-02 23:56:56', '1', '2026-05-19 08:48:53', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5038, 'OTA å级任å¡åæ¶', 'iot:ota-task:cancel', 3, 13, 5032, '', '', '', '', 0, b'1', b'1', b'1', '1', '2025-07-02 23:57:26', '1', '2025-07-02 23:57:26', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5039, 'OTA å级任å¡å建', 'iot:ota-task:create', 3, 12, 5032, '', '', '', '', 0, b'1', b'1', b'1', '1', '2025-07-02 23:57:52', '1', '2025-07-02 23:57:52', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (5040, 'OTA åçº§è®°å½æ¥è¯¢', 'iot:ota-task-record:query', 3, 21, 5032, '', '', '', '', 0, b'1', b'1', b'1', '1', '2025-07-02 23:58:30', '1', '2025-07-02 23:58:30', b'0'); |
| | |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6582, 'ç¨æ·è¡¨æ
å é¤', 'im:manager:face-user-item:delete', 3, 20, 6580, '', '', '', '', 0, b'1', b'1', b'1', '', '2026-05-06 13:56:08', '', '2026-05-06 13:56:08', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6600, 'ç§è管ç', '', 1, 20, 6500, 'private', 'ep:chat-round', NULL, NULL, 0, b'1', b'1', b'1', '1', '2026-05-07 00:40:35', '1', '2026-05-07 00:40:35', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6610, '群è管ç', '', 1, 30, 6500, 'group', 'ep:chat-line-round', NULL, NULL, 0, b'1', b'1', b'1', '1', '2026-05-07 00:40:35', '1', '2026-05-07 00:40:35', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6611, 'éè¯è®°å½', '', 2, 40, 6500, 'rtc', 'ep:phone', 'im/manager/rtc/index', 'ImRtcCall', 0, b'1', b'1', b'1', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6612, 'éè¯è®°å½æ¥è¯¢', 'im:manager:rtc:query', 3, 1, 6611, '', '', NULL, NULL, 0, b'1', b'1', b'1', 'admin', '2026-05-18 03:36:12', 'admin', '2026-05-18 03:36:12', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6700, 'é¢é管ç', '', 1, 90, 6500, 'channel', 'ep:promotion', NULL, NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6710, 'é¢éå表', '', 2, 1, 6700, 'list', 'ep:promotion', 'im/manager/channel/list/index', 'ImChannel', 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-19 09:44:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6711, 'é¢éæ¥è¯¢', 'im:manager:channel:query', 3, 1, 6710, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6712, 'é¢éå建', 'im:manager:channel:create', 3, 2, 6710, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6713, 'é¢éä¿®æ¹', 'im:manager:channel:update', 3, 3, 6710, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6714, 'é¢éå é¤', 'im:manager:channel:delete', 3, 4, 6710, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6720, 'é¢éç´ æ', '', 2, 2, 6700, 'material', 'ep:document', 'im/manager/channel/material/index', 'ImChannelMaterial', 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-19 09:44:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6721, 'ç´ ææ¥è¯¢', 'im:manager:channel-material:query', 3, 1, 6720, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6722, 'ç´ æå建', 'im:manager:channel-material:create', 3, 2, 6720, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6723, 'ç´ æä¿®æ¹', 'im:manager:channel-material:update', 3, 3, 6720, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6724, 'ç´ æå é¤', 'im:manager:channel-material:delete', 3, 4, 6720, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6730, 'é¢éæ¶æ¯', '', 2, 3, 6700, 'message', 'ep:message', 'im/manager/channel/message/index', 'ImChannelMessage', 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-19 09:44:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6731, 'æ¶æ¯æ¥è¯¢', 'im:manager:channel-message:query', 3, 1, 6730, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6732, 'ç«å³æ¨é', 'im:manager:channel-message:send', 3, 2, 6730, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6733, 'æ¶æ¯å é¤', 'im:manager:channel-message:delete', 3, 3, 6730, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-18 13:14:34', '1', '2026-05-18 13:14:34', b'0'); |
| | | INSERT INTO `system_menu` (`id`, `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (6734, 'è§£æ£ç¾¤', 'im:manager:group:dissolve', 3, 21, 6540, '', '', '', NULL, 0, b'1', b'1', b'1', '1', '2026-05-24 12:02:38', '1', '2026-05-24 12:02:38', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_access_token`(`access_token` ASC) USING BTREE, |
| | | INDEX `idx_refresh_token`(`refresh_token` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 54457 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'OAuth2 访é®ä»¤ç'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 108473 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'OAuth2 访é®ä»¤ç'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_oauth2_access_token |
| | |
| | | INSERT INTO `system_oauth2_client` (`id`, `client_id`, `secret`, `name`, `logo`, `description`, `status`, `access_token_validity_seconds`, `refresh_token_validity_seconds`, `redirect_uris`, `authorized_grant_types`, `scopes`, `auto_approve_scopes`, `authorities`, `resource_ids`, `additional_information`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1, 'default', 'admin123', 'èéæºç ', 'http://test.yudao.iocoder.cn/20250502/sort2_1746189740718.png', 'ææ¯æè¿°', 0, 1800, 2592000, '[\"https://www.iocoder.cn\",\"https://doc.iocoder.cn\"]', '[\"password\",\"authorization_code\",\"implicit\",\"refresh_token\",\"client_credentials\"]', '[\"user.read\",\"user.write\"]', '[]', '[\"user.read\",\"user.write\"]', '[]', '{}', '1', '2022-05-11 21:47:12', '1', '2025-12-07 20:07:09', b'0'); |
| | | INSERT INTO `system_oauth2_client` (`id`, `client_id`, `secret`, `name`, `logo`, `description`, `status`, `access_token_validity_seconds`, `refresh_token_validity_seconds`, `redirect_uris`, `authorized_grant_types`, `scopes`, `auto_approve_scopes`, `authorities`, `resource_ids`, `additional_information`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (40, 'test', 'test2', 'biubiu', 'http://test.yudao.iocoder.cn/20251227/javayuanma_1766829882970.jpg', 'å¦å¦å¦å¦', 0, 1800, 43200, '[\"https://www.iocoder.cn\"]', '[\"password\",\"authorization_code\",\"implicit\"]', '[\"user_info\",\"projects\"]', '[\"user_info\"]', '[]', '[]', '{}', '1', '2022-05-12 00:28:20', '1', '2025-12-27 18:04:44', b'0'); |
| | | INSERT INTO `system_oauth2_client` (`id`, `client_id`, `secret`, `name`, `logo`, `description`, `status`, `access_token_validity_seconds`, `refresh_token_validity_seconds`, `redirect_uris`, `authorized_grant_types`, `scopes`, `auto_approve_scopes`, `authorities`, `resource_ids`, `additional_information`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (41, 'yudao-sso-demo-by-code', 'test', 'åºäºææç 模å¼ï¼å¦ä½å®ç° SSO åç¹ç»å½ï¼', 'http://test.yudao.iocoder.cn/it/20250502/sign_1746181948685.png', NULL, 0, 1800, 43200, '[\"http://127.0.0.1:18080\"]', '[\"authorization_code\",\"refresh_token\"]', '[\"user.read\",\"user.write\"]', '[]', '[]', '[]', NULL, '1', '2022-09-29 13:28:31', '1', '2025-05-02 18:32:30', b'0'); |
| | | INSERT INTO `system_oauth2_client` (`id`, `client_id`, `secret`, `name`, `logo`, `description`, `status`, `access_token_validity_seconds`, `refresh_token_validity_seconds`, `redirect_uris`, `authorized_grant_types`, `scopes`, `auto_approve_scopes`, `authorities`, `resource_ids`, `additional_information`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (42, 'yudao-sso-demo-by-password', 'test', 'åºäºå¯ç 模å¼ï¼å¦ä½å®ç° SSO åç¹ç»å½ï¼', 'http://test.yudao.iocoder.cn/20251025/images (3)_1761360515810.jpeg', NULL, 0, 1800, 43200, '[\"http://127.0.0.1:18080\"]', '[\"password\",\"refresh_token\"]', '[\"user.read\",\"user.write\"]', '[]', '[]', '[]', NULL, '1', '2022-10-04 17:40:16', '1', '2025-10-25 10:49:40', b'0'); |
| | | INSERT INTO `system_oauth2_client` (`id`, `client_id`, `secret`, `name`, `logo`, `description`, `status`, `access_token_validity_seconds`, `refresh_token_validity_seconds`, `redirect_uris`, `authorized_grant_types`, `scopes`, `auto_approve_scopes`, `authorities`, `resource_ids`, `additional_information`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (42, 'yudao-sso-demo-by-password', 'test', 'åºäºå¯ç 模å¼ï¼å¦ä½å®ç° SSO åç¹ç»å½ï¼', 'http://test.yudao.iocoder.cn/oauth2/20260615/iShot_2026-05-31_23.18.10.png', NULL, 0, 1800, 43200, '[\"http://127.0.0.1:18080\"]', '[\"password\",\"refresh_token\"]', '[\"user.read\",\"user.write\"]', '[]', '[]', '[]', NULL, '1', '2022-10-04 17:40:16', '1', '2026-06-15 18:58:30', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_refresh_token`(`refresh_token` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 2590 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'OAuth2 å·æ°ä»¤ç'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 3382 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'OAuth2 å·æ°ä»¤ç'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_oauth2_refresh_token |
| | |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_user_id`(`user_id` ASC) USING BTREE, |
| | | INDEX `idx_create_time`(`create_time` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 9194 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä½æ¥å¿è®°å½ V2 çæ¬'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 9208 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'æä½æ¥å¿è®°å½ V2 çæ¬'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_operate_log |
| | |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 8 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'å²ä½ä¿¡æ¯è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 9 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'å²ä½ä¿¡æ¯è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_post |
| | |
| | | INSERT INTO `system_role` (`id`, `name`, `code`, `sort`, `data_scope`, `data_scope_dept_ids`, `status`, `type`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3, 'CRM 管çå', 'crm_admin', 2, 1, '', 0, 1, 'CRM ä¸å±è§è²', '1', '2024-02-24 10:51:13', '1', '2024-02-24 02:51:32', b'0', 1); |
| | | INSERT INTO `system_role` (`id`, `name`, `code`, `sort`, `data_scope`, `data_scope_dept_ids`, `status`, `type`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (109, 'ç§æ·ç®¡çå', 'tenant_admin', 0, 1, '', 0, 1, 'ç³»ç»èªå¨çæ', '1', '2022-02-22 00:56:14', '1', '2022-02-22 00:56:14', b'0', 121); |
| | | INSERT INTO `system_role` (`id`, `name`, `code`, `sort`, `data_scope`, `data_scope_dept_ids`, `status`, `type`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (111, 'ç§æ·ç®¡çå', 'tenant_admin', 0, 1, '', 0, 1, 'ç³»ç»èªå¨çæ', '1', '2022-03-07 21:37:58', '1', '2022-03-07 21:37:58', b'0', 122); |
| | | INSERT INTO `system_role` (`id`, `name`, `code`, `sort`, `data_scope`, `data_scope_dept_ids`, `status`, `type`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (155, 'æµè¯æ°æ®æé1', 'test-dp', 4, 2, '[112,100,102,103,104,105,107,108]', 0, 2, '1111', '1', '2025-03-31 14:58:06', '1', '2025-12-04 23:29:40', b'0', 1); |
| | | INSERT INTO `system_role` (`id`, `name`, `code`, `sort`, `data_scope`, `data_scope_dept_ids`, `status`, `type`, `remark`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (155, 'æµè¯æ°æ®æé12', 'test-dp', 4, 2, '[112,100,102,103,104,105,107,108]', 0, 2, '1111', '1', '2025-03-31 14:58:06', '1', '2026-06-26 10:42:44', b'0', 1); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_role_id`(`role_id` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 6381 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'è§è²åèåå
³è表'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 6692 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'è§è²åèåå
³è表'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_role_menu |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (706, 2, 112, '1', '2022-02-22 13:16:57', '1', '2022-02-22 13:16:57', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (707, 2, 113, '1', '2022-02-22 13:16:57', '1', '2022-02-22 13:16:57', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1296, 110, 1, '110', '2022-02-23 00:23:55', '110', '2022-02-23 00:23:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1578, 111, 1, '1', '2022-03-07 21:37:58', '1', '2022-03-07 21:37:58', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1729, 109, 100, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1730, 109, 101, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1731, 109, 1063, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1743, 109, 1010, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1744, 109, 1011, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1745, 109, 1012, '1', '2022-09-21 22:08:51', '1', '2022-09-21 22:08:51', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1746, 111, 100, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1747, 111, 101, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1748, 111, 1063, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1749, 111, 1064, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1750, 111, 1001, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1751, 111, 1065, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1752, 111, 1002, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1753, 111, 1003, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1754, 111, 1004, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1755, 111, 1005, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1756, 111, 1006, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1757, 111, 1007, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1758, 111, 1008, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1759, 111, 1009, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1760, 111, 1010, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1761, 111, 1011, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1762, 111, 1012, '1', '2022-09-21 22:08:52', '1', '2022-09-21 22:08:52', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1763, 109, 100, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1764, 109, 101, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1765, 109, 1063, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1777, 109, 1010, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1778, 109, 1011, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1779, 109, 1012, '1', '2022-09-21 22:08:53', '1', '2022-09-21 22:08:53', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1780, 111, 100, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1781, 111, 101, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1782, 111, 1063, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1783, 111, 1064, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1784, 111, 1001, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1785, 111, 1065, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1786, 111, 1002, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1787, 111, 1003, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1788, 111, 1004, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1789, 111, 1005, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1790, 111, 1006, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1791, 111, 1007, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1792, 111, 1008, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1793, 111, 1009, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1794, 111, 1010, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1795, 111, 1011, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1796, 111, 1012, '1', '2022-09-21 22:08:54', '1', '2022-09-21 22:08:54', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1797, 109, 100, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1798, 109, 101, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1799, 109, 1063, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1811, 109, 1010, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1812, 109, 1011, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1813, 109, 1012, '1', '2022-09-21 22:08:55', '1', '2022-09-21 22:08:55', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1814, 111, 100, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1815, 111, 101, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1816, 111, 1063, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1817, 111, 1064, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1818, 111, 1001, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1819, 111, 1065, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1820, 111, 1002, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1821, 111, 1003, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1822, 111, 1004, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1823, 111, 1005, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1824, 111, 1006, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1825, 111, 1007, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1826, 111, 1008, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1827, 111, 1009, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1828, 111, 1010, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1829, 111, 1011, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1830, 111, 1012, '1', '2022-09-21 22:08:56', '1', '2022-09-21 22:08:56', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1831, 109, 103, '1', '2022-09-21 22:43:23', '1', '2022-09-21 22:43:23', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1832, 109, 1017, '1', '2022-09-21 22:43:23', '1', '2022-09-21 22:43:23', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1833, 109, 1018, '1', '2022-09-21 22:43:23', '1', '2022-09-21 22:43:23', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1834, 109, 1019, '1', '2022-09-21 22:43:23', '1', '2022-09-21 22:43:23', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1835, 109, 1020, '1', '2022-09-21 22:43:23', '1', '2022-09-21 22:43:23', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1836, 111, 103, '1', '2022-09-21 22:43:24', '1', '2022-09-21 22:43:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1837, 111, 1017, '1', '2022-09-21 22:43:24', '1', '2022-09-21 22:43:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1838, 111, 1018, '1', '2022-09-21 22:43:24', '1', '2022-09-21 22:43:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1839, 111, 1019, '1', '2022-09-21 22:43:24', '1', '2022-09-21 22:43:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1840, 111, 1020, '1', '2022-09-21 22:43:24', '1', '2022-09-21 22:43:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1841, 109, 1036, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1842, 109, 1037, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1843, 109, 1038, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1844, 109, 1039, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1845, 109, 107, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1846, 111, 1036, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1847, 111, 1037, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1848, 111, 1038, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1849, 111, 1039, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1850, 111, 107, '1', '2022-09-21 22:48:13', '1', '2022-09-21 22:48:13', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1991, 2, 1024, '1', '2023-01-25 08:42:52', '1', '2023-01-25 08:42:52', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1992, 2, 1025, '1', '2023-01-25 08:42:52', '1', '2023-01-25 08:42:52', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1993, 2, 1026, '1', '2023-01-25 08:42:52', '1', '2023-01-25 08:42:52', b'0', 1); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2938, 109, 1141, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2939, 109, 1142, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2940, 109, 1143, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2941, 111, 1224, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2942, 111, 1225, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2943, 111, 1226, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2944, 111, 1227, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2945, 111, 1228, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2946, 111, 1229, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2947, 111, 1138, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2948, 111, 1139, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2949, 111, 1140, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2950, 111, 1141, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2951, 111, 1142, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2952, 111, 1143, '1', '2023-12-02 23:19:40', '1', '2023-12-02 23:19:40', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2993, 109, 2, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2994, 109, 1031, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2995, 109, 1032, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3066, 109, 1258, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3067, 109, 1259, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3068, 109, 1260, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3069, 111, 2, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3070, 111, 1031, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3071, 111, 1032, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3072, 111, 1033, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3073, 111, 1034, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3074, 111, 1035, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3075, 111, 1050, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3076, 111, 1051, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3077, 111, 1052, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3078, 111, 1053, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3079, 111, 1054, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3080, 111, 1056, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3081, 111, 1057, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3082, 111, 1058, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3083, 111, 1059, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3084, 111, 1060, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3085, 111, 1066, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3086, 111, 1067, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3087, 111, 1070, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3088, 111, 1075, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3090, 111, 1077, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3091, 111, 1078, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3092, 111, 1082, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3093, 111, 1083, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3094, 111, 1084, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3095, 111, 1085, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3096, 111, 1086, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3097, 111, 1087, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3098, 111, 1088, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3099, 111, 1089, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3100, 111, 1090, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3101, 111, 1091, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3102, 111, 1092, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3103, 111, 106, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3104, 111, 110, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3105, 111, 111, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3106, 111, 112, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3107, 111, 113, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3108, 111, 114, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3109, 111, 115, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3110, 111, 116, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3111, 111, 2472, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3112, 111, 2478, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3113, 111, 2479, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3114, 111, 2480, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3115, 111, 2481, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3116, 111, 2482, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3117, 111, 2483, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3118, 111, 2484, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3119, 111, 2485, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3120, 111, 2486, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3121, 111, 2487, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3122, 111, 2488, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3123, 111, 2489, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3124, 111, 2490, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3125, 111, 2491, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3126, 111, 2492, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3127, 111, 2493, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3128, 111, 2494, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3129, 111, 2495, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3130, 111, 2497, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3131, 111, 1237, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3132, 111, 1238, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3133, 111, 1239, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3134, 111, 1240, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3135, 111, 1241, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3136, 111, 1242, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3137, 111, 1243, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3138, 111, 2525, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3139, 111, 1255, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3140, 111, 1256, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3141, 111, 1257, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3142, 111, 1258, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3143, 111, 1259, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3144, 111, 1260, '1', '2023-12-02 23:41:02', '1', '2023-12-02 23:41:02', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3221, 109, 102, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3222, 109, 1013, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3223, 109, 1014, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3224, 109, 1015, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3225, 109, 1016, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3226, 111, 102, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3227, 111, 1013, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3228, 111, 1014, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3229, 111, 1015, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (3230, 111, 1016, '1', '2023-12-30 11:42:36', '1', '2023-12-30 11:42:36', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4163, 109, 5, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4164, 109, 1118, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4165, 109, 1119, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4219, 109, 1220, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4220, 109, 1221, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4221, 109, 1222, '1', '2024-03-30 17:53:17', '1', '2024-03-30 17:53:17', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4222, 111, 5, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4223, 111, 1118, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4224, 111, 1119, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4225, 111, 1120, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4226, 111, 2713, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4227, 111, 2714, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4228, 111, 2715, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4229, 111, 2716, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4230, 111, 2717, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4231, 111, 2718, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4232, 111, 2720, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4233, 111, 1185, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4234, 111, 2721, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4235, 111, 1186, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4236, 111, 2722, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4237, 111, 1187, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4238, 111, 2723, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4239, 111, 1188, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4240, 111, 2724, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4241, 111, 1189, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4242, 111, 2725, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4243, 111, 1190, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4244, 111, 2726, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4245, 111, 1191, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4246, 111, 2727, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4247, 111, 1192, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4248, 111, 2728, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4249, 111, 1193, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4250, 111, 2729, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4251, 111, 1194, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4252, 111, 2730, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4253, 111, 1195, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4254, 111, 2731, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4256, 111, 2732, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4257, 111, 1197, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4258, 111, 2733, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4259, 111, 1198, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4260, 111, 2734, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4261, 111, 1199, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4262, 111, 2735, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4263, 111, 1200, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4264, 111, 1201, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4265, 111, 1202, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4266, 111, 1207, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4267, 111, 1208, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4268, 111, 1209, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4269, 111, 1210, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4270, 111, 1211, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4271, 111, 1212, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4272, 111, 1213, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4273, 111, 1215, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4274, 111, 1216, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4275, 111, 1217, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4276, 111, 1218, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4277, 111, 1219, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4278, 111, 1220, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4279, 111, 1221, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (4280, 111, 1222, '1', '2024-03-30 17:53:18', '1', '2024-03-30 17:53:18', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5779, 2, 2739, '1', '2024-07-07 20:39:38', '1', '2024-07-07 20:39:38', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5780, 2, 2740, '1', '2024-07-07 20:39:38', '1', '2024-07-07 20:39:38', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5781, 2, 2758, '1', '2024-07-07 20:39:38', '1', '2024-07-07 20:39:38', b'0', 1); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5785, 2, 2030, '1', '2024-07-07 20:39:38', '1', '2024-07-07 20:39:38', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5789, 109, 2739, '1', '2024-07-13 22:37:24', '1', '2024-07-13 22:37:24', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5790, 109, 2740, '1', '2024-07-13 22:37:24', '1', '2024-07-13 22:37:24', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5791, 111, 2739, '1', '2024-07-13 22:37:24', '1', '2024-07-13 22:37:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5792, 111, 2740, '1', '2024-07-13 22:37:24', '1', '2024-07-13 22:37:24', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6053, 155, 4000, '1', '2025-04-01 13:48:26', '1', '2025-04-01 13:48:26', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6097, 155, 4050, '1', '2025-04-01 13:48:26', '1', '2025-04-01 13:48:26', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6104, 155, 4032, '1', '2025-04-01 13:49:30', '1', '2025-04-01 13:49:30', b'0', 1); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6175, 109, 2557, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6176, 109, 2558, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6177, 109, 2559, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6178, 111, 1117, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6179, 111, 1126, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6180, 111, 1127, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6181, 111, 1128, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6182, 111, 1129, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6183, 111, 1130, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6184, 111, 1132, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6185, 111, 1133, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6186, 111, 1134, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6187, 111, 1135, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6188, 111, 1136, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6189, 111, 1137, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6190, 111, 2161, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6191, 111, 1150, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6192, 111, 1161, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6193, 111, 1162, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6194, 111, 1166, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6195, 111, 1173, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6196, 111, 1174, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6197, 111, 1178, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6198, 111, 2745, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6199, 111, 2746, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6200, 111, 2747, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6201, 111, 2748, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6202, 111, 2301, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6203, 111, 2302, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6204, 111, 5011, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6205, 111, 5012, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6206, 111, 2549, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6207, 111, 2550, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6208, 111, 2551, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6209, 111, 2552, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6210, 111, 2553, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6211, 111, 2554, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6212, 111, 2555, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6213, 111, 2556, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6214, 111, 2557, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6215, 111, 2558, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6216, 111, 2559, '1', '2025-09-06 20:52:12', '1', '2025-09-06 20:52:12', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6217, 109, 2756, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6218, 109, 2757, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6219, 109, 2262, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6252, 109, 2335, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6253, 109, 2363, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6254, 109, 2364, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6255, 111, 2756, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6256, 111, 2757, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6257, 111, 2262, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6258, 111, 2275, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6259, 111, 2276, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6260, 111, 2277, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6261, 111, 2281, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6262, 111, 2282, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6263, 111, 2283, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6264, 111, 2284, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6265, 111, 2285, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6266, 111, 2287, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6267, 111, 2288, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6268, 111, 2293, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6269, 111, 2294, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6270, 111, 2297, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6271, 111, 2300, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6272, 111, 2317, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6273, 111, 2318, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6274, 111, 2319, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6275, 111, 2320, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6276, 111, 2321, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6277, 111, 2322, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6278, 111, 2323, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6279, 111, 2324, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6280, 111, 2325, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6281, 111, 2326, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6282, 111, 2327, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6283, 111, 2328, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6284, 111, 2329, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6285, 111, 2330, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6286, 111, 2331, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6287, 111, 2332, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6288, 111, 2333, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6289, 111, 2334, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6290, 111, 2335, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6291, 111, 2363, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6292, 111, 2364, '1', '2025-09-06 20:52:25', '1', '2025-09-06 20:52:25', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6293, 2, 5, '1', '2026-01-04 18:09:41', '1', '2026-01-04 18:09:41', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6294, 2, 1118, '1', '2026-01-04 18:09:41', '1', '2026-01-04 18:09:41', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6295, 2, 1119, '1', '2026-01-04 18:09:41', '1', '2026-01-04 18:09:41', b'0', 1); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6360, 2, 5811, '', '2026-03-30 03:13:05', '', '2026-03-30 03:13:05', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6361, 3, 5811, '', '2026-03-30 03:13:05', '', '2026-03-30 03:13:05', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6362, 109, 5811, '', '2026-03-30 03:13:05', '', '2026-03-30 03:13:05', b'0', 121); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6363, 111, 5811, '', '2026-03-30 03:13:05', '', '2026-03-30 03:13:05', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6364, 155, 5811, '', '2026-03-30 03:13:05', '', '2026-03-30 03:13:05', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6365, 2, 6400, '1', '2026-05-09 16:11:01', '1', '2026-05-09 16:11:01', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6366, 2, 6401, '1', '2026-05-09 16:11:01', '1', '2026-05-09 16:11:01', b'0', 1); |
| | |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6370, 2, 6405, '1', '2026-05-09 16:11:01', '1', '2026-05-09 16:11:01', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6371, 2, 6406, '1', '2026-05-09 16:11:01', '1', '2026-05-09 16:11:01', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6380, 2, 6490, '1', '2026-05-14 09:36:12', '1', '2026-05-14 09:36:12', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6381, 111, 1, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6382, 111, 2, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6383, 111, 5, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6384, 111, 1031, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6385, 111, 1032, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6386, 111, 1033, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6387, 111, 1034, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6388, 111, 1035, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6389, 111, 1036, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6390, 111, 1037, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6391, 111, 1038, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6392, 111, 1039, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6393, 111, 1050, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6394, 111, 1051, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6395, 111, 1052, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6396, 111, 1053, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6397, 111, 1054, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6398, 111, 1056, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6399, 111, 1057, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6400, 111, 1058, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6401, 111, 1059, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6402, 111, 1060, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6403, 111, 1063, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6404, 111, 1064, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6405, 111, 1065, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6406, 111, 1066, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6407, 111, 1067, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6408, 111, 1070, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6409, 111, 1075, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6410, 111, 1077, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6411, 111, 1078, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6412, 111, 1082, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6413, 111, 1083, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6414, 111, 1084, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6415, 111, 1085, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6416, 111, 1086, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6417, 111, 1087, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6418, 111, 1088, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6419, 111, 1089, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6420, 111, 1090, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6421, 111, 1091, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6422, 111, 1092, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6423, 111, 1117, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6424, 111, 1118, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6425, 111, 1119, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6426, 111, 1120, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6427, 111, 100, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6428, 111, 101, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6429, 111, 102, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6430, 111, 1126, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6431, 111, 103, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6432, 111, 1127, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6433, 111, 1128, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6434, 111, 1129, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6435, 111, 106, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6436, 111, 1130, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6437, 111, 107, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6438, 111, 1132, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6439, 111, 1133, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6440, 111, 110, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6441, 111, 1134, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6442, 111, 111, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6443, 111, 1135, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6444, 111, 112, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6445, 111, 1136, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6446, 111, 113, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6447, 111, 1137, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6448, 111, 2161, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6449, 111, 114, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6450, 111, 1138, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6451, 111, 1139, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6452, 111, 115, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6453, 111, 1140, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6454, 111, 116, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6455, 111, 1141, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6456, 111, 1142, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6457, 111, 1143, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6458, 111, 1150, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6459, 111, 1161, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6460, 111, 1162, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6461, 111, 1166, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6462, 111, 1173, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6463, 111, 1174, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6464, 111, 2713, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6465, 111, 2714, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6466, 111, 1178, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6467, 111, 2715, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6468, 111, 2716, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6469, 111, 2717, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6470, 111, 2718, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6471, 111, 2720, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6472, 111, 2721, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6473, 111, 1185, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6474, 111, 2722, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6475, 111, 1186, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6476, 111, 1187, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6477, 111, 2723, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6478, 111, 1188, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6479, 111, 2724, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6480, 111, 1189, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6481, 111, 2725, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6482, 111, 1190, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6483, 111, 2726, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6484, 111, 1191, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6485, 111, 2727, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6486, 111, 1192, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6487, 111, 2728, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6488, 111, 2729, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6489, 111, 1193, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6490, 111, 1194, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6491, 111, 2730, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6492, 111, 1195, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6493, 111, 2731, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6494, 111, 2732, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6495, 111, 1197, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6496, 111, 2733, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6497, 111, 1198, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6498, 111, 2734, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6499, 111, 1199, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6500, 111, 2735, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6501, 111, 1200, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6502, 111, 1201, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6503, 111, 1202, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6504, 111, 2739, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6505, 111, 2740, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6506, 111, 1207, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6507, 111, 1208, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6508, 111, 1209, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6509, 111, 2745, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6510, 111, 1210, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6511, 111, 2746, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6512, 111, 1211, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6513, 111, 2747, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6514, 111, 1212, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6515, 111, 2748, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6516, 111, 1213, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6517, 111, 1215, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6518, 111, 1216, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6519, 111, 1217, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6520, 111, 1218, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6521, 111, 1219, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6522, 111, 1220, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6523, 111, 2756, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6524, 111, 1221, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6525, 111, 2757, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6526, 111, 1222, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6527, 111, 1224, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6528, 111, 1225, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6529, 111, 1226, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6530, 111, 1227, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6531, 111, 1228, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6532, 111, 1229, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6533, 111, 1237, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6534, 111, 1238, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6535, 111, 2262, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6536, 111, 1239, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6537, 111, 1240, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6538, 111, 1241, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6539, 111, 1242, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6540, 111, 1243, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6541, 111, 2275, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6542, 111, 2276, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6543, 111, 2277, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6544, 111, 1255, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6545, 111, 1256, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6546, 111, 1257, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6547, 111, 2281, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6548, 111, 1258, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6549, 111, 2282, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6550, 111, 1259, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6551, 111, 2283, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6552, 111, 1260, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6553, 111, 2284, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6554, 111, 2285, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6555, 111, 2287, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6556, 111, 2288, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6557, 111, 2293, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6558, 111, 2294, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6559, 111, 2297, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6560, 111, 2300, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6561, 111, 2301, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6562, 111, 2302, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6563, 111, 2317, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6564, 111, 2318, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6565, 111, 2319, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6566, 111, 2320, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6567, 111, 2321, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6568, 111, 2322, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6569, 111, 2323, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6570, 111, 2324, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6571, 111, 2325, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6572, 111, 2326, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6573, 111, 2327, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6574, 111, 2328, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6575, 111, 2329, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6576, 111, 2330, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6577, 111, 2331, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6578, 111, 2332, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6579, 111, 2333, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6580, 111, 2334, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6581, 111, 2335, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6582, 111, 2363, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6583, 111, 2364, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6584, 111, 5011, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6585, 111, 5012, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6586, 111, 2472, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6587, 111, 2478, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6588, 111, 2479, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6589, 111, 2480, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6590, 111, 2481, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6591, 111, 2482, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6592, 111, 2483, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6593, 111, 2484, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6594, 111, 2485, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6595, 111, 2486, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6596, 111, 2487, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6597, 111, 2488, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6598, 111, 2489, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6599, 111, 2490, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6600, 111, 2491, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6601, 111, 2492, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6602, 111, 2493, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6603, 111, 2494, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6604, 111, 2495, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6605, 111, 2497, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6606, 111, 2525, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6607, 111, 1001, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6608, 111, 1002, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6609, 111, 1003, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6610, 111, 1004, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6611, 111, 1005, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6612, 111, 1006, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6613, 111, 1007, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6614, 111, 1008, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6615, 111, 1009, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6616, 111, 1010, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6617, 111, 1011, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6618, 111, 1012, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6619, 111, 1013, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6620, 111, 2549, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6621, 111, 1014, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6622, 111, 2550, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6623, 111, 1015, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6624, 111, 2551, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6625, 111, 1016, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6626, 111, 2552, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6627, 111, 1017, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6628, 111, 2553, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6629, 111, 1018, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6630, 111, 2554, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6631, 111, 1019, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6632, 111, 2555, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6633, 111, 1020, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6634, 111, 2556, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6635, 111, 2557, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6636, 111, 2558, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6637, 111, 2559, '1', '2026-06-01 23:29:35', '1', '2026-06-01 23:29:35', b'0', 122); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6638, 155, 5780, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6639, 155, 2084, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6640, 155, 2085, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6641, 155, 2086, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6642, 155, 2087, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6643, 155, 2088, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6644, 155, 2089, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6645, 155, 2090, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6646, 155, 2091, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6647, 155, 2092, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6648, 155, 2093, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6649, 155, 5805, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6650, 155, 2094, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6651, 155, 2095, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6652, 155, 2096, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6653, 155, 2097, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6654, 155, 2098, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6655, 155, 5042, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6656, 155, 2099, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6657, 155, 5043, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6658, 155, 2100, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6659, 155, 5044, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6660, 155, 2101, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6661, 155, 5045, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6662, 155, 2102, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6663, 155, 5046, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6664, 155, 2103, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6665, 155, 2104, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6666, 155, 2105, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6667, 155, 2106, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6668, 155, 2107, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6669, 155, 2108, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6670, 155, 2109, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6671, 155, 2110, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6672, 155, 2111, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6673, 155, 2112, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6674, 155, 2113, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6675, 155, 2114, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6676, 155, 2115, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6677, 155, 2116, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6678, 155, 2117, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6679, 155, 2118, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6680, 155, 2119, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6681, 155, 2120, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6682, 155, 2121, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6683, 155, 2122, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6684, 155, 2123, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6685, 155, 2124, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6686, 155, 2125, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6687, 155, 2126, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6688, 155, 2127, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6689, 155, 2128, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6690, 155, 2129, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | INSERT INTO `system_role_menu` (`id`, `role_id`, `menu_id`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (6691, 155, 5100, '1', '2026-06-10 09:04:18', '1', '2026-06-10 09:04:18', b'0', 1); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `tenant_id` bigint NOT NULL DEFAULT 0 COMMENT 'ç§æ·ç¼å·', |
| | | PRIMARY KEY (`id`) USING BTREE, |
| | | INDEX `idx_mobile`(`mobile` ASC) USING BTREE COMMENT 'ææºå·' |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 690 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ææºéªè¯ç '; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 694 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ææºéªè¯ç '; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_sms_code |
| | |
| | | `update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'æ´æ°æ¶é´', |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1553 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'çä¿¡æ¥å¿'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 1568 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'çä¿¡æ¥å¿'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_sms_log |
| | |
| | | BEGIN; |
| | | INSERT INTO `system_tenant` (`id`, `name`, `contact_user_id`, `contact_name`, `contact_mobile`, `status`, `websites`, `package_id`, `expire_time`, `account_count`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (1, 'èéæºç ', NULL, 'èè¿', '17321315478', 0, 'www.iocoder.cn,127.0.0.1:3000,wxc4598c446f8a9cb3', 0, '2099-02-19 17:14:16', 9999, '1', '2021-01-05 17:03:47', '1', '2025-08-19 05:18:41', b'0'); |
| | | INSERT INTO `system_tenant` (`id`, `name`, `contact_user_id`, `contact_name`, `contact_mobile`, `status`, `websites`, `package_id`, `expire_time`, `account_count`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (121, 'å°ç§æ·', 110, 'å°ç2', '15601691300', 0, 'zsxq.iocoder.cn,123321', 111, '2026-07-10 00:00:00', 30, '1', '2022-02-22 00:56:14', '1', '2025-08-19 21:19:29', b'0'); |
| | | INSERT INTO `system_tenant` (`id`, `name`, `contact_user_id`, `contact_name`, `contact_mobile`, `status`, `websites`, `package_id`, `expire_time`, `account_count`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (122, 'æµè¯ç§æ·', 113, 'èé', '15601691300', 0, 'test.iocoder.cn,222,333', 111, '2023-04-29 00:00:00', 50, '1', '2022-03-07 21:37:58', '1', '2025-12-21 09:50:00', b'0'); |
| | | INSERT INTO `system_tenant` (`id`, `name`, `contact_user_id`, `contact_name`, `contact_mobile`, `status`, `websites`, `package_id`, `expire_time`, `account_count`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (122, 'æµè¯ç§æ·', 113, 'èé', '15601691300', 0, 'test.iocoder.cn,222,333', 111, '2023-04-29 00:00:00', 50, '1', '2022-03-07 21:37:58', '1', '2026-06-01 23:29:35', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | `update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'æ´æ°æ¶é´', |
| | | `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT 'æ¯å¦å é¤', |
| | | PRIMARY KEY (`id`) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 113 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç§æ·å¥é¤è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 114 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç§æ·å¥é¤è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_tenant_package |
| | | -- ---------------------------- |
| | | BEGIN; |
| | | INSERT INTO `system_tenant_package` (`id`, `name`, `status`, `remark`, `menu_ids`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (111, 'æ®éå¥é¤', 0, 'å°åè½', '[1,2,5,1031,1032,1033,1034,1035,1036,1037,1038,1039,1050,1051,1052,1053,1054,1056,1057,1058,1059,1060,1063,1064,1065,1066,1067,1070,1075,1077,1078,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1117,1118,1119,1120,100,101,102,1126,103,1127,1128,1129,106,1130,107,1132,1133,110,1134,111,1135,112,1136,113,1137,2161,114,1138,1139,115,1140,116,1141,1142,1143,1150,1161,1162,1166,1173,1174,2713,2714,1178,2715,2716,2717,2718,2720,2721,1185,2722,1186,1187,2723,1188,2724,1189,2725,1190,2726,1191,2727,1192,2728,2729,1193,1194,2730,1195,2731,2732,1197,2733,1198,2734,1199,2735,1200,1201,1202,2739,2740,1207,1208,1209,2745,1210,2746,1211,2747,1212,2748,1213,1215,1216,1217,1218,1219,1220,2756,1221,2757,1222,1224,1225,1226,1227,1228,1229,1237,1238,2262,1239,1240,1241,1242,1243,2275,2276,2277,1255,1256,1257,2281,1258,2282,1259,2283,1260,2284,2285,2287,2288,2293,2294,2297,2300,2301,2302,2317,2318,2319,2320,2321,2322,2323,2324,2325,2326,2327,2328,2329,2330,2331,2332,2333,2334,2335,2363,2364,5011,5012,2472,2478,2479,2480,2481,2482,2483,2484,2485,2486,2487,2488,2489,2490,2491,2492,2493,2494,2495,2497,2525,1001,1002,1003,1004,1005,1006,1007,1008,1009,1010,1011,1012,1013,2549,1014,2550,1015,2551,1016,2552,1017,2553,1018,2554,1019,2555,1020,2556,2557,2558,2559]', '1', '2022-02-22 00:54:00', '1', '2025-09-06 20:52:25', b'0'); |
| | | INSERT INTO `system_tenant_package` (`id`, `name`, `status`, `remark`, `menu_ids`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES (113, 'æµè¯å¥é¤ï¼å¥é½æ²¡æï¼', 0, '', '[2160,1254,2159]', '1', '2026-06-01 23:22:39', '1', '2026-06-09 14:44:00', b'0'); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | INDEX `idx_mobile`(`mobile` ASC) USING BTREE, |
| | | INDEX `idx_email`(`email` ASC) USING BTREE, |
| | | INDEX `idx_dept_id`(`dept_id` ASC) USING BTREE |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 145 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç¨æ·ä¿¡æ¯è¡¨'; |
| | | ) ENGINE = InnoDB AUTO_INCREMENT = 225 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci COMMENT = 'ç¨æ·ä¿¡æ¯è¡¨'; |
| | | |
| | | -- ---------------------------- |
| | | -- Records of system_users |
| | | -- ---------------------------- |
| | | BEGIN; |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1, 'admin', '$2a$04$.vd8nPeLwxt6hnSzmAoAyul8BOLX7Cib6QhcxRe30rfvrIPQHH1OG', 'èéæºç ', '管çå', 103, '[1,2]', '13aoteman@126.com', '18818260272', 1, 'http://test.yudao.iocoder.cn/user/avatar/20251220/blob_1766215463801.jpg', 0, '0:0:0:0:0:0:0:1', '2026-05-15 22:24:39', 'admin', '2021-01-05 17:03:47', NULL, '2026-05-15 22:24:39', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (100, 'yudao', '$2a$04$.vd8nPeLwxt6hnSzmAoAyul8BOLX7Cib6QhcxRe30rfvrIPQHH1OG', 'èé', 'ä¸è¦åæ', 104, '[1]', 'yudao@iocoder.cn', '15601691300', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2026-04-19 17:40:55', '', '2021-01-07 09:07:17', NULL, '2026-04-19 17:40:55', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (1, 'admin', '$2a$04$.vd8nPeLwxt6hnSzmAoAyul8BOLX7Cib6QhcxRe30rfvrIPQHH1OG', 'èéæºç ', '管çå', 103, '[1,2]', '13aoteman@126.com', '18818260272', 1, 'http://test.yudao.iocoder.cn/20260517/blob_1778998103688.png', 0, '0:0:0:0:0:0:0:1', '2026-06-28 03:39:52', 'admin', '2021-01-05 17:03:47', NULL, '2026-06-28 03:39:52', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (100, 'yudao', '$2a$04$.vd8nPeLwxt6hnSzmAoAyul8BOLX7Cib6QhcxRe30rfvrIPQHH1OG', 'èé', 'ä¸è¦åæ', 104, '[1]', 'yudao@iocoder.cn', '15601691300', 1, NULL, 0, '127.0.0.1', '2026-06-17 09:37:17', '', '2021-01-07 09:07:17', NULL, '2026-06-17 09:37:17', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (103, 'yuanma', '$2a$04$k/d6mc0nySN0i2udwcI8Ee8V5aM5OHixBRbQfXmPuFTUl3Zf/DBs.', 'æºç ', NULL, 106, NULL, 'yuanma@iocoder.cn', '15601701300', 0, NULL, 0, '0:0:0:0:0:0:0:1', '2026-04-27 13:19:27', '', '2021-01-13 23:50:35', NULL, '2026-04-27 13:19:27', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (104, 'test', '$2a$04$BrwaYn303hjA/6TnXqdGoOLhyHOAA0bVrAFu6.1dJKycqKUnIoRz2', 'æµè¯å·', NULL, 107, '[1,2]', '111@qq.com', '15601691200', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2026-05-09 09:57:13', '', '2021-01-21 02:13:53', NULL, '2026-05-09 09:57:13', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (104, 'test', '$2a$04$BrwaYn303hjA/6TnXqdGoOLhyHOAA0bVrAFu6.1dJKycqKUnIoRz2', 'æµè¯å·', NULL, 107, '[1,2]', '111@qq.com', '15601691200', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2026-06-16 11:37:56', '', '2021-01-21 02:13:53', NULL, '2026-06-16 11:37:56', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (107, 'admin107', '$2a$10$dYOOBKMO93v/.ReCqzyFg.o67Tqk.bbc2bhrpyBGkIw9aypCtr2pm', 'èè¿', NULL, NULL, NULL, '', '15601691300', 0, NULL, 0, '', NULL, '1', '2022-02-20 22:59:33', '1', '2025-04-21 14:23:08', b'0', 118); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (108, 'admin108', '$2a$10$y6mfvKoNYL1GXWak8nYwVOH.kCWqjactkzdoIDgiKl93WN3Ejg.Lu', 'èè¿', NULL, NULL, NULL, '', '15601691300', 0, NULL, 0, '', NULL, '1', '2022-02-20 23:00:50', '1', '2025-04-21 14:23:08', b'0', 119); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (109, 'admin109', '$2a$10$JAqvH0tEc0I7dfDVBI7zyuB4E3j.uH6daIjV53.vUS6PknFkDJkuK', 'èè¿', NULL, NULL, NULL, '', '15601691300', 0, NULL, 0, '', NULL, '1', '2022-02-20 23:11:50', '1', '2025-04-21 14:23:08', b'0', 120); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (110, 'admin110', '$2a$10$mRMIYLDtRHlf6.9ipiqH1.Z.bh/R9dO9d5iHiGYPigi6r5KOoR2Wm', 'å°ç', NULL, NULL, NULL, '', '15601691300', 0, NULL, 0, '0:0:0:0:0:0:0:1', '2024-07-20 22:23:17', '1', '2022-02-22 00:56:14', NULL, '2025-04-21 14:23:08', b'0', 121); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (111, 'test', '$2a$10$mRMIYLDtRHlf6.9ipiqH1.Z.bh/R9dO9d5iHiGYPigi6r5KOoR2Wm', 'æµè¯ç¨æ·', NULL, NULL, '[]', '', '', 0, NULL, 0, '0:0:0:0:0:0:0:1', '2023-12-30 11:42:17', '110', '2022-02-23 13:14:33', NULL, '2025-04-21 14:23:08', b'0', 121); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (112, 'newobject', '$2a$04$dB0z8Q819fJWz0hbaLe6B.VfHCjYgWx6LFfET5lyz3JwcqlyCkQ4C', 'æ°å¯¹è±¡', NULL, 100, '[]', '', '15601691235', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2024-03-16 23:11:38', '1', '2022-02-23 19:08:03', NULL, '2025-04-21 14:23:08', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (112, 'newobject', '$2a$04$dB0z8Q819fJWz0hbaLe6B.VfHCjYgWx6LFfET5lyz3JwcqlyCkQ4C', 'æ°å¯¹è±¡', NULL, 100, '[]', '', '15601691235', 1, NULL, 0, '127.0.0.1', '2026-06-17 09:07:20', '1', '2022-02-23 19:08:03', NULL, '2026-06-17 09:07:20', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (113, 'aoteman', '$2a$10$0acJOIk2D25/oC87nyclE..0lzeu9DtQ/n3geP4fkun/zIVRhHJIO', 'èé1', NULL, NULL, NULL, '', '15601691300', 0, NULL, 0, '127.0.0.1', '2022-03-19 18:38:51', '1', '2022-03-07 21:37:58', '1', '2025-05-05 15:30:53', b'0', 122); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (114, 'hrmgr', '$2a$10$TR4eybBioGRhBmDBWkqWLO6NIh3mzYa8KBKDDB5woiGYFVlRAi.fu', 'hr å°å§å§', NULL, NULL, '[5]', '', '15601691236', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2026-01-04 18:16:01', '1', '2022-03-19 21:50:58', NULL, '2026-01-04 18:16:01', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (115, 'aotemane', '$2a$04$GcyP0Vyzb2F2Yni5PuIK9ueGxM0tkZGMtDwVRwrNbtMvorzbpNsV2', 'é¿å', '11222', 102, '[1,2]', '7648@qq.com', '15601691229', 2, NULL, 0, '', NULL, '1', '2022-04-30 02:55:43', '1', '2025-04-21 14:23:08', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (117, 'admin123', '$2a$04$sEtimsHu9YCkYY4/oqElHem2Ijc9ld20eYO6lN.g/21NfLUTDLB9W', 'æµè¯å·02', '1111', 100, '[2]', '', '15601691234', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2024-10-02 10:16:20', '1', '2022-07-09 17:40:26', '1', '2025-05-14 09:56:04', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (118, 'goudan', '$2a$04$3suGZjnA6rM5bErf38u1felbgqbsPHGdRG3l9NkxPCEt2ah9Y6aJi', 'çè', NULL, 103, '[1]', '', '15601691239', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2025-11-23 15:28:25', '1', '2022-07-09 17:44:43', NULL, '2025-11-23 15:28:25', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (139, 'wwbwwb', '$2a$04$FJLIyg8lbPytP29pbZaiU.LesJvCsYfEaHqQfB0pGQhK3e9BeZmLy', 'å°ç§å¤´', '123', 108, '[2,4]', '', '', 1, NULL, 0, '0:0:0:0:0:0:0:1', '2024-09-10 21:03:58', NULL, '2024-09-10 21:03:58', '1', '2025-12-15 22:38:15', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (141, 'admin1', '$2a$04$oj6F6d7HrZ70kYVD3TNzEu.m3TPUzajOVuC66zdKna8KRerK1FmVa', 'æ°ç¨æ·', NULL, NULL, NULL, '', '', 0, '', 0, '0:0:0:0:0:0:0:1', '2025-04-08 13:09:07', '1', '2025-04-08 13:09:07', '1', '2025-05-14 19:11:48', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (142, 'test01', '$2a$04$4bCYWZkjxxOC4QE0LY2M9uEEKWeJbLfs489NFtQoyidL5I0FndRaO', 'test01', '', NULL, '[]', '', '19021719925', 1, '', 0, '0:0:0:0:0:0:0:1', '2025-07-29 19:47:17', '1', '2025-07-09 21:07:10', NULL, '2025-12-02 13:23:11', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (141, 'admin1', '$2a$04$oj6F6d7HrZ70kYVD3TNzEu.m3TPUzajOVuC66zdKna8KRerK1FmVa', 'æ°ç¨æ·', NULL, NULL, NULL, '', '', 0, '', 0, '127.0.0.1', '2026-06-17 09:37:18', '1', '2025-04-08 13:09:07', NULL, '2026-06-17 09:37:18', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (142, 'test01', '$2a$04$4bCYWZkjxxOC4QE0LY2M9uEEKWeJbLfs489NFtQoyidL5I0FndRaO', 'test01', '', NULL, '[]', '', '19021719925', 1, '', 0, '0:0:0:0:0:0:0:1', '2026-06-17 10:44:58', '1', '2025-07-09 21:07:10', NULL, '2026-06-17 10:44:58', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (143, 'a00001', '$2a$04$GhVHFviOw/SsTmiQtifHJesDYFlHMeGK7OWh7aGCCjGGVCmbHVAwa', 'a00001', NULL, 104, NULL, '', '', 0, '', 0, '0:0:0:0:0:0:0:1', '2025-12-01 16:10:13', NULL, '2025-12-01 16:10:13', '1', '2025-12-05 21:34:05', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (144, 'aoteman001', '$2a$04$omQOmhz8OyUFBKw77nr8KOtMp6xdvoQ1gWStjk9r8.OYT3Bv6oEYe', 'aoteman001', NULL, 116, NULL, '', '', 0, '', 1, '0:0:0:0:0:0:0:1', '2025-12-01 17:05:27', '1', '2025-12-01 17:05:27', '1', '2025-12-15 15:55:54', b'0', 1); |
| | | INSERT INTO `system_users` (`id`, `username`, `password`, `nickname`, `remark`, `dept_id`, `post_ids`, `email`, `mobile`, `sex`, `avatar`, `status`, `login_ip`, `login_date`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (144, 'aoteman001', '$2a$04$omQOmhz8OyUFBKw77nr8KOtMp6xdvoQ1gWStjk9r8.OYT3Bv6oEYe', 'aoteman00112', NULL, 104, NULL, '', '', 0, '', 1, '0:0:0:0:0:0:0:1', '2025-12-01 17:05:27', '1', '2025-12-01 17:05:27', '1', '2026-06-15 18:58:56', b'0', 1); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | INSERT INTO `yudao_demo03_course` (`id`, `student_id`, `name`, `score`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (17, 2, 'è¯æ', 66, '1', '2023-11-16 23:21:49', '1', '2024-09-17 18:55:31', b'0', 1); |
| | | INSERT INTO `yudao_demo03_course` (`id`, `student_id`, `name`, `score`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (18, 2, 'æ°å¦', 22, '1', '2023-11-16 23:21:49', '1', '2024-09-17 18:55:31', b'0', 1); |
| | | INSERT INTO `yudao_demo03_course` (`id`, `student_id`, `name`, `score`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (19, 9, 'æ»éª', 12, '1', '2023-11-17 13:13:20', '1', '2025-04-19 02:49:03', b'1', 1); |
| | | INSERT INTO `yudao_demo03_course` (`id`, `student_id`, `name`, `score`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (20, 9, 'æ»éª', 12, '1', '2023-11-17 13:13:20', '1', '2025-04-19 10:49:04', b'0', 1); |
| | | INSERT INTO `yudao_demo03_course` (`id`, `student_id`, `name`, `score`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (20, 9, 'æ»éª', 12, '1', '2023-11-17 13:13:20', '1', '2026-06-27 08:42:44', b'0', 1); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | BEGIN; |
| | | INSERT INTO `yudao_demo03_grade` (`id`, `student_id`, `name`, `teacher`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (7, 2, 'ä¸å¹´ 2 ç', '卿°ä¼¦', '1', '2023-11-16 23:21:49', '1', '2024-09-17 18:55:31', b'0', 1); |
| | | INSERT INTO `yudao_demo03_grade` (`id`, `student_id`, `name`, `teacher`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (8, 5, 'å为', 'é¥é¥é¢å
', '1', '2023-11-16 23:22:46', '1', '2024-09-17 18:55:29', b'0', 1); |
| | | INSERT INTO `yudao_demo03_grade` (`id`, `student_id`, `name`, `teacher`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (9, 9, 'å°å¾', 'å°å¨111', '1', '2023-11-17 13:10:23', '1', '2025-04-19 10:49:04', b'0', 1); |
| | | INSERT INTO `yudao_demo03_grade` (`id`, `student_id`, `name`, `teacher`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (9, 9, 'å°å¾', 'å°å¨111', '1', '2023-11-17 13:10:23', '1', '2026-06-27 08:42:44', b'0', 1); |
| | | COMMIT; |
| | | |
| | | -- ---------------------------- |
| | |
| | | BEGIN; |
| | | INSERT INTO `yudao_demo03_student` (`id`, `name`, `sex`, `birthday`, `description`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (2, 'å°ç½', 1, '2023-11-16 00:00:00', '<p>å害</p>', '1', '2023-11-16 23:21:49', '1', '2024-09-17 18:55:31', b'0', 1); |
| | | INSERT INTO `yudao_demo03_student` (`id`, `name`, `sex`, `birthday`, `description`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (5, '大é»', 2, '2023-11-13 00:00:00', '<p>ä½ å¨ææåäº?</p>', '1', '2023-11-16 23:22:46', '1', '2024-09-17 18:55:29', b'0', 1); |
| | | INSERT INTO `yudao_demo03_student` (`id`, `name`, `sex`, `birthday`, `description`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (9, 'å°è±', 1, '2023-11-07 00:00:00', '<p>ååå</p>', '1', '2023-11-17 00:04:47', '1', '2025-04-19 10:49:04', b'0', 1); |
| | | INSERT INTO `yudao_demo03_student` (`id`, `name`, `sex`, `birthday`, `description`, `creator`, `create_time`, `updater`, `update_time`, `deleted`, `tenant_id`) VALUES (9, 'å°è±', 1, '2023-11-07 00:00:00', '<p>ååå</p>', '1', '2023-11-17 00:04:47', '1', '2026-06-27 08:42:44', b'0', 1); |
| | | COMMIT; |
| | | |
| | | SET FOREIGN_KEY_CHECKS = 1; |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', '2025-09-06 00:02:21', '1', '2025-09-06 00:02:31', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', '2023-11-04 13:05:38', '1', '2023-11-04 13:07:16', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', '2025-12-16 19:25:51', '1', '2025-12-17 09:46:15', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', '2026-02-04 00:32:47', '1', '2026-02-04 00:32:47', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | COMMIT; |
| | | -- @formatter:on |
| | | |
| | |
| | | DROP SEQUENCE IF EXISTS yudao_demo03_student_seq; |
| | | CREATE SEQUENCE yudao_demo03_student_seq |
| | | START 10; |
| | | |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', to_date('2025-09-06 00:02:21', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2025-09-06 00:02:31', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', to_date('2023-11-04 13:05:38', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2023-11-04 13:07:16', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', to_date('2025-12-16 19:25:51', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2025-12-17 09:46:15', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', SYSDATE, '1', SYSDATE, '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', SYSDATE, '1', SYSDATE, '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', to_date('2026-02-04 00:32:47', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-02-04 00:32:47', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', to_date('2026-02-04 00:32:55', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-02-04 00:32:55', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', to_date('2026-02-04 00:32:55', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-02-04 00:32:55', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-05 15:53:46', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '1', to_date('2026-04-16 09:47:00', 'SYYYY-MM-DD HH24:MI:SS'), '0'); |
| | | COMMIT; |
| | | -- @formatter:on |
| | | |
| | |
| | | |
| | | CREATE SEQUENCE yudao_demo03_student_seq |
| | | START WITH 10; |
| | | |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3034, 1, 'ttt', 'tt', 'iot_ota_task_record_status', 0, 'success', '', NULL, '1', '2025-09-06 00:02:21', '1', '2025-09-06 00:02:31', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3035, 40, 'æ¯ä»å®å°ç¨åº', '40', 'system_social_type', 0, '', '', '', '1', '2023-11-04 13:05:38', '1', '2023-11-04 13:07:16', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, 'Admin Uniapp ç§»å¨ç«¯', '60', 'infra_codegen_front_type', 0, '', '', NULL, '1', '2025-12-16 19:25:51', '1', '2025-12-17 09:46:15', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, 'Vben5.0 Antdv Next Schema 模ç', '42', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, 'Vben5.0 Antdv Next æ 忍¡ç', '43', 'infra_codegen_front_type', 0, '', '', '', '1', NOW(), '1', NOW(), '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, 'UDP', 'udp', 'iot_protocol_type', 0, '', '', 'UDP åè®®', '1', '2026-02-04 00:32:47', '1', '2026-02-04 00:32:47', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, 'WebSocket', 'websocket', 'iot_protocol_type', 0, '', '', 'WebSocket åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3042, 3, 'HTTP', 'http', 'iot_protocol_type', 0, '', '', 'HTTP åè®®', '1', '2026-02-04 00:32:55', '1', '2026-02-04 00:32:55', '0'); |
| | |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3443, 1, 'è稿', '0', 'mes_wm_product_produce_status', 0, 'info', '', 'èç¨¿ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3444, 2, '已宿', '4', 'mes_wm_product_produce_status', 0, 'success', '', 'å·²å®æç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, '已忶', '5', 'mes_wm_product_produce_status', 0, 'danger', '', 'å·²åæ¶ç¶æ', '1', '2026-04-05 15:53:46', '1', '2026-04-05 15:53:46', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'èÂâ°Ã§Â¨Â¿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, 'å·²å®ÅæËÂ', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, 'å·²åÂâæ¶Ë', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, 'è稿', '0', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, '已宿', '4', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, '已忶', '5', 'mes_pro_task_status', 0, '', '', NULL, '1', '2026-04-16 09:47:00', '1', '2026-04-16 09:47:00', '0'); |
| | | COMMIT; |
| | | -- @formatter:on |
| | | |
| | |
| | | DROP SEQUENCE IF EXISTS yudao_demo03_student_seq; |
| | | CREATE SEQUENCE yudao_demo03_student_seq |
| | | START 10; |
| | | |
| | |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3036, 60, N'Admin Uniapp ç§»å¨ç«¯', N'60', N'infra_codegen_front_type', 0, N'', N'', NULL, N'1', N'2025-12-16 19:25:51', N'1', N'2025-12-17 09:46:15', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3037, 42, N'Vben5.0 Antdv Next Schema 模ç', N'42', N'infra_codegen_front_type', 0, N'', N'', N'', N'1', N'2026-05-16 00:00:00', N'1', N'2026-05-16 00:00:00', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3038, 43, N'Vben5.0 Antdv Next æ 忍¡ç', N'43', N'infra_codegen_front_type', 0, N'', N'', N'', N'1', N'2026-05-16 00:00:00', N'1', N'2026-05-16 00:00:00', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3040, 1, N'UDP', N'udp', N'iot_protocol_type', 0, N'', N'', N'UDP åè®®', N'1', N'2026-02-04 00:32:47', N'1', N'2026-02-04 00:32:47', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3041, 2, N'WebSocket', N'websocket', N'iot_protocol_type', 0, N'', N'', N'WebSocket åè®®', N'1', N'2026-02-04 00:32:55', N'1', N'2026-02-04 00:32:55', N'0') |
| | |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3445, 3, N'已忶', N'5', N'mes_wm_product_produce_status', 0, N'danger', N'', N'å·²åæ¶ç¶æ', N'1', N'2026-04-05 15:53:46', N'1', N'2026-04-05 15:53:46', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, N'èÂâ°Ã§Â¨Â¿', N'0', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3446, 0, N'è稿', N'0', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, N'å·²å®ÅæËÂ', N'4', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3447, 1, N'已宿', N'4', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | GO |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, N'å·²åÂâæ¶Ë', N'5', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | INSERT INTO system_dict_data (id, sort, label, value, dict_type, status, color_type, css_class, remark, creator, create_time, updater, update_time, deleted) VALUES (3448, 2, N'已忶', N'5', N'mes_pro_task_status', 0, N'', N'', NULL, N'1', N'2026-04-16 09:47:00', N'1', N'2026-04-16 09:47:00', N'0') |
| | | GO |
| | | SET IDENTITY_INSERT system_dict_data OFF |
| | | GO |
| | |
| | | COMMIT |
| | | GO |
| | | -- @formatter:on |
| | | |
| | |
| | | ```Bash |
| | | docker compose up -d dm8 |
| | | # 注æï¼å¯å¨å® dm åï¼éè¦æå¨åæ§è¡å¦ä¸å½ä»¤ï¼å 为 dm 䏿¯æåå§åèæ¬ |
| | | docker compose exec dm8 bash -c '/opt/dmdbms/bin/disql SYSDBA/SYSDBA001 \`/tmp/schema.sql' |
| | | docker compose exec dm8 bash -c 'printf "SET DEFINE OFF;\n" > /tmp/schema-with-define-off.sql && cat /tmp/schema.sql >> /tmp/schema-with-define-off.sql && /opt/dmdbms/bin/disql SYSDBA/SYSDBA001 \`/tmp/schema-with-define-off.sql' |
| | | exit |
| | | ``` |
| | | |
| | | > 注æï¼é¡¹ç® DM8 èæ¬ä½¿ç¨ `varchar(n char)` ä¿æå MySQL `varchar(n)` ä¸è´çå符é¿åº¦è¯ä¹ï¼å»ºè®®åå§å DM8 æ¶ä½¿ç¨ `PAGE_SIZE=16`ã`UNICODE_FLAG=1`ã`sql/tools/docker-compose.yaml` å·²æè¯¥é
ç½®æä¾ç¤ºä¾ãä½¿ç¨ `disql` 导å
¥æ¶éè¦å
æ§è¡ `SET DEFINE OFF;`ï¼é¿å
æ°æ®éç `&` 被å½ä½åéæ¿æ¢ã |
| | | |
| | | ### 1.6 KingbaseES 人大éä» |
| | | |
| | |
| | | docker compose exec opengauss bash -c '/usr/local/opengauss/bin/gsql -U $GS_USERNAME -W $GS_PASSWORD -d postgres -f /tmp/schema.sql' |
| | | ``` |
| | | |
| | | ### 1.8 HighGo ç髿°æ®åº |
| | | |
| | | â ä¸è½½çé«å®æ¹ Docker éåï¼å¹¶å è½½éåæä»¶ãå è½½åï¼å°éåæææ¬å°æ ç¾ï¼ |
| | | |
| | | ```Bash |
| | | docker load -i <highgo-image>.tar |
| | | docker tag <image>:<tag> highgo:local |
| | | ``` |
| | | |
| | | â¡ å¨é¡¹ç® `sql/tools` ç®å½ä¸è¿è¡ï¼ |
| | | |
| | | ```Bash |
| | | docker compose up -d highgo |
| | | ``` |
| | | |
| | | > 注æï¼ä¸åçé«éåçæ°æ®ç®å½å¯è½ä¸åï¼å¦æå®¹å¨æ æ³å¯å¨ï¼è¯·æéåå®é
`PGDATA` ä¿®æ¹ `docker-compose.yaml` ä¸ç `highgo` æ°æ®å·æè½½ç®å½ã |
| | | |
| | | ⢠å¯å¨å®æåï¼éè¦æå¨å¯¼å
¥ Quartz åé¡¹ç® SQLãçé«å
¼å®¹ PostgreSQLï¼å
·ä½å®¢æ·ç«¯å½ä»¤ä»¥å½åéå为åï¼å¯ä½¿ç¨ `psql` æçé«éåå
ç½®çå
¼å®¹å®¢æ·ç«¯æ§è¡ `/tmp/quartz.sql`ã`/tmp/schema.sql`ã |
| | | |
| | | ## 1.X 容å¨ç鿝é建 |
| | | |
| | | å¼åæµè¯è¿ç¨ä¸ï¼ææ¶åéè¦å建å
¨æ°å¹²åçæ°æ®åºãç±äºæµè¯æ°æ® Docker 容å¨éç¨æ°æ®å· Volume æè½½æ°æ®åºå®ä¾çæ°æ®ç®å½ï¼å æ¤éæ¯æ°æ®éè¦åæ¢å®¹å¨åï¼å 餿°æ®å·ï¼ç¶ååéæ°å建容å¨ã |
| | |
| | | |
| | | ## 2. MySQL 转æ¢å
¶å®æ°æ®åº |
| | | |
| | | é¡¹ç®æä¾äº `sql/tools/convertor.py` èæ¬ï¼æ¯æå° MySQL 转æ¢ä¸º OracleãPostgreSQLãSQL Serverã达梦ã人大éä»ãOpenGauss çæ°æ®åºçèæ¬ã |
| | | é¡¹ç®æä¾äº `sql/tools/convertor.py` èæ¬ï¼æ¯æå° MySQL 转æ¢ä¸º OracleãPostgreSQLãSQL Serverã达梦ã人大éä»ãOpenGaussãçé«çæ°æ®åºçèæ¬ã |
| | | |
| | | ### 2.1 å®ç°åç |
| | | |
| | |
| | | # pip3 install simple-ddl-parser |
| | | ``` |
| | | |
| | | â¡ å¨ `sql/tools/` ç®å½ä¸ï¼æ§è¡å¦ä¸å½ä»¤æå°çæ postgres çèæ¬å
容ï¼å
¶ä»å¯éåæ°æï¼`oracle`ã`sqlserver`ã`dm8`ã`kingbase`ã`opengauss`ï¼ |
| | | â¡ å¨ `sql/tools/` ç®å½ä¸ï¼æ§è¡å¦ä¸å½ä»¤æå°çæ postgres çèæ¬å
容ï¼å
¶ä»å¯éåæ°æï¼`oracle`ã`sqlserver`ã`dm8`ã`kingbase`ã`opengauss`ã`highgo`ï¼ |
| | | |
| | | ```Bash |
| | | python3 convertor.py postgres |
| | | # python3 convertor.py postgres > tmp.sql |
| | | # python3 convertor.py highgo ../mysql/ruoyi-vue-pro.sql > ../highgo/ruoyi-vue-pro.sql |
| | | ``` |
| | | |
| | | ç¨åºå° SQL èæ¬æå°å°ç»ç«¯ï¼å¯ä»¥éå®åå°ä¸´æ¶æä»¶ `tmp.sql`ã |
| | |
| | | uv run --with simple-ddl-parser convertor.py sqlserver ../mysql/ruoyi-vue-pro.sql > ../sqlserver/ruoyi-vue-pro.sql |
| | | uv run --with simple-ddl-parser convertor.py kingbase ../mysql/ruoyi-vue-pro.sql > ../kingbase/ruoyi-vue-pro.sql |
| | | uv run --with simple-ddl-parser convertor.py opengauss ../mysql/ruoyi-vue-pro.sql > ../opengauss/ruoyi-vue-pro.sql |
| | | uv run --with simple-ddl-parser convertor.py highgo ../mysql/ruoyi-vue-pro.sql > ../highgo/ruoyi-vue-pro.sql |
| | | uv run --with simple-ddl-parser convertor.py oracle ../mysql/ruoyi-vue-pro.sql > ../oracle/ruoyi-vue-pro.sql |
| | | uv run --with simple-ddl-parser convertor.py dm8 ../mysql/ruoyi-vue-pro.sql > ../dm/ruoyi-vue-pro-dm8.sql |
| | | """ |
| | |
| | | |
| | | |
| | | class Convertor(ABC): |
| | | # ä¸åæ°æ®åºçå
³é®åä¸å®å
¨ä¸è´ï¼åç±»æé声æéè¦è½¬ä¹çååã |
| | | reserved_column_names = set() |
| | | |
| | | def __init__(self, src: str, db_type) -> None: |
| | | self.src = src |
| | | self.db_type = db_type |
| | |
| | | """ |
| | | return "" |
| | | |
| | | def escape_column_name(self, name: str) -> str: |
| | | """转ä¹ç®æ åºä¿çåååï¼ä¾å¦ Oracle / Kingbase ç levelã""" |
| | | |
| | | column_name = name.lower() |
| | | if column_name in self.reserved_column_names: |
| | | return f'"{column_name}"' |
| | | return column_name |
| | | |
| | | def escape_insert_columns(self, insert_script: str) -> str: |
| | | """INSERT æ¾å¼åæ¸
åéè¦å CREATE / COMMENT 使ç¨åä¸å¥åå转ä¹ã""" |
| | | |
| | | match = re.match( |
| | | r"(INSERT INTO\s+\S+\s*\()([^)]+)(\)\s+VALUES\s+[\s\S]*)", |
| | | insert_script, |
| | | flags=re.IGNORECASE, |
| | | ) |
| | | if not match: |
| | | return insert_script |
| | | |
| | | columns = [ |
| | | self.escape_column_name(column.strip()) |
| | | for column in match.group(2).split(",") |
| | | ] |
| | | return f"{match.group(1)}{', '.join(columns)}{match.group(3)}" |
| | | |
| | | @staticmethod |
| | | def inserts(table_name: str, script_content: str) -> Generator: |
| | | PREFIX = f"INSERT INTO `{table_name}`" |
| | |
| | | Generator[str]: create index è¯å¥ |
| | | """ |
| | | |
| | | def generate_columns(columns): |
| | | keys = [ |
| | | f"{col['name'].lower()}{' ' + col['order'].lower() if col['order'] != 'ASC' else ''}" |
| | | for col in columns[0] |
| | | ] |
| | | return ", ".join(keys) |
| | | |
| | | for no, index in enumerate(ddl["index"], 1): |
| | | columns = generate_columns(index["columns"]) |
| | | for no, index in enumerate(ddl.get("index", []), 1): |
| | | columns = ", ".join(Convertor.index_columns(index.get("columns", []))) |
| | | if not columns: |
| | | continue |
| | | table_name = ddl["table_name"].lower() |
| | | yield f"CREATE INDEX idx_{table_name}_{no:02d} ON {table_name} ({columns})" |
| | | |
| | | @staticmethod |
| | | def index_columns(columns) -> list: |
| | | """å
¼å®¹ simple-ddl-parser ä¸åçæ¬çç´¢å¼åç»æã""" |
| | | |
| | | keys = [] |
| | | |
| | | def append(name, order="ASC"): |
| | | if not name: |
| | | return |
| | | column_name = str(name).strip("`").lower() |
| | | column_order = str(order or "ASC").upper() |
| | | if column_order == "DESC": |
| | | keys.append(f"{column_name} desc") |
| | | else: |
| | | keys.append(column_name) |
| | | |
| | | def visit(value): |
| | | # æ®éç´¢å¼å¸¸è§ç»æï¼[[{'name': 'user_id', 'order': 'ASC'}]] |
| | | if isinstance(value, (list, tuple)): |
| | | for item in value: |
| | | visit(item) |
| | | return |
| | | if isinstance(value, dict): |
| | | name = value.get("name") |
| | | if isinstance(name, (dict, list, tuple)): |
| | | visit(name) |
| | | return |
| | | append(name, value.get("order", "ASC")) |
| | | return |
| | | # å¯ä¸ç´¢å¼å¨é¨åçæ¬ä¸ä¼è¢«è§£ææ ['mobile', 'ASC', 'tenant_id', 'ASC']ã |
| | | if isinstance(value, str): |
| | | token = value.strip("`") |
| | | order = token.upper() |
| | | if order in ("ASC", "DESC"): |
| | | if order == "DESC" and keys and not keys[-1].endswith(" desc"): |
| | | keys[-1] = f"{keys[-1]} desc" |
| | | return |
| | | append(token) |
| | | |
| | | visit(columns) |
| | | return keys |
| | | |
| | | @staticmethod |
| | | def unique_index(ddl: Dict) -> Generator: |
| | |
| | | for uk in uk_list: |
| | | table_name = ddl["table_name"] |
| | | uk_name = uk["constraint_name"] |
| | | uk_columns = uk["columns"] |
| | | uk_columns = Convertor.index_columns(uk["columns"]) |
| | | if not uk_columns: |
| | | continue |
| | | yield table_name, uk_name, uk_columns |
| | | |
| | | @staticmethod |
| | |
| | | ) |
| | | nullable = "NULL" if col["nullable"] else "NOT NULL" |
| | | default = f"DEFAULT {col['default']}" if col["default"] is not None else "" |
| | | return f"{name} {full_type} {nullable} {default}" |
| | | return f"{self.escape_column_name(name)} {full_type} {nullable} {default}" |
| | | |
| | | table_name = ddl["table_name"].lower() |
| | | columns = [f"{_generate_column(col).strip()}" for col in ddl["columns"]] |
| | |
| | | for column in table_ddl["columns"]: |
| | | table_comment = column["comment"] |
| | | script += ( |
| | | f"COMMENT ON COLUMN {table_ddl['table_name']}.{column['name']} IS '{table_comment}';" |
| | | f"COMMENT ON COLUMN {table_ddl['table_name']}.{self.escape_column_name(column['name'])} IS '{table_comment}';" |
| | | + "\n" |
| | | ) |
| | | |
| | |
| | | """çæ insert è¯å¥ï¼ä»¥åæ ¹æ®æåç insert id+1 çæ Sequence""" |
| | | |
| | | inserts = list(Convertor.inserts(table_name, self.content)) |
| | | inserts = [self.escape_insert_columns(s) for s in inserts] |
| | | # è½¬æ¢ MySQL å符串转ä¹ä¸º PostgreSQL æ ¼å¼ï¼\\ -> \ï¼\' -> '' |
| | | inserts = [re.sub(r"\\\\|\\'", lambda m: "\\" if m.group() == "\\\\" else "''", s) for s in inserts] |
| | | ## çæ insert èæ¬ |
| | |
| | | |
| | | |
| | | class OracleConvertor(Convertor): |
| | | reserved_column_names = {"level", "size"} |
| | | |
| | | def __init__(self, src): |
| | | super().__init__(src, "Oracle") |
| | | |
| | |
| | | # Oracleç INSERT '' ä¸è½éè¿NOT NULLæ ¡éªï¼å æ¤å¯¹æåç±»ååæ®µè¦å为 NULL |
| | | nullable = "NULL" if type in ("varchar", "text", "longtext") else nullable |
| | | default = f"DEFAULT {col['default']}" if col["default"] is not None else "" |
| | | # Oracle ä¸ size ä¸è½ä½ä¸ºå段å |
| | | field_name = '"size"' if name == "size" else name |
| | | # Oracle DEFAULT å®ä¹å¨ NULLABLE ä¹å |
| | | return f"{field_name} {full_type} {default} {nullable}" |
| | | return f"{self.escape_column_name(name)} {full_type} {default} {nullable}" |
| | | |
| | | table_name = ddl["table_name"].lower() |
| | | columns = [f"{generate_column(col).strip()}" for col in ddl["columns"]] |
| | |
| | | for column in table_ddl["columns"]: |
| | | table_comment = column["comment"] |
| | | script += ( |
| | | f"COMMENT ON COLUMN {table_ddl['table_name']}.{column['name']} IS '{table_comment}';" |
| | | f"COMMENT ON COLUMN {table_ddl['table_name']}.{self.escape_column_name(column['name'])} IS '{table_comment}';" |
| | | + "\n" |
| | | ) |
| | | |
| | |
| | | """æ·è´ INSERT è¯å¥""" |
| | | inserts = [] |
| | | for insert_script in Convertor.inserts(table_name, self.content): |
| | | insert_script = self.escape_insert_columns(insert_script) |
| | | # å¯¹æ¥ææ°æ®æ·»å TO_DATE è½¬æ¢ |
| | | insert_script = re.sub( |
| | | r"('\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}')", |
| | |
| | | type = type.lower() |
| | | |
| | | if type == "varchar": |
| | | return f"varchar({size})" |
| | | # MySQL varchar(n) is character-oriented. DM8 may treat varchar(n) |
| | | # as bytes, so use explicit CHAR semantics for generated scripts. |
| | | return f"varchar({size} char)" |
| | | if type in ("int", "int unsigned"): |
| | | return "int" |
| | | if type in ("bigint", "bigint unsigned"): |
| | |
| | | |
| | | |
| | | class KingbaseConvertor(PostgreSQLConvertor): |
| | | reserved_column_names = {"level"} |
| | | |
| | | def __init__(self, src): |
| | | super().__init__(src) |
| | | self.db_type = "Kingbase" |
| | |
| | | if full_type == "text": |
| | | nullable = "NULL" |
| | | default = f"DEFAULT {col['default']}" if col["default"] is not None else "" |
| | | return f"{name} {full_type} {nullable} {default}" |
| | | return f"{self.escape_column_name(name)} {full_type} {nullable} {default}" |
| | | |
| | | table_name = ddl["table_name"].lower() |
| | | columns = [f"{_generate_column(col).strip()}" for col in ddl["columns"]] |
| | |
| | | |
| | | |
| | | class OpengaussConvertor(KingbaseConvertor): |
| | | reserved_column_names = set() |
| | | |
| | | def __init__(self, src): |
| | | super().__init__(src) |
| | | self.db_type = "OpenGauss" |
| | | |
| | | |
| | | class HighGoConvertor(PostgreSQLConvertor): |
| | | def __init__(self, src): |
| | | super().__init__(src) |
| | | self.db_type = "HighGo" |
| | | |
| | | |
| | | def main(): |
| | |
| | | "type", |
| | | type=str, |
| | | help="ç®æ æ°æ®åºç±»å", |
| | | choices=["postgres", "oracle", "sqlserver", "dm8", "kingbase", "opengauss"], |
| | | choices=["postgres", "oracle", "sqlserver", "dm8", "kingbase", "opengauss", "highgo"], |
| | | ) |
| | | parser.add_argument( |
| | | "path", |
| | | type=str, |
| | | help="æºæ°æ®åºèæ¬è·¯å¾", |
| | | nargs="?", |
| | | default="../mysql/ruoyi-vue-pro.sql" |
| | | ) |
| | | args = parser.parse_args() |
| | |
| | | convertor = KingbaseConvertor(sql_file) |
| | | elif args.type == "opengauss": |
| | | convertor = OpengaussConvertor(sql_file) |
| | | elif args.type == "highgo": |
| | | convertor = HighGoConvertor(sql_file) |
| | | else: |
| | | raise NotImplementedError(f"䏿¯æç®æ æ°æ®åºç±»å: {args.type}") |
| | | |
| | |
| | | dm8: { } |
| | | kingbase: { } |
| | | opengauss: { } |
| | | highgo: { } |
| | | |
| | | services: |
| | | mysql: |
| | |
| | | volumes: |
| | | - opengauss:/var/lib/opengauss |
| | | - ../opengauss/ruoyi-vue-pro.sql:/tmp/schema.sql:ro |
| | | # docker compose exec opengauss bash -c '/usr/local/opengauss/bin/gsql -U $GS_USERNAME -W $GS_PASSWORD -d postgres -f /tmp/schema.sql' |
| | | # docker compose exec opengauss bash -c '/usr/local/opengauss/bin/gsql -U $GS_USERNAME -W $GS_PASSWORD -d postgres -f /tmp/schema.sql' |
| | | |
| | | highgo: |
| | | # 使ç¨çé«å®æ¹æä¾ç Docker éåï¼å è½½åæææ¬å°æ ç¾ï¼ |
| | | # docker tag <image>:<tag> highgo:local |
| | | image: highgo:local |
| | | restart: unless-stopped |
| | | ports: |
| | | - "5866:5866" |
| | | volumes: |
| | | - highgo:/home/highgo/hgdb/data |
| | | - ../highgo/quartz.sql:/tmp/quartz.sql:ro |
| | | - ../highgo/ruoyi-vue-pro.sql:/tmp/schema.sql:ro |
| | |
| | | <url>https://github.com/YunaiV/ruoyi-vue-pro</url> |
| | | |
| | | <properties> |
| | | <revision>2026.04-SNAPSHOT</revision> |
| | | <revision>2026.06-jdk25-SNAPSHOT</revision> |
| | | <flatten-maven-plugin.version>1.7.2</flatten-maven-plugin.version> |
| | | <!-- ç»ä¸ä¾èµç®¡ç --> |
| | | <spring.boot.version>4.0.6</spring.boot.version> |
| | | <spring.boot.version>4.1.0</spring.boot.version> |
| | | <!-- Web ç¸å
³ --> |
| | | <springdoc.version>3.0.3</springdoc.version> |
| | | <knife4j.version>4.5.0</knife4j.version> |
| | |
| | | <mybatis-plus-join.version>1.5.7</mybatis-plus-join.version> |
| | | <dynamic-datasource.version>4.5.0</dynamic-datasource.version> |
| | | <easy-trans.version>3.1.5</easy-trans.version> |
| | | <redisson.version>4.3.1</redisson.version> |
| | | <redisson.version>4.6.1</redisson.version> |
| | | <dm8.jdbc.version>8.1.3.140</dm8.jdbc.version> |
| | | <kingbase.jdbc.version>9.0.1.jre7</kingbase.jdbc.version> |
| | | <opengauss.jdbc.version>7.0.0-RC3-og</opengauss.jdbc.version> |
| | | <taos.version>3.8.3</taos.version> |
| | | <taos.version>3.8.4</taos.version> |
| | | <!-- æ¶æ¯éå --> |
| | | <rocketmq-spring.version>2.3.5</rocketmq-spring.version> |
| | | <rocketmq-spring.version>2.3.6</rocketmq-spring.version> |
| | | <!-- æå¡ä¿éç¸å
³ --> |
| | | <lock4j.version>2.2.7</lock4j.version> |
| | | <!-- çæ§ç¸å
³ --> |
| | |
| | | <opentracing.version>0.33.0</opentracing.version> |
| | | <!-- Test æµè¯ç¸å
³ --> |
| | | <podam.version>8.0.2.RELEASE</podam.version> |
| | | <jedis-mock.version>1.1.12</jedis-mock.version> |
| | | <jedis-mock.version>1.1.15</jedis-mock.version> |
| | | <mockito-inline.version>5.2.0</mockito-inline.version> |
| | | <!-- Bpm 工使µç¸å
³ --> |
| | | <flowable.version>7.2.0</flowable.version> |
| | | <flowable.version>8.0.0</flowable.version> |
| | | <!-- å·¥å
·ç±»ç¸å
³ --> |
| | | <anji-plus-captcha.version>1.4.0</anji-plus-captcha.version> |
| | | <jsoup.version>1.22.2</jsoup.version> |
| | | <sensitive-word.version>0.29.5</sensitive-word.version> |
| | | <pinyin4j.version>2.5.1</pinyin4j.version> |
| | | <lombok.version>1.18.46</lombok.version> |
| | | <mapstruct.version>1.6.3</mapstruct.version> |
| | | <hutool-5.version>5.8.44</hutool-5.version> |
| | | <hutool-5.version>5.8.46</hutool-5.version> |
| | | <hutool-6.version>6.0.0-M22</hutool-6.version> |
| | | <fastexcel.version>1.3.0</fastexcel.version> |
| | | <velocity.version>2.4.1</velocity.version> |
| | | <fastjson.version>1.2.83</fastjson.version> |
| | | <fastjson2.version>2.0.62</fastjson2.version> |
| | | <guava.version>33.6.0-jre</guava.version> |
| | | <transmittable-thread-local.version>2.14.5</transmittable-thread-local.version> |
| | | <commons-net.version>3.13.0</commons-net.version> |
| | | <commons-lang3.version>3.20.0</commons-lang3.version> |
| | | <jsch.version>2.28.2</jsch.version> |
| | | <tika-core.version>3.3.0</tika-core.version> |
| | | <jsch.version>2.28.3</jsch.version> |
| | | <tika-core.version>3.3.1</tika-core.version> |
| | | <ip2region.version>2.7.0</ip2region.version> |
| | | <bizlog-sdk.version>3.0.6</bizlog-sdk.version> |
| | | <netty.version>4.2.12.Final</netty.version> |
| | | <netty.version>4.2.15.Final</netty.version> |
| | | <mqtt.version>1.2.5</mqtt.version> |
| | | <vertx.version>4.5.26</vertx.version> |
| | | <okhttp.version>4.12.0</okhttp.version> |
| | | <californium.version>3.14.0</californium.version> |
| | | <j2mod.version>3.3.0</j2mod.version> |
| | | <!-- 䏿¹äºæå¡ç¸å
³ --> |
| | | <awssdk.version>2.44.0</awssdk.version> |
| | | <awssdk.version>2.46.17</awssdk.version> |
| | | <justauth.version>1.16.7</justauth.version> |
| | | <justauth-starter.version>1.4.0</justauth-starter.version> |
| | | <jimureport.version>2.3.2</jimureport.version> |
| | | <jimureport.version>2.3.4</jimureport.version> |
| | | <jimubi.version>2.3.2</jimubi.version> |
| | | <weixin-java.version>4.8.2-20260501.180637</weixin-java.version> |
| | | <alipay-sdk-java.version>4.40.771.ALL</alipay-sdk-java.version> |
| | | <weixin-java.version>4.8.4-20260623.211820</weixin-java.version> |
| | | <bouncycastle.version>1.80</bouncycastle.version> |
| | | <alipay-sdk-java.version>4.40.865.ALL</alipay-sdk-java.version> |
| | | </properties> |
| | | |
| | | <dependencyManagement> |
| | |
| | | <artifactId>fastjson</artifactId> |
| | | <version>${fastjson.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>com.alibaba.fastjson2</groupId> |
| | | <artifactId>fastjson2</artifactId> |
| | | <version>${fastjson2.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>com.google.guava</groupId> |
| | |
| | | <groupId>org.jsoup</groupId> |
| | | <artifactId>jsoup</artifactId> |
| | | <version>${jsoup.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>com.github.houbb</groupId> |
| | | <artifactId>sensitive-word</artifactId> <!-- ææè¯æ£æµï¼trie æ 髿å¹é
--> |
| | | <version>${sensitive-word.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>com.belerweb</groupId> |
| | | <artifactId>pinyin4j</artifactId> <!-- æ±å转æ¼é³ï¼ä½ä¸º hutool PinyinUtil çåºå±å¼æ --> |
| | | <version>${pinyin4j.version}</version> |
| | | </dependency> |
| | | |
| | | <!-- Vert.x --> |
| | |
| | | </exclusions> |
| | | </dependency> |
| | | |
| | | <!-- éå® weixin-java ä¼ éä¾èµï¼é¿å
Maven çæ¬èå´èªå¨åçº§å° 1.80.2 å Fat Jar å¯å¨å¤±è´¥ã |
| | | åé¦ï¼https://t.zsxq.com/pCVBo --> |
| | | <dependency> |
| | | <groupId>org.bouncycastle</groupId> |
| | | <artifactId>bcprov-jdk18on</artifactId> |
| | | <version>${bouncycastle.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.bouncycastle</groupId> |
| | | <artifactId>bcutil-jdk18on</artifactId> |
| | | <version>${bouncycastle.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.bouncycastle</groupId> |
| | | <artifactId>bcpkix-jdk18on</artifactId> |
| | | <version>${bouncycastle.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>com.github.binarywang</groupId> |
| | | <artifactId>weixin-java-pay</artifactId> |
| | |
| | | return from.stream().filter(filter).map(func).filter(Objects::nonNull).collect(Collectors.toSet()); |
| | | } |
| | | |
| | | public static <T, U> Set<U> convertLinkedSet(Collection<T> from, Function<T, U> func) { |
| | | if (CollUtil.isEmpty(from)) { |
| | | return new LinkedHashSet<>(); |
| | | } |
| | | return from.stream().map(func).filter(Objects::nonNull) |
| | | .collect(Collectors.toCollection(LinkedHashSet::new)); |
| | | } |
| | | |
| | | public static <T, U> Set<U> convertLinkedSet(Collection<T> from, Function<T, U> func, Predicate<T> filter) { |
| | | if (CollUtil.isEmpty(from)) { |
| | | return new LinkedHashSet<>(); |
| | | } |
| | | return from.stream().filter(filter).map(func).filter(Objects::nonNull) |
| | | .collect(Collectors.toCollection(LinkedHashSet::new)); |
| | | } |
| | | |
| | | public static <T, K> Map<K, T> convertMapByFilter(Collection<T> from, Predicate<T> filter, Function<T, K> keyFunc) { |
| | | if (CollUtil.isEmpty(from)) { |
| | | return new HashMap<>(); |
| | |
| | | return false; |
| | | } |
| | | |
| | | /** |
| | | * æåå
ç´ head ä¸éå tail åå¹¶ææ° Listï¼head å¨åï¼tail 顺åºä¿çï¼ |
| | | */ |
| | | public static <T> List<T> of(T head, Collection<T> tail) { |
| | | List<T> list = new ArrayList<>(); |
| | | list.add(head); |
| | | CollUtil.addAll(list, tail); |
| | | return list; |
| | | } |
| | | |
| | | } |
| | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.date.DatePattern; |
| | | import cn.hutool.core.date.LocalDateTimeUtil; |
| | | import cn.hutool.core.date.TemporalAccessorUtil; |
| | | import cn.hutool.core.lang.Assert; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import cn.iocoder.yudao.framework.common.enums.DateIntervalEnum; |
| | |
| | | import java.time.temporal.TemporalAdjusters; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.TimeZone; |
| | | |
| | | import static cn.hutool.core.date.DatePattern.*; |
| | | |
| | |
| | | public static LocalDateTime EMPTY = buildTime(1970, 1, 1); |
| | | |
| | | public static DateTimeFormatter UTC_MS_WITH_XXX_OFFSET_FORMATTER = createFormatter(UTC_MS_WITH_XXX_OFFSET_PATTERN); |
| | | |
| | | /** |
| | | * é»è®¤æ¶åº |
| | | */ |
| | | private static final ZoneId DEFAULT_ZONE_ID = TimeZone.getTimeZone(DateUtils.TIME_ZONE_DEFAULT).toZoneId(); |
| | | |
| | | /** |
| | | * è§£ææ¶é´ |
| | |
| | | |
| | | public static boolean afterNow(LocalDateTime date) { |
| | | return date.isAfter(LocalDateTime.now()); |
| | | } |
| | | |
| | | /** |
| | | * å° Unix ç§æ¶é´æ³è½¬æ¢ä¸ºé»è®¤æ¶åºçæ¬å°æ¶é´ |
| | | * |
| | | * @param epochSecond Unix ç§æ¶é´æ³ |
| | | * @return æ¬å°æ¶é´ |
| | | */ |
| | | public static LocalDateTime ofEpochSecond(long epochSecond) { |
| | | return ofEpochSecond(epochSecond, DEFAULT_ZONE_ID); |
| | | } |
| | | |
| | | /** |
| | | * å° Unix ç§æ¶é´æ³è½¬æ¢ä¸ºæå®æ¶åºçæ¬å°æ¶é´ |
| | | * |
| | | * @param epochSecond Unix ç§æ¶é´æ³ |
| | | * @param zoneId æ¶åºç¼å· |
| | | * @return æ¬å°æ¶é´ |
| | | */ |
| | | public static LocalDateTime ofEpochSecond(long epochSecond, ZoneId zoneId) { |
| | | return LocalDateTime.ofInstant(Instant.ofEpochSecond(epochSecond), zoneId); |
| | | } |
| | | |
| | | /** |
| | |
| | | return LocalDateTime.now().with(TemporalAdjusters.firstDayOfYear()).with(LocalTime.MIN); |
| | | } |
| | | |
| | | /** |
| | | * è·åæè¿ N 天ç 0 ç¹æ¶å»åºåï¼ååºï¼å«ä»å¤©ï¼ |
| | | * <p> |
| | | * ä¾ï¼getLatestDays(3) è¿å [å天 00:00, æ¨å¤© 00:00, ä»å¤© 00:00] |
| | | * |
| | | * @param days 天æ°ï¼å«ä»å¤©ï¼ |
| | | * @return ååºç LocalDateTime å表 |
| | | */ |
| | | public static List<LocalDateTime> getLatestDays(int days) { |
| | | LocalDateTime today = getToday(); |
| | | List<LocalDateTime> dates = new ArrayList<>(days); |
| | | for (int i = days - 1; i >= 0; i--) { |
| | | dates.add(today.minusDays(i)); |
| | | } |
| | | return dates; |
| | | } |
| | | |
| | | public static List<LocalDateTime[]> getDateRangeList(LocalDateTime startTime, |
| | | LocalDateTime endTime, |
| | | Integer interval) { |
| | |
| | | * @throws DateTimeException å¦æè½¬æ¢è¿ç¨ä¸åçæ¶é´è¶
åºèå´æå
¶ä»æ¶é´å¤çå¼å¸¸ |
| | | */ |
| | | public static Long toEpochSecond(LocalDateTime sourceDateTime) { |
| | | return TemporalAccessorUtil.toInstant(sourceDateTime).getEpochSecond(); |
| | | return toEpochSecond(sourceDateTime, DEFAULT_ZONE_ID); |
| | | } |
| | | |
| | | /** |
| | | * å°ç»å®ç {@link LocalDateTime} ææå®æ¶åºè½¬æ¢ä¸ºèª Unix 纪å
æ¶é´ï¼1970-01-01T00:00:00Zï¼ä»¥æ¥çç§æ°ã |
| | | * |
| | | * @param sourceDateTime éè¦è½¬æ¢çæ¬å°æ¥ææ¶é´ï¼ä¸è½ä¸ºç©º |
| | | * @param zoneId æ¶åºç¼å· |
| | | * @return èª 1970-01-01T00:00:00Z èµ·çç§æ°ï¼epoch secondï¼ |
| | | */ |
| | | public static Long toEpochSecond(LocalDateTime sourceDateTime, ZoneId zoneId) { |
| | | return sourceDateTime.atZone(zoneId).toEpochSecond(); |
| | | } |
| | | |
| | | } |
| | |
| | | import org.springframework.util.StringUtils; |
| | | import org.springframework.web.util.UriComponents; |
| | | import org.springframework.web.util.UriComponentsBuilder; |
| | | import org.springframework.web.util.UriUtils; |
| | | |
| | | import java.net.URI; |
| | | import java.net.URLDecoder; |
| | |
| | | * @return è§£ç åçè·¯å¾ |
| | | */ |
| | | public static String decodeUrlPath(String path) { |
| | | if (StrUtil.isEmpty(path)) { |
| | | return path; |
| | | } |
| | | // å
å° + æ¿æ¢ä¸º %2Bï¼é¿å
被 URLDecoder è§£ç ä¸ºç©ºæ ¼ |
| | | String encoded = path.replace("+", "%2B"); |
| | | return URLDecoder.decode(encoded, StandardCharsets.UTF_8); |
| | | } |
| | | |
| | | /** |
| | | * ç¼ç URL è·¯å¾ï¼æè·¯å¾æ®µç¼ç ï¼ä¿ç / åé符 |
| | | * |
| | | * @param path URL è·¯å¾ï¼ä¾å¦ 20250602/xxx.pdf |
| | | * @return ç¼ç åçè·¯å¾ |
| | | */ |
| | | public static String encodeUrlPath(String path) { |
| | | if (StrUtil.isEmpty(path)) { |
| | | return path; |
| | | } |
| | | String[] segments = path.split(StrUtil.SLASH, -1); |
| | | StringBuilder result = new StringBuilder(path.length()); |
| | | for (int i = 0; i < segments.length; i++) { |
| | | if (i > 0) { |
| | | result.append(StrUtil.SLASH); |
| | | } |
| | | result.append(encodeUrlPathSegment(segments[i])); |
| | | } |
| | | return result.toString(); |
| | | } |
| | | |
| | | /** |
| | | * ç¼ç URL è·¯å¾æ®µ |
| | | * |
| | | * @param segment URL è·¯å¾æ®µ |
| | | * @return ç¼ç åçè·¯å¾æ®µ |
| | | */ |
| | | public static String encodeUrlPathSegment(String segment) { |
| | | return UriUtils.encodePathSegment(segment, StandardCharsets.UTF_8); |
| | | } |
| | | |
| | | public static String removeUrlPathQueryAndFragment(String path) { |
| | | if (StrUtil.isEmpty(path)) { |
| | | return path; |
| | | } |
| | | int endIndex = path.length(); |
| | | int queryIndex = path.indexOf('?'); |
| | | if (queryIndex >= 0) { |
| | | endIndex = queryIndex; |
| | | } |
| | | int fragmentIndex = path.indexOf('#'); |
| | | if (fragmentIndex >= 0 && fragmentIndex < endIndex) { |
| | | endIndex = fragmentIndex; |
| | | } |
| | | return path.substring(0, endIndex); |
| | | } |
| | | |
| | | public static String replaceUrlQuery(String url, String key, String value) { |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * WebSocket URL 忢æ HTTP URLï¼ws:// â http://ï¼wss:// â https://ï¼å
¶å®æ ¼å¼åæ ·ä¿ç |
| | | * |
| | | * @param url åå§ URL |
| | | * @return 忢åè®®åç URL |
| | | */ |
| | | public static String wsUrlToHttp(String url) { |
| | | return StrUtil.startWithIgnoreCase(url, "ws") ? "http" + url.substring(2) : url; |
| | | } |
| | | |
| | | } |
| | |
| | | import java.time.LocalDateTime; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * JSON å·¥å
·ç±» |
| | |
| | | |
| | | private static ObjectMapper buildObjectMapper() { |
| | | SimpleModule simpleModule = new SimpleModule() |
| | | // è§£å³ LocalDateTime çåºåå |
| | | .addSerializer(LocalDateTime.class, TimestampLocalDateTimeSerializer.INSTANCE) |
| | | .addDeserializer(LocalDateTime.class, TimestampLocalDateTimeDeserializer.INSTANCE); |
| | | return JsonMapper.builder() |
| | | .disable(SerializationFeature.FAIL_ON_EMPTY_BEANS) |
| | | .disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES) |
| | | // 强å¶å°æ´æ°ååºåå为 Longï¼è§£å³ Redis ç¼åååºååæ¶ Integer 转 Long çé®é¢ |
| | | .enable(DeserializationFeature.USE_LONG_FOR_INTS) |
| | | .changeDefaultPropertyInclusion(value -> JsonInclude.Value.construct(JsonInclude.Include.NON_NULL, JsonInclude.Include.NON_NULL)) |
| | | .addModule(simpleModule) |
| | | .build(); |
| | |
| | | } |
| | | |
| | | /** |
| | | * è§£æ JSON å符串æ Mapï¼ç©ºå符串æè§£æå¤±è´¥è¿å null |
| | | * |
| | | * @param text JSON å符串 |
| | | * @return Map 对象 |
| | | */ |
| | | public static Map<String, Object> parseMap(String text) { |
| | | if (StrUtil.isEmpty(text)) { |
| | | return null; |
| | | } |
| | | try { |
| | | return objectMapper.readValue(text, new TypeReference<Map<String, Object>>() {}); |
| | | } catch (JacksonException e) { |
| | | return null; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * è§£æ JSON å符串ææå®ç±»åç对象ï¼å¦æè§£æå¤±è´¥ï¼åè¿å null |
| | | * |
| | | * @param text å符串 |
| | |
| | | } |
| | | } |
| | | |
| | | public static String getText(JsonNode node, String fieldName) { |
| | | if (node == null) { |
| | | return null; |
| | | } |
| | | JsonNode value = node.get(fieldName); |
| | | return value != null && !value.isNull() ? value.asText() : null; |
| | | } |
| | | |
| | | public static boolean isJson(String text) { |
| | | return JSONUtil.isTypeJSON(text); |
| | | } |
| | |
| | | import tools.jackson.core.JsonGenerator; |
| | | import tools.jackson.databind.SerializationContext; |
| | | import tools.jackson.databind.annotation.JacksonStdImpl; |
| | | import tools.jackson.databind.ser.std.StdScalarSerializer; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.math.BigInteger; |
| | | |
| | | /** |
| | | * Long åºååè§å |
| | |
| | | * @author æè¯ |
| | | */ |
| | | @JacksonStdImpl |
| | | public class NumberSerializer extends StdScalarSerializer<Number> { |
| | | public class NumberSerializer extends tools.jackson.databind.ser.jdk.NumberSerializer { |
| | | |
| | | private static final long MAX_SAFE_INTEGER = 9007199254740991L; |
| | | private static final long MIN_SAFE_INTEGER = -9007199254740991L; |
| | | |
| | | public static final NumberSerializer INSTANCE = new NumberSerializer(Number.class); |
| | | |
| | | @SuppressWarnings("unchecked") |
| | | public NumberSerializer(Class<? extends Number> rawType) { |
| | | super((Class<Number>) rawType); |
| | | super(rawType); |
| | | } |
| | | |
| | | @Override |
| | | public void serialize(Number value, JsonGenerator gen, SerializationContext serializers) throws JacksonException { |
| | | // è¶
åºèå´ åºååä½å符串 |
| | | if (value.longValue() > MIN_SAFE_INTEGER && value.longValue() < MAX_SAFE_INTEGER) { |
| | | writeNumber(value, gen); |
| | | super.serialize(value, gen, serializers); |
| | | } else { |
| | | gen.writeString(value.toString()); |
| | | } |
| | | } |
| | | |
| | | private static void writeNumber(Number value, JsonGenerator gen) throws JacksonException { |
| | | if (value instanceof BigDecimal decimal) { |
| | | gen.writeNumber(decimal); |
| | | } else if (value instanceof BigInteger integer) { |
| | | gen.writeNumber(integer); |
| | | } else if (value instanceof Double doubleValue) { |
| | | gen.writeNumber(doubleValue); |
| | | } else if (value instanceof Float floatValue) { |
| | | gen.writeNumber(floatValue); |
| | | } else if (value instanceof Long longValue) { |
| | | gen.writeNumber(longValue); |
| | | } else { |
| | | gen.writeNumber(value.intValue()); |
| | | } |
| | | } |
| | | } |
| | |
| | | import cn.hutool.core.text.StrPool; |
| | | import cn.hutool.core.util.ArrayUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import cn.hutool.extra.pinyin.PinyinUtil; |
| | | import org.aspectj.lang.JoinPoint; |
| | | |
| | | import java.util.Arrays; |
| | |
| | | } |
| | | |
| | | /** |
| | | * 转å°åæ¼é³ï¼åä¹é´ä»¥ç©ºæ ¼åéï¼ä¾¿äºè°ç¨æ¹æéæ¼æ¥ / åé¦åæ¯ / æ¼é³æç´¢ |
| | | * |
| | | * ä¾ï¼ãèå¼ ãâ "lao zhang"ããZhangSanãâ "zhangsan" |
| | | * è±æ / æ°å / 符å·åæ ·è¿åï¼ç©ºå¼è¿å null |
| | | * |
| | | * 注æï¼åºå±ä¾èµ hutool-extra ç {@link PinyinUtil}ï¼éè¦ä¸å¡æ¨¡åèªè¡å¼å
¥æ¼é³å¼æä¾èµ |
| | | * ï¼pinyin4j / TinyPinyin / Bopomofo4j ä»»éå
¶ä¸ï¼ï¼å¦åè¿è¡æ¶ä¼æ NoClassDefFoundError |
| | | * |
| | | * @param str å符串 |
| | | * @return æ¼é³ä¸²ï¼ä¿çç©ºæ ¼åéï¼ |
| | | */ |
| | | public static String toPinyin(String str) { |
| | | if (StrUtil.isBlank(str)) { |
| | | return null; |
| | | } |
| | | return PinyinUtil.getPinyin(str); |
| | | } |
| | | |
| | | /** |
| | | * æ¼æ¥æ¹æ³çåæ° |
| | | * |
| | | * ç¹æ®ï¼æé¤ä¸äºæ æ³åºååçåæ°ï¼å¦ ServletRequestãServletResponseãMultipartFile |
| | |
| | | public class HttpUtilsTest { |
| | | |
| | | @Test |
| | | public void testEncodeUrlPath() { |
| | | // åå¤åæ° |
| | | String path = "avatar/䏿 100%+æä»¶.jpg"; |
| | | |
| | | // è°ç¨ |
| | | String result = HttpUtils.encodeUrlPath(path); |
| | | |
| | | // æè¨ |
| | | assertEquals("avatar/%E4%B8%AD%E6%96%87%20100%25+%E6%96%87%E4%BB%B6.jpg", result); |
| | | } |
| | | |
| | | @Test |
| | | public void testDecodeUrlPath() { |
| | | // åå¤åæ°ï¼+ æ¯è·¯å¾å符ï¼ä¸åºè¯¥æ query parameter è¯ä¹è§£ç ä¸ºç©ºæ ¼ |
| | | String path = "avatar/%E4%B8%AD%E6%96%87%20100%25+%E6%96%87%E4%BB%B6.jpg"; |
| | | |
| | | // è°ç¨ |
| | | String result = HttpUtils.decodeUrlPath(path); |
| | | |
| | | // æè¨ |
| | | assertEquals("avatar/䏿 100%+æä»¶.jpg", result); |
| | | } |
| | | |
| | | @Test |
| | | public void testRemoveUrlPathQueryAndFragment() { |
| | | assertEquals("avatar/test.jpg", HttpUtils.removeUrlPathQueryAndFragment("avatar/test.jpg?token=1#preview")); |
| | | assertEquals("avatar/test.jpg", HttpUtils.removeUrlPathQueryAndFragment("avatar/test.jpg#preview?token=1")); |
| | | } |
| | | |
| | | @Test |
| | | public void testReplaceUrlQuery_replace() { |
| | | // åå¤åæ° |
| | | String url = "https://www.iocoder.cn/path?a=1&b=2"; |
| | |
| | | import org.springframework.boot.web.servlet.FilterRegistrationBean; |
| | | import org.springframework.context.ApplicationContext; |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.context.annotation.Configuration; |
| | | import org.springframework.context.annotation.Primary; |
| | | import org.springframework.data.redis.cache.BatchStrategies; |
| | | import org.springframework.data.redis.cache.RedisCacheConfiguration; |
| | |
| | | import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; |
| | | import org.springframework.web.servlet.mvc.method.RequestMappingInfo; |
| | | import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping; |
| | | import org.springframework.web.util.pattern.PathPattern; |
| | | |
| | | import java.util.*; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | |
| | | @AutoConfiguration |
| | | @ConditionalOnProperty(prefix = "yudao.tenant", value = "enable", matchIfMissing = true) // å
è®¸ä½¿ç¨ yudao.tenant.enable=false ç¦ç¨å¤ç§æ· |
| | |
| | | * |
| | | * @return 忽ç¥ç§æ·ç URL éå |
| | | */ |
| | | @SuppressWarnings("removal") |
| | | private Set<String> getTenantIgnoreUrls() { |
| | | Set<String> ignoreUrls = new HashSet<>(); |
| | | // è·å¾æ¥å£å¯¹åºç HandlerMethod éå |
| | |
| | | continue; |
| | | } |
| | | // æ·»å å°å¿½ç¥ç URL ä¸ |
| | | ignoreUrls.addAll(entry.getKey().getPatternValues()); |
| | | if (entry.getKey().getPatternsCondition() != null) { |
| | | ignoreUrls.addAll(entry.getKey().getPatternsCondition().getPatterns()); |
| | | } |
| | | if (entry.getKey().getPathPatternsCondition() != null) { |
| | | ignoreUrls.addAll( |
| | | convertList(entry.getKey().getPathPatternsCondition().getPatterns(), PathPattern::getPatternString)); |
| | | } |
| | | } |
| | | return ignoreUrls; |
| | | } |
| | | |
| | | // ========== MQ ========== |
| | | |
| | | @Bean |
| | | public TenantRedisMessageInterceptor tenantRedisMessageInterceptor() { |
| | | return new TenantRedisMessageInterceptor(); |
| | | @Configuration(proxyBeanMethods = false) |
| | | @ConditionalOnClass(name = "cn.iocoder.yudao.framework.mq.redis.core.interceptor.RedisMessageInterceptor") |
| | | public static class TenantRedisMQConfiguration { |
| | | |
| | | @Bean |
| | | public TenantRedisMessageInterceptor tenantRedisMessageInterceptor() { |
| | | return new TenantRedisMessageInterceptor(); |
| | | } |
| | | |
| | | } |
| | | |
| | | @Bean |
| | | @Configuration(proxyBeanMethods = false) |
| | | @ConditionalOnClass(name = "org.springframework.amqp.rabbit.core.RabbitTemplate") |
| | | public TenantRabbitMQInitializer tenantRabbitMQInitializer() { |
| | | return new TenantRabbitMQInitializer(); |
| | | public static class TenantRabbitMQConfiguration { |
| | | |
| | | @Bean |
| | | public TenantRabbitMQInitializer tenantRabbitMQInitializer() { |
| | | return new TenantRabbitMQInitializer(); |
| | | } |
| | | |
| | | } |
| | | |
| | | @Bean |
| | | @Configuration(proxyBeanMethods = false) |
| | | @ConditionalOnClass(name = "org.apache.rocketmq.spring.core.RocketMQTemplate") |
| | | public TenantRocketMQInitializer tenantRocketMQInitializer() { |
| | | return new TenantRocketMQInitializer(); |
| | | } |
| | | public static class TenantRocketMQConfiguration { |
| | | |
| | | // ========== Job ========== |
| | | @Bean |
| | | public TenantRocketMQInitializer tenantRocketMQInitializer() { |
| | | return new TenantRocketMQInitializer(); |
| | | } |
| | | |
| | | @Bean |
| | | public TenantJobAspect tenantJobAspect(TenantFrameworkService tenantFrameworkService) { |
| | | return new TenantJobAspect(tenantFrameworkService); |
| | | } |
| | | |
| | | // ========== Redis ========== |
| | |
| | | RedisCacheWriter cacheWriter = RedisCacheWriter.nonLockingRedisCacheWriter(connectionFactory, |
| | | BatchStrategies.scan(yudaoCacheProperties.getRedisScanBatchSize())); |
| | | // å建 TenantRedisCacheManager 对象 |
| | | return new TenantRedisCacheManager(cacheWriter, redisCacheConfiguration, tenantProperties.getIgnoreCaches()); |
| | | TenantRedisCacheManager cacheManager = new TenantRedisCacheManager(cacheWriter, redisCacheConfiguration, |
| | | tenantProperties.getIgnoreCaches()); |
| | | // å¼å¯äºå¡æç¥ï¼@Transactional æ¹æ³å
ç @CacheEvict / @CachePut èªå¨å»¶è¿å° afterCommitï¼ |
| | | // é¿å
äºå¡æªæäº¤å°±æ¸
ç¼å被并å读穿åèå¼ï¼æ äºå¡æ¶ç«å³çæï¼è¡ä¸ºä¸å |
| | | cacheManager.setTransactionAware(true); |
| | | return cacheManager; |
| | | } |
| | | |
| | | // ========== Job ========== |
| | | |
| | | @Configuration(proxyBeanMethods = false) |
| | | @ConditionalOnClass(name = "cn.iocoder.yudao.framework.quartz.core.handler.JobHandler") |
| | | public static class TenantJobConfiguration { |
| | | |
| | | @Bean |
| | | public TenantJobAspect tenantJobAspect(TenantFrameworkService tenantFrameworkService) { |
| | | return new TenantJobAspect(tenantFrameworkService); |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | |
| | | import cn.iocoder.yudao.framework.redis.config.YudaoRedisAutoConfiguration; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.redisson.api.RedissonClient; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.boot.autoconfigure.AutoConfiguration; |
| | | import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; |
| | | import org.springframework.context.annotation.Bean; |
| | |
| | | public RedisPendingMessageResendJob redisPendingMessageResendJob(List<AbstractRedisStreamMessageListener<?>> listeners, |
| | | RedisMQTemplate redisTemplate, |
| | | RedissonClient redissonClient) { |
| | | return new RedisPendingMessageResendJob(listeners, redisTemplate, redissonClient); |
| | | return new RedisPendingMessageResendJob(listeners, redisTemplate, redissonClient, |
| | | RedisPendingMessageResendJob.DEFAULT_RESEND_LOCK_KEY); |
| | | } |
| | | |
| | | /** |
| | |
| | | public RedisStreamMessageCleanupJob redisStreamMessageCleanupJob(List<AbstractRedisStreamMessageListener<?>> listeners, |
| | | RedisMQTemplate redisTemplate, |
| | | RedissonClient redissonClient) { |
| | | return new RedisStreamMessageCleanupJob(listeners, redisTemplate, redissonClient); |
| | | return new RedisStreamMessageCleanupJob(listeners, redisTemplate, redissonClient, |
| | | RedisStreamMessageCleanupJob.DEFAULT_CLEANUP_LOCK_KEY); |
| | | } |
| | | |
| | | /** |
| | |
| | | @AllArgsConstructor |
| | | public class RedisPendingMessageResendJob { |
| | | |
| | | private static final String LOCK_KEY = "redis:stream:pending-message-resend:lock"; |
| | | public static final String DEFAULT_RESEND_LOCK_KEY = "redis:stream:pending-message-resend:lock"; |
| | | |
| | | public static final String IOT_RESEND_LOCK_KEY = "redis:stream:pending-message-resend:lock:iot"; |
| | | |
| | | /** |
| | | * æ¶æ¯è¶
æ¶æ¶é´ï¼é»è®¤ 5 åé |
| | |
| | | private final List<AbstractRedisStreamMessageListener<?>> listeners; |
| | | private final RedisMQTemplate redisTemplate; |
| | | private final RedissonClient redissonClient; |
| | | private final String resendLockKey; |
| | | |
| | | /** |
| | | * ä¸åéæ§è¡ä¸æ¬¡,è¿ééæ©æ¯åéç 35 ç§æ§è¡ï¼æ¯ä¸ºäºé¿å
æ´ç¹ä»»å¡è¿å¤çé®é¢ |
| | | */ |
| | | @Scheduled(cron = "35 * * * * ?") |
| | | public void messageResend() { |
| | | RLock lock = redissonClient.getLock(LOCK_KEY); |
| | | // å°è¯å é |
| | | RLock lock = redissonClient.getLock(resendLockKey); |
| | | if (lock.tryLock()) { |
| | | try { |
| | | execute(); |
| | | } catch (Exception ex) { |
| | | log.error("[messageResend][æ§è¡å¼å¸¸]", ex); |
| | | log.error("[messageResend][æ§è¡å¼å¸¸][lockKey={}]", resendLockKey, ex); |
| | | } finally { |
| | | lock.unlock(); |
| | | if (lock.isHeldByCurrentThread()) { |
| | | lock.unlock(); |
| | | } |
| | | } |
| | | } else { |
| | | log.debug("[messageResend][æªè·åå°éï¼è·³è¿æ¬è½®][lockKey={}]", resendLockKey); |
| | | } |
| | | } |
| | | |
| | |
| | | @AllArgsConstructor |
| | | public class RedisStreamMessageCleanupJob { |
| | | |
| | | private static final String LOCK_KEY = "redis:stream:message-cleanup:lock"; |
| | | /** |
| | | * ä¸å¡ MQï¼Spring 容å¨å
AbstractRedisStreamMessageListenerï¼æ¸
çä»»å¡ä½¿ç¨çåå¸å¼é |
| | | */ |
| | | public static final String DEFAULT_CLEANUP_LOCK_KEY = "redis:stream:message-cleanup:lock"; |
| | | |
| | | /** |
| | | * IoT Redis æ»çº¿æ¸
çä»»å¡ä½¿ç¨çåå¸å¼éï¼é¡»ä¸ {@link #DEFAULT_CLEANUP_LOCK_KEY} åºåï¼å¦åä¼å
±æ¢ä¸æéï¼ |
| | | * å䏿¶å»åªæä¸ä¾§è½æ§è¡ XTRIMï¼å¦ä¸ä¾§ Stream å¯è½æ é积åï¼ |
| | | */ |
| | | public static final String IOT_CLEANUP_LOCK_KEY = "redis:stream:message-cleanup:lock:iot"; |
| | | |
| | | /** |
| | | * ä¿ççæ¶æ¯æ°éï¼é»è®¤ä¿çæè¿ 10000 æ¡æ¶æ¯ |
| | |
| | | private final List<AbstractRedisStreamMessageListener<?>> listeners; |
| | | private final RedisMQTemplate redisTemplate; |
| | | private final RedissonClient redissonClient; |
| | | /** |
| | | * Redisson éé®ï¼å¤ Bean æ³¨åæ¸
ç任塿¶å¿
é¡»åä¸ç¸åï¼ |
| | | */ |
| | | private final String cleanupLockKey; |
| | | |
| | | /** |
| | | * æ¯å°æ¶æ§è¡ä¸æ¬¡æ¸
çä»»å¡ |
| | | */ |
| | | @Scheduled(cron = "0 0 * * * ?") |
| | | public void cleanup() { |
| | | RLock lock = redissonClient.getLock(LOCK_KEY); |
| | | // å°è¯å é |
| | | RLock lock = redissonClient.getLock(cleanupLockKey); |
| | | if (lock.tryLock()) { |
| | | try { |
| | | execute(); |
| | | } catch (Exception ex) { |
| | | log.error("[cleanup][æ§è¡å¼å¸¸]", ex); |
| | | log.error("[cleanup][æ§è¡å¼å¸¸][lockKey={}]", cleanupLockKey, ex); |
| | | } finally { |
| | | lock.unlock(); |
| | | if (lock.isHeldByCurrentThread()) { |
| | | lock.unlock(); |
| | | } |
| | | } |
| | | } else { |
| | | log.debug("[cleanup][æªè·åå°éï¼è·³è¿æ¬è½®][lockKey={}]", cleanupLockKey); |
| | | } |
| | | } |
| | | |
| | |
| | | StreamOperations<String, Object, Object> ops = redisTemplate.getRedisTemplate().opsForStream(); |
| | | listeners.forEach(listener -> { |
| | | try { |
| | | // ä½¿ç¨ XTRIM å½ä»¤æ¸
çæ¶æ¯ï¼åªä¿çæè¿ç MAX_LEN æ¡æ¶æ¯ |
| | | Long trimCount = ops.trim(listener.getStreamKey(), MAX_COUNT, true); |
| | | // ä½¿ç¨ XTRIM MAXLEN 精确è£åªï¼approximate=falseï¼ï¼é¿å
~ 模å¼ä¸é¿æææ¾é«äºä¸é |
| | | Long trimCount = ops.trim(listener.getStreamKey(), MAX_COUNT, false); |
| | | if (trimCount != null && trimCount > 0) { |
| | | log.info("[execute][Stream({}) æ¸
çæ¶æ¯æ°é({})]", listener.getStreamKey(), trimCount); |
| | | } |
| | |
| | | <dependency> |
| | | <groupId>com.baomidou</groupId> |
| | | <artifactId>dynamic-datasource-spring-boot4-starter</artifactId> <!-- 夿°æ®æº --> |
| | | <exclusions> |
| | | <exclusion> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-starter-undertow</artifactId> |
| | | </exclusion> |
| | | </exclusions> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | |
| | | <groupId>org.dromara</groupId> |
| | | <artifactId>easy-trans-mybatis-plus-extend</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- Test æµè¯ç¸å
³ --> |
| | | <dependency> |
| | | <groupId>org.springframework.boot</groupId> |
| | | <artifactId>spring-boot-starter-test</artifactId> |
| | | <scope>test</scope> |
| | | </dependency> |
| | | </dependencies> |
| | | |
| | | </project> |
| | |
| | | |
| | | /** |
| | | * H2 |
| | | * |
| | | * 注æï¼H2 䏿¯æ find_in_set 彿° |
| | | */ |
| | | H2(DbType.H2, "H2", ""), |
| | | H2(DbType.H2, "H2", "POSITION(',' || CAST(#{value} AS VARCHAR) || ',' IN ',' || #{column} || ',') > 0"), |
| | | |
| | | /** |
| | | * MySQL |
| | | */ |
| | | MY_SQL(DbType.MYSQL, "MySQL", "FIND_IN_SET('#{value}', #{column}) <> 0"), |
| | | MY_SQL(DbType.MYSQL, "MySQL", "FIND_IN_SET(#{value}, #{column}) <> 0"), |
| | | |
| | | /** |
| | | * Oracle |
| | | */ |
| | | ORACLE(DbType.ORACLE, "Oracle", "FIND_IN_SET('#{value}', #{column}) <> 0"), |
| | | ORACLE(DbType.ORACLE, "Oracle", "INSTR(',' || #{column} || ',', ',' || #{value} || ',') > 0"), |
| | | |
| | | /** |
| | | * PostgreSQL |
| | | * |
| | | * å为 openGauss ä½¿ç¨ ProductName ä¸ PostgreSQL ç¸å |
| | | */ |
| | | POSTGRE_SQL(DbType.POSTGRE_SQL,"PostgreSQL", "POSITION('#{value}' IN #{column}) <> 0"), |
| | | POSTGRE_SQL(DbType.POSTGRE_SQL, "PostgreSQL", "POSITION(',' || CAST(#{value} AS VARCHAR) || ',' IN ',' || #{column} || ',') > 0"), |
| | | |
| | | /** |
| | | * SQL Server |
| | | */ |
| | | SQL_SERVER(DbType.SQL_SERVER, "Microsoft SQL Server", "CHARINDEX(',' + #{value} + ',', ',' + #{column} + ',') <> 0"), |
| | | SQL_SERVER(DbType.SQL_SERVER, "Microsoft SQL Server", "CHARINDEX(',' + CAST(#{value} AS varchar(255)) + ',', ',' + #{column} + ',') > 0"), |
| | | /** |
| | | * SQL Server 2005 |
| | | */ |
| | | SQL_SERVER2005(DbType.SQL_SERVER2005, "Microsoft SQL Server 2005", "CHARINDEX(',' + #{value} + ',', ',' + #{column} + ',') <> 0"), |
| | | SQL_SERVER2005(DbType.SQL_SERVER2005, "Microsoft SQL Server 2005", "CHARINDEX(',' + CAST(#{value} AS varchar(255)) + ',', ',' + #{column} + ',') > 0"), |
| | | |
| | | /** |
| | | * 达梦 |
| | | */ |
| | | DM(DbType.DM, "DM DBMS", "FIND_IN_SET('#{value}', #{column}) <> 0"), |
| | | DM(DbType.DM, "DM DBMS", "FIND_IN_SET(#{value}, #{column}) <> 0"), |
| | | |
| | | /** |
| | | * 人大éä» |
| | | */ |
| | | KINGBASE_ES(DbType.KINGBASE_ES, "KingbaseES", "POSITION('#{value}' IN #{column}) <> 0"), |
| | | KINGBASE_ES(DbType.KINGBASE_ES, "KingbaseES", "POSITION(',' || CAST(#{value} AS VARCHAR) || ',' IN ',' || #{column} || ',') > 0"), |
| | | |
| | | /** |
| | | * OceanBase |
| | | */ |
| | | OCEAN_BASE(DbType.OCEAN_BASE, "OceanBase", "FIND_IN_SET('#{value}', #{column}) <> 0") |
| | | OCEAN_BASE(DbType.OCEAN_BASE, "OceanBase", "FIND_IN_SET(#{value}, #{column}) <> 0") |
| | | |
| | | ; |
| | | |
| | |
| | | } |
| | | |
| | | public static String getFindInSetTemplate(DbType dbType) { |
| | | return Optional.of(MAP_BY_MP.get(dbType).getFindInSetTemplate()) |
| | | return Optional.ofNullable(MAP_BY_MP.get(dbType)) |
| | | .map(DbTypeEnum::getFindInSetTemplate) |
| | | .filter(StrUtil::isNotBlank) |
| | | .orElseThrow(() -> new IllegalArgumentException("FIND_IN_SET not supported")); |
| | | } |
| | | } |
| | |
| | | return CollUtil.getFirst(list); |
| | | } |
| | | |
| | | /** |
| | | * è·å满足æ¡ä»¶çææ°ä¸æ¡è®°å½ |
| | | * <p> |
| | | * ç®çï¼è§£å³å¹¶ååºæ¯ä¸ï¼æå
¥å¤æ¡è®°å½åï¼ä½¿ç¨ selectOne 伿¥éçé®é¢ |
| | | * |
| | | * @param queryWrapper æ¥è¯¢æ¡ä»¶ |
| | | * @return ææ°ä¸æ¡ï¼ä¸åå¨è¿å null |
| | | */ |
| | | default T selectLastOne(LambdaQueryWrapper<T> queryWrapper) { |
| | | return CollUtil.getLast(selectList(queryWrapper)); |
| | | } |
| | | |
| | | default Long selectCount() { |
| | | return selectCount(new QueryWrapper<>()); |
| | |
| | | return this; |
| | | } |
| | | |
| | | public LambdaQueryWrapperX<T> likeRightIfPresent(SFunction<T, ?> column, String val) { |
| | | if (StringUtils.hasText(val)) { |
| | | return (LambdaQueryWrapperX<T>) super.likeRight(column, val); |
| | | } |
| | | return this; |
| | | } |
| | | |
| | | public LambdaQueryWrapperX<T> inIfPresent(SFunction<T, ?> column, Collection<?> values) { |
| | | if (ObjectUtil.isAllNotEmpty(values) && !ArrayUtil.isEmpty(values)) { |
| | | return (LambdaQueryWrapperX<T>) super.in(column, values); |
| | |
| | | return this; |
| | | } |
| | | |
| | | public <S> MPJLambdaWrapperX<T> likeRightIfPresent(SFunction<S, ?> column, String val) { |
| | | if (StringUtils.hasText(val)) { |
| | | return (MPJLambdaWrapperX<T>) super.likeRight(column, val); |
| | | } |
| | | return this; |
| | | } |
| | | |
| | | public <S> MPJLambdaWrapperX<T> inIfPresent(SFunction<S, ?> column, Collection<?> values) { |
| | | if (ObjectUtil.isAllNotEmpty(values) && !ArrayUtil.isEmpty(values)) { |
| | | return (MPJLambdaWrapperX<T>) super.in(column, values); |
| | |
| | | } |
| | | return this; |
| | | } |
| | | |
| | | |
| | | // ========== éåç¶ç±»æ¹æ³ï¼æ¹ä¾¿é¾å¼è°ç¨ ========== |
| | | |
| | |
| | | return this; |
| | | } |
| | | |
| | | public QueryWrapperX<T> likeRightIfPresent(String column, String val) { |
| | | if (StringUtils.hasText(val)) { |
| | | return (QueryWrapperX<T>) super.likeRight(column, val); |
| | | } |
| | | return this; |
| | | } |
| | | |
| | | public QueryWrapperX<T> inIfPresent(String column, Collection<?> values) { |
| | | if (!CollectionUtils.isEmpty(values)) { |
| | | return (QueryWrapperX<T>) super.in(column, values); |
| | |
| | | } |
| | | |
| | | public QueryWrapperX<T> betweenIfPresent(String column, Object[] values) { |
| | | if (values!= null && values.length != 0 && values[0] != null && values[1] != null) { |
| | | if (values != null && values.length != 0 && values[0] != null && values[1] != null) { |
| | | return (QueryWrapperX<T>) super.between(column, values[0], values[1]); |
| | | } |
| | | if (values!= null && values.length != 0 && values[0] != null) { |
| | | if (values != null && values.length != 0 && values[0] != null) { |
| | | return (QueryWrapperX<T>) ge(column, values[0]); |
| | | } |
| | | if (values!= null && values.length != 0 && values[1] != null) { |
| | | if (values != null && values.length != 0 && values[1] != null) { |
| | | return (QueryWrapperX<T>) le(column, values[1]); |
| | | } |
| | | return this; |
| | |
| | | import java.util.ArrayList; |
| | | import java.util.Collection; |
| | | import java.util.List; |
| | | import java.util.regex.Pattern; |
| | | |
| | | /** |
| | | * MyBatis å·¥å
·ç±» |
| | |
| | | public class MyBatisUtils { |
| | | |
| | | private static final String MYSQL_ESCAPE_CHARACTER = "`"; |
| | | |
| | | private static final Pattern SAFE_COLUMN_NAME_PATTERN = Pattern.compile("^[a-zA-Z0-9_]+(\\.[a-zA-Z0-9_]+)*$"); |
| | | |
| | | private static final String FIND_IN_SET_VALUE_PLACEHOLDER = "#{value}"; |
| | | |
| | | private static final String FIND_IN_SET_COLUMN_PLACEHOLDER = "#{column}"; |
| | | |
| | | public static <T> Page<T> buildPage(PageParam pageParam) { |
| | | return buildPage(pageParam, null); |
| | |
| | | // æåºå段 |
| | | if (CollUtil.isNotEmpty(sortingFields)) { |
| | | for (SortingField sortingField : sortingFields) { |
| | | page.addOrder(new OrderItem().setAsc(SortingField.ORDER_ASC.equals(sortingField.getOrder())) |
| | | .setColumn(StrUtil.toUnderlineCase(sortingField.getField()))); |
| | | String columnName = buildSafeOrderColumn(sortingField.getField()); |
| | | if (columnName == null) { |
| | | continue; |
| | | } |
| | | page.addOrder(new OrderItem().setAsc(isAscOrder(sortingField.getOrder())).setColumn(columnName)); |
| | | } |
| | | } |
| | | return page; |
| | |
| | | if (wrapper instanceof QueryWrapper<T>) { |
| | | QueryWrapper<T> query = (QueryWrapper<T>) wrapper; |
| | | for (SortingField sortingField : sortingFields) { |
| | | query.orderBy(true, |
| | | SortingField.ORDER_ASC.equals(sortingField.getOrder()), |
| | | StrUtil.toUnderlineCase(sortingField.getField())); |
| | | String columnName = buildSafeOrderColumn(sortingField.getField()); |
| | | if (columnName == null) { |
| | | continue; |
| | | } |
| | | query.orderBy(true, isAscOrder(sortingField.getOrder()), columnName); |
| | | } |
| | | } else if (wrapper instanceof LambdaQueryWrapper<T>) { |
| | | // LambdaQueryWrapper ä¸ç´æ¥æ¯æåç¬¦ä¸²åæ®µæåºï¼ä½¿ç¨ last æ¹æ³æ¼æ¥ ORDER BY |
| | | LambdaQueryWrapper<T> lambdaQuery = (LambdaQueryWrapper<T>) wrapper; |
| | | StringBuilder orderBy = new StringBuilder(); |
| | | for (SortingField sortingField : sortingFields) { |
| | | String columnName = buildSafeOrderColumn(sortingField.getField()); |
| | | if (columnName == null) { |
| | | continue; |
| | | } |
| | | if (StrUtil.isNotEmpty(orderBy)) { |
| | | orderBy.append(", "); |
| | | } |
| | | orderBy.append(StrUtil.toUnderlineCase(sortingField.getField())) |
| | | .append(" ") |
| | | .append(SortingField.ORDER_ASC.equals(sortingField.getOrder()) ? "ASC" : "DESC"); |
| | | orderBy.append(columnName).append(" ").append(getOrderDirection(sortingField.getOrder())); |
| | | } |
| | | lambdaQuery.last("ORDER BY " + orderBy); |
| | | if (StrUtil.isNotEmpty(orderBy)) { |
| | | lambdaQuery.last("ORDER BY " + orderBy); |
| | | } |
| | | // å¦å¤ä¸ªæè·¯ï¼https://blog.csdn.net/m0_59084856/article/details/138450913 |
| | | } else { |
| | | throw new IllegalArgumentException("Unsupported wrapper type: " + wrapper.getClass().getName()); |
| | | } |
| | | |
| | | } |
| | | |
| | | public static boolean isAscOrder(String order) { |
| | | return SortingField.ORDER_ASC.equals(order); |
| | | } |
| | | |
| | | public static String getOrderDirection(String order) { |
| | | return isAscOrder(order) ? "ASC" : "DESC"; |
| | | } |
| | | |
| | | private static String buildSafeOrderColumn(String field) { |
| | | String columnName = StrUtil.toUnderlineCase(field); |
| | | if (StrUtil.isEmpty(columnName) || !SAFE_COLUMN_NAME_PATTERN.matcher(columnName).matches()) { |
| | | return null; |
| | | } |
| | | return columnName; |
| | | } |
| | | |
| | | /** |
| | |
| | | /** |
| | | * è·¨æ°æ®åºç find_in_set å®ç° |
| | | * |
| | | * @param column åæ®µåç§° |
| | | * @param value æ¥è¯¢å¼(ä¸å¸¦åå¼å·) |
| | | * @param columnName åæ®µåç§° |
| | | * @return sql |
| | | */ |
| | | public static String findInSet(String column, Object value) { |
| | | public static String findInSet(String columnName) { |
| | | return findInSet(columnName, 0); |
| | | } |
| | | |
| | | /** |
| | | * è·¨æ°æ®åºç find_in_set å®ç°ï¼éç¨äºåä¸ä¸ª apply è¯å¥ä¸æå¤ä¸ªåæ°çåºæ¯ |
| | | * |
| | | * @param columnName åæ®µåç§° |
| | | * @param paramIndex apply åæ°åºå· |
| | | * @return sql |
| | | */ |
| | | public static String findInSetWithParamIndex(String columnName, int paramIndex) { |
| | | return findInSet(columnName, paramIndex); |
| | | } |
| | | |
| | | private static String findInSet(String columnName, int paramIndex) { |
| | | DbType dbType = JdbcUtils.getDbType(); |
| | | return findInSet(dbType, columnName, paramIndex); |
| | | } |
| | | |
| | | static String findInSet(DbType dbType, String columnName, int paramIndex) { |
| | | if (!isSafeColumnName(columnName)) { |
| | | throw new IllegalArgumentException("Invalid column name: " + columnName); |
| | | } |
| | | if (paramIndex < 0) { |
| | | throw new IllegalArgumentException("Invalid param index: " + paramIndex); |
| | | } |
| | | return DbTypeEnum.getFindInSetTemplate(dbType) |
| | | .replace("#{column}", column) |
| | | .replace("#{value}", StrUtil.toString(value)); |
| | | .replace(FIND_IN_SET_COLUMN_PLACEHOLDER, columnName) |
| | | .replace(FIND_IN_SET_VALUE_PLACEHOLDER, "{" + paramIndex + "}"); |
| | | } |
| | | |
| | | private static boolean isSafeColumnName(String columnName) { |
| | | return StrUtil.isNotEmpty(columnName) && SAFE_COLUMN_NAME_PATTERN.matcher(columnName).matches(); |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | @Bean |
| | | @ConditionalOnBean(TransService.class) |
| | | @SuppressWarnings({"InstantiationOfUtilityClass", "SpringJavaInjectionPointsAutowiringInspection"}) |
| | | @SuppressWarnings("InstantiationOfUtilityClass") |
| | | public TranslateUtils translateUtils(TransService transService) { |
| | | TranslateUtils.init(transService); |
| | | return new TranslateUtils(); |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.framework.mybatis.core.util; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import cn.iocoder.yudao.framework.common.pojo.SortingField; |
| | | import com.baomidou.mybatisplus.annotation.DbType; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.OrderItem; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import org.junit.jupiter.api.Test; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.List; |
| | | |
| | | import static org.junit.jupiter.api.Assertions.assertEquals; |
| | | import static org.junit.jupiter.api.Assertions.assertFalse; |
| | | import static org.junit.jupiter.api.Assertions.assertThrows; |
| | | import static org.junit.jupiter.api.Assertions.assertTrue; |
| | | |
| | | /** |
| | | * {@link MyBatisUtils} çåå
æµè¯ |
| | | */ |
| | | public class MyBatisUtilsTest { |
| | | |
| | | @Test |
| | | public void testBuildPage_sortingFields() { |
| | | // åå¤åæ° |
| | | PageParam pageParam = new PageParam(); |
| | | pageParam.setPageNo(2); |
| | | pageParam.setPageSize(20); |
| | | List<SortingField> sortingFields = Arrays.asList( |
| | | new SortingField("userName", SortingField.ORDER_ASC), |
| | | new SortingField("u.id", SortingField.ORDER_DESC), |
| | | new SortingField("name desc", SortingField.ORDER_DESC)); |
| | | |
| | | // è°ç¨ |
| | | Page<Object> page = MyBatisUtils.buildPage(pageParam, sortingFields); |
| | | |
| | | // æè¨ |
| | | assertEquals(2, page.getCurrent()); |
| | | assertEquals(20, page.getSize()); |
| | | assertEquals(2, page.orders().size()); |
| | | assertOrderItem(page.orders().get(0), "user_name", true); |
| | | assertOrderItem(page.orders().get(1), "u.id", false); |
| | | } |
| | | |
| | | @Test |
| | | public void testAddOrder_queryWrapper() { |
| | | // åå¤åæ° |
| | | QueryWrapper<Object> query = new QueryWrapper<>(); |
| | | List<SortingField> sortingFields = Arrays.asList( |
| | | new SortingField("userName", SortingField.ORDER_ASC), |
| | | new SortingField("u.id", SortingField.ORDER_DESC), |
| | | new SortingField("name;drop", SortingField.ORDER_ASC)); |
| | | |
| | | // è°ç¨ |
| | | MyBatisUtils.addOrder(query, sortingFields); |
| | | |
| | | // æè¨ |
| | | assertEquals(" ORDER BY user_name ASC,u.id DESC", query.getSqlSegment()); |
| | | } |
| | | |
| | | @Test |
| | | public void testAddOrder_lambdaQueryWrapper() { |
| | | // åå¤åæ° |
| | | LambdaQueryWrapper<Object> query = new LambdaQueryWrapper<>(); |
| | | List<SortingField> sortingFields = Arrays.asList( |
| | | new SortingField("userName", SortingField.ORDER_ASC), |
| | | new SortingField("u.id", SortingField.ORDER_DESC), |
| | | new SortingField("name`", SortingField.ORDER_ASC)); |
| | | |
| | | // è°ç¨ |
| | | MyBatisUtils.addOrder(query, sortingFields); |
| | | |
| | | // æè¨ |
| | | assertEquals(" ORDER BY user_name ASC, u.id DESC", query.getSqlSegment()); |
| | | } |
| | | |
| | | @Test |
| | | public void testAddOrder_lambdaQueryWrapper_invalidSortingFields() { |
| | | // åå¤åæ° |
| | | LambdaQueryWrapper<Object> query = new LambdaQueryWrapper<>(); |
| | | List<SortingField> sortingFields = Arrays.asList( |
| | | new SortingField("name desc", SortingField.ORDER_ASC), |
| | | new SortingField("name;drop", SortingField.ORDER_DESC)); |
| | | |
| | | // è°ç¨ |
| | | MyBatisUtils.addOrder(query, sortingFields); |
| | | |
| | | // æè¨ |
| | | assertEquals("", query.getSqlSegment()); |
| | | } |
| | | |
| | | @Test |
| | | public void testOrderDirection() { |
| | | assertTrue(MyBatisUtils.isAscOrder(SortingField.ORDER_ASC)); |
| | | assertFalse(MyBatisUtils.isAscOrder(SortingField.ORDER_DESC)); |
| | | assertEquals("ASC", MyBatisUtils.getOrderDirection(SortingField.ORDER_ASC)); |
| | | assertEquals("DESC", MyBatisUtils.getOrderDirection(SortingField.ORDER_DESC)); |
| | | assertEquals("DESC", MyBatisUtils.getOrderDirection(null)); |
| | | } |
| | | |
| | | @Test |
| | | public void testFindInSet() { |
| | | assertEquals("FIND_IN_SET({0}, websites) <> 0", |
| | | MyBatisUtils.findInSet(DbType.MYSQL, "websites", 0)); |
| | | assertEquals("POSITION(',' || CAST({0} AS VARCHAR) || ',' IN ',' || websites || ',') > 0", |
| | | MyBatisUtils.findInSet(DbType.H2, "websites", 0)); |
| | | assertEquals("INSTR(',' || t.websites || ',', ',' || {0} || ',') > 0", |
| | | MyBatisUtils.findInSet(DbType.ORACLE, "t.websites", 0)); |
| | | assertEquals("POSITION(',' || CAST({1} AS VARCHAR) || ',' IN ',' || websites || ',') > 0", |
| | | MyBatisUtils.findInSet(DbType.POSTGRE_SQL, "websites", 1)); |
| | | assertEquals("CHARINDEX(',' + CAST({2} AS varchar(255)) + ',', ',' + websites + ',') > 0", |
| | | MyBatisUtils.findInSet(DbType.SQL_SERVER, "websites", 2)); |
| | | } |
| | | |
| | | @Test |
| | | public void testFindInSet_invalidColumnName() { |
| | | assertThrows(IllegalArgumentException.class, |
| | | () -> MyBatisUtils.findInSet(DbType.MYSQL, "websites;drop table system_tenant", 0)); |
| | | assertThrows(IllegalArgumentException.class, |
| | | () -> MyBatisUtils.findInSet(DbType.MYSQL, "FIND_IN_SET(value, websites)", 0)); |
| | | } |
| | | |
| | | @Test |
| | | public void testFindInSet_invalidParamIndex() { |
| | | assertThrows(IllegalArgumentException.class, |
| | | () -> MyBatisUtils.findInSet(DbType.MYSQL, "websites", -1)); |
| | | } |
| | | |
| | | @Test |
| | | public void testFindInSet_applyBindsValue() { |
| | | // åå¤åæ° |
| | | QueryWrapper<Object> query = new QueryWrapper<>(); |
| | | String value = "test' OR 1 = 1"; |
| | | |
| | | // è°ç¨ |
| | | query.apply(MyBatisUtils.findInSet(DbType.MYSQL, "to_mails", 0), value); |
| | | |
| | | // æè¨ï¼SQL çæ®µéåªæ MyBatis Plus åæ°å ä½ï¼ç¨æ·è¾å
¥ä¸ä¼è¢«ç´æ¥æ¼æ¥è¿å» |
| | | assertEquals("(FIND_IN_SET(#{ew.paramNameValuePairs.MPGENVAL1}, to_mails) <> 0)", |
| | | query.getSqlSegment()); |
| | | assertFalse(query.getSqlSegment().contains(value)); |
| | | assertEquals(value, query.getParamNameValuePairs().get("MPGENVAL1")); |
| | | } |
| | | |
| | | @Test |
| | | public void testFindInSet_applyBindsMultipleValues() { |
| | | // åå¤åæ° |
| | | QueryWrapper<Object> query = new QueryWrapper<>(); |
| | | String value1 = "1' OR 1 = 1"; |
| | | String value2 = "2' OR 1 = 1"; |
| | | |
| | | // è°ç¨ |
| | | query.apply(MyBatisUtils.findInSet(DbType.MYSQL, "tag_ids", 0) |
| | | + " OR " + MyBatisUtils.findInSet(DbType.MYSQL, "tag_ids", 1), value1, value2); |
| | | |
| | | // æè¨ï¼å¤ä¸ªåæ°é½ç± MyBatis Plus çæå ä½ç¬¦ï¼ä¸æ¼æ¥ç¨æ·è¾å
¥ |
| | | assertEquals("(FIND_IN_SET(#{ew.paramNameValuePairs.MPGENVAL1}, tag_ids) <> 0" |
| | | + " OR FIND_IN_SET(#{ew.paramNameValuePairs.MPGENVAL2}, tag_ids) <> 0)", |
| | | query.getSqlSegment()); |
| | | assertFalse(query.getSqlSegment().contains(value1)); |
| | | assertFalse(query.getSqlSegment().contains(value2)); |
| | | assertEquals(value1, query.getParamNameValuePairs().get("MPGENVAL1")); |
| | | assertEquals(value2, query.getParamNameValuePairs().get("MPGENVAL2")); |
| | | } |
| | | |
| | | private void assertOrderItem(OrderItem orderItem, String column, boolean asc) { |
| | | assertEquals(column, orderItem.getColumn()); |
| | | assertEquals(asc, orderItem.isAsc()); |
| | | } |
| | | |
| | | } |
| | |
| | | RedisConnectionFactory connectionFactory = Objects.requireNonNull(redisTemplate.getConnectionFactory()); |
| | | RedisCacheWriter cacheWriter = RedisCacheWriter.nonLockingRedisCacheWriter(connectionFactory, |
| | | BatchStrategies.scan(yudaoCacheProperties.getRedisScanBatchSize())); |
| | | // å建 TenantRedisCacheManager 对象 |
| | | return new TimeoutRedisCacheManager(cacheWriter, redisCacheConfiguration); |
| | | // å建 TimeoutRedisCacheManager 对象 |
| | | TimeoutRedisCacheManager cacheManager = new TimeoutRedisCacheManager(cacheWriter, redisCacheConfiguration); |
| | | // å¼å¯äºå¡æç¥ï¼@Transactional æ¹æ³å
ç @CacheEvict / @CachePut èªå¨å»¶è¿å° afterCommitï¼ |
| | | // é¿å
äºå¡æªæäº¤å°±æ¸
ç¼å被并å读穿åèå¼ï¼æ äºå¡æ¶ç«å³çæï¼è¡ä¸ºä¸å |
| | | cacheManager.setTransactionAware(true); |
| | | return cacheManager; |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.framework.redis.config; |
| | | |
| | | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import org.redisson.spring.starter.RedissonAutoConfigurationV4; |
| | | import org.springframework.boot.autoconfigure.AutoConfiguration; |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.data.redis.connection.RedisConnectionFactory; |
| | | import org.springframework.data.redis.core.RedisTemplate; |
| | | import org.springframework.data.redis.serializer.RedisSerializer; |
| | | |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.util.HashSet; |
| | | import java.util.LinkedHashSet; |
| | | import java.util.Set; |
| | | import java.util.TreeSet; |
| | | |
| | | import tools.jackson.core.type.TypeReference; |
| | | import tools.jackson.databind.ObjectMapper; |
| | | |
| | | /** |
| | | * Redis é
置类 |
| | |
| | | return template; |
| | | } |
| | | |
| | | @SuppressWarnings("UnnecessaryLocalVariable") |
| | | public static RedisSerializer<?> buildRedisSerializer() { |
| | | // 使ç¨èªå®ä¹åºååå¨ï¼è§£å³ Set/List ç Collection ååºååç±»åé®é¢ |
| | | return new TypedJsonRedisSerializer(); |
| | | } |
| | | |
| | | /** |
| | | * èªå®ä¹ Redis åºååå¨ï¼è§£å³ Set/List ç Collection ååºååç±»åé®é¢ |
| | | */ |
| | | private static class TypedJsonRedisSerializer implements RedisSerializer<Object> { |
| | | |
| | | private static final String JAVA_TYPE_PREFIX = "@class:"; |
| | | private static final ObjectMapper OBJECT_MAPPER = JsonUtils.getObjectMapper(); |
| | | private static final TypeReference<HashSet<Object>> HASH_SET_TYPE = new TypeReference<>() {}; |
| | | private static final TypeReference<LinkedHashSet<Object>> LINKED_HASH_SET_TYPE = new TypeReference<>() {}; |
| | | private static final TypeReference<TreeSet<Object>> TREE_SET_TYPE = new TypeReference<>() {}; |
| | | |
| | | @Override |
| | | public byte[] serialize(Object value) { |
| | | if (value == null) { |
| | | return new byte[0]; |
| | | } |
| | | // å°ç±»åä¿¡æ¯ä¸ JSON ä¸èµ·åå¨ |
| | | String json = JsonUtils.toJsonString(value); |
| | | String typePrefix = JAVA_TYPE_PREFIX + value.getClass().getName() + ":"; |
| | | return (typePrefix + json).getBytes(StandardCharsets.UTF_8); |
| | | } |
| | | |
| | | @Override |
| | | public Object deserialize(byte[] bytes) { |
| | | if (bytes == null || bytes.length == 0) { |
| | | return null; |
| | | } |
| | | String content = new String(bytes, StandardCharsets.UTF_8); |
| | | if (!content.startsWith(JAVA_TYPE_PREFIX)) { |
| | | // å
¼å®¹æ§æ°æ®ï¼æ²¡æç±»åä¿¡æ¯çæ
åµ |
| | | // æ£æµæ¯å¦ä¸º JSON æ°ç»ï¼è¥æ¯å转æ¢ä¸º HashSet |
| | | return deserializeLegacyData(content); |
| | | } |
| | | // æåç±»åä¿¡æ¯å JSON |
| | | int colonIndex = content.indexOf(':', JAVA_TYPE_PREFIX.length()); |
| | | if (colonIndex == -1) { |
| | | return deserializeLegacyData(content); |
| | | } |
| | | String className = content.substring(JAVA_TYPE_PREFIX.length(), colonIndex); |
| | | String json = content.substring(colonIndex + 1); |
| | | try { |
| | | Class<?> clazz = Class.forName(className); |
| | | // ç¹æ®å¤ç Set ç±»åï¼å 为 Jackson é»è®¤ä¼å° JSON æ°ç»ååºåå为 List |
| | | return deserializeWithTypeHint(json, clazz); |
| | | } catch (ClassNotFoundException e) { |
| | | // ç±»åä¸å卿¶ï¼å°è¯å
¼å®¹è§£æ |
| | | return deserializeLegacyData(json); |
| | | } catch (Exception e) { |
| | | // è§£æå¤±è´¥æ¶ï¼å°è¯å
¼å®¹è§£æ |
| | | return deserializeLegacyData(json); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * å
¼å®¹æ§æ°æ®ï¼æ²¡æç±»ååç¼ï¼çè§£æ |
| | | * å¯¹äº JSON æ°ç»ï¼é»è®¤è½¬æ¢ä¸º HashSet |
| | | */ |
| | | private Object deserializeLegacyData(String content) { |
| | | if (StrUtil.isEmpty(content)) { |
| | | return null; |
| | | } |
| | | content = content.trim(); |
| | | // 夿æ¯å¦ä¸º JSON æ°ç» |
| | | if (content.startsWith("[") && content.endsWith("]")) { |
| | | try { |
| | | // æ°ç»ç±»åé»è®¤è½¬ä¸º HashSet |
| | | return OBJECT_MAPPER.readValue(content, HASH_SET_TYPE); |
| | | } catch (Exception e) { |
| | | return JsonUtils.parseObject(content, Object.class); |
| | | } |
| | | } |
| | | // å
¶ä»ç±»åç´æ¥è§£æ |
| | | return JsonUtils.parseObject(content, Object.class); |
| | | } |
| | | |
| | | private Object deserializeWithTypeHint(String json, Class<?> clazz) { |
| | | // å¤ç Set æ¥å£çå®ç°ç±» |
| | | if (HashSet.class.isAssignableFrom(clazz) || |
| | | "java.util.Collections$UnmodifiableSet".equals(clazz.getName()) || |
| | | "java.util.Collections$SingletonSet".equals(clazz.getName()) || |
| | | Set.class.isAssignableFrom(clazz)) { |
| | | return OBJECT_MAPPER.readValue(json, HASH_SET_TYPE); |
| | | } |
| | | if (LinkedHashSet.class.isAssignableFrom(clazz)) { |
| | | return OBJECT_MAPPER.readValue(json, LINKED_HASH_SET_TYPE); |
| | | } |
| | | if (TreeSet.class.isAssignableFrom(clazz)) { |
| | | return OBJECT_MAPPER.readValue(json, TREE_SET_TYPE); |
| | | } |
| | | // ä½¿ç¨ Jackson ç readValue æå®ç±»åï¼ç¡®ä¿ POJO æ£ç¡®ååºåå |
| | | return OBJECT_MAPPER.readValue(json, clazz); |
| | | } |
| | | RedisSerializer<Object> json = RedisSerializer.json(); |
| | | // ç¹æ®ï¼spring boot 4.x æ éè§£å³ LocalDateTime çåºåå |
| | | // åå ï¼Spring Data Redis 4 ä½¿ç¨ Jackson 3ï¼RedisSerializer.json() å·²æ¯æ Java Time ç±»å |
| | | return json; |
| | | } |
| | | |
| | | } |
| | |
| | | import org.springframework.web.method.HandlerMethod; |
| | | import org.springframework.web.servlet.mvc.method.RequestMappingInfo; |
| | | import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping; |
| | | import org.springframework.web.util.pattern.PathPattern; |
| | | |
| | | import java.util.HashSet; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | |
| | | /** |
| | | * èªå®ä¹ç Spring Security é
ç½®éé
å¨å®ç° |
| | |
| | | return webProperties.getAppApi().getPrefix() + url; |
| | | } |
| | | |
| | | @SuppressWarnings("removal") |
| | | private Multimap<HttpMethod, String> getPermitAllUrlsFromAnnotations() { |
| | | Multimap<HttpMethod, String> result = HashMultimap.create(); |
| | | // è·å¾æ¥å£å¯¹åºç HandlerMethod éå |
| | |
| | | continue; |
| | | } |
| | | Set<String> urls = new HashSet<>(); |
| | | urls.addAll(entry.getKey().getPatternValues()); |
| | | if (entry.getKey().getPatternsCondition() != null) { |
| | | urls.addAll(entry.getKey().getPatternsCondition().getPatterns()); |
| | | } |
| | | if (entry.getKey().getPathPatternsCondition() != null) { |
| | | urls.addAll(convertList(entry.getKey().getPathPatternsCondition().getPatterns(), PathPattern::getPatternString)); |
| | | } |
| | | if (urls.isEmpty()) { |
| | | continue; |
| | | } |
| | |
| | | Long tenantId = WebSocketFrameworkUtils.getTenantId(session); |
| | | TenantUtils.execute(tenantId, () -> messageListener.onMessage(session, messageObj)); |
| | | } catch (Throwable ex) { |
| | | log.error("[handleTextMessage][session({}) message({}) å¤çå¼å¸¸]", session.getId(), message.getPayload()); |
| | | log.error("[handleTextMessage][session({}) message({}) å¤çå¼å¸¸]", session.getId(), message.getPayload(), ex); |
| | | } |
| | | } |
| | | |
| | |
| | | public boolean beforeHandshake(ServerHttpRequest request, ServerHttpResponse response, |
| | | WebSocketHandler wsHandler, Map<String, Object> attributes) { |
| | | LoginUser loginUser = SecurityFrameworkUtils.getLoginUser(); |
| | | if (loginUser != null) { |
| | | WebSocketFrameworkUtils.setLoginUser(loginUser, attributes); |
| | | if (loginUser == null) { |
| | | return false; |
| | | } |
| | | WebSocketFrameworkUtils.setLoginUser(loginUser, attributes); |
| | | return true; |
| | | } |
| | | |
| | |
| | | å½å¤ï¼OpenAIãOllamaãMidjourneyãStableDiffusionãSuno |
| | | </description> |
| | | <properties> |
| | | <spring-ai.version>2.0.0-M7</spring-ai.version> |
| | | <spring-ai-legacy-model.version>2.0.0-M4</spring-ai-legacy-model.version> |
| | | <spring-ai.version>2.0.0</spring-ai.version> |
| | | <!-- https://mvnrepository.com/artifact/com.alibaba.cloud.ai/spring-ai-alibaba --> |
| | | <alibaba-ai.version>1.1.2.3</alibaba-ai.version> |
| | | <alibaba-ai.version>2.0.0-M1.1</alibaba-ai.version> |
| | | <tinyflow.version>1.2.6</tinyflow.version> |
| | | </properties> |
| | | |
| | |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-azure-openai</artifactId> |
| | | <version>${spring-ai-legacy-model.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-anthropic</artifactId> |
| | | <version>${spring-ai.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-deepseek</artifactId> |
| | | <version>${spring-ai.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-google-genai</artifactId> |
| | | <version>${spring-ai.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | |
| | | <version>${spring-ai.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <!-- æºè°± GLM --> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-zhipuai</artifactId> |
| | | <version>${spring-ai-legacy-model.version}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.springframework.ai</groupId> |
| | | <artifactId>spring-ai-starter-model-minimax</artifactId> |
| | | <version>${spring-ai.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <!-- éä¹åé® --> |
| | | <groupId>com.alibaba.cloud.ai</groupId> |
| | | <artifactId>spring-ai-alibaba-starter-dashscope</artifactId> |
| | | <version>${alibaba-ai.version}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <!-- æå¿ä¸è¨ --> |
| | | <groupId>org.springaicommunity</groupId> |
| | | <artifactId>qianfan-core</artifactId> |
| | | <version>1.0.0</version> |
| | | </dependency> |
| | | <dependency> |
| | | <!-- æä¹æé¢ --> |
| | | <groupId>org.springaicommunity</groupId> |
| | | <artifactId>moonshot-core</artifactId> |
| | | <version>1.0.0</version> |
| | | </dependency> |
| | | |
| | | <!-- åéåå¨ï¼https://db-engines.com/en/ranking/vector+dbms --> |
| | |
| | | // ========== API å¯é¥ 1-040-000-000 ========== |
| | | ErrorCode API_KEY_NOT_EXISTS = new ErrorCode(1_040_000_000, "API å¯é¥ä¸åå¨"); |
| | | ErrorCode API_KEY_DISABLE = new ErrorCode(1_040_000_001, "API å¯é¥å·²ç¦ç¨ï¼"); |
| | | ErrorCode API_CONFIG_PLACEHOLDER_NOT_RESOLVED = new ErrorCode(1_040_000_002, "AI é
ç½®({})æ æ³è§£æï¼è¯·æ£æ¥ç¯å¢åéæé
置项"); |
| | | |
| | | // ========== API 模å 1-040-001-000 ========== |
| | | ErrorCode MODEL_NOT_EXISTS = new ErrorCode(1_040_001_000, "模åä¸åå¨!"); |
| | |
| | | MINI_MAX("MiniMax", "MiniMax"), // ç¨å®ç§æ |
| | | MOONSHOT("Moonshot", "æä¹æé¢"), // KIMI |
| | | BAI_CHUAN("BaiChuan", "ç¾å·æºè½"), // ç¾å·æºè½ |
| | | STEP_FUN("StepFun", "é¶è·æè¾°"), // é¶è·æè¾° |
| | | |
| | | // ========== å½å¤å¹³å° ========== |
| | | |
| | |
| | | STABLE_DIFFUSION("StableDiffusion", "StableDiffusion"), // Stability AI |
| | | MIDJOURNEY("Midjourney", "Midjourney"), // Midjourney |
| | | SUNO("Suno", "Suno"), // Suno AI |
| | | GROK("Grok","Grok"), // Grok |
| | | GROK("Grok", "Grok"), // Grok |
| | | |
| | | ; |
| | | |
| | |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.AiModelFactoryImpl; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.baichuan.BaiChuanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.doubao.DouBaoChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.gemini.GeminiChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.grok.GrokChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.hunyuan.HunYuanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.midjourney.api.MidjourneyApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.minimax.MiniMaxChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.moonshot.MoonshotChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowApiConstants; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.stepfun.StepFunChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.suno.api.SunoApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.xinghuo.XingHuoChatModel; |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.yiyan.YiYanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.zhipu.ZhiPuChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.webserch.AiWebSearchClient; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.webserch.bocha.AiBoChaWebSearchClient; |
| | | import cn.iocoder.yudao.module.ai.tool.method.PersonService; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeApi; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeImageApi; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatModel; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatOptions; |
| | | import com.alibaba.cloud.ai.dashscope.embedding.text.DashScopeEmbeddingModel; |
| | | import com.alibaba.cloud.ai.dashscope.embedding.text.DashScopeEmbeddingOptions; |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageModel; |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageOptions; |
| | | import io.micrometer.observation.ObservationRegistry; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import org.springframework.ai.document.MetadataMode; |
| | | import org.springframework.ai.embedding.BatchingStrategy; |
| | | import org.springframework.ai.embedding.TokenCountBatchingStrategy; |
| | | import org.springframework.ai.model.tool.ToolCallingManager; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import org.springframework.ai.retry.RetryUtils; |
| | | import org.springframework.ai.support.ToolCallbacks; |
| | | import org.springframework.ai.tokenizer.JTokkitTokenCountEstimator; |
| | | import org.springframework.ai.tokenizer.TokenCountEstimator; |
| | |
| | | import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; |
| | | import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; |
| | | import org.springframework.boot.context.properties.EnableConfigurationProperties; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.context.annotation.Bean; |
| | | import org.springframework.context.annotation.Configuration; |
| | | |
| | | import java.util.List; |
| | | import java.util.Optional; |
| | | |
| | | /** |
| | | * èé AI èªå¨é
ç½® |
| | |
| | | // ========== åç§ AI Client å建 ========== |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.gemini.enable", havingValue = "true") |
| | | public GeminiChatModel geminiChatModel(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.Gemini properties = yudaoAiProperties.getGemini(); |
| | | return buildGeminiChatClient(properties); |
| | | @ConditionalOnMissingBean |
| | | @ConditionalOnProperty(value = "spring.ai.dashscope.api-key") |
| | | public DashScopeChatModel dashScopeChatModel(@Value("${spring.ai.dashscope.api-key}") String apiKey, |
| | | ToolCallingManager toolCallingManager, |
| | | ObservationRegistry observationRegistry) { |
| | | return buildTongYiChatModel(apiKey, toolCallingManager, observationRegistry); |
| | | } |
| | | |
| | | public GeminiChatModel buildGeminiChatClient(YudaoAiProperties.Gemini properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(GeminiChatModel.MODEL_DEFAULT); |
| | | } |
| | | OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .baseUrl(GeminiChatModel.BASE_URL) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | @Bean |
| | | @ConditionalOnMissingBean |
| | | @ConditionalOnProperty(value = "spring.ai.dashscope.api-key") |
| | | public DashScopeImageModel dashScopeImageModel(@Value("${spring.ai.dashscope.api-key}") String apiKey, |
| | | ObservationRegistry observationRegistry) { |
| | | return buildTongYiImagesModel(apiKey, observationRegistry); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnMissingBean |
| | | @ConditionalOnProperty(value = "spring.ai.dashscope.api-key") |
| | | public DashScopeEmbeddingModel dashScopeEmbeddingModel(@Value("${spring.ai.dashscope.api-key}") String apiKey, |
| | | ObservationRegistry observationRegistry) { |
| | | return buildTongYiEmbeddingModel(apiKey, null, observationRegistry); |
| | | } |
| | | |
| | | public static DashScopeChatModel buildTongYiChatModel(String apiKey) { |
| | | return buildTongYiChatModel(apiKey, getToolCallingManager(), getObservationRegistry()); |
| | | } |
| | | |
| | | private static DashScopeChatModel buildTongYiChatModel(String apiKey, ToolCallingManager toolCallingManager, |
| | | ObservationRegistry observationRegistry) { |
| | | DashScopeApi dashScopeApi = DashScopeApi.builder().apiKey(apiKey).build(); |
| | | DashScopeChatOptions options = DashScopeChatOptions.builder() |
| | | .model(DashScopeApi.DEFAULT_CHAT_MODEL) |
| | | .temperature(0.7) |
| | | .build(); |
| | | return new GeminiChatModel(openAiChatModel); |
| | | return new DashScopeChatModel(dashScopeApi, options, toolCallingManager, RetryUtils.DEFAULT_RETRY_TEMPLATE, |
| | | observationRegistry); |
| | | } |
| | | |
| | | public static DashScopeImageModel buildTongYiImagesModel(String apiKey) { |
| | | return buildTongYiImagesModel(apiKey, getObservationRegistry()); |
| | | } |
| | | |
| | | private static DashScopeImageModel buildTongYiImagesModel(String apiKey, ObservationRegistry observationRegistry) { |
| | | DashScopeImageApi dashScopeImageApi = DashScopeImageApi.builder().apiKey(apiKey).build(); |
| | | DashScopeImageOptions options = DashScopeImageOptions.builder() |
| | | .model(DashScopeImageApi.DEFAULT_IMAGE_MODEL) |
| | | .build(); |
| | | return new DashScopeImageModel(dashScopeImageApi, options, RetryUtils.DEFAULT_RETRY_TEMPLATE, |
| | | observationRegistry); |
| | | } |
| | | |
| | | public static DashScopeEmbeddingModel buildTongYiEmbeddingModel(String apiKey, String model) { |
| | | return buildTongYiEmbeddingModel(apiKey, model, getObservationRegistry()); |
| | | } |
| | | |
| | | private static DashScopeEmbeddingModel buildTongYiEmbeddingModel(String apiKey, String model, |
| | | ObservationRegistry observationRegistry) { |
| | | DashScopeApi dashScopeApi = DashScopeApi.builder().apiKey(apiKey).build(); |
| | | DashScopeEmbeddingOptions options = DashScopeEmbeddingOptions.builder() |
| | | .model(StrUtil.blankToDefault(model, DashScopeApi.DEFAULT_EMBEDDING_MODEL)) |
| | | .build(); |
| | | return new DashScopeEmbeddingModel(dashScopeApi, MetadataMode.EMBED, options, RetryUtils.DEFAULT_RETRY_TEMPLATE, |
| | | observationRegistry); |
| | | } |
| | | |
| | | @Bean |
| | |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(DouBaoChatModel.MODEL_DEFAULT); |
| | | } |
| | | OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(DouBaoChatModel.BASE_URL) |
| | | .completionsPath(DouBaoChatModel.COMPLETE_PATH) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new DouBaoChatModel(openAiChatModel); |
| | | } |
| | |
| | | .baseUrl(SiliconFlowApiConstants.DEFAULT_BASE_URL) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new SiliconFlowChatModel(openAiChatModel); |
| | | } |
| | |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(HunYuanChatModel.MODEL_DEFAULT); |
| | | } |
| | | // ç¹æ®ï¼ç±äºæ··å
大模åä¸æä¾ deepseekï¼èæ¯éè¿ç¥è¯å¼æï¼æä»¥éè¦åºåä¸ URL |
| | | if (StrUtil.isEmpty(properties.getBaseUrl())) { |
| | | properties.setBaseUrl( |
| | | StrUtil.startWithIgnoreCase(properties.getModel(), "deepseek") ? HunYuanChatModel.DEEP_SEEK_BASE_URL |
| | | : HunYuanChatModel.BASE_URL); |
| | | properties.setBaseUrl(HunYuanChatModel.BASE_URL); |
| | | } |
| | | // å建 DeepSeekChatModelãHunYuanChatModel 对象 |
| | | DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | |
| | | .completionsPath(HunYuanChatModel.COMPLETE_PATH) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new HunYuanChatModel(openAiChatModel); |
| | | } |
| | |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(XingHuoChatModel.MODEL_DEFAULT); |
| | | } |
| | | OpenAIOkHttpClient.Builder builder = OpenAIOkHttpClient.builder() |
| | | .baseUrl(XingHuoChatModel.BASE_URL_V1) |
| | | .apiKey(properties.getAppKey() + ":" + properties.getSecretKey()); |
| | | if ("x1".equals(properties.getModel())) { |
| | | builder.baseUrl(XingHuoChatModel.BASE_URL_V2); |
| | | } |
| | | OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(builder.build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | return XingHuoChatModel.builder() |
| | | .apiKey(properties.getApiKey()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | // TODO @èè¿ï¼æç«ç function call æ bugï¼ä¼æ¥ ToolResponseMessage must have an id é误ï¼ï¼ï¼ |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new XingHuoChatModel(openAiChatModel); |
| | | } |
| | | |
| | | @Bean |
| | |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(BaiChuanChatModel.MODEL_DEFAULT); |
| | | } |
| | | OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | DeepSeekChatModel deepSeekChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(BaiChuanChatModel.BASE_URL) |
| | | .apiKey(properties.getApiKey()) |
| | | .completionsPath(BaiChuanChatModel.COMPLETE_PATH) |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new BaiChuanChatModel(openAiChatModel); |
| | | return new BaiChuanChatModel(deepSeekChatModel); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.yiyan.enable", havingValue = "true") |
| | | public YiYanChatModel yiYanChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.YiYan properties = yudaoAiProperties.getYiyan(); |
| | | return buildYiYanChatClient(properties); |
| | | } |
| | | |
| | | public YiYanChatModel buildYiYanChatClient(YudaoAiProperties.YiYan properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(YiYanChatModel.MODEL_DEFAULT); |
| | | } |
| | | return new YiYanChatModel(buildDeepSeekCompatibleChatModel( |
| | | StrUtil.blankToDefault(properties.getBaseUrl(), YiYanChatModel.BASE_URL), |
| | | null, properties.getApiKey(), properties.getModel(), properties.getTemperature(), |
| | | properties.getMaxTokens(), properties.getTopP())); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.zhipu.enable", havingValue = "true") |
| | | public ZhiPuChatModel zhiPuChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.ZhiPu properties = yudaoAiProperties.getZhipu(); |
| | | return buildZhiPuChatClient(properties); |
| | | } |
| | | |
| | | public ZhiPuChatModel buildZhiPuChatClient(YudaoAiProperties.ZhiPu properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(ZhiPuChatModel.MODEL_DEFAULT); |
| | | } |
| | | DeepSeekChatModel deepSeekChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(StrUtil.blankToDefault(properties.getBaseUrl(), ZhiPuChatModel.BASE_URL)) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .build(); |
| | | return new ZhiPuChatModel(deepSeekChatModel); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.minimax.enable", havingValue = "true") |
| | | public MiniMaxChatModel miniMaxChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.MiniMax properties = yudaoAiProperties.getMinimax(); |
| | | return buildMiniMaxChatClient(properties); |
| | | } |
| | | |
| | | public MiniMaxChatModel buildMiniMaxChatClient(YudaoAiProperties.MiniMax properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(MiniMaxChatModel.MODEL_DEFAULT); |
| | | } |
| | | return new MiniMaxChatModel(buildDeepSeekCompatibleChatModel( |
| | | StrUtil.blankToDefault(properties.getBaseUrl(), MiniMaxChatModel.BASE_URL), |
| | | null, properties.getApiKey(), properties.getModel(), properties.getTemperature(), |
| | | properties.getMaxTokens(), properties.getTopP())); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.moonshot.enable", havingValue = "true") |
| | | public MoonshotChatModel moonshotChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.Moonshot properties = yudaoAiProperties.getMoonshot(); |
| | | return buildMoonshotChatClient(properties); |
| | | } |
| | | |
| | | public MoonshotChatModel buildMoonshotChatClient(YudaoAiProperties.Moonshot properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(MoonshotChatModel.MODEL_DEFAULT); |
| | | } |
| | | return new MoonshotChatModel(buildDeepSeekCompatibleChatModel( |
| | | StrUtil.blankToDefault(properties.getBaseUrl(), MoonshotChatModel.BASE_URL), |
| | | MoonshotChatModel.COMPLETE_PATH, properties.getApiKey(), properties.getModel(), |
| | | properties.getTemperature(), properties.getMaxTokens(), properties.getTopP())); |
| | | } |
| | | |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.stepfun.enable", havingValue = "true") |
| | | public StepFunChatModel stepFunChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.StepFun properties = yudaoAiProperties.getStepfun(); |
| | | return buildStepFunChatClient(properties); |
| | | } |
| | | |
| | | public StepFunChatModel buildStepFunChatClient(YudaoAiProperties.StepFun properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(StepFunChatModel.MODEL_DEFAULT); |
| | | } |
| | | return new StepFunChatModel(buildDeepSeekCompatibleChatModel( |
| | | StrUtil.blankToDefault(properties.getBaseUrl(), StepFunChatModel.BASE_URL), |
| | | StepFunChatModel.COMPLETE_PATH, properties.getApiKey(), properties.getModel(), |
| | | properties.getTemperature(), properties.getMaxTokens(), properties.getTopP())); |
| | | } |
| | | |
| | | private static DeepSeekChatModel buildDeepSeekCompatibleChatModel(String baseUrl, String completionsPath, |
| | | String apiKey, String model, |
| | | Double temperature, Integer maxTokens, |
| | | Double topP) { |
| | | DeepSeekApi.Builder apiBuilder = DeepSeekApi.builder() |
| | | .baseUrl(baseUrl) |
| | | .apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(completionsPath)) { |
| | | apiBuilder.completionsPath(completionsPath); |
| | | } |
| | | return DeepSeekChatModel.builder() |
| | | .deepSeekApi(apiBuilder.build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(model) |
| | | .temperature(temperature) |
| | | .maxTokens(maxTokens) |
| | | .topP(topP) |
| | | .build()) |
| | | .build(); |
| | | } |
| | | |
| | | @Bean |
| | |
| | | return new SunoApi(yudaoAiProperties.getSuno().getBaseUrl()); |
| | | } |
| | | |
| | | public ChatModel buildGrokChatClient(YudaoAiProperties.Grok properties) { |
| | | @Bean |
| | | @ConditionalOnProperty(value = "yudao.ai.grok.enable", havingValue = "true") |
| | | public GrokChatModel grokChatClient(YudaoAiProperties yudaoAiProperties) { |
| | | YudaoAiProperties.Grok properties = yudaoAiProperties.getGrok(); |
| | | return buildGrokChatClient(properties); |
| | | } |
| | | |
| | | public GrokChatModel buildGrokChatClient(YudaoAiProperties.Grok properties) { |
| | | if (StrUtil.isEmpty(properties.getModel())) { |
| | | properties.setModel(GrokChatModel.MODEL_DEFAULT); |
| | | } |
| | | OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .baseUrl(Optional.ofNullable(properties.getBaseUrl()) |
| | | .orElse(GrokChatModel.BASE_URL)) |
| | | .apiKey(properties.getApiKey()) |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl(StrUtil.blankToDefault(properties.getBaseUrl(), GrokChatModel.BASE_URL)) |
| | | .apiKey(properties.getApiKey()) |
| | | .model(properties.getModel()) |
| | | .temperature(properties.getTemperature()) |
| | | .maxTokens(properties.getMaxTokens()) |
| | | .topP(properties.getTopP()) |
| | | .build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return new DouBaoChatModel(openAiChatModel); |
| | | return new GrokChatModel(openAiChatModel); |
| | | } |
| | | |
| | | // ========== RAG ç¸å
³ ========== |
| | |
| | | return SpringUtil.getBean(ToolCallingManager.class); |
| | | } |
| | | |
| | | private static ObservationRegistry getObservationRegistry() { |
| | | return SpringUtil.getBean(ObservationRegistry.class); |
| | | } |
| | | |
| | | // ========== Web Search ç¸å
³ ========== |
| | | |
| | | @Bean |
| | |
| | | public class YudaoAiProperties { |
| | | |
| | | /** |
| | | * è°·æ Gemini |
| | | */ |
| | | private Gemini gemini; |
| | | |
| | | /** |
| | | * åèè±å
|
| | | */ |
| | | private DouBao doubao; |
| | |
| | | private BaiChuan baichuan; |
| | | |
| | | /** |
| | | * æå¿ä¸è¨ |
| | | */ |
| | | private YiYan yiyan; |
| | | |
| | | /** |
| | | * æºè°± |
| | | */ |
| | | private ZhiPu zhipu; |
| | | |
| | | /** |
| | | * MiniMax |
| | | */ |
| | | private MiniMax minimax; |
| | | |
| | | /** |
| | | * æä¹æé¢ |
| | | */ |
| | | private Moonshot moonshot; |
| | | |
| | | /** |
| | | * é¶è·æè¾° |
| | | */ |
| | | private StepFun stepfun; |
| | | |
| | | /** |
| | | * Grok |
| | | */ |
| | | private Grok grok; |
| | | |
| | | /** |
| | | * Midjourney ç»å¾ |
| | | */ |
| | | private Midjourney midjourney; |
| | |
| | | * ç½ç»æç´¢ |
| | | */ |
| | | private WebSearch webSearch; |
| | | |
| | | @Data |
| | | public static class Gemini { |
| | | |
| | | private String enable; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class DouBao { |
| | |
| | | public static class XingHuo { |
| | | |
| | | private String enable; |
| | | private String appId; |
| | | private String appKey; |
| | | private String secretKey; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | |
| | | public static class BaiChuan { |
| | | |
| | | private String enable; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class YiYan { |
| | | |
| | | private String enable; |
| | | private String baseUrl; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class ZhiPu { |
| | | |
| | | private String enable; |
| | | private String baseUrl; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class MiniMax { |
| | | |
| | | private String enable; |
| | | private String baseUrl; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class Moonshot { |
| | | |
| | | private String enable; |
| | | private String baseUrl; |
| | | private String apiKey; |
| | | |
| | | private String model; |
| | |
| | | } |
| | | |
| | | @Data |
| | | public static class StepFun { |
| | | |
| | | private String enable; |
| | | private String apiKey; |
| | | private String baseUrl; |
| | | |
| | | private String model; |
| | | private Double temperature; |
| | | private Integer maxTokens; |
| | | private Double topP; |
| | | |
| | | } |
| | | |
| | | @Data |
| | | public static class WebSearch { |
| | | |
| | | private boolean enable; |
| | |
| | | import cn.hutool.core.util.RuntimeUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import cn.hutool.extra.spring.SpringUtil; |
| | | import cn.iocoder.yudao.framework.common.util.spring.SpringUtils; |
| | | import cn.iocoder.yudao.module.ai.enums.model.AiPlatformEnum; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.config.AiAutoConfiguration; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.config.YudaoAiProperties; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.baichuan.BaiChuanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.doubao.DouBaoChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.gemini.GeminiChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.hunyuan.HunYuanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.midjourney.api.MidjourneyApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.minimax.MiniMaxChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.moonshot.MoonshotChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowApiConstants; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowImageApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowImageModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.stepfun.StepFunChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.suno.api.SunoApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.xinghuo.XingHuoChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.yiyan.YiYanChatModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.zhipu.ZhiPuChatModel; |
| | | import cn.iocoder.yudao.module.ai.util.AiUtils; |
| | | import com.alibaba.cloud.ai.autoconfigure.dashscope.DashScopeChatAutoConfiguration; |
| | | import com.alibaba.cloud.ai.autoconfigure.dashscope.DashScopeEmbeddingAutoConfiguration; |
| | | import com.alibaba.cloud.ai.autoconfigure.dashscope.DashScopeImageAutoConfiguration; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeApi; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeImageApi; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatModel; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatOptions; |
| | | import com.alibaba.cloud.ai.dashscope.embedding.text.DashScopeEmbeddingModel; |
| | | import com.alibaba.cloud.ai.dashscope.embedding.text.DashScopeEmbeddingOptions; |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageModel; |
| | | import com.anthropic.client.okhttp.AnthropicOkHttpClient; |
| | | import com.azure.ai.openai.OpenAIClientBuilder; |
| | | import com.azure.core.credential.KeyCredential; |
| | | import com.openai.client.OpenAIClient; |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import com.google.genai.Client; |
| | | import com.google.genai.types.HttpOptions; |
| | | import io.micrometer.observation.ObservationRegistry; |
| | | import io.milvus.client.MilvusServiceClient; |
| | | import io.qdrant.client.QdrantClient; |
| | | import io.qdrant.client.QdrantGrpcClient; |
| | | import lombok.SneakyThrows; |
| | | import org.springaicommunity.moonshot.MoonshotChatModel; |
| | | import org.springaicommunity.moonshot.MoonshotChatOptions; |
| | | import org.springaicommunity.moonshot.api.MoonshotApi; |
| | | import org.springaicommunity.qianfan.QianFanChatModel; |
| | | import org.springaicommunity.qianfan.QianFanEmbeddingModel; |
| | | import org.springaicommunity.qianfan.QianFanEmbeddingOptions; |
| | | import org.springaicommunity.qianfan.QianFanImageModel; |
| | | import org.springaicommunity.qianfan.api.QianFanApi; |
| | | import org.springaicommunity.qianfan.api.QianFanImageApi; |
| | | import org.springframework.ai.azure.openai.AzureOpenAiChatModel; |
| | | import org.springframework.ai.azure.openai.AzureOpenAiEmbeddingModel; |
| | | import org.springframework.ai.anthropic.AnthropicChatModel; |
| | | import org.springframework.ai.anthropic.AnthropicChatOptions; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | |
| | | import org.springframework.ai.embedding.BatchingStrategy; |
| | | import org.springframework.ai.embedding.EmbeddingModel; |
| | | import org.springframework.ai.embedding.observation.EmbeddingModelObservationConvention; |
| | | import org.springframework.ai.google.genai.GoogleGenAiChatModel; |
| | | import org.springframework.ai.google.genai.GoogleGenAiChatOptions; |
| | | import org.springframework.ai.image.ImageModel; |
| | | import org.springframework.ai.minimax.MiniMaxChatModel; |
| | | import org.springframework.ai.minimax.MiniMaxChatOptions; |
| | | import org.springframework.ai.minimax.MiniMaxEmbeddingModel; |
| | | import org.springframework.ai.minimax.MiniMaxEmbeddingOptions; |
| | | import org.springframework.ai.minimax.api.MiniMaxApi; |
| | | import org.springframework.ai.model.anthropic.autoconfigure.AnthropicChatAutoConfiguration; |
| | | import org.springframework.ai.model.azure.openai.autoconfigure.AzureOpenAiChatAutoConfiguration; |
| | | import org.springframework.ai.model.azure.openai.autoconfigure.AzureOpenAiEmbeddingAutoConfiguration; |
| | | import org.springframework.ai.model.azure.openai.autoconfigure.AzureOpenAiEmbeddingProperties; |
| | | import org.springframework.ai.model.deepseek.autoconfigure.DeepSeekChatAutoConfiguration; |
| | | import org.springframework.ai.model.minimax.autoconfigure.MiniMaxChatAutoConfiguration; |
| | | import org.springframework.ai.model.minimax.autoconfigure.MiniMaxEmbeddingAutoConfiguration; |
| | | import org.springframework.ai.model.google.genai.autoconfigure.chat.GoogleGenAiChatAutoConfiguration; |
| | | import org.springframework.ai.model.ollama.autoconfigure.OllamaChatAutoConfiguration; |
| | | import org.springframework.ai.model.openai.autoconfigure.OpenAiChatAutoConfiguration; |
| | | import org.springframework.ai.model.openai.autoconfigure.OpenAiEmbeddingAutoConfiguration; |
| | | import org.springframework.ai.model.openai.autoconfigure.OpenAiImageAutoConfiguration; |
| | | import org.springframework.ai.model.stabilityai.autoconfigure.StabilityAiImageAutoConfiguration; |
| | | import org.springframework.ai.model.tool.ToolCallingManager; |
| | | import org.springframework.ai.model.zhipuai.autoconfigure.ZhiPuAiChatAutoConfiguration; |
| | | import org.springframework.ai.model.zhipuai.autoconfigure.ZhiPuAiEmbeddingAutoConfiguration; |
| | | import org.springframework.ai.model.zhipuai.autoconfigure.ZhiPuAiImageAutoConfiguration; |
| | | import org.springframework.ai.ollama.OllamaChatModel; |
| | | import org.springframework.ai.ollama.OllamaEmbeddingModel; |
| | | import org.springframework.ai.ollama.api.OllamaApi; |
| | | import org.springframework.ai.ollama.api.OllamaEmbeddingOptions; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiEmbeddingModel; |
| | | import org.springframework.ai.openai.OpenAiEmbeddingOptions; |
| | | import org.springframework.ai.openai.OpenAiImageModel; |
| | | import org.springframework.ai.anthropic.AnthropicChatModel; |
| | | import org.springframework.ai.openai.*; |
| | | import org.springframework.ai.retry.RetryUtils; |
| | | import org.springframework.ai.stabilityai.StabilityAiImageModel; |
| | | import org.springframework.ai.stabilityai.api.StabilityAiApi; |
| | | import org.springframework.ai.vectorstore.SimpleVectorStore; |
| | |
| | | import org.springframework.ai.vectorstore.redis.RedisVectorStore; |
| | | import org.springframework.ai.vectorstore.redis.autoconfigure.RedisVectorStoreAutoConfiguration; |
| | | import org.springframework.ai.vectorstore.redis.autoconfigure.RedisVectorStoreProperties; |
| | | import org.springframework.ai.zhipuai.*; |
| | | import org.springframework.ai.zhipuai.api.ZhiPuAiApi; |
| | | import org.springframework.ai.zhipuai.api.ZhiPuAiImageApi; |
| | | import org.springframework.beans.BeansException; |
| | | import org.springframework.beans.factory.ObjectProvider; |
| | | import org.springframework.boot.data.redis.autoconfigure.DataRedisProperties; |
| | | import org.springframework.web.client.RestClient; |
| | | import redis.clients.jedis.JedisPooled; |
| | | import redis.clients.jedis.DefaultJedisClientConfig; |
| | | import redis.clients.jedis.HostAndPort; |
| | | import redis.clients.jedis.JedisClientConfig; |
| | | import redis.clients.jedis.RedisClient; |
| | | |
| | | import java.io.File; |
| | | import java.time.Duration; |
| | | import java.util.List; |
| | | import java.util.Collections; |
| | | import java.util.Map; |
| | | import java.util.Timer; |
| | | import java.util.TimerTask; |
| | |
| | | public class AiModelFactoryImpl implements AiModelFactory { |
| | | |
| | | @Override |
| | | public ChatModel getOrCreateChatModel(AiPlatformEnum platform, String apiKey, String url) { |
| | | public ChatModel getOrCreateChatModel(AiPlatformEnum platform, String rawApiKey, String rawUrl) { |
| | | final String apiKey = resolveSpringPlaceholders(rawApiKey); |
| | | final String url = resolveSpringPlaceholders(rawUrl); |
| | | String cacheKey = buildClientCacheKey(ChatModel.class, platform, apiKey, url); |
| | | return Singleton.get(cacheKey, (Func0<ChatModel>) () -> { |
| | | // noinspection EnhancedSwitchMigration |
| | |
| | | return buildMiniMaxChatModel(apiKey, url); |
| | | case MOONSHOT: |
| | | return buildMoonshotChatModel(apiKey, url); |
| | | case STEP_FUN: |
| | | return buildStepFunChatModel(apiKey, url); |
| | | case XING_HUO: |
| | | return buildXingHuoChatModel(apiKey); |
| | | case BAI_CHUAN: |
| | |
| | | case ANTHROPIC: |
| | | return buildAnthropicChatModel(apiKey, url); |
| | | case GEMINI: |
| | | return buildGeminiChatModel(apiKey); |
| | | return buildGeminiChatModel(apiKey, url); |
| | | case OLLAMA: |
| | | return buildOllamaChatModel(url); |
| | | case GROK: |
| | | return buildGrokChatModel(apiKey,url); |
| | | return buildGrokChatModel(apiKey, url); |
| | | default: |
| | | throw new IllegalArgumentException(StrUtil.format("æªç¥å¹³å°({})", platform)); |
| | | } |
| | |
| | | case TONG_YI: |
| | | return SpringUtil.getBean(DashScopeChatModel.class); |
| | | case YI_YAN: |
| | | return SpringUtil.getBean(QianFanChatModel.class); |
| | | return SpringUtil.getBean(YiYanChatModel.class); |
| | | case DEEP_SEEK: |
| | | return SpringUtil.getBean(DeepSeekChatModel.class); |
| | | case DOU_BAO: |
| | |
| | | case SILICON_FLOW: |
| | | return SpringUtil.getBean(SiliconFlowChatModel.class); |
| | | case ZHI_PU: |
| | | return SpringUtil.getBean(ZhiPuAiChatModel.class); |
| | | return SpringUtil.getBean(ZhiPuChatModel.class); |
| | | case MINI_MAX: |
| | | return SpringUtil.getBean(MiniMaxChatModel.class); |
| | | case MOONSHOT: |
| | | return SpringUtil.getBean(MoonshotChatModel.class); |
| | | case STEP_FUN: |
| | | return SpringUtil.getBean(StepFunChatModel.class); |
| | | case XING_HUO: |
| | | return SpringUtil.getBean(XingHuoChatModel.class); |
| | | case BAI_CHUAN: |
| | | return SpringUtil.getBean(BaiChuanChatModel.class); |
| | | case OPENAI: |
| | | return SpringUtil.getBean(OpenAiChatModel.class); |
| | | case AZURE_OPENAI: |
| | | return SpringUtil.getBean(AzureOpenAiChatModel.class); |
| | | case ANTHROPIC: |
| | | return SpringUtil.getBean(AnthropicChatModel.class); |
| | | case GEMINI: |
| | | return SpringUtil.getBean(GeminiChatModel.class); |
| | | return SpringUtil.getBean(GoogleGenAiChatModel.class); |
| | | case OLLAMA: |
| | | return SpringUtil.getBean(OllamaChatModel.class); |
| | | default: |
| | |
| | | switch (platform) { |
| | | case TONG_YI: |
| | | return SpringUtil.getBean(DashScopeImageModel.class); |
| | | case YI_YAN: |
| | | return SpringUtil.getBean(QianFanImageModel.class); |
| | | case ZHI_PU: |
| | | return SpringUtil.getBean(ZhiPuAiImageModel.class); |
| | | case SILICON_FLOW: |
| | | return SpringUtil.getBean(SiliconFlowImageModel.class); |
| | | case OPENAI: |
| | |
| | | } |
| | | |
| | | @Override |
| | | public ImageModel getOrCreateImageModel(AiPlatformEnum platform, String apiKey, String url) { |
| | | public ImageModel getOrCreateImageModel(AiPlatformEnum platform, String rawApiKey, String rawUrl) { |
| | | String apiKey = resolveSpringPlaceholders(rawApiKey); |
| | | String url = resolveSpringPlaceholders(rawUrl); |
| | | // noinspection EnhancedSwitchMigration |
| | | switch (platform) { |
| | | case TONG_YI: |
| | | return buildTongYiImagesModel(apiKey); |
| | | case YI_YAN: |
| | | return buildQianFanImageModel(apiKey); |
| | | case ZHI_PU: |
| | | return buildZhiPuAiImageModel(apiKey, url); |
| | | case OPENAI: |
| | | return buildOpenAiImageModel(apiKey, url); |
| | | case SILICON_FLOW: |
| | | return buildSiliconFlowImageModel(apiKey,url); |
| | | return buildSiliconFlowImageModel(apiKey, url); |
| | | case STABLE_DIFFUSION: |
| | | return buildStabilityAiImageModel(apiKey, url); |
| | | default: |
| | |
| | | } |
| | | |
| | | @Override |
| | | public MidjourneyApi getOrCreateMidjourneyApi(String apiKey, String url) { |
| | | String cacheKey = buildClientCacheKey(MidjourneyApi.class, AiPlatformEnum.MIDJOURNEY.getPlatform(), apiKey, |
| | | url); |
| | | public MidjourneyApi getOrCreateMidjourneyApi(String rawApiKey, String rawUrl) { |
| | | final String apiKey = resolveSpringPlaceholders(rawApiKey); |
| | | final String url = resolveSpringPlaceholders(rawUrl); |
| | | String cacheKey = buildClientCacheKey(MidjourneyApi.class, AiPlatformEnum.MIDJOURNEY.getPlatform(), |
| | | apiKey, url); |
| | | return Singleton.get(cacheKey, (Func0<MidjourneyApi>) () -> { |
| | | YudaoAiProperties.Midjourney properties = SpringUtil.getBean(YudaoAiProperties.class) |
| | | .getMidjourney(); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public SunoApi getOrCreateSunoApi(String apiKey, String url) { |
| | | public SunoApi getOrCreateSunoApi(String rawApiKey, String rawUrl) { |
| | | final String apiKey = resolveSpringPlaceholders(rawApiKey); |
| | | final String url = resolveSpringPlaceholders(rawUrl); |
| | | String cacheKey = buildClientCacheKey(SunoApi.class, AiPlatformEnum.SUNO.getPlatform(), apiKey, url); |
| | | return Singleton.get(cacheKey, (Func0<SunoApi>) () -> new SunoApi(url)); |
| | | } |
| | | |
| | | @Override |
| | | @SuppressWarnings("EnhancedSwitchMigration") |
| | | public EmbeddingModel getOrCreateEmbeddingModel(AiPlatformEnum platform, String apiKey, String url, String model) { |
| | | public EmbeddingModel getOrCreateEmbeddingModel(AiPlatformEnum platform, String rawApiKey, String rawUrl, String model) { |
| | | final String apiKey = resolveSpringPlaceholders(rawApiKey); |
| | | final String url = resolveSpringPlaceholders(rawUrl); |
| | | String cacheKey = buildClientCacheKey(EmbeddingModel.class, platform, apiKey, url, model); |
| | | return Singleton.get(cacheKey, (Func0<EmbeddingModel>) () -> { |
| | | switch (platform) { |
| | | case TONG_YI: |
| | | return buildTongYiEmbeddingModel(apiKey, model); |
| | | case YI_YAN: |
| | | return buildYiYanEmbeddingModel(apiKey, model); |
| | | case ZHI_PU: |
| | | return buildZhiPuEmbeddingModel(apiKey, url, model); |
| | | case MINI_MAX: |
| | | return buildMiniMaxEmbeddingModel(apiKey, url, model); |
| | | case OPENAI: |
| | | return buildOpenAiEmbeddingModel(apiKey, url, model); |
| | | case AZURE_OPENAI: |
| | |
| | | return StrUtil.format("{}#{}", clazz.getName(), ArrayUtil.join(params, "_")); |
| | | } |
| | | |
| | | private static String resolveSpringPlaceholders(String value) { |
| | | // yml é
ç½®çå ä½ç¬¦ç± Spring èªå¨è§£æï¼DB éä¿åç ${xxx} éè¦å¨è¿éæå¨è§£æã |
| | | return AiUtils.resolveSpringPlaceholders(value); |
| | | } |
| | | |
| | | // ========== åç§å建 spring-ai 客æ·ç«¯çæ¹æ³ ========== |
| | | |
| | | /** |
| | | * å¯åè {@link DashScopeChatAutoConfiguration} ç dashscopeChatModel æ¹æ³ |
| | | */ |
| | | private static DashScopeChatModel buildTongYiChatModel(String key) { |
| | | DashScopeApi dashScopeApi = DashScopeApi.builder().apiKey(key).build(); |
| | | DashScopeChatOptions options = DashScopeChatOptions |
| | | .builder() |
| | | .model(DashScopeApi.DEFAULT_CHAT_MODEL) |
| | | .temperature(0.7) |
| | | .build(); |
| | | return DashScopeChatModel |
| | | .builder() |
| | | .dashScopeApi(dashScopeApi) |
| | | .defaultOptions(options) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | return AiAutoConfiguration.buildTongYiChatModel(key); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link DashScopeImageAutoConfiguration} ç dashScopeImageModel æ¹æ³ |
| | | */ |
| | | private static DashScopeImageModel buildTongYiImagesModel(String key) { |
| | | DashScopeImageApi dashScopeImageApi = DashScopeImageApi.builder().apiKey(key).build(); |
| | | return DashScopeImageModel.builder() |
| | | .dashScopeApi(dashScopeImageApi) |
| | | .build(); |
| | | return AiAutoConfiguration.buildTongYiImagesModel(key); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè QianFanChatAutoConfiguration ç qianFanChatModel æ¹æ³ |
| | | */ |
| | | private static QianFanChatModel buildYiYanChatModel(String key) { |
| | | // TODO spring ai qianfan æ bugï¼æ æ³ä½¿ç¨ https://github.com/spring-ai-community/qianfan/issues/6 |
| | | List<String> keys = StrUtil.split(key, '|'); |
| | | Assert.equals(keys.size(), 2, "YiYanChatClient çå¯é¥éè¦ (appKey|secretKey) æ ¼å¼"); |
| | | String appKey = keys.get(0); |
| | | String secretKey = keys.get(1); |
| | | QianFanApi qianFanApi = new QianFanApi(appKey, secretKey); |
| | | return new QianFanChatModel(qianFanApi); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè QianFanEmbeddingAutoConfiguration ç qianFanImageModel æ¹æ³ |
| | | */ |
| | | private QianFanImageModel buildQianFanImageModel(String key) { |
| | | // TODO spring ai qianfan æ bugï¼æ æ³ä½¿ç¨ https://github.com/spring-ai-community/qianfan/issues/6 |
| | | List<String> keys = StrUtil.split(key, '|'); |
| | | Assert.equals(keys.size(), 2, "YiYanChatClient çå¯é¥éè¦ (appKey|secretKey) æ ¼å¼"); |
| | | String appKey = keys.get(0); |
| | | String secretKey = keys.get(1); |
| | | QianFanImageApi qianFanApi = new QianFanImageApi(appKey, secretKey); |
| | | return new QianFanImageModel(qianFanApi); |
| | | private ChatModel buildYiYanChatModel(String apiKey) { |
| | | YudaoAiProperties.YiYan properties = new YudaoAiProperties.YiYan() |
| | | .setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildYiYanChatClient(properties); |
| | | } |
| | | |
| | | /** |
| | |
| | | .temperature(0.7).build(); |
| | | return DeepSeekChatModel.builder() |
| | | .deepSeekApi(deepSeekApi) |
| | | .defaultOptions(options) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .options(options) |
| | | .build(); |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link ZhiPuAiChatAutoConfiguration} ç zhiPuAiChatModel æ¹æ³ |
| | | * å¯åè {@link AiAutoConfiguration#zhiPuChatClient(YudaoAiProperties)} |
| | | */ |
| | | private ZhiPuAiChatModel buildZhiPuChatModel(String apiKey, String url) { |
| | | ZhiPuAiApi.Builder zhiPuAiApiBuilder = ZhiPuAiApi.builder().apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | zhiPuAiApiBuilder.baseUrl(url); |
| | | } |
| | | ZhiPuAiChatOptions options = ZhiPuAiChatOptions.builder().model(ZhiPuAiApi.DEFAULT_CHAT_MODEL).temperature(0.7).build(); |
| | | return new ZhiPuAiChatModel(zhiPuAiApiBuilder.build(), options, getToolCallingManager(), new org.springframework.core.retry.RetryTemplate(), |
| | | getObservationRegistry().getIfAvailable()); |
| | | private ZhiPuChatModel buildZhiPuChatModel(String apiKey, String url) { |
| | | YudaoAiProperties.ZhiPu properties = new YudaoAiProperties.ZhiPu() |
| | | .setBaseUrl(url).setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildZhiPuChatClient(properties); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link ZhiPuAiImageAutoConfiguration} ç zhiPuAiImageModel æ¹æ³ |
| | | */ |
| | | private ZhiPuAiImageModel buildZhiPuAiImageModel(String apiKey, String url) { |
| | | ZhiPuAiImageApi zhiPuAiApi = StrUtil.isEmpty(url) ? new ZhiPuAiImageApi(apiKey) |
| | | : new ZhiPuAiImageApi(url, apiKey, RestClient.builder()); |
| | | return new ZhiPuAiImageModel(zhiPuAiApi); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link MiniMaxChatAutoConfiguration} ç miniMaxChatModel æ¹æ³ |
| | | * å¯åè {@link AiAutoConfiguration#miniMaxChatClient(YudaoAiProperties)} |
| | | */ |
| | | private MiniMaxChatModel buildMiniMaxChatModel(String apiKey, String url) { |
| | | MiniMaxApi miniMaxApi = StrUtil.isEmpty(url) ? new MiniMaxApi(apiKey) |
| | | : new MiniMaxApi(url, apiKey); |
| | | MiniMaxChatOptions options = MiniMaxChatOptions.builder().model(MiniMaxApi.DEFAULT_CHAT_MODEL).temperature(0.7).build(); |
| | | return new MiniMaxChatModel(miniMaxApi, options, getToolCallingManager(), new org.springframework.core.retry.RetryTemplate()); |
| | | YudaoAiProperties.MiniMax properties = new YudaoAiProperties.MiniMax() |
| | | .setBaseUrl(url).setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildMiniMaxChatClient(properties); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè MoonshotChatAutoConfiguration ç moonshotChatModel æ¹æ³ |
| | | * å¯åè {@link AiAutoConfiguration#moonshotChatClient(YudaoAiProperties)} |
| | | */ |
| | | private MoonshotChatModel buildMoonshotChatModel(String apiKey, String url) { |
| | | MoonshotApi.Builder moonshotApiBuilder = MoonshotApi.builder() |
| | | .apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | moonshotApiBuilder.baseUrl(url); |
| | | } |
| | | MoonshotChatOptions options = MoonshotChatOptions.builder().model(MoonshotApi.DEFAULT_CHAT_MODEL).build(); |
| | | return MoonshotChatModel.builder() |
| | | .moonshotApi(moonshotApiBuilder.build()) |
| | | .defaultOptions(options) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | YudaoAiProperties.Moonshot properties = new YudaoAiProperties.Moonshot() |
| | | .setBaseUrl(url).setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildMoonshotChatClient(properties); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AiAutoConfiguration#stepFunChatClient(YudaoAiProperties)} |
| | | */ |
| | | private StepFunChatModel buildStepFunChatModel(String apiKey, String url) { |
| | | YudaoAiProperties.StepFun properties = new YudaoAiProperties.StepFun() |
| | | .setBaseUrl(url).setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildStepFunChatClient(properties); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AiAutoConfiguration#xingHuoChatClient(YudaoAiProperties)} |
| | | */ |
| | | private static XingHuoChatModel buildXingHuoChatModel(String key) { |
| | | List<String> keys = StrUtil.split(key, '|'); |
| | | Assert.equals(keys.size(), 2, "XingHuoChatClient çå¯é¥éè¦ (appKey|secretKey) æ ¼å¼"); |
| | | private static XingHuoChatModel buildXingHuoChatModel(String apiKey) { |
| | | YudaoAiProperties.XingHuo properties = new YudaoAiProperties.XingHuo() |
| | | .setAppKey(keys.get(0)).setSecretKey(keys.get(1)); |
| | | .setApiKey(apiKey).setModel(XingHuoChatModel.MODEL_DEFAULT); |
| | | return new AiAutoConfiguration().buildXingHuoChatClient(properties); |
| | | } |
| | | |
| | |
| | | */ |
| | | private static OpenAiChatModel buildOpenAiChatModel(String openAiToken, String url) { |
| | | return OpenAiChatModel.builder() |
| | | .openAiClient(buildOpenAiClient(openAiToken, url)) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .options(buildOpenAiChatOptions(openAiToken, url).build()) |
| | | .build(); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AzureOpenAiChatAutoConfiguration} |
| | | */ |
| | | private static AzureOpenAiChatModel buildAzureOpenAiChatModel(String apiKey, String url) { |
| | | // TODO @èè¿ï¼ä½¿ç¨åï¼è¯·æµè¯ï¼ææ¶æ²¡å¯é¥ï¼ï¼ï¼ |
| | | OpenAIClientBuilder openAIClientBuilder = new OpenAIClientBuilder() |
| | | .endpoint(url).credential(new KeyCredential(apiKey)); |
| | | return AzureOpenAiChatModel.builder() |
| | | .openAIClientBuilder(openAIClientBuilder) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | private static OpenAiChatModel buildAzureOpenAiChatModel(String openAiToken, String url) { |
| | | return OpenAiChatModel.builder() |
| | | .options(buildOpenAiChatOptions(openAiToken, url) |
| | | .azure(true) |
| | | .build()) |
| | | .build(); |
| | | } |
| | | |
| | | private static OpenAiChatOptions.Builder buildOpenAiChatOptions(String apiKey, String url) { |
| | | OpenAiChatOptions.Builder optionsBuilder = OpenAiChatOptions.builder().apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | optionsBuilder.baseUrl(url); |
| | | } |
| | | return optionsBuilder; |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AnthropicChatAutoConfiguration} ç anthropicApi æ¹æ³ |
| | | */ |
| | | private static AnthropicChatModel buildAnthropicChatModel(String apiKey, String url) { |
| | | AnthropicOkHttpClient.Builder builder = AnthropicOkHttpClient.builder().apiKey(apiKey); |
| | | AnthropicChatOptions.Builder optionsBuilder = AnthropicChatOptions.builder().apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | builder.baseUrl(url); |
| | | optionsBuilder.baseUrl(url); |
| | | } |
| | | return AnthropicChatModel.builder() |
| | | .anthropicClient(builder.build()) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .options(optionsBuilder.build()) |
| | | .build(); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AiAutoConfiguration#buildGeminiChatClient(YudaoAiProperties.Gemini)} |
| | | * å¯åè {@link GoogleGenAiChatAutoConfiguration} ç googleGenAiChatModel æ¹æ³ |
| | | */ |
| | | private static GeminiChatModel buildGeminiChatModel(String apiKey) { |
| | | YudaoAiProperties.Gemini properties = SpringUtil.getBean(YudaoAiProperties.class) |
| | | .getGemini().setApiKey(apiKey); |
| | | return new AiAutoConfiguration().buildGeminiChatClient(properties); |
| | | private static GoogleGenAiChatModel buildGeminiChatModel(String apiKey, String url) { |
| | | Client.Builder clientBuilder = Client.builder().apiKey(apiKey); |
| | | if (StrUtil.isNotBlank(url)) { |
| | | clientBuilder.httpOptions(HttpOptions.builder() |
| | | .baseUrl(url) |
| | | // TeamOrouter ç Gemini åçåè®®ä½¿ç¨ Authorization Bearer é´æ |
| | | .headers(Collections.singletonMap("Authorization", "Bearer " + apiKey)) |
| | | .build()); |
| | | } |
| | | return GoogleGenAiChatModel.builder() |
| | | .genAiClient(clientBuilder.build()) |
| | | .options(GoogleGenAiChatOptions.builder() |
| | | .model("gemini-2.5-flash") |
| | | .build()) |
| | | .toolCallingManager(SpringUtil.getBean(ToolCallingManager.class)) |
| | | .retryTemplate(RetryUtils.DEFAULT_RETRY_TEMPLATE) |
| | | .observationRegistry(SpringUtil.getBean(ObservationRegistry.class)) |
| | | .build(); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link OpenAiImageAutoConfiguration} ç openAiImageModel æ¹æ³ |
| | | */ |
| | | private OpenAiImageModel buildOpenAiImageModel(String openAiToken, String url) { |
| | | return new OpenAiImageModel(buildOpenAiClient(openAiToken, url)); |
| | | OpenAiImageOptions.Builder optionsBuilder = OpenAiImageOptions.builder().apiKey(openAiToken); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | optionsBuilder.baseUrl(url); |
| | | } |
| | | return OpenAiImageModel.builder() |
| | | .options(optionsBuilder.build()) |
| | | .build(); |
| | | } |
| | | |
| | | /** |
| | |
| | | OllamaApi ollamaApi = OllamaApi.builder().baseUrl(url).build(); |
| | | return OllamaChatModel.builder() |
| | | .ollamaApi(ollamaApi) |
| | | .toolCallingManager(getToolCallingManager()) |
| | | .build(); |
| | | } |
| | | |
| | |
| | | * å¯åè {@link DashScopeEmbeddingAutoConfiguration} ç DashScopeEmbeddingModel æ¹æ³ |
| | | */ |
| | | private DashScopeEmbeddingModel buildTongYiEmbeddingModel(String apiKey, String model) { |
| | | DashScopeApi dashScopeApi = DashScopeApi.builder().apiKey(apiKey).build(); |
| | | DashScopeEmbeddingOptions dashScopeEmbeddingOptions = DashScopeEmbeddingOptions.builder().model(model).build(); |
| | | return new DashScopeEmbeddingModel(dashScopeApi, MetadataMode.EMBED, dashScopeEmbeddingOptions); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link ZhiPuAiEmbeddingAutoConfiguration} ç ZhiPuAiEmbeddingModel æ¹æ³ |
| | | */ |
| | | private ZhiPuAiEmbeddingModel buildZhiPuEmbeddingModel(String apiKey, String url, String model) { |
| | | ZhiPuAiApi.Builder zhiPuAiApiBuilder = ZhiPuAiApi.builder().apiKey(apiKey); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | zhiPuAiApiBuilder.baseUrl(url); |
| | | } |
| | | ZhiPuAiEmbeddingOptions zhiPuAiEmbeddingOptions = ZhiPuAiEmbeddingOptions.builder().model(model).build(); |
| | | return new ZhiPuAiEmbeddingModel(zhiPuAiApiBuilder.build(), MetadataMode.EMBED, zhiPuAiEmbeddingOptions); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link MiniMaxEmbeddingAutoConfiguration} ç miniMaxEmbeddingModel æ¹æ³ |
| | | */ |
| | | private EmbeddingModel buildMiniMaxEmbeddingModel(String apiKey, String url, String model) { |
| | | MiniMaxApi miniMaxApi = StrUtil.isEmpty(url)? new MiniMaxApi(apiKey) |
| | | : new MiniMaxApi(url, apiKey); |
| | | MiniMaxEmbeddingOptions miniMaxEmbeddingOptions = MiniMaxEmbeddingOptions.builder().model(model).build(); |
| | | return new MiniMaxEmbeddingModel(miniMaxApi, MetadataMode.EMBED, miniMaxEmbeddingOptions); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link QianFanEmbeddingModel} ç qianFanEmbeddingModel æ¹æ³ |
| | | */ |
| | | private QianFanEmbeddingModel buildYiYanEmbeddingModel(String key, String model) { |
| | | List<String> keys = StrUtil.split(key, '|'); |
| | | Assert.equals(keys.size(), 2, "YiYanChatClient çå¯é¥éè¦ (appKey|secretKey) æ ¼å¼"); |
| | | String appKey = keys.get(0); |
| | | String secretKey = keys.get(1); |
| | | QianFanApi qianFanApi = new QianFanApi(appKey, secretKey); |
| | | QianFanEmbeddingOptions qianFanEmbeddingOptions = QianFanEmbeddingOptions.builder().model(model).build(); |
| | | return new QianFanEmbeddingModel(qianFanApi, MetadataMode.EMBED, qianFanEmbeddingOptions); |
| | | return AiAutoConfiguration.buildTongYiEmbeddingModel(apiKey, model); |
| | | } |
| | | |
| | | private OllamaEmbeddingModel buildOllamaEmbeddingModel(String url, String model) { |
| | |
| | | OllamaEmbeddingOptions ollamaOptions = OllamaEmbeddingOptions.builder().model(model).build(); |
| | | return OllamaEmbeddingModel.builder() |
| | | .ollamaApi(ollamaApi) |
| | | .defaultOptions(ollamaOptions) |
| | | .options(ollamaOptions) |
| | | .build(); |
| | | } |
| | | |
| | |
| | | * å¯åè {@link OpenAiEmbeddingAutoConfiguration} ç openAiEmbeddingModel æ¹æ³ |
| | | */ |
| | | private OpenAiEmbeddingModel buildOpenAiEmbeddingModel(String openAiToken, String url, String model) { |
| | | OpenAiEmbeddingOptions openAiEmbeddingProperties = OpenAiEmbeddingOptions.builder().model(model).build(); |
| | | return new OpenAiEmbeddingModel(buildOpenAiClient(openAiToken, url), MetadataMode.EMBED, openAiEmbeddingProperties); |
| | | } |
| | | |
| | | private static OpenAIClient buildOpenAiClient(String apiKey, String url) { |
| | | OpenAIOkHttpClient.Builder builder = OpenAIOkHttpClient.builder().apiKey(apiKey); |
| | | OpenAiEmbeddingOptions.Builder optionsBuilder = OpenAiEmbeddingOptions.builder() |
| | | .apiKey(openAiToken) |
| | | .model(model); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | builder.baseUrl(url); |
| | | optionsBuilder.baseUrl(url); |
| | | } |
| | | return builder.build(); |
| | | return OpenAiEmbeddingModel.builder() |
| | | .metadataMode(MetadataMode.EMBED) |
| | | .options(optionsBuilder.build()) |
| | | .build(); |
| | | } |
| | | |
| | | /** |
| | | * å¯åè {@link AzureOpenAiEmbeddingAutoConfiguration} ç azureOpenAiEmbeddingModel æ¹æ³ |
| | | */ |
| | | private AzureOpenAiEmbeddingModel buildAzureOpenAiEmbeddingModel(String apiKey, String url, String model) { |
| | | // TODO @èè¿ï¼æå¤´ææ¶æ²¡å¯é¥ï¼ä½¿ç¨å»ºè®®åæµè¯ä¸ |
| | | AzureOpenAiEmbeddingAutoConfiguration azureOpenAiAutoConfiguration = new AzureOpenAiEmbeddingAutoConfiguration(); |
| | | // å建 OpenAIClientBuilder 对象 |
| | | OpenAIClientBuilder openAIClientBuilder = new OpenAIClientBuilder() |
| | | .endpoint(url).credential(new KeyCredential(apiKey)); |
| | | // è·å AzureOpenAiChatProperties 对象 |
| | | AzureOpenAiEmbeddingProperties embeddingProperties = SpringUtil.getBean(AzureOpenAiEmbeddingProperties.class); |
| | | return azureOpenAiAutoConfiguration.azureOpenAiEmbeddingModel(openAIClientBuilder, embeddingProperties, |
| | | getObservationRegistry(), getEmbeddingModelObservationConvention()); |
| | | private OpenAiEmbeddingModel buildAzureOpenAiEmbeddingModel(String openAiToken, String url, String model) { |
| | | OpenAiEmbeddingOptions.Builder optionsBuilder = OpenAiEmbeddingOptions.builder() |
| | | .apiKey(openAiToken) |
| | | .model(model) |
| | | .deploymentName(model) |
| | | .azure(true); |
| | | if (StrUtil.isNotEmpty(url)) { |
| | | optionsBuilder.baseUrl(url); |
| | | } |
| | | return OpenAiEmbeddingModel.builder() |
| | | .metadataMode(MetadataMode.EMBED) |
| | | .options(optionsBuilder.build()) |
| | | .build(); |
| | | } |
| | | |
| | | // ========== åç§å建 VectorStore çæ¹æ³ ========== |
| | |
| | | */ |
| | | private RedisVectorStore buildRedisVectorStore(EmbeddingModel embeddingModel, |
| | | Map<String, Class<?>> metadataFields) { |
| | | // å建 JedisPooled 对象 |
| | | DataRedisProperties redisProperties = SpringUtils.getBean(DataRedisProperties.class); |
| | | JedisPooled jedisPooled = new JedisPooled(redisProperties.getHost(), redisProperties.getPort(), |
| | | redisProperties.getUsername(), redisProperties.getPassword()); |
| | | // å建 RedisClient 对象 |
| | | RedisClient redisClient = buildRedisClient(); |
| | | // å建 RedisVectorStoreProperties 对象 |
| | | RedisVectorStoreProperties properties = SpringUtil.getBean(RedisVectorStoreProperties.class); |
| | | RedisVectorStore redisVectorStore = RedisVectorStore.builder(jedisPooled, embeddingModel) |
| | | RedisVectorStore redisVectorStore = RedisVectorStore.builder(redisClient, embeddingModel) |
| | | .indexName(properties.getIndexName()).prefix(properties.getPrefix()) |
| | | .initializeSchema(properties.isInitializeSchema()) |
| | | .metadataFields(convertList(metadataFields.entrySet(), entry -> { |
| | |
| | | // åå§åç´¢å¼ |
| | | redisVectorStore.afterPropertiesSet(); |
| | | return redisVectorStore; |
| | | } |
| | | |
| | | private RedisClient buildRedisClient() { |
| | | DataRedisProperties redisProperties = SpringUtil.getBean(DataRedisProperties.class); |
| | | Assert.isNull(redisProperties.getCluster(), "RedisVectorStore æä¸æ¯æ Redis Cluster 模å¼"); |
| | | Assert.isNull(redisProperties.getSentinel(), "RedisVectorStore æä¸æ¯æ Redis Sentinel 模å¼"); |
| | | Assert.isNull(redisProperties.getMasterreplica(), "RedisVectorStore æä¸æ¯æ Redis Master-Replica 模å¼"); |
| | | if (StrUtil.isNotEmpty(redisProperties.getUrl())) { |
| | | return RedisClient.create(redisProperties.getUrl()); |
| | | } |
| | | DefaultJedisClientConfig.Builder clientConfigBuilder = DefaultJedisClientConfig.builder() |
| | | .ssl(redisProperties.getSsl().isEnabled()) |
| | | .database(redisProperties.getDatabase()); |
| | | if (StrUtil.isNotEmpty(redisProperties.getUsername())) { |
| | | clientConfigBuilder.user(redisProperties.getUsername()); |
| | | } |
| | | if (StrUtil.isNotEmpty(redisProperties.getPassword())) { |
| | | clientConfigBuilder.password(redisProperties.getPassword()); |
| | | } |
| | | if (StrUtil.isNotEmpty(redisProperties.getClientName())) { |
| | | clientConfigBuilder.clientName(redisProperties.getClientName()); |
| | | } |
| | | if (redisProperties.getTimeout() != null) { |
| | | clientConfigBuilder.socketTimeoutMillis(toMillis(redisProperties.getTimeout())); |
| | | } |
| | | if (redisProperties.getConnectTimeout() != null) { |
| | | clientConfigBuilder.connectionTimeoutMillis(toMillis(redisProperties.getConnectTimeout())); |
| | | } |
| | | JedisClientConfig clientConfig = clientConfigBuilder.build(); |
| | | return RedisClient.builder() |
| | | .hostAndPort(new HostAndPort(redisProperties.getHost(), redisProperties.getPort())) |
| | | .clientConfig(clientConfig) |
| | | .build(); |
| | | } |
| | | |
| | | private static int toMillis(Duration duration) { |
| | | return Math.toIntExact(duration.toMillis()); |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | private static BatchingStrategy getBatchingStrategy() { |
| | | return SpringUtil.getBean(BatchingStrategy.class); |
| | | } |
| | | |
| | | private static ToolCallingManager getToolCallingManager() { |
| | | return SpringUtil.getBean(ToolCallingManager.class); |
| | | } |
| | | |
| | | private static ObjectProvider<EmbeddingModelObservationConvention> getEmbeddingModelObservationConvention() { |
| | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | |
| | | |
| | | public static final String BASE_URL = "https://api.baichuan-ai.com"; |
| | | |
| | | public static final String MODEL_DEFAULT = "Baichuan4-Turbo"; |
| | | public static final String COMPLETE_PATH = "/v1/chat/completions"; |
| | | |
| | | public static final String MODEL_DEFAULT = "Baichuan-M3"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final OpenAiChatModel openAiChatModel; |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return openAiChatModel.call(prompt); |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return openAiChatModel.stream(prompt); |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModel.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | public static final String BASE_URL = "https://ark.cn-beijing.volces.com/api"; |
| | | public static final String COMPLETE_PATH = "/v3/chat/completions"; |
| | | |
| | | public static final String MODEL_DEFAULT = "doubao-1-5-lite-32k-250115"; |
| | | public static final String MODEL_DEFAULT = "doubao-seed-2-1-turbo-260628"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return openAiChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModel.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | @RequiredArgsConstructor |
| | | public class GrokChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://api.x.ai"; |
| | | public static final String BASE_URL = "https://api.x.ai/v1"; |
| | | public static final String COMPLETE_PATH = "/v1/chat/completions"; |
| | | public static final String MODEL_DEFAULT = "grok-4-fast-reasoning"; |
| | | public static final String MODEL_DEFAULT = "grok-4.3"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return openAiChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModel.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * è
¾äºæ··å
{@link ChatModel} å®ç°ç±» |
| | | * è
¾è®¯æ··å
{@link ChatModel} å®ç°ç±» |
| | | * |
| | | * 1. æ··å
大模åï¼åºäº <a href="https://cloud.tencent.com/document/product/1729/111007">ç¥è¯å¼æååè½å</a> å®ç° |
| | | * 2. ç¥è¯å¼æååè½åï¼åºäº <a href="https://cloud.tencent.com/document/product/1772/115969">ç¥è¯å¼æååè½å</a> å®ç° |
| | | * åºäº <a href="https://cloud.tencent.com/document/product/1823/132252">TokenHub OpenAI å
¼å®¹æ¥å£</a> å®ç° |
| | | * |
| | | * @author fansili |
| | | */ |
| | |
| | | @RequiredArgsConstructor |
| | | public class HunYuanChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://api.hunyuan.cloud.tencent.com"; |
| | | public static final String BASE_URL = "https://tokenhub.tencentmaas.com"; |
| | | public static final String COMPLETE_PATH = "/v1/chat/completions"; |
| | | |
| | | public static final String MODEL_DEFAULT = "hunyuan-turbo"; |
| | | |
| | | public static final String DEEP_SEEK_BASE_URL = "https://api.lkeap.cloud.tencent.com"; |
| | | |
| | | public static final String DEEP_SEEK_MODEL_DEFAULT = "deepseek-v3"; |
| | | public static final String MODEL_DEFAULT = "hy3-preview"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return openAiChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModel.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.minimax; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * MiniMax {@link ChatModel} å®ç°ç±» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class MiniMaxChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://api.minimaxi.com/v1"; |
| | | |
| | | public static final String MODEL_DEFAULT = "MiniMax-M3"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.moonshot; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * æä¹æé¢ {@link ChatModel} å®ç°ç±» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class MoonshotChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://api.moonshot.cn"; |
| | | |
| | | public static final String COMPLETE_PATH = "/v1/chat/completions"; |
| | | |
| | | public static final String MODEL_DEFAULT = "kimi-k2.6"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | public static final String DEFAULT_BASE_URL = "https://api.siliconflow.cn"; |
| | | |
| | | public static final String MODEL_DEFAULT = "deepseek-ai/DeepSeek-R1-Distill-Qwen-7B"; |
| | | public static final String MODEL_DEFAULT = "deepseek-ai/DeepSeek-V4-Pro"; |
| | | |
| | | public static final String DEFAULT_IMAGE_MODEL = "Kwai-Kolors/Kolors"; |
| | | |
| | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return openAiChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModel.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | import org.springframework.ai.openai.OpenAiImageModel; |
| | | import org.springframework.ai.openai.metadata.OpenAiImageGenerationMetadata; |
| | | import org.springframework.ai.retry.RetryUtils; |
| | | import org.springframework.core.retry.RetryTemplate; |
| | | import org.springframework.http.ResponseEntity; |
| | | import org.jspecify.annotations.Nullable; |
| | | import org.springframework.retry.support.RetryTemplate; |
| | | import org.springframework.util.Assert; |
| | | |
| | | import java.util.List; |
| | |
| | | .observation(this.observationConvention, DEFAULT_OBSERVATION_CONVENTION, () -> observationContext, |
| | | this.observationRegistry) |
| | | .observe(() -> { |
| | | ResponseEntity<SiliconFlowImageApi.SiliconFlowImageResponse> imageResponseEntity = this.retryTemplate |
| | | .execute(ctx -> this.siliconFlowImageApi.createImage(imageRequest)); |
| | | ResponseEntity<SiliconFlowImageApi.SiliconFlowImageResponse> imageResponseEntity = RetryUtils.execute( |
| | | this.retryTemplate, () -> this.siliconFlowImageApi.createImage(imageRequest)); |
| | | |
| | | ImageResponse imageResponse = convertResponse(imageResponseEntity, imageRequest); |
| | | |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.stepfun; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * é¶è·æè¾° {@link ChatModel} å®ç°ç±» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class StepFunChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://api.stepfun.com"; |
| | | |
| | | public static final String COMPLETE_PATH = "/v1/chat/completions"; |
| | | |
| | | public static final String MODEL_DEFAULT = "step-3.7-flash"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.xinghuo; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | |
| | | * @author fansili |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class XingHuoChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL_V1 = "https://spark-api-open.xf-yun.com"; |
| | | |
| | | public static final String BASE_URL_V2 = "https://spark-api-open.xf-yun.com"; |
| | | public static final String BASE_COMPLETIONS_PATH_V2 = "/v2/chat/completions"; |
| | | /** |
| | | * æç« X2 |
| | | * |
| | | * @see <a href="https://spark-api-open.xf-yun.com/x2/chat/completions">æ¥å£å°å</a> |
| | | */ |
| | | public static final String MODEL_X2 = "x2"; |
| | | |
| | | /** |
| | | * å·²ç¥æ¨¡ååå表ï¼x1ã4.0Ultraãgeneralv3.5ãmax-32kãgeneralv3ãpro-128kãlite |
| | | * æç« X2 Flash |
| | | * |
| | | * @see <a href="https://spark-api-open.xf-yun.com/agent/v1/chat/completions">æ¥å£å°å</a> |
| | | */ |
| | | public static final String MODEL_DEFAULT = "4.0Ultra"; |
| | | public static final String MODEL_X2_FLASH = "x2-flash"; |
| | | |
| | | private static final String BASE_URL_X2 = "https://spark-api-open.xf-yun.com/x2"; |
| | | |
| | | private static final String BASE_URL_X2_FLASH = "https://spark-api-open.xf-yun.com/agent/v1"; |
| | | |
| | | public static final String MODEL_DEFAULT = MODEL_X2_FLASH; |
| | | |
| | | private static String getBaseUrl(String model) { |
| | | if (MODEL_X2_FLASH.equals(model)) { |
| | | return BASE_URL_X2_FLASH; |
| | | } |
| | | return BASE_URL_X2; |
| | | } |
| | | |
| | | private final String apiKey; |
| | | |
| | | private final DeepSeekChatOptions options; |
| | | |
| | | /** |
| | | * v1 å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼è¿è¡å¤ç¨ |
| | | */ |
| | | private final ChatModel openAiChatModelV1; |
| | | private final ChatModel chatModelX2; |
| | | |
| | | private final ChatModel chatModelX2Flash; |
| | | |
| | | private XingHuoChatModel(String apiKey, DeepSeekChatOptions options) { |
| | | this.apiKey = apiKey; |
| | | this.options = options; |
| | | this.chatModelX2 = buildChatModel(MODEL_X2); |
| | | this.chatModelX2Flash = buildChatModel(MODEL_X2_FLASH); |
| | | } |
| | | |
| | | public static Builder builder() { |
| | | return new Builder(); |
| | | } |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return openAiChatModelV1.call(prompt); |
| | | return getChatModel(prompt).call(buildApiPrompt(prompt)); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return openAiChatModelV1.stream(prompt); |
| | | return getChatModel(prompt).stream(buildApiPrompt(prompt)); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return options; |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return openAiChatModelV1.getDefaultOptions(); |
| | | return getOptions(); |
| | | } |
| | | |
| | | private ChatModel getChatModel(Prompt prompt) { |
| | | String model = options.getModel(); |
| | | ChatOptions options = prompt.getOptions(); |
| | | if (options != null && isBusinessModel(options.getModel())) { |
| | | model = options.getModel(); |
| | | } |
| | | return getChatModel(model); |
| | | } |
| | | |
| | | private ChatModel getChatModel(String model) { |
| | | if (MODEL_X2_FLASH.equals(model)) { |
| | | return chatModelX2Flash; |
| | | } |
| | | return chatModelX2; |
| | | } |
| | | |
| | | private ChatModel buildChatModel(String model) { |
| | | return DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(getBaseUrl(model)) |
| | | .apiKey(apiKey) |
| | | .build()) |
| | | .options(options.mutate().model("spark-x").build()) |
| | | .build(); |
| | | } |
| | | |
| | | private static Prompt buildApiPrompt(Prompt prompt) { |
| | | ChatOptions options = prompt.getOptions(); |
| | | if (options == null) { |
| | | return prompt; |
| | | } |
| | | return Prompt.builder() |
| | | .messages(prompt.getInstructions()) |
| | | .chatOptions(options.mutate().model("spark-x").build()) |
| | | .build(); |
| | | } |
| | | |
| | | private static boolean isBusinessModel(String model) { |
| | | return MODEL_X2.equals(model) || MODEL_X2_FLASH.equals(model); |
| | | } |
| | | |
| | | public static final class Builder { |
| | | |
| | | private String apiKey; |
| | | |
| | | private DeepSeekChatOptions options; |
| | | |
| | | public Builder apiKey(String apiKey) { |
| | | this.apiKey = apiKey; |
| | | return this; |
| | | } |
| | | |
| | | public Builder options(DeepSeekChatOptions options) { |
| | | this.options = options; |
| | | return this; |
| | | } |
| | | |
| | | public XingHuoChatModel build() { |
| | | DeepSeekChatOptions options = this.options != null ? this.options : DeepSeekChatOptions.builder().build(); |
| | | if (StrUtil.isEmpty(options.getModel())) { |
| | | options = options.mutate().model(MODEL_DEFAULT).build(); |
| | | } |
| | | return new XingHuoChatModel(apiKey, options); |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.yiyan; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * æå¿ä¸è¨ {@link ChatModel} å®ç°ç±» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class YiYanChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://qianfan.baidubce.com/v2"; |
| | | |
| | | public static final String MODEL_DEFAULT = "ernie-5.1"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.zhipu; |
| | | |
| | | import lombok.RequiredArgsConstructor; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.ai.chat.model.ChatModel; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | /** |
| | | * æºè°± {@link ChatModel} å®ç°ç±» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Slf4j |
| | | @RequiredArgsConstructor |
| | | public class ZhiPuChatModel implements ChatModel { |
| | | |
| | | public static final String BASE_URL = "https://open.bigmodel.cn/api/paas/v4"; |
| | | |
| | | public static final String MODEL_DEFAULT = "glm-5.2"; |
| | | |
| | | /** |
| | | * å
¼å®¹ OpenAI æ¥å£ï¼å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | */ |
| | | private final DeepSeekChatModel deepSeekChatModel; |
| | | |
| | | @Override |
| | | public ChatResponse call(Prompt prompt) { |
| | | return deepSeekChatModel.call(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public Flux<ChatResponse> stream(Prompt prompt) { |
| | | return deepSeekChatModel.stream(prompt); |
| | | } |
| | | |
| | | @Override |
| | | public ChatOptions getOptions() { |
| | | return deepSeekChatModel.getOptions(); |
| | | } |
| | | |
| | | @Override |
| | | @Deprecated(forRemoval = true) |
| | | @SuppressWarnings("removal") |
| | | public ChatOptions getDefaultOptions() { |
| | | return getOptions(); |
| | | } |
| | | |
| | | } |
| | |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageOptions; |
| | | import jakarta.annotation.Resource; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springaicommunity.qianfan.QianFanImageOptions; |
| | | import org.springframework.ai.image.ImageModel; |
| | | import org.springframework.ai.image.ImageOptions; |
| | | import org.springframework.ai.image.ImagePrompt; |
| | | import org.springframework.ai.image.ImageResponse; |
| | | import org.springframework.ai.openai.OpenAiImageOptions; |
| | | import org.springframework.ai.stabilityai.api.StabilityAiImageOptions; |
| | | import org.springframework.ai.zhipuai.ZhiPuAiImageOptions; |
| | | import org.springframework.scheduling.annotation.Async; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | return DashScopeImageOptions.builder() |
| | | .model(model.getModel()).n(1) |
| | | .height(draw.getHeight()).width(draw.getWidth()) |
| | | .build(); |
| | | } else if (ObjUtil.equal(model.getPlatform(), AiPlatformEnum.YI_YAN.getPlatform())) { |
| | | return QianFanImageOptions.builder() |
| | | .model(model.getModel()).N(1) |
| | | .height(draw.getHeight()).width(draw.getWidth()) |
| | | .build(); |
| | | } else if (ObjUtil.equal(model.getPlatform(), AiPlatformEnum.ZHI_PU.getPlatform())) { |
| | | return ZhiPuAiImageOptions.builder() |
| | | .model(model.getModel()) |
| | | .build(); |
| | | } |
| | | throw new IllegalArgumentException("䏿¯æç AI å¹³å°ï¼" + model.getPlatform()); |
| | |
| | | import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder; |
| | | import cn.iocoder.yudao.module.ai.enums.model.AiPlatformEnum; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatOptions; |
| | | import org.springaicommunity.moonshot.MoonshotChatOptions; |
| | | import org.springaicommunity.qianfan.QianFanChatOptions; |
| | | import cn.hutool.extra.spring.SpringUtil; |
| | | import org.springframework.ai.anthropic.AnthropicChatOptions; |
| | | import org.springframework.ai.azure.openai.AzureOpenAiChatOptions; |
| | | import org.springframework.ai.chat.messages.*; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.ai.deepseek.DeepSeekAssistantMessage; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.minimax.MiniMaxChatOptions; |
| | | import org.springframework.ai.google.genai.GoogleGenAiChatOptions; |
| | | import org.springframework.ai.ollama.api.OllamaChatOptions; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import org.springframework.ai.tool.ToolCallback; |
| | | import org.springframework.ai.zhipuai.ZhiPuAiChatOptions; |
| | | import org.springframework.core.env.Environment; |
| | | |
| | | import java.util.*; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| | | import static cn.iocoder.yudao.module.ai.enums.ErrorCodeConstants.API_CONFIG_PLACEHOLDER_NOT_RESOLVED; |
| | | |
| | | /** |
| | | * Spring AI å·¥å
·ç±» |
| | |
| | | public static final String TOOL_CONTEXT_TENANT_ID = "TENANT_ID"; |
| | | |
| | | /** |
| | | * è§£æ DB ç卿é
ç½®éç Spring å ä½ç¬¦ï¼ä¾å¦ ${OPENAI_API_KEY} |
| | | * |
| | | * @param value å¾
è§£æçé
ç½®å¼ |
| | | * @return è§£æåçé
ç½®å¼ |
| | | */ |
| | | public static String resolveSpringPlaceholders(String value) { |
| | | if (StrUtil.isBlank(value) || !StrUtil.contains(value, "${")) { |
| | | return value; |
| | | } |
| | | try { |
| | | return SpringUtil.getBean(Environment.class).resolveRequiredPlaceholders(value); |
| | | } catch (IllegalArgumentException ex) { |
| | | throw exception(API_CONFIG_PLACEHOLDER_NOT_RESOLVED, value); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ ¡éª API Keyï¼é¿å
éææµè¯ä½¿ç¨é»è®¤å ä½å¼åèµ·è°ç¨ã |
| | | * |
| | | * @param apiKey API Key |
| | | */ |
| | | public static void validateApiKey(String apiKey) { |
| | | if (StrUtil.isBlank(apiKey) || "sk-xxxx".equals(apiKey)) { |
| | | throw new IllegalStateException("apiKey ä¸è½ä¸ºç©º"); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * éä¹å鮿¯æå¤æ¨¡æç模å |
| | | * |
| | | * @see <a href="https://bailian.console.aliyun.com/cn-beijing/?tab=model#/model-market/all?providers=qwen&capabilities=VU">模å广åº</a> |
| | | * @see <a href="https://help.aliyun.com/zh/model-studio/error-code#error-url">å¿
é¡»å¼å¯ withMultiModel åæ°</a> |
| | | */ |
| | | public static final Set<String> TONG_YI_MULTI_MODELS = SetUtils.asSet( |
| | | // qwen3.5 / 3.6 ç³»åï¼ç»ä¸å¤æ¨¡æä¸»å¹²ï¼ |
| | | // qwen3.5 / 3.6 / 3.7 ç³»åï¼ç»ä¸å¤æ¨¡æä¸»å¹²ï¼ |
| | | "qwen3.7-max", "qwen3.7-plus", "qwen3.7-flash", |
| | | "qwen3.6-plus", "qwen3.6-flash", |
| | | "qwen3.5-plus", "qwen3.5-flash", |
| | | // qwen-vl è§è§çè§£ |
| | |
| | | .enableThinking(true) // TODO èè¿ï¼é»è®¤é½å¼å¯ thinking 模å¼ï¼åç»å¯ä»¥è®©ç¨æ·é
ç½® |
| | | .multiModel(TONG_YI_MULTI_MODELS.contains(model)) // æ¯å¦å¤æ¨¡ææ¨¡å |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case YI_YAN: |
| | | return QianFanChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens).build(); |
| | | case DEEP_SEEK: |
| | | case DOU_BAO: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case HUN_YUAN: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case SILICON_FLOW: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case YI_YAN: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case ZHI_PU: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case XING_HUO: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case MINI_MAX: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case MOONSHOT: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case BAI_CHUAN: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | case STEP_FUN: // å¤ç¨ DeepSeek 客æ·ç«¯ |
| | | return DeepSeekChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case ZHI_PU: |
| | | return ZhiPuAiChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case MINI_MAX: |
| | | return MiniMaxChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case MOONSHOT: |
| | | return MoonshotChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case OPENAI: |
| | | case GEMINI: // å¤ç¨ OpenAI 客æ·ç«¯ |
| | | case BAI_CHUAN: // å¤ç¨ OpenAI 客æ·ç«¯ |
| | | case GROK: // å¤ç¨ OpenAI 客æ·ç«¯ |
| | | return OpenAiChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case GEMINI: |
| | | return GoogleGenAiChatOptions.builder().model(model).temperature(temperature).maxOutputTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case AZURE_OPENAI: |
| | | return AzureOpenAiChatOptions.builder().deploymentName(model).temperature(temperature).maxTokens(maxTokens) |
| | | return OpenAiChatOptions.builder().model(model).deploymentName(model).azure(true) |
| | | .temperature(temperature).maxTokens(maxTokens) |
| | | .toolCallbacks(toolCallbacks).toolContext(toolContext).build(); |
| | | case ANTHROPIC: |
| | | return AnthropicChatOptions.builder().model(model).temperature(temperature).maxTokens(maxTokens) |
| | |
| | | return MapUtil.getStr(output.getMetadata(), "reasoningContent"); |
| | | } |
| | | |
| | | } |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.springframework.ai.model.tool; |
| | | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | |
| | | import java.lang.reflect.Method; |
| | | |
| | | /** |
| | | * TODO èè¿ï¼spring-ai-alibaba 2.0.0-M1.1 ä»ä¾èµæ§ç Spring AI ToolExecutionEligibilityPredicateï¼ |
| | | * 临æ¶è¡¥é½ï¼å级å°å
¼å®¹ Spring AI 2.0.0 ç spring-ai-alibaba çæ¬åï¼å 餿¬å
ä¸ç shimã |
| | | */ |
| | | public class DefaultToolExecutionEligibilityPredicate implements ToolExecutionEligibilityPredicate { |
| | | |
| | | @Override |
| | | public boolean test(ChatOptions promptOptions, ChatResponse chatResponse) { |
| | | return isInternalToolExecutionEnabled(promptOptions) && chatResponse != null && chatResponse.hasToolCalls(); |
| | | } |
| | | |
| | | private static boolean isInternalToolExecutionEnabled(ChatOptions promptOptions) { |
| | | try { |
| | | Method method = promptOptions.getClass().getMethod("getInternalToolExecutionEnabled"); |
| | | Object result = method.invoke(promptOptions); |
| | | return result == null || Boolean.TRUE.equals(result); |
| | | } catch (ReflectiveOperationException | SecurityException ignored) { |
| | | return true; |
| | | } |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package org.springframework.ai.model.tool; |
| | | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.ChatOptions; |
| | | import org.springframework.util.Assert; |
| | | |
| | | import java.util.function.BiPredicate; |
| | | |
| | | /** |
| | | * TODO èè¿ï¼spring-ai-alibaba 2.0.0-M1.1 ä»ä¾èµæ§ç Spring AI ToolExecutionEligibilityPredicateï¼ |
| | | * 临æ¶è¡¥é½ï¼å级å°å
¼å®¹ Spring AI 2.0.0 ç spring-ai-alibaba çæ¬åï¼å 餿¬å
ä¸ç shimã |
| | | */ |
| | | public interface ToolExecutionEligibilityPredicate extends BiPredicate<ChatOptions, ChatResponse> { |
| | | |
| | | default boolean isToolExecutionRequired(ChatOptions promptOptions, ChatResponse chatResponse) { |
| | | Assert.notNull(promptOptions, "promptOptions cannot be null"); |
| | | Assert.notNull(chatResponse, "chatResponse cannot be null"); |
| | | return test(promptOptions, chatResponse); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.anthropic.client.okhttp.AnthropicOkHttpClient; |
| | | import cn.hutool.system.SystemUtil; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.anthropic.AnthropicChatModel; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link AnthropicChatModel} éææµè¯ç±» |
| | |
| | | */ |
| | | public class AnthropicChatModelTest { |
| | | |
| | | private static final String BASE_URL = SystemUtil.get("ANTHROPIC_BASE_URL", |
| | | "https://api.teamorouter.com"); |
| | | private static final String API_KEY = SystemUtil.get("ANTHROPIC_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç Anthropic API Key |
| | | private static final String MODEL = SystemUtil.get("ANTHROPIC_MODEL", |
| | | "claude-sonnet-4-6"); |
| | | |
| | | private final AnthropicChatModel chatModel = AnthropicChatModel.builder() |
| | | .anthropicClient(AnthropicOkHttpClient.builder() |
| | | .apiKey("sk-muubv7cXeLw0Etgs743f365cD5Ea44429946Fa7e672d8942") |
| | | .baseUrl("https://aihubmix.com") |
| | | .build()) |
| | | .options(AnthropicChatOptions.builder() |
| | | .model("claude-sonnet-4-5") |
| | | .baseUrl(BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .maxTokens(4096) |
| | | .build()) |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | // TODO @èè¿ï¼éè¦ç spring ai å级ï¼https://github.com/spring-projects/spring-ai/pull/2800 |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("thkinking ä¸ï¼1+1 为ä»ä¹çäº 2 ")); |
| | | AnthropicChatOptions options = AnthropicChatOptions.builder() |
| | | .model("claude-sonnet-4-5") |
| | | .temperature(1D) |
| | | .baseUrl(BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(MODEL) |
| | | .thinkingEnabled(1024) // https://platform.claude.com/docs/en/build-with-claude/extended-thinking |
| | | .maxTokens(4096) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.azure.ai.openai.OpenAIClientBuilder; |
| | | import com.azure.core.credential.AzureKeyCredential; |
| | | import cn.hutool.system.SystemUtil; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.azure.openai.AzureOpenAiChatModel; |
| | | import org.springframework.ai.azure.openai.AzureOpenAiChatOptions; |
| | | import org.springframework.ai.chat.messages.Message; |
| | | import org.springframework.ai.chat.messages.SystemMessage; |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static org.springframework.ai.model.azure.openai.autoconfigure.AzureOpenAiChatProperties.DEFAULT_DEPLOYMENT_NAME; |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link AzureOpenAiChatModel} éææµè¯ |
| | | * Azure OpenAI éææµè¯ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | public class AzureOpenAIChatModelTests { |
| | | |
| | | // TODO @èè¿ï¼æç¹å¨è°æ´ |
| | | private final OpenAIClientBuilder openAiApi = new OpenAIClientBuilder() |
| | | .endpoint("https://eastusprejade.openai.azure.com") |
| | | .credential(new AzureKeyCredential("xxx")); |
| | | private final AzureOpenAiChatModel chatModel = AzureOpenAiChatModel.builder() |
| | | .openAIClientBuilder(openAiApi) |
| | | .defaultOptions(AzureOpenAiChatOptions.builder() |
| | | .deploymentName(DEFAULT_DEPLOYMENT_NAME) |
| | | private static final String BASE_URL = SystemUtil.get("AZURE_OPENAI_BASE_URL", |
| | | "https://xxx.openai.azure.com"); |
| | | private static final String API_KEY = SystemUtil.get("AZURE_OPENAI_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç Azure OpenAI API Key |
| | | private static final String DEPLOYMENT_NAME = SystemUtil.get("AZURE_OPENAI_DEPLOYMENT_NAME", |
| | | "gpt-5.4"); // Azure ä¸åå»ºçæ¨¡åé¨ç½²åç§° |
| | | |
| | | private final OpenAiChatModel chatModel = OpenAiChatModel.builder() |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl(BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(DEPLOYMENT_NAME) |
| | | .microsoftFoundry(true) |
| | | .deploymentName(DEPLOYMENT_NAME) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.baichuan.BaiChuanChatModel; |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link BaiChuanChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class BaiChuanChatModelTests { |
| | | |
| | | private final OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | private static final String API_KEY = SystemUtil.get("BAICHUAN_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çç¾å· API Key |
| | | private static final String MODEL = SystemUtil.get("BAICHUAN_MODEL", |
| | | BaiChuanChatModel.MODEL_DEFAULT); |
| | | |
| | | private final BaiChuanChatModel chatModel = new BaiChuanChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(BaiChuanChatModel.BASE_URL) |
| | | .apiKey("sk-61b6766a94c70786ed02673f5e16af3c") // apiKey |
| | | .completionsPath(BaiChuanChatModel.COMPLETE_PATH) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .model("Baichuan4-Turbo") // 模åï¼https://platform.baichuan-ai.com/docs/apiï¼ |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | |
| | | private final BaiChuanChatModel chatModel = new BaiChuanChatModel(openAiChatModel); |
| | | .build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | |
| | | public class CozeChatModelTests { |
| | | |
| | | private final OpenAiChatModel chatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl("http://127.0.0.1:3000") |
| | | .apiKey("app-4hy2d7fJauSbrKbzTKX1afuP") // apiKey |
| | | .build()) |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link DeepSeekChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class DeepSeekChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("DEEPSEEK_API_KEY", |
| | | "sk-xxxx"); |
| | | private static final String MODEL = SystemUtil.get("DEEPSEEK_MODEL", |
| | | "deepseek-v4-flash"); |
| | | |
| | | private final DeepSeekChatModel chatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .apiKey("sk-eaf4172a057344dd9bc64b1f806b6axx") // apiKey |
| | | .apiKey(API_KEY) // apiKey |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .model("deepseek-chat") // 模å |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("deepseek-reasoner") |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | |
| | | public class DifyChatModelTests { |
| | | |
| | | private final OpenAiChatModel chatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl("http://127.0.0.1:3000") |
| | | .apiKey("app-4hy2d7fJauSbrKbzTKX1afuP") // apiKey |
| | | .build()) |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.doubao.DouBaoChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link DouBaoChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class DouBaoChatModelTests { |
| | | |
| | | /** |
| | | * ç¸æ¯ OpenAIChatModel æ¥è¯´ï¼DeepSeekChatModel å¯ä»¥å
¼å®¹è±å
ç thinking è½åï¼ |
| | | */ |
| | | private static final String API_KEY = SystemUtil.get("DOUBAO_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çè±å
API Key |
| | | private static final String MODEL = SystemUtil.get("DOUBAO_MODEL", |
| | | DouBaoChatModel.MODEL_DEFAULT); |
| | | |
| | | private final DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(DouBaoChatModel.BASE_URL) |
| | | .completionsPath(DouBaoChatModel.COMPLETE_PATH) |
| | | .apiKey("5c1b5747-26d2-4ebd-a4e0-dd0e8d8b4272") // apiKey |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .model("doubao-1-5-lite-32k-250115") // 模åï¼doubaoï¼ |
| | | // .model("doubao-seed-1-6-thinking-250715") // 模åï¼doubaoï¼ |
| | | // .model("deepseek-r1-250120") // 模åï¼deepseekï¼ |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("doubao-seed-1-6-thinking-250715") |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages, options)); |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | |
| | | public class FastGPTChatModelTests { |
| | | |
| | | private final OpenAiChatModel chatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl("https://cloud.fastgpt.cn/api") |
| | | .apiKey("fastgpt-aqcc61kFtF8CeaglnGAfQOCIDWwjGdJVJHv6hIlMo28otFlva2aZNK") // apiKey |
| | | .build()) |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.gemini.GeminiChatModel; |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import cn.hutool.system.SystemUtil; |
| | | import com.google.genai.Client; |
| | | import com.google.genai.types.HttpOptions; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import org.springframework.ai.google.genai.GoogleGenAiChatModel; |
| | | import org.springframework.ai.google.genai.GoogleGenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link GeminiChatModel} éææµè¯ |
| | | * {@link GoogleGenAiChatModel} éææµè¯ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | public class GeminiChatModelTests { |
| | | |
| | | private final OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .baseUrl(GeminiChatModel.BASE_URL) |
| | | .apiKey("AIzaSyAVoBxgoFvvte820vEQMma2LKBnC98bqMQ") |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .model(GeminiChatModel.MODEL_DEFAULT) // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | private static final String BASE_URL = SystemUtil.get("GEMINI_BASE_URL"); |
| | | private static final String API_KEY = SystemUtil.get("GEMINI_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç Gemini API Key |
| | | private static final String MODEL = "gemini-3.5-flash"; |
| | | |
| | | private final GeminiChatModel chatModel = new GeminiChatModel(openAiChatModel); |
| | | private final GoogleGenAiChatModel chatModel = GoogleGenAiChatModel.builder() |
| | | .genAiClient(buildClient()) |
| | | .options(GoogleGenAiChatOptions.builder() |
| | | .model(MODEL) // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | |
| | | private static Client buildClient() { |
| | | Client.Builder builder = Client.builder().apiKey(API_KEY); |
| | | if (StrUtil.isNotBlank(BASE_URL)) { |
| | | builder.httpOptions(HttpOptions.builder().baseUrl(BASE_URL).build()); |
| | | } |
| | | return builder.build(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | flux.doOnNext(response -> { |
| | | System.out.println(response); |
| | | // System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | GoogleGenAiChatOptions options = GoogleGenAiChatOptions.builder() |
| | | .model(MODEL) |
| | | .thinkingBudget(1024) |
| | | .includeThoughts(true) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages, options)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | System.out.println(response); |
| | | // System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.grok.GrokChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | | import org.springframework.ai.chat.messages.SystemMessage; |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.openai.OpenAiChatModel; |
| | | import org.springframework.ai.openai.OpenAiChatOptions; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link GrokChatModel} éææµè¯ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | public class GrokChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("GROK_API_KEY", |
| | | "sk-xxxx"); |
| | | private static final String MODEL = SystemUtil.get("GROK_MODEL", |
| | | GrokChatModel.MODEL_DEFAULT); |
| | | |
| | | private final GrokChatModel chatModel = new GrokChatModel(OpenAiChatModel.builder() |
| | | .options(OpenAiChatOptions.builder() |
| | | .baseUrl(GrokChatModel.BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.hunyuan.HunYuanChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link HunYuanChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class HunYuanChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("HUNYUAN_API_KEY", |
| | | "sk-xxxx"); |
| | | private static final String MODEL = SystemUtil.get("HUNYUAN_MODEL", |
| | | HunYuanChatModel.MODEL_DEFAULT); |
| | | |
| | | private final DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(HunYuanChatModel.BASE_URL) |
| | | .completionsPath(HunYuanChatModel.COMPLETE_PATH) |
| | | .apiKey("sk-abc") // apiKey |
| | | .apiKey(API_KEY) // apiKey |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .model(HunYuanChatModel.MODEL_DEFAULT) // 模å |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // è°ç¨ |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("hunyuan-a13b") |
| | | // .model("hunyuan-turbos-latest") |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages, options)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | private final DeepSeekChatModel deepSeekOpenAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(HunYuanChatModel.DEEP_SEEK_BASE_URL) |
| | | .completionsPath(HunYuanChatModel.COMPLETE_PATH) |
| | | .apiKey("sk-abc") // apiKey |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | // .model(HunYuanChatModel.DEEP_SEEK_MODEL_DEFAULT) // 模åï¼"deepseek-v3"ï¼ |
| | | .model("deepseek-r1") // 模åï¼"deepseek-r1"ï¼ |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | |
| | | private final HunYuanChatModel deepSeekChatModel = new HunYuanChatModel(deepSeekOpenAiChatModel); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall_deepseek() { |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | ChatResponse response = deepSeekChatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_deepseek() { |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = deepSeekChatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_deepseek_thinking() { |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("deepseek-r1") |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = deepSeekChatModel.stream(new Prompt(messages, options)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | |
| | | .ollamaApi(OllamaApi.builder() |
| | | .baseUrl("http://127.0.0.1:11434") // Ollama æå¡å°å |
| | | .build()) |
| | | .defaultOptions(OllamaChatOptions.builder() |
| | | .options(OllamaChatOptions.builder() |
| | | .model(OllamaModel.LLAMA3.getName()) // 模å |
| | | .build()) |
| | | .build(); |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.minimax.MiniMaxChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.minimax.MiniMaxChatModel; |
| | | import org.springframework.ai.minimax.MiniMaxChatOptions; |
| | | import org.springframework.ai.minimax.api.MiniMaxApi; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link MiniMaxChatModel} çéææµè¯ |
| | |
| | | */ |
| | | public class MiniMaxChatModelTests { |
| | | |
| | | private final MiniMaxChatModel chatModel = new MiniMaxChatModel( |
| | | new MiniMaxApi("eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJHcm91cE5hbWUiOiLnjovmlofmlowiLCJVc2VyTmFtZSI6IueOi-aWh-aWjCIsIkFjY291bnQiOiIiLCJTdWJqZWN0SUQiOiIxODk3Mjg3MjQ5NDU2ODA4MzQ2IiwiUGhvbmUiOiIxNTYwMTY5MTM5OSIsIkdyb3VwSUQiOiIxODk3Mjg3MjQ5NDQ4NDE5NzM4IiwiUGFnZU5hbWUiOiIiLCJNYWlsIjoiIiwiQ3JlYXRlVGltZSI6IjIwMjUtMDMtMTEgMTI6NTI6MDIiLCJUb2tlblR5cGUiOjEsImlzcyI6Im1pbmltYXgifQ.aAuB7gWW_oA4IYhh-CF7c9MfWWxKN49B_HK-DYjXaDwwffhiG-H1571z1WQhp9QytWG-DqgLejneeSxkiq1wQIe3FsEP2wz4BmGBct31LehbJu8ehLxg_vg75Uod1nFAHbm5mZz6JSVLNIlSo87Xr3UtSzJhAXlapEkcqlA4YOzOpKrZ8l5_OJPTORTCmHWZYgJcRS-faNiH62ZnUEHUozesTFhubJHo5GfJCw_edlnmfSUocERV1BjWvenhZ9My-aYXNktcW9WaSj9l6gayV7A0Ium_PL55T9ln1PcI8gayiVUKJGJDoqNyF1AF9_aF9NOKtTnQzwNqnZdlTYH6hw"), // å¯é¥ |
| | | MiniMaxChatOptions.builder() |
| | | .model(MiniMaxApi.ChatModel.ABAB_6_5_G_Chat.getValue()) // 模å |
| | | .build()); |
| | | private static final String API_KEY = SystemUtil.get("MINIMAX_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç MiniMax API Key |
| | | private static final String MODEL = SystemUtil.get("MINIMAX_MODEL", |
| | | MiniMaxChatModel.MODEL_DEFAULT); |
| | | |
| | | private final MiniMaxChatModel chatModel = new MiniMaxChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(MiniMaxChatModel.BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build()) |
| | | .build()); |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | // TODO @èè¿ï¼ææ¶æ²¡è§£æ reasoning_content ç»æï¼éè¦ç宿¹ä¿®å¤ |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | MiniMaxChatOptions options = MiniMaxChatOptions.builder() |
| | | .model("MiniMax-M1") |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.moonshot.MoonshotChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springaicommunity.moonshot.MoonshotChatModel; |
| | | import org.springaicommunity.moonshot.MoonshotChatOptions; |
| | | import org.springaicommunity.moonshot.api.MoonshotApi; |
| | | import org.springframework.ai.chat.messages.Message; |
| | | import org.springframework.ai.chat.messages.SystemMessage; |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link MoonshotChatModel} çéææµè¯ |
| | |
| | | */ |
| | | public class MoonshotChatModelTests { |
| | | |
| | | private final MoonshotChatModel chatModel = MoonshotChatModel.builder() |
| | | .moonshotApi(MoonshotApi.builder() |
| | | .apiKey("sk-aHYYV1SARscItye5QQRRNbXij4fy65Ee7pNZlC9gsSQnUKXA") // å¯é¥ |
| | | private static final String API_KEY = SystemUtil.get("MOONSHOT_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç Moonshot API Key |
| | | private static final String MODEL = SystemUtil.get("MOONSHOT_MODEL", |
| | | MoonshotChatModel.MODEL_DEFAULT); |
| | | |
| | | private final MoonshotChatModel chatModel = new MoonshotChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(MoonshotChatModel.BASE_URL) |
| | | .completionsPath(MoonshotChatModel.COMPLETE_PATH) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .defaultOptions(MoonshotChatOptions.builder() |
| | | .model("kimi-k2-0711-preview") // 模å |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .temperature(1D) |
| | | .build()) |
| | | .build(); |
| | | .build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | // TODO @èè¿ï¼ææ¶æ²¡è§£æ reasoning_content ç»æï¼éè¦ç宿¹ä¿®å¤ |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | MoonshotChatOptions options = MoonshotChatOptions.builder() |
| | | // .model("kimi-k2-0711-preview") |
| | | .model("kimi-thinking-preview") |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | .ollamaApi(OllamaApi.builder() |
| | | .baseUrl("http://127.0.0.1:11434") // Ollama æå¡å°å |
| | | .build()) |
| | | .defaultOptions(OllamaChatOptions.builder() |
| | | .options(OllamaChatOptions.builder() |
| | | // .model("qwen") // 模åï¼https://ollama.com/library/qwenï¼ |
| | | .model("deepseek-r1") // 模åï¼https://ollama.com/library/deepseek-r1ï¼ |
| | | .build()) |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import com.azure.ai.openai.models.ReasoningEffortValue; |
| | | import cn.hutool.system.SystemUtil; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link OpenAiChatModel} éææµè¯ |
| | | * |
| | |
| | | */ |
| | | public class OpenAIChatModelTests { |
| | | |
| | | private static final String BASE_URL = SystemUtil.get("OPENAI_BASE_URL", |
| | | "https://api.teamorouter.com/v1"); |
| | | private static final String API_KEY = SystemUtil.get("OPENAI_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç OpenAI API Key |
| | | private static final String MODEL = SystemUtil.get("OPENAI_MODEL", |
| | | "gpt-5.5"); |
| | | |
| | | private final OpenAiChatModel chatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .baseUrl("https://api.holdai.top") |
| | | .apiKey("sk-z5joyRoV1iFEnh2SAi8QPNrIZTXyQSyxTmD5CoNDQbFixK2l") // apiKey |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .model("gpt-5-nano-2025-08-07") // 模å |
| | | // .model("o1") // 模å |
| | | .baseUrl(BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | OpenAiChatOptions options = OpenAiChatOptions.builder() |
| | | .model("gpt-5") |
| | | // .model("o4-mini") |
| | | // .model("o3-pro") |
| | | .reasoningEffort(ReasoningEffortValue.LOW.getValue()) |
| | | .baseUrl(BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(MODEL) |
| | | .reasoningEffort("low") // https://help.openai.com/zh-hant/articles/5072518-controlling-the-length-of-openai-model-responses |
| | | .maxCompletionTokens(1024) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowApiConstants; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link SiliconFlowChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class SiliconFlowChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("SILICONFLOW_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç SiliconFlow API Key |
| | | private static final String MODEL = SystemUtil.get("SILICONFLOW_MODEL", |
| | | SiliconFlowApiConstants.MODEL_DEFAULT); |
| | | |
| | | private final DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(SiliconFlowApiConstants.DEFAULT_BASE_URL) |
| | | .apiKey("sk-epsakfenqnyzoxhmbucsxlhkdqlcbnimslqoivkshalvdozz") // apiKey |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | .model(SiliconFlowApiConstants.MODEL_DEFAULT) // 模å |
| | | // .model("deepseek-ai/DeepSeek-R1") // 模åï¼deepseek-ai/DeepSeek-R1ï¼å¯ç¨èµ è´¹ |
| | | // .model("Pro/deepseek-ai/DeepSeek-R1") // 模åï¼Pro/deepseek-ai/DeepSeek-R1ï¼éè¦ä»è´¹ |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) // 模å |
| | | // .model("deepseek-ai/DeepSeek-V4-Flash") // 模å |
| | | // .model("moonshotai/Kimi-K2.7-Code") // 模å |
| | | // .model("moonshotai/Kimi-K2.6") // 模å |
| | | // .model("zai-org/GLM-5.2") // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("deepseek-ai/DeepSeek-R1") |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.stepfun.StepFunChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | | import org.springframework.ai.chat.messages.SystemMessage; |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link StepFunChatModel} éææµè¯ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | public class StepFunChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("STEPFUN_API_KEY", |
| | | "sk-xxxx"); |
| | | private static final String MODEL = SystemUtil.get("STEPFUN_MODEL", |
| | | StepFunChatModel.MODEL_DEFAULT); |
| | | |
| | | private final StepFunChatModel chatModel = new StepFunChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(StepFunChatModel.BASE_URL) |
| | | .completionsPath(StepFunChatModel.COMPLETE_PATH) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | // System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | System.out.println(response.getResult() != null ? response.getResult().getOutput() : null); |
| | | }).then().block(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; |
| | | import cn.iocoder.yudao.module.ai.util.AiUtils; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeApi; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatModel; |
| | | import com.alibaba.cloud.ai.dashscope.chat.DashScopeChatOptions; |
| | |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | import static java.util.Arrays.asList; |
| | | |
| | | /** |
| | |
| | | */ |
| | | public class TongYiChatModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("DASHSCOPE_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç DashScope API Key |
| | | private static final String MODEL = SystemUtil.get("DASHSCOPE_MODEL", |
| | | "qwen3.7-plus"); |
| | | |
| | | private final DashScopeChatModel chatModel = DashScopeChatModel.builder() |
| | | .dashScopeApi(DashScopeApi.builder() |
| | | .apiKey("sk-cd9f39e99ea54840bd1888282325f55a") // https://bailian.console.aliyun.com/cn-beijing/?tab=model#/api-key è·åå¯é¥ |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .defaultOptions(DashScopeChatOptions.builder() |
| | | .multiModel(true) // 注æï¼å½ä½¿ç¨ qwen3.6-plus ç夿¨¡ææ¨¡åï¼éè¦è®¾ç½®ä¸º trueï¼å¯è§ https://help.aliyun.com/zh/model-studio/error-code#error-url 龿¥ |
| | | .model("qwen3.6-plus") // 模å |
| | | .multiModel(AiUtils.TONG_YI_MULTI_MODELS.contains(MODEL)) // 夿¨¡ææ¨¡åéè¦è®¾ç½®ä¸º trueï¼å¯è§ https://help.aliyun.com/zh/model-studio/error-code#error-url |
| | | .model(MODEL) // 模å |
| | | // .model("deepseek-r1") // 模åï¼deepseek-r1ï¼ |
| | | // .model("deepseek-v3") // 模åï¼deepseek-v3ï¼ |
| | | // .model("deepseek-r1-distill-qwen-1.5b") // 模åï¼deepseek-r1-distill-qwen-1.5bï¼ |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | // messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DashScopeChatOptions options = DashScopeChatOptions.builder() |
| | | .model("qwen3.6-plus").multiModel(true) |
| | | .model(MODEL).multiModel(AiUtils.TONG_YI_MULTI_MODELS.contains(MODEL)) |
| | | // .withModel("qwen-max-2025-01-25") |
| | | .enableThinking(true) // å¿
须设置ï¼å¦å伿¥é |
| | | .build(); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testRerank() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤ç¯å¢ |
| | | RerankModel rerankModel = new DashScopeRerankModel( |
| | | DashScopeApi.builder() |
| | | .apiKey("sk-47aa124781be4bfb95244cc62f63f7d0") |
| | | .apiKey(API_KEY) |
| | | .build()); |
| | | // åå¤åæ° |
| | | String query = "spring"; |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.xinghuo.XingHuoChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link XingHuoChatModel} éææµè¯ |
| | |
| | | */ |
| | | public class XingHuoChatModelTests { |
| | | |
| | | private final DeepSeekChatModel openAiChatModel = DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(XingHuoChatModel.BASE_URL_V2) |
| | | .completionsPath(XingHuoChatModel.BASE_COMPLETIONS_PATH_V2) |
| | | .apiKey("75b161ed2aef4719b275d6e7f2a4d4cd:YWYxYWI2MTA4ODI2NGZlYTQyNjAzZTcz") // appKey:secretKey |
| | | .build()) |
| | | .defaultOptions(DeepSeekChatOptions.builder() |
| | | // .model("generalv3.5") // 模å |
| | | .model("x1") // 模å |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | private static final String API_KEY = SystemUtil.get("XINGHUO_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çè®¯é£æç« API Key |
| | | private static final String MODEL = SystemUtil.get("XINGHUO_MODEL", |
| | | XingHuoChatModel.MODEL_DEFAULT); |
| | | |
| | | private final XingHuoChatModel chatModel = new XingHuoChatModel(openAiChatModel); |
| | | private final XingHuoChatModel chatModel = XingHuoChatModel.builder() |
| | | .apiKey(API_KEY) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model("x1") |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.yiyan.YiYanChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springaicommunity.qianfan.QianFanChatModel; |
| | | import org.springaicommunity.qianfan.QianFanChatOptions; |
| | | import org.springaicommunity.qianfan.api.QianFanApi; |
| | | import org.springframework.ai.chat.messages.Message; |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | // TODO @èè¿ï¼ç¾åº¦åå¸ API æä¾äº V2 çæ¬ï¼ç®å Spring AI ä¸å
¼å®¹ï¼å¯å
³é® <https://github.com/spring-projects/spring-ai/issues/2179> è¿å± |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link QianFanChatModel} çéææµè¯ |
| | | * {@link YiYanChatModel} çéææµè¯ |
| | | * |
| | | * @author fansili |
| | | */ |
| | | public class YiYanChatModelTests { |
| | | |
| | | private final QianFanChatModel chatModel = new QianFanChatModel( |
| | | new QianFanApi("DGnyzREuaY7av7c38bOM9Ji2", "9aR8myflEOPDrEeLhoXv0FdqANOAyIZW"), // å¯é¥ |
| | | QianFanChatOptions.builder() |
| | | .model("ERNIE-4.5-8K-Preview") |
| | | .build() |
| | | ); |
| | | private static final String API_KEY = SystemUtil.get("YIYAN_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çæå¿ä¸è¨ API Key |
| | | private static final String MODEL = SystemUtil.get("YIYAN_MODEL", |
| | | YiYanChatModel.MODEL_DEFAULT); |
| | | |
| | | private final YiYanChatModel chatModel = new YiYanChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(YiYanChatModel.BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build()) |
| | | .build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | // TODO @èè¿ï¼æå¿ä¸è¨ï¼åªè¦å¸¦ä¸ system message å°±æ¥éï¼å·²ç»åç§æµè¯ï¼å¾è«åï¼ |
| | | // messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | // TODO @èè¿ï¼æå¿ä¸è¨ï¼åªè¦å¸¦ä¸ system message å°±æ¥éï¼å·²ç»åç§æµè¯ï¼å¾è«åï¼ |
| | | // messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | | messages.add(new UserMessage("1 + 1 = ï¼")); |
| | | |
| | | // è°ç¨ |
| | | Flux<ChatResponse> flux = chatModel.stream(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | flux.doOnNext(System.out::println).then().block(); |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.chat; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.zhipu.ZhiPuChatModel; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.messages.Message; |
| | |
| | | import org.springframework.ai.chat.messages.UserMessage; |
| | | import org.springframework.ai.chat.model.ChatResponse; |
| | | import org.springframework.ai.chat.prompt.Prompt; |
| | | import org.springframework.ai.zhipuai.ZhiPuAiChatModel; |
| | | import org.springframework.ai.zhipuai.ZhiPuAiChatOptions; |
| | | import org.springframework.ai.zhipuai.api.ZhiPuAiApi; |
| | | import org.springframework.ai.deepseek.DeepSeekChatModel; |
| | | import org.springframework.ai.deepseek.DeepSeekChatOptions; |
| | | import org.springframework.ai.deepseek.api.DeepSeekApi; |
| | | import reactor.core.publisher.Flux; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link ZhiPuAiChatModel} çéææµè¯ |
| | | * {@link ZhiPuChatModel} çéææµè¯ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | public class ZhiPuAiChatModelTests { |
| | | |
| | | private final ZhiPuAiChatModel chatModel = new ZhiPuAiChatModel( |
| | | ZhiPuAiApi.builder().apiKey("2f35fb6ca4ea41fab898729b7fac086c.6ESSfPcCkxaKEUlR").build(), // å¯é¥ |
| | | ZhiPuAiChatOptions.builder() |
| | | .model(ZhiPuAiApi.ChatModel.GLM_4.getName()) // 模å |
| | | private static final String API_KEY = SystemUtil.get("ZHIPU_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çæºè°± API Key |
| | | private static final String MODEL = SystemUtil.get("ZHIPU_MODEL", |
| | | ZhiPuChatModel.MODEL_DEFAULT); |
| | | |
| | | private final ZhiPuChatModel chatModel = new ZhiPuChatModel(DeepSeekChatModel.builder() |
| | | .deepSeekApi(DeepSeekApi.builder() |
| | | .baseUrl(ZhiPuChatModel.BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .options(DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build() |
| | | ); |
| | | ).build()); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | ChatResponse response = chatModel.call(new Prompt(messages)); |
| | | // æå°ç»æ |
| | | System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | } |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testStream() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new SystemMessage("ä½ æ¯ä¸ä¸ªä¼è´¨çæè¨æä½è
ï¼ç¨æè¨ææè¿°çååå¸ç人æé£æ¯ã")); |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | | // TODO @èè¿ï¼ææ¶æ²¡è§£æ reasoning_content ç»æï¼éè¦ç宿¹ä¿®å¤ |
| | | @Test |
| | | @Disabled |
| | | public void testStream_thinking() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | List<Message> messages = new ArrayList<>(); |
| | | messages.add(new UserMessage("详ç»åæä¸ï¼å¦ä½è®¾è®¡ä¸ä¸ªçµåç³»ç»ï¼")); |
| | | ZhiPuAiChatOptions options = ZhiPuAiChatOptions.builder() |
| | | .model("GLM-4.5") |
| | | DeepSeekChatOptions options = DeepSeekChatOptions.builder() |
| | | .model(MODEL) |
| | | .build(); |
| | | |
| | | // è°ç¨ |
| | |
| | | // æå°ç»æ |
| | | flux.doOnNext(response -> { |
| | | // System.out.println(response); |
| | | System.out.println(response.getResult().getOutput()); |
| | | System.out.println(Objects.requireNonNull(response.getResult()).getOutput()); |
| | | }).then().block(); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.image; |
| | | |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.image.ImageOptions; |
| | |
| | | */ |
| | | public class OpenAiImageModelTests { |
| | | |
| | | private final OpenAiImageModel imageModel = new OpenAiImageModel(OpenAIOkHttpClient.builder() |
| | | .baseUrl("https://api.holdai.top") // apiKey |
| | | .apiKey("sk-PytRecQlmjEteoa2RRN6cGnwslo72UUPLQVNEMS6K9yjbmpD") |
| | | .build()); |
| | | private final OpenAiImageModel imageModel = OpenAiImageModel.builder() |
| | | .options(OpenAiImageOptions.builder() |
| | | .baseUrl("https://api.holdai.top") // apiKey |
| | | .apiKey("sk-xxx") |
| | | .build()) |
| | | .build(); |
| | | |
| | | @Test |
| | | @Disabled |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.image; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowImageApi; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowImageModel; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.siliconflow.SiliconFlowImageOptions; |
| | |
| | | import org.springframework.ai.image.ImagePrompt; |
| | | import org.springframework.ai.image.ImageResponse; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link SiliconFlowImageModel} éææµè¯ |
| | | */ |
| | | public class SiliconFlowImageModelTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("SILICONFLOW_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç SiliconFlow API Key |
| | | |
| | | private final SiliconFlowImageModel imageModel = new SiliconFlowImageModel( |
| | | new SiliconFlowImageApi("sk-epsakfenqnyzoxhmbucsxlhkdqlcbnimslqoivkshalvdozz") // å¯é¥ |
| | | new SiliconFlowImageApi(API_KEY) |
| | | ); |
| | | |
| | | @Test |
| | | @Disabled |
| | | public void testCall() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | SiliconFlowImageOptions imageOptions = SiliconFlowImageOptions.builder() |
| | | .model("Kwai-Kolors/Kolors") |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.image; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import com.alibaba.cloud.ai.dashscope.api.DashScopeImageApi; |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageModel; |
| | | import com.alibaba.cloud.ai.dashscope.image.DashScopeImageOptions; |
| | |
| | | import org.springframework.ai.image.ImageOptions; |
| | | import org.springframework.ai.image.ImagePrompt; |
| | | import org.springframework.ai.image.ImageResponse; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | /** |
| | | * {@link DashScopeImageModel} éææµè¯ç±» |
| | |
| | | */ |
| | | public class TongYiImagesModelTest { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("DASHSCOPE_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ ç DashScope API Key |
| | | |
| | | private final DashScopeImageModel imageModel = DashScopeImageModel.builder() |
| | | .dashScopeApi(DashScopeImageApi.builder() |
| | | .apiKey("sk-cd9f39e99ea54840bd1888282325f55a") // https://bailian.console.aliyun.com/cn-beijing/?tab=model#/api-key è·åå¯é¥ |
| | | .apiKey(API_KEY) |
| | | .build()) |
| | | .build(); |
| | | |
| | |
| | | @Test |
| | | @Disabled |
| | | public void imageCallTest() { |
| | | validateApiKey(API_KEY); |
| | | // åå¤åæ° |
| | | ImageOptions options = DashScopeImageOptions.builder() |
| | | .model("wan2.7-image") |
| | |
| | | package cn.iocoder.yudao.module.ai.framework.ai.core.model.mcp; |
| | | |
| | | import cn.hutool.system.SystemUtil; |
| | | import cn.iocoder.yudao.module.ai.framework.ai.core.model.doubao.DouBaoChatModel; |
| | | import com.openai.client.okhttp.OpenAIOkHttpClient; |
| | | import org.junit.jupiter.api.Disabled; |
| | | import org.junit.jupiter.api.Test; |
| | | import org.springframework.ai.chat.client.ChatClient; |
| | |
| | | import org.springframework.ai.tool.annotation.Tool; |
| | | import org.springframework.ai.tool.method.MethodToolCallbackProvider; |
| | | |
| | | import static cn.iocoder.yudao.module.ai.util.AiUtils.validateApiKey; |
| | | |
| | | @Disabled |
| | | public class DouBaoMcpTests { |
| | | |
| | | private static final String API_KEY = SystemUtil.get("DOUBAO_API_KEY", |
| | | "sk-xxxx"); // æéæ¹æä½ çè±å
API Key |
| | | |
| | | private final OpenAiChatModel openAiChatModel = OpenAiChatModel.builder() |
| | | .openAiClient(OpenAIOkHttpClient.builder() |
| | | .baseUrl(DouBaoChatModel.BASE_URL) |
| | | .apiKey("5c1b5747-26d2-4ebd-a4e0-dd0e8d8b4272") // apiKey |
| | | .build()) |
| | | .options(OpenAiChatOptions.builder() |
| | | .model("doubao-1-5-lite-32k-250115") // 模åï¼doubaoï¼ |
| | | .baseUrl(DouBaoChatModel.BASE_URL) |
| | | .apiKey(API_KEY) |
| | | .model(DouBaoChatModel.MODEL_DEFAULT) // 模åï¼doubaoï¼ |
| | | .temperature(0.7) |
| | | .build()) |
| | | .build(); |
| | |
| | | |
| | | @Test |
| | | public void testMcpGetUserInfo() { |
| | | validateApiKey(API_KEY); |
| | | // æå°ç»æ |
| | | System.out.println(chatClient.prompt() |
| | | .user("ç®åæåªäºå·¥å
·å¯ä»¥ä½¿ç¨") |
| | |
| | | @GetMapping("/get-bpmn-model-view") |
| | | @Operation(summary = "è·åæµç¨å®ä¾ç BPMN 模åè§å¾", description = "å¨ãæµç¨è¯¦ç»ãçé¢ä¸ï¼è¿è¡è°ç¨") |
| | | @Parameter(name = "id", description = "æµç¨å®ä¾çç¼å·", required = true) |
| | | @PreAuthorize("@ss.hasPermission('bpm:process-instance:query')") |
| | | public CommonResult<BpmProcessInstanceBpmnModelViewRespVO> getProcessInstanceBpmnModelView( |
| | | @RequestParam(value = "id") String id) { |
| | | return success(processInstanceService.getProcessInstanceBpmnModelView(id)); |
| | |
| | | @Schema(description = "ç¾å", example = "https://www.iocoder.cn/sign.png") |
| | | private String signPicUrl; |
| | | |
| | | @Schema(description = "éä»¶", example = "[https://test.yudao.iocoder.cn/20260609/test.txt]") |
| | | private List<String> attachments; |
| | | |
| | | } |
| | | |
| | | } |
| | |
| | | @Schema(description = "ç¾å", example = "https://www.iocoder.cn/sign.png") |
| | | private String signPicUrl; |
| | | |
| | | @Schema(description = "éä»¶", example = "[https://test.yudao.iocoder.cn/20260609/test.txt]") |
| | | private List<String> attachments; |
| | | |
| | | @Schema(description = "åéå®ä¾ï¼å¨æè¡¨åï¼", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private Map<String, Object> variables; |
| | | |
| | |
| | | |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - ä¸éè¿æµç¨ä»»å¡ç Request VO") |
| | | @Data |
| | | public class BpmTaskRejectReqVO { |
| | |
| | | @Schema(description = "å®¡æ¹æè§", requiredMode = Schema.RequiredMode.REQUIRED, example = "ä¸éä¸éï¼") |
| | | private String reason; |
| | | |
| | | @Schema(description = "éä»¶", example = "[https://test.yudao.iocoder.cn/20260609/test.txt]") |
| | | private List<String> attachments; |
| | | |
| | | } |
| | |
| | | import cn.iocoder.yudao.framework.common.util.date.DateUtils; |
| | | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.bpm.api.event.BpmProcessInstanceStatusEvent; |
| | | import cn.iocoder.yudao.module.bpm.controller.admin.base.user.UserSimpleBaseVO; |
| | | import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model.BpmModelMetaInfoVO; |
| | | import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model.simple.BpmSimpleModelNodeVO; |
| | |
| | | import cn.iocoder.yudao.module.bpm.convert.definition.BpmProcessDefinitionConvert; |
| | | import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmCategoryDO; |
| | | import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmProcessDefinitionInfoDO; |
| | | import cn.iocoder.yudao.module.bpm.api.event.BpmProcessInstanceStatusEvent; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmTaskStatusEnum; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.enums.BpmnVariableConstants; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.util.BpmnModelUtils; |
| | |
| | | import org.flowable.engine.history.HistoricProcessInstance; |
| | | import org.flowable.engine.repository.ProcessDefinition; |
| | | import org.flowable.engine.runtime.ProcessInstance; |
| | | import org.flowable.engine.task.Attachment; |
| | | import org.flowable.task.api.Task; |
| | | import org.flowable.task.api.history.HistoricTaskInstance; |
| | | import org.mapstruct.Mapper; |
| | |
| | | if (CollUtil.isNotEmpty(respVO.getTasks())) { |
| | | respVO.getTasks().forEach(task -> { |
| | | AdminUserRespDTO assigneeUser = userMap.get(task.getAssignee()); |
| | | if (assigneeUser!= null) { |
| | | if (assigneeUser != null) { |
| | | task.setAssigneeUser(BeanUtils.toBean(assigneeUser, UserSimpleBaseVO.class)); |
| | | MapUtils.findAndThen(deptMap, assigneeUser.getDeptId(), dept -> task.getAssigneeUser().setDeptName(dept.getName())); |
| | | } |
| | |
| | | |
| | | default BpmMessageSendWhenProcessInstanceRejectReqDTO buildProcessInstanceRejectMessage(ProcessInstance instance, String reason) { |
| | | return new BpmMessageSendWhenProcessInstanceRejectReqDTO() |
| | | .setProcessInstanceName(instance.getName()) |
| | | .setProcessInstanceId(instance.getId()) |
| | | .setReason(reason) |
| | | .setStartUserId(NumberUtils.parseLong(instance.getStartUserId())); |
| | | .setProcessInstanceName(instance.getName()) |
| | | .setProcessInstanceId(instance.getId()) |
| | | .setReason(reason) |
| | | .setStartUserId(NumberUtils.parseLong(instance.getStartUserId())); |
| | | } |
| | | |
| | | default BpmProcessInstanceBpmnModelViewRespVO buildProcessInstanceBpmnModelView(HistoricProcessInstance processInstance, |
| | |
| | | } |
| | | |
| | | default UserSimpleBaseVO buildUser(Long userId, |
| | | Map<Long, AdminUserRespDTO> userMap, |
| | | Map<Long, DeptRespDTO> deptMap) { |
| | | Map<Long, AdminUserRespDTO> userMap, |
| | | Map<Long, DeptRespDTO> deptMap) { |
| | | if (userId == null) { |
| | | return null; |
| | | } |
| | |
| | | return userVO; |
| | | } |
| | | |
| | | default BpmApprovalDetailRespVO.ActivityNodeTask buildApprovalTaskInfo(HistoricTaskInstance task) { |
| | | default BpmApprovalDetailRespVO.ActivityNodeTask buildApprovalTaskInfo(HistoricTaskInstance task, List<Attachment> attachments) { |
| | | if (task == null) { |
| | | return null; |
| | | } |
| | | return BeanUtils.toBean(task, BpmApprovalDetailRespVO.ActivityNodeTask.class) |
| | | .setStatus(FlowableUtils.getTaskStatus(task)).setReason(FlowableUtils.getTaskReason(task)) |
| | | .setSignPicUrl(FlowableUtils.getTaskSignPicUrl(task)); |
| | | .setSignPicUrl(FlowableUtils.getTaskSignPicUrl(task)) |
| | | .setAttachments(convertList(attachments, Attachment::getUrl)); |
| | | } |
| | | |
| | | default Set<Long> parseUserIds(HistoricProcessInstance processInstance, |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.bpm.enums.task; |
| | | |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * éä»¶ç±»åæä¸¾ |
| | | * |
| | | * @author jason |
| | | */ |
| | | @Getter |
| | | @AllArgsConstructor |
| | | public enum BpmAttachmentTypeEnum { |
| | | |
| | | TASK_ATTACHMENT("1", "ç¨æ·ä»»å¡éä»¶"); |
| | | |
| | | /** |
| | | * æä½ç±»å |
| | | * <p> |
| | | * ç±äº BPM attachment ç±»å为 Stringï¼æä»¥è¿éå°±ä¸ä½¿ç¨ Integer |
| | | */ |
| | | private final String type; |
| | | /** |
| | | * æä½åå |
| | | */ |
| | | private final String name; |
| | | } |
| | |
| | | MULTI_DEPT_LEADER_MULTI(23, "è¿ç»å¤çº§é¨é¨çè´è´£äºº"), |
| | | POST(22, "å²ä½"), |
| | | USER(30, "ç¨æ·"), |
| | | APPROVE_USER_SELECT(34, "审æ¹äººèªèº«"), // å½å审æ¹äººï¼å¯å¨å®¡æ¹æ¶ï¼éæ©ä¸ä¸ä¸ªèç¹ç审æ¹äºº |
| | | APPROVE_USER_SELECT(34, "审æ¹äººèªé"), // å½å审æ¹äººï¼å¯å¨å®¡æ¹æ¶ï¼éæ©ä¸ä¸ä¸ªèç¹ç审æ¹äºº |
| | | START_USER_SELECT(35, "å起人èªé"), // ç³è¯·äººèªå·±ï¼å¯å¨æäº¤ç³è¯·æ¶ï¼éæ©æ¤èç¹ç审æ¹äºº |
| | | START_USER(36, "å起人èªå·±"), // ç³è¯·äººèªå·±, ä¸è¬ç´§æ¨å¼å§èç¹ï¼å¸¸ç¨äºå起人信æ¯å®¡æ ¸åºæ¯ |
| | | START_USER_DEPT_LEADER(37, "å起人é¨é¨è´è´£äºº"), |
| | |
| | | /** |
| | | * æ·»å HTTP 请æ±åæ°ã请æ±å¤´æè
请æ±ä½ |
| | | * |
| | | * @param params HTTP 请æ±åæ° |
| | | * @param headers HTTP 请æ±å¤´ |
| | | * @param paramSettings HTTP 请æ±åæ°è®¾ç½® |
| | | * @param processVariables æµç¨åé |
| | | */ |
| | |
| | | } |
| | | |
| | | /** |
| | | * æ ¹æ®èç¹ï¼éå½è·å䏿¸¸ source 为 UserTask çå
¥å£è¿çº¿ |
| | | * |
| | | * 1. 妿å½åèç¹çç´æ¥å
¥å£è¿çº¿ source å°±æ¯ UserTaskï¼åç´æ¥è¿å该è¿çº¿ |
| | | * 2. 妿å½åèç¹çç´æ¥å
¥å£è¿çº¿ source 䏿¯ UserTaskï¼åç»§ç»åä¸é彿¥æ¾ |
| | | * 3. 妿éå½è¿ç¨ä¸éå° StartEvent æ SubProcessï¼ååæ¢è¯¥åæ¯ç»§ç»å䏿¥æ¾ |
| | | * |
| | | * @param source èµ·å§èç¹ |
| | | * @return 䏿¸¸è¿æ¥ UserTask çå
¥å£è¿çº¿å表 |
| | | */ |
| | | public static List<SequenceFlow> getElementIncomingUserTaskFlows(FlowElement source) { |
| | | List<SequenceFlow> result = new ArrayList<>(); |
| | | collectElementIncomingUserTaskFlows(source, new HashSet<>(), new HashSet<>(), result); |
| | | return result; |
| | | } |
| | | |
| | | private static void collectElementIncomingUserTaskFlows(FlowElement source, Set<String> visitedSequenceFlowIds, |
| | | Set<String> resultSequenceFlowIds, List<SequenceFlow> result) { |
| | | // 妿æ¯å¼å§èç¹æåæµç¨ï¼ååæ¢è¯¥åæ¯å䏿¥æ¾ |
| | | if (source == null || source instanceof StartEvent || source instanceof SubProcess) { |
| | | return; |
| | | } |
| | | // è·åå
¥å£è¿çº¿ |
| | | List<SequenceFlow> incomingFlows = getElementIncomingFlows(source); |
| | | if (CollUtil.isEmpty(incomingFlows)) { |
| | | return; |
| | | } |
| | | |
| | | // å¾ªç¯æ¾å°ç®æ å
ç´ |
| | | for (SequenceFlow incomingFlow : incomingFlows) { |
| | | // 妿åç°è¿çº¿éå¤ï¼è¯´æè¿çº¿å·²ç»èµ°è¿ãè·³è¿ |
| | | if (incomingFlow == null || !visitedSequenceFlowIds.add(incomingFlow.getId())) { |
| | | continue; |
| | | } |
| | | // 妿 source æ¯ UserTaskï¼åæ·»å å°ç»æä¸ |
| | | FlowElement sourceFlowElement = incomingFlow.getSourceFlowElement(); |
| | | if (sourceFlowElement instanceof UserTask) { |
| | | if (resultSequenceFlowIds.add(incomingFlow.getId())) { |
| | | result.add(incomingFlow); |
| | | } |
| | | continue; |
| | | } |
| | | // éå½å䏿¥æ¾ UserTask |
| | | collectElementIncomingUserTaskFlows(sourceFlowElement, visitedSequenceFlowIds, |
| | | resultSequenceFlowIds, result); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ ¹æ®èç¹ï¼è·ååºå£è¿çº¿ |
| | | * |
| | | * @param source èµ·å§èç¹ |
| | |
| | | } |
| | | |
| | | /** |
| | | * æ¥æ¾èµ·å§èç¹ä¸ä¸ä¸ªç¨æ·ä»»å¡å表å表 |
| | | * æ¥æ¾èµ·å§èç¹ä¸ä¸ä¸ªç¨æ·ä»»å¡å表, è¯¥æ¹æ³ä¼éå½å䏿¥æ¾ï¼è·³è¿é UserTask èç¹, æ¯æç½å
³æ¡ä»¶å¤æ |
| | | * |
| | | * <ul> |
| | | * <li>æä»ç½å
³ï¼èµ°æ»¡è¶³æ¡ä»¶çå¯ä¸ä¸æ¡è·¯å¾ï¼å«é»è®¤è·¯å¾å
åºï¼</li> |
| | | * <li>å
容ç½å
³ï¼èµ°æææ»¡è¶³æ¡ä»¶çè·¯å¾</li> |
| | | * <li>å¹¶è¡ç½å
³ï¼èµ°ææåºå£è·¯å¾</li> |
| | | * </ul> |
| | | * |
| | | * @param currentElement å½åèç¹ |
| | | * @param bpmnModel BPMN 模å |
| | | * @param variables æµç¨åéï¼ç¨äºç½å
³æ¡ä»¶å¤æï¼ |
| | | * @return ä¸ä¸ä¸ªç¨æ·ä»»å¡èç¹å表 |
| | | */ |
| | | public static List<UserTask> getNextUserTasks(FlowElement currentElement, BpmnModel bpmnModel, |
| | | Map<String, Object> variables) { |
| | | return getNextUserTasks(currentElement, bpmnModel, variables, new HashSet<>(), new ArrayList<>()); |
| | | } |
| | | |
| | | private static List<UserTask> getNextUserTasks(FlowElement currentElement, BpmnModel bpmnModel, |
| | | Map<String, Object> variables, |
| | | Set<String> hasSequenceFlow, List<UserTask> userTaskList) { |
| | | // 1. æ ¹æ®èç¹ç±»åå³å®è¦éåçåºå£è¿çº¿ |
| | | // ç½å
³éè¦æ ¹æ®æ¡ä»¶è¡¨è¾¾å¼çéï¼å
¶å®èç¹ç´æ¥åææ outgoing flows |
| | | List<SequenceFlow> outgoingFlows; |
| | | if (currentElement instanceof Gateway) { |
| | | outgoingFlows = getGatewayOutgoingFlows((Gateway) currentElement, variables); |
| | | } else { |
| | | outgoingFlows = getElementOutgoingFlows(currentElement); |
| | | } |
| | | if (CollUtil.isEmpty(outgoingFlows)) { |
| | | return userTaskList; |
| | | } |
| | | // 2. éååºå£è¿çº¿ï¼é彿¥æ¾ç¨æ·ä»»å¡ |
| | | for (SequenceFlow outgoingFlow : outgoingFlows) { |
| | | // 鲿¢è¿çº¿æç¯å¯¼è´æ»å¾ªç¯ |
| | | if (hasSequenceFlow.contains(outgoingFlow.getId())) { |
| | | continue; |
| | | } |
| | | hasSequenceFlow.add(outgoingFlow.getId()); |
| | | // è·åç®æ èç¹ |
| | | FlowElement targetElement = bpmnModel.getFlowElement(outgoingFlow.getTargetRef()); |
| | | if (targetElement == null || targetElement instanceof EndEvent) { |
| | | continue; |
| | | } |
| | | if (targetElement instanceof UserTask) { |
| | | // æ¾å°ç¨æ·ä»»å¡ï¼å å
¥ç»æ |
| | | userTaskList.add((UserTask) targetElement); |
| | | } else { |
| | | // éç¨æ·ä»»å¡ï¼ç½å
³ãæå¡ä»»å¡ãä¸é´äºä»¶çï¼ï¼ç»§ç»éå½å䏿¥æ¾ |
| | | getNextUserTasks(targetElement, bpmnModel, variables, hasSequenceFlow, userTaskList); |
| | | } |
| | | } |
| | | return userTaskList; |
| | | } |
| | | |
| | | /** |
| | | * æ ¹æ®ç½å
³ç±»å䏿µç¨åéï¼çéç½å
³çåºå£è¿çº¿ |
| | | * |
| | | * @param gateway ç½å
³èç¹ |
| | | * @param variables æµç¨åé |
| | | * @return å½ä¸çåºå£è¿çº¿å表 |
| | | */ |
| | | private static List<SequenceFlow> getGatewayOutgoingFlows(Gateway gateway, Map<String, Object> variables) { |
| | | if (gateway instanceof ExclusiveGateway) { |
| | | SequenceFlow matchFlow = findMatchSequenceFlowByExclusiveGateway(gateway, variables); |
| | | return matchFlow == null ? Collections.emptyList() : Collections.singletonList(matchFlow); |
| | | } |
| | | if (gateway instanceof InclusiveGateway) { |
| | | return new ArrayList<>(findMatchSequenceFlowsByInclusiveGateway(gateway, variables)); |
| | | } |
| | | // é»è®¤ï¼å¹¶è¡ç½å
³çï¼ï¼èµ°ææåºå£ |
| | | return gateway.getOutgoingFlows(); |
| | | } |
| | | |
| | | /** |
| | | * æ¥æ¾èµ·å§èç¹ä¸ä¸ä¸ªç¨æ·ä»»å¡å表å表, ä¸å¤æç½å
³æ¡ä»¶ |
| | | * |
| | | * @param source èµ·å§èç¹ |
| | | * @return ç»æ |
| | | */ |
| | | public static List<UserTask> getNextUserTasks(FlowElement source) { |
| | | return getNextUserTasks(source, null, null); |
| | | return getNextUserTasks(source, new HashSet<>(), new ArrayList<>()); |
| | | } |
| | | |
| | | /** |
| | |
| | | import org.flowable.engine.impl.util.CommandContextUtil; |
| | | import org.flowable.engine.runtime.ProcessInstance; |
| | | import org.flowable.task.api.TaskInfo; |
| | | import tools.jackson.databind.JsonNode; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.LinkedHashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Objects; |
| | |
| | | } |
| | | |
| | | // è§£æè¡¨åé
ç½® |
| | | Map<String, BpmFormFieldVO> formFieldsMap = new HashMap<>(); |
| | | Map<String, BpmFormFieldVO> formFieldsMap = new LinkedHashMap<>(); |
| | | processDefinitionInfo.getFormFields().forEach(formFieldStr -> { |
| | | BpmFormFieldVO formField = JsonUtils.parseObject(formFieldStr, BpmFormFieldVO.class); |
| | | parseFormField(formField, formFieldsMap); |
| | | JsonNode formFieldNode = JsonUtils.parseObject(formFieldStr, JsonNode.class); |
| | | parseFormField(formFieldNode, formFieldsMap); |
| | | }); |
| | | |
| | | // æ
åµä¸ï¼å½èªå®ä¹äºæè¦ |
| | |
| | | /** |
| | | * éå½è§£æè¡¨ååæ®µ |
| | | */ |
| | | private static void parseFormField(BpmFormFieldVO formField, Map<String, BpmFormFieldVO> formFieldsMap) { |
| | | if (formField == null) { |
| | | private static void parseFormField(JsonNode formFieldNode, Map<String, BpmFormFieldVO> formFieldsMap) { |
| | | if (formFieldNode == null || !formFieldNode.isObject()) { |
| | | return; |
| | | } |
| | | // 妿åå¨ children -> è¯´ææ¯å¸å±ç»ä»¶ |
| | | if (formField.getChildren() != null && !formField.getChildren().isEmpty()) { |
| | | for (BpmFormFieldVO child : formField.getChildren()) { |
| | | |
| | | // 妿 children éåå¨å¯¹è±¡èç¹ï¼è¯´ææ¯å¸å±ç»ä»¶ï¼å符串èç¹æ¯åå²çº¿ãæ ç¾ãæåçå±ç¤ºç»ä»¶å
容ï¼ç´æ¥è·³è¿ã |
| | | JsonNode children = formFieldNode.get("children"); |
| | | if (children != null && children.isArray() && children.size() > 0) { |
| | | boolean hasObjectChild = false; |
| | | for (JsonNode child : children) { |
| | | if (!child.isObject()) { |
| | | continue; |
| | | } |
| | | hasObjectChild = true; |
| | | parseFormField(child, formFieldsMap); |
| | | } |
| | | return; |
| | | if (hasObjectChild) { |
| | | return; |
| | | } |
| | | } |
| | | |
| | | // çå®å段æå å
¥ map |
| | | BpmFormFieldVO formField = new BpmFormFieldVO() |
| | | .setType(JsonUtils.getText(formFieldNode, "type")) |
| | | .setField(JsonUtils.getText(formFieldNode, "field")) |
| | | .setTitle(JsonUtils.getText(formFieldNode, "title")); |
| | | if (StrUtil.isNotBlank(formField.getField())) { |
| | | formFieldsMap.put(formField.getField(), formField); |
| | | } |
| | |
| | | import cn.hutool.core.lang.Assert; |
| | | import cn.hutool.core.util.*; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; |
| | | import cn.iocoder.yudao.framework.common.util.date.DateUtils; |
| | | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.ObjectUtils; |
| | |
| | | import cn.iocoder.yudao.module.bpm.enums.ErrorCodeConstants; |
| | | import cn.iocoder.yudao.module.bpm.enums.definition.BpmModelTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.definition.BpmSimpleModelNodeTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmAttachmentTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmProcessInstanceStatusEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmReasonEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmTaskStatusEnum; |
| | |
| | | import org.flowable.engine.runtime.Execution; |
| | | import org.flowable.engine.runtime.ProcessInstance; |
| | | import org.flowable.engine.runtime.ProcessInstanceBuilder; |
| | | import org.flowable.engine.task.Attachment; |
| | | import org.flowable.task.api.Task; |
| | | import org.flowable.task.api.history.HistoricTaskInstance; |
| | | import org.springframework.context.annotation.Lazy; |
| | |
| | | processVariables.putAll(reqVO.getProcessVariables()); |
| | | } |
| | | |
| | | // 3. è·åä¸ä¸ä¸ªå°è¦æ§è¡çèç¹éå |
| | | // 3.1 è·åä¸ä¸ä¸ªå°è¦æ§è¡çèç¹éå |
| | | FlowElement flowElement = bpmnModel.getFlowElement(task.getTaskDefinitionKey()); |
| | | List<FlowNode> nextFlowNodes = BpmnModelUtils.getNextFlowNodes(flowElement, bpmnModel, processVariables); |
| | | // ä»
ä»
è·å UserTask èç¹ TODO add from jasonï¼å¦æç½å
³èç¹åç½å
³èç¹ç¸è¿ï¼è·åä¸ä¸ª UserTask. è²ä¼¼æç¹ä¸åã |
| | | List<FlowNode> nextUserTaskList = CollectionUtils.filterList(nextFlowNodes, node -> node instanceof UserTask); |
| | | // 3.2 è·å UserTask èç¹ |
| | | List<UserTask> nextUserTaskList = BpmnModelUtils.getNextUserTasks(flowElement, bpmnModel, processVariables); |
| | | List<ActivityNode> nextActivityNodes = convertList(nextUserTaskList, node -> new ActivityNode().setId(node.getId()) |
| | | .setName(node.getName()).setNodeType(BpmSimpleModelNodeTypeEnum.APPROVE_NODE.getType()) |
| | | .setStatus(BpmTaskStatusEnum.RUNNING.getStatus()) |
| | |
| | | // éå tasks å表ï¼åªå¤çå·²ç»æç UserTask |
| | | // 为ä»ä¹ä¸éè¿ activities å¢ï¼å 为ï¼å ç¾åºæ¯ä¸ï¼å®åªåå¨äº tasksï¼æ²¡æ activitiesï¼å¯¼è´å¦æéå activities çè¯ï¼å®æ æ³æä¸ºä¸ä¸ªèç¹ |
| | | List<HistoricTaskInstance> endTasks = filterList(tasks, task -> task.getEndTime() != null); |
| | | // è·å已宿èç¹çéä»¶ |
| | | Set<String> endTaskIds = convertSet(endTasks, HistoricTaskInstance::getId); |
| | | List<Attachment> attachments = taskService.getAttachments(historicProcessInstance.getId(), endTaskIds, BpmAttachmentTypeEnum.TASK_ATTACHMENT); |
| | | Map<String, List<Attachment>> taskAttachmentMap = convertMultiMap(attachments, Attachment::getTaskId); |
| | | List<ActivityNode> approvalNodes = convertList(endTasks, task -> { |
| | | FlowElement flowNode = BpmnModelUtils.getFlowElementById(bpmnModel, task.getTaskDefinitionKey()); |
| | | List<Attachment> taskAttachments = taskAttachmentMap.get(task.getId()); |
| | | ActivityNode activityNode = new ActivityNode().setId(task.getTaskDefinitionKey()).setName(task.getName()) |
| | | .setNodeType(START_USER_NODE_ID.equals(task.getTaskDefinitionKey()) |
| | | ? BpmSimpleModelNodeTypeEnum.START_USER_NODE.getType() |
| | |
| | | .setStatus(getEndActivityNodeStatus(task)) |
| | | .setCandidateStrategy(BpmnModelUtils.parseCandidateStrategy(flowNode)) |
| | | .setStartTime(DateUtils.of(task.getCreateTime())).setEndTime(DateUtils.of(task.getEndTime())) |
| | | .setTasks(singletonList(BpmProcessInstanceConvert.INSTANCE.buildApprovalTaskInfo(task))); |
| | | .setTasks(singletonList(BpmProcessInstanceConvert.INSTANCE.buildApprovalTaskInfo(task, taskAttachments))); |
| | | // 妿æ¯åæ¶ç¶æï¼åè·³è¿ |
| | | if (BpmTaskStatusEnum.isCancelStatus(activityNode.getStatus())) { |
| | | return null; |
| | |
| | | if (task == null) { |
| | | continue; |
| | | } |
| | | activityNode.getTasks().add(BpmProcessInstanceConvert.INSTANCE.buildApprovalTaskInfo(task)); |
| | | activityNode.getTasks().add(BpmProcessInstanceConvert.INSTANCE.buildApprovalTaskInfo(task, null)); |
| | | // å ç¾åä»»å¡ï¼éè¦è¿æ»¤æå·²ç»å®æçå ç¾åä»»å¡ |
| | | List<HistoricTaskInstance> childrenTasks = filterList( |
| | | taskService.getAllChildrenTaskListByParentTaskId(activity.getTaskId(), tasks), |
| | | childTask -> childTask.getEndTime() == null); |
| | | if (CollUtil.isNotEmpty(childrenTasks)) { |
| | | activityNode.getTasks().addAll( |
| | | convertList(childrenTasks, BpmProcessInstanceConvert.INSTANCE::buildApprovalTaskInfo)); |
| | | convertList(childrenTasks, item->BpmProcessInstanceConvert.INSTANCE.buildApprovalTaskInfo(item, null))); |
| | | } |
| | | } |
| | | // å¤çæ¯ä¸ªä»»å¡ç candidateUsers 屿§ï¼å¦ææ¯ä¾æ¬¡å®¡æ¹ï¼éè¦é¢æµå®çåç»å®¡æ¹äººãå 为 Task æ¯å®¡æ¹å®ä¸ä¸ªï¼å建ä¸ä¸ªæ°ç Task |
| | |
| | | import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; |
| | | import cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task.*; |
| | | import cn.iocoder.yudao.module.bpm.enums.definition.BpmUserTaskTimeoutHandlerTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmAttachmentTypeEnum; |
| | | import jakarta.validation.Valid; |
| | | import org.flowable.bpmn.model.UserTask; |
| | | import org.flowable.engine.history.HistoricActivityInstance; |
| | | import org.flowable.engine.task.Attachment; |
| | | import org.flowable.task.api.Task; |
| | | import org.flowable.task.api.TaskInfo; |
| | | import org.flowable.task.api.history.HistoricTaskInstance; |
| | |
| | | import java.util.Collection; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | |
| | | /** |
| | | * æµç¨ä»»å¡å®ä¾ Service æ¥å£ |
| | |
| | | */ |
| | | List<HistoricTaskInstance> getFinishedTaskListByProcessInstanceIdWithoutCancel(String processInstanceId); |
| | | |
| | | |
| | | /** |
| | | * æ ¹æ®æ¡ä»¶è·åéä»¶ |
| | | * |
| | | * @param processInstanceId æµç¨ id |
| | | * @param taskIds ä»»å¡ id éå |
| | | * @param attachmentType éä»¶ç±»å |
| | | * @return éä»¶éå |
| | | */ |
| | | List<Attachment> getAttachments(String processInstanceId, Set<String> taskIds, BpmAttachmentTypeEnum attachmentType); |
| | | |
| | | // ========== Update åå
¥ç¸å
³æ¹æ³ ========== |
| | | |
| | | /** |
| | |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.convert.Convert; |
| | | import cn.hutool.core.io.FileUtil; |
| | | import cn.hutool.core.lang.Assert; |
| | | import cn.hutool.core.map.MapUtil; |
| | | import cn.hutool.core.util.*; |
| | | import cn.hutool.extra.spring.SpringUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | |
| | | import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmFormDO; |
| | | import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmProcessDefinitionInfoDO; |
| | | import cn.iocoder.yudao.module.bpm.enums.definition.*; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmCommentTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmReasonEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmTaskSignTypeEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.BpmTaskStatusEnum; |
| | | import cn.iocoder.yudao.module.bpm.enums.task.*; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.enums.BpmTaskCandidateStrategyEnum; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.enums.BpmnVariableConstants; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.util.BpmHttpRequestUtils; |
| | |
| | | import org.flowable.engine.runtime.ActivityInstance; |
| | | import org.flowable.engine.runtime.Execution; |
| | | import org.flowable.engine.runtime.ProcessInstance; |
| | | import org.flowable.engine.task.Attachment; |
| | | import org.flowable.task.api.DelegationState; |
| | | import org.flowable.task.api.Task; |
| | | import org.flowable.task.api.TaskInfo; |
| | |
| | | .orderByHistoricTaskInstanceStartTime().asc().list(); |
| | | } |
| | | |
| | | @Override |
| | | public List<Attachment> getAttachments(String processInstanceId, Set<String> taskIds, BpmAttachmentTypeEnum attachmentType) { |
| | | List<Attachment> result = taskService.getProcessInstanceAttachments(processInstanceId); |
| | | if (CollUtil.isNotEmpty(taskIds)) { |
| | | result = filterList(result, attachment -> taskIds.contains(attachment.getTaskId())); |
| | | } |
| | | if (attachmentType != null) { |
| | | result = filterList(result, attachment -> attachmentType.getType().equals(attachment.getType())); |
| | | } |
| | | return result; |
| | | } |
| | | |
| | | /** |
| | | * 夿æå®ç¨æ·ï¼æ¯å¦æ¯å½åä»»å¡ç审æ¹äºº |
| | | * |
| | |
| | | // 2.2 æ·»å è¯è®º |
| | | taskService.addComment(task.getId(), task.getProcessInstanceId(), BpmCommentTypeEnum.APPROVE.getType(), |
| | | BpmCommentTypeEnum.APPROVE.formatComment(reqVO.getReason())); |
| | | // 2.3 æ·»å éä»¶ |
| | | if (CollUtil.isNotEmpty(reqVO.getAttachments())) { |
| | | reqVO.getAttachments().forEach(attachment -> taskService.createAttachment(BpmAttachmentTypeEnum.TASK_ATTACHMENT.getType(), |
| | | task.getId(), task.getProcessInstanceId(), FileUtil.getName(URLUtil.getPath(attachment)), null, attachment)); |
| | | } |
| | | |
| | | // 3. 设置æµç¨åéã妿æµç¨åéåç«¯ä¼ ç©ºï¼éè¦ä»åå²å®ä¾ä¸è·åï¼åå ï¼å端表å妿å¨å½åèç¹æ å¯ç¼è¾çåæ®µæ¶ variables ä¸å®ä¼ä¸ºç©º |
| | | // åºæ¯ä¸ï¼A èç¹åèµ·ï¼B èç¹è¡¨åæ å¯ç¼è¾å段ï¼å®¡æ¹éè¿æ¶ï¼C èç¹éè¦æµç¨åéè·åä¸ä¸ä¸ªæ§è¡èç¹ï¼ä½å 为 B èç¹æ å¯ç¼è¾çåæ®µï¼variables ä¸ºç©ºï¼æµç¨å¯è½åºç°é®é¢ã |
| | |
| | | } |
| | | |
| | | // 4. æ ¡éªå¹¶å¤ç APPROVE_USER_SELECT å½å审æ¹äººï¼éæ©ä¸ä¸èç¹å®¡æ¹äººçé»è¾ |
| | | Map<String, Object> variables = validateAndSetNextAssignees(task.getTaskDefinitionKey(), processVariables, |
| | | validateAndSetNextAssignees(task.getTaskDefinitionKey(), processVariables, |
| | | bpmnModel, reqVO.getNextAssignees(), instance); |
| | | runtimeService.setVariables(task.getProcessInstanceId(), variables); |
| | | runtimeService.setVariables(task.getProcessInstanceId(), processVariables); |
| | | |
| | | // 5. 妿å½åèç¹ Id åå¨äºéè¦é¢æµçæµç¨èç¹ä¸ï¼ä»ä¸ç§»é¤ã æµç¨åéå¨åéæä½ä¸è®¾ç½® |
| | | Object needSimulateTaskIds = runtimeService.getVariable(task.getProcessInstanceId(), BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_NEED_SIMULATE_TASK_IDS); |
| | |
| | | runtimeService.setVariable(task.getProcessInstanceId(), BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_NEED_SIMULATE_TASK_IDS, needSimulateTaskIdsByReturn); |
| | | } |
| | | |
| | | // 6. è°ç¨ BPM complete å»å®æä»»å¡ |
| | | taskService.complete(task.getId(), variables, true); |
| | | // 6. æ¸
çéå设置çä¸èªå¨éè¿çåéãä»
å¨è¯¥æ è®°å卿¶æå é¤ï¼é¿å
æ¯æ¬¡å®æä»»å¡é½äº§çæ è°ç DB delete |
| | | String returnFlagKey = String.format(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_RETURN_FLAG, task.getTaskDefinitionKey()); |
| | | if (runtimeService.hasVariable(task.getProcessInstanceId(), returnFlagKey)) { |
| | | log.info("[approveTask][taskId({}) æ¸
çéåæ è®°åé({})]", task.getId(), returnFlagKey); |
| | | runtimeService.removeVariable(task.getProcessInstanceId(), returnFlagKey); |
| | | } |
| | | |
| | | // 7. è°ç¨ BPM complete å»å®æä»»å¡ |
| | | Map<String,Object> taskVariables = MapUtil.emptyIfNull(reqVO.getVariables()); // task local variables. ä¸è¬ç¨äºä»»å¡å
嵿µç¨è¡¨å |
| | | taskService.complete(task.getId(), taskVariables, true); |
| | | |
| | | // ãå ç¾ä¸å±ãå¤çå ç¾ä»»å¡ |
| | | handleParentTaskIfSign(task.getParentTaskId()); |
| | |
| | | } |
| | | // 1. è·åä¸ä¸ä¸ªå°è¦æ§è¡çèç¹éå |
| | | FlowElement flowElement = bpmnModel.getFlowElement(taskDefinitionKey); |
| | | List<FlowNode> nextFlowNodes = getNextFlowNodes(flowElement, bpmnModel, variables); |
| | | List<UserTask> nextFlowNodes = getNextUserTasks(flowElement, bpmnModel, variables); |
| | | |
| | | // 2. æ ¡éªéæ©çä¸ä¸ä¸ªèç¹ç审æ¹äººï¼æ¯å¦åæ³ |
| | | for (FlowNode nextFlowNode : nextFlowNodes) { |
| | | for (UserTask nextFlowNode : nextFlowNodes) { |
| | | Integer candidateStrategy = parseCandidateStrategy(nextFlowNode); |
| | | // 2.1 æ
åµä¸ï¼å¦æèç¹ä¸ç审æ¹äººçç¥ä¸º å起人èªé |
| | | if (ObjUtil.equals(candidateStrategy, BpmTaskCandidateStrategyEnum.START_USER_SELECT.getStrategy())) { |
| | |
| | | |
| | | // 2.2 æ
åµäºï¼å¦æèç¹ä¸ç审æ¹äººçç¥ä¸º 审æ¹äººï¼å¨å®¡æ¹æ¶éæ©ä¸ä¸ä¸ªèç¹ç审æ¹äººï¼å¹¶ä¸è¯¥èç¹ç审æ¹äººä¸ºç©º |
| | | if (ObjUtil.equals(candidateStrategy, BpmTaskCandidateStrategyEnum.APPROVE_USER_SELECT.getStrategy())) { |
| | | // 妿èç¹åå¨ï¼ä½æªé
置审æ¹äºº |
| | | // ç¹æ®ï¼å¦æå½åèç¹å·²ç»åå¨å®¡æ¹äººï¼åä¸å
许è¦çã ä¾å¦å¹¶è¡èç¹åï¼è®¾ç½®ç审æ¹äººèªéèç¹ã https://t.zsxq.com/daxv1 |
| | | Map<String, List<Long>> approveUserSelectAssignees = FlowableUtils.getApproveUserSelectAssignees(processInstance.getProcessVariables()); |
| | | if (approveUserSelectAssignees != null && CollUtil.isNotEmpty(approveUserSelectAssignees.get(nextFlowNode.getId()))) { |
| | | continue; |
| | | } |
| | | // 妿èç¹åå¨ï¼ä½æªé
置审æ¹äºº |
| | | List<Long> assignees = nextAssignees != null ? nextAssignees.get(nextFlowNode.getId()) : null; |
| | | if (CollUtil.isEmpty(assignees)) { |
| | | throw exception(PROCESS_INSTANCE_APPROVE_USER_SELECT_ASSIGNEES_NOT_CONFIG, nextFlowNode.getName()); |
| | |
| | | // 2.2 æ·»å æµç¨è¯è®º |
| | | taskService.addComment(task.getId(), task.getProcessInstanceId(), BpmCommentTypeEnum.REJECT.getType(), |
| | | BpmCommentTypeEnum.REJECT.formatComment(reqVO.getReason())); |
| | | // 2.3 妿å½å任塿¶è¢«å ç¾çï¼åå å®çæ ¹ä»»å¡ä¹æ è®°ææªéè¿ |
| | | // 2.3 æ·»å éä»¶ |
| | | if (CollUtil.isNotEmpty(reqVO.getAttachments())) { |
| | | reqVO.getAttachments().forEach(attachment -> taskService.createAttachment(BpmAttachmentTypeEnum.TASK_ATTACHMENT.getType(), |
| | | task.getId(), task.getProcessInstanceId(), FileUtil.getName(URLUtil.getPath(attachment)), null, attachment)); |
| | | } |
| | | |
| | | // 2.4 妿å½å任塿¶è¢«å ç¾çï¼åå å®çæ ¹ä»»å¡ä¹æ è®°ææªéè¿ |
| | | // çé®ï¼ä¸ºä»ä¹è¦æ è®°æªéè¿å¢ï¼ |
| | | // åçï¼ä¾å¦è¯´ A ä»»å¡è¢«ååå ç¾é¤ B 任塿¶ï¼B ä»»å¡è¢«å®¡æ¹ä¸éè¿ï¼æ¤æ¶ A ä¼è¢«åæ¶ãè yudao-ui-admin-vue3 ä¸å±ç¤ºâ已忶âçä»»å¡ï¼å¯¼è´å±ç¤ºä¸åºå®¡æ¹ä¸éè¿çç»èã |
| | | if (task.getParentTaskId() != null) { |
| | |
| | | // 为ä»ä¹ä¸ç´æ¥ä½¿ç¨ runTaskKeyList å¢ï¼å 为å¯è½åå¨å¤ä¸ªå®¡æ¹åæ¯ï¼ä¾å¦è¯´ï¼A -> B -> C å D -> Fï¼èåªè¦ C æ¤åå° Aï¼éè¦æé¤æ F |
| | | List<UserTask> returnUserTaskList = BpmnModelUtils.iteratorFindChildUserTasks(targetElement, runTaskKeyList, null, null); |
| | | List<String> returnTaskKeyList = convertList(returnUserTaskList, UserTask::getId); |
| | | |
| | | // 2. ç»å½åè¦è¢«éåç task æ°ç»ï¼è®¾ç½®éåæè§ |
| | | taskList.forEach(task -> { |
| | | // éè¦æé¤æï¼ä¸éè¦è®¾ç½®éåæè§çä»»å¡ |
| | | if (!returnTaskKeyList.contains(task.getTaskDefinitionKey())) { |
| | | return; |
| | | } |
| | | |
| | | // 夿æ¯å¦åé
ç»èªå·±ä»»å¡ï¼å 为ä¼ç¾ä»»å¡ï¼ä¸ä¸ªèç¹ä¼æå¤ä¸ªä»»å¡ |
| | | if (isAssignUserTask(userId, task)) { // æ
åµä¸ï¼èªå·±çä»»å¡ï¼è¿è¡ RETURN æ è®° |
| | | // 2.1.1 æ·»å è¯è®º |
| | |
| | | // ç¸å
³ issue: https://github.com/flowable/flowable-engine/issues/3944 |
| | | // â¡ flowable 7.2.0 çæ¬åï¼ç»§ç»ä½¿ç¨ moveActivityIdsToSingleActivityId æ¹æ³ãåå ï¼flowable 7.2.0 çæ¬ä¿®å¤äºè¯¥é®é¢ã |
| | | // ç¸å
³ issueï¼https://github.com/YunaiV/ruoyi-vue-pro/issues/1018 |
| | | // ⢠moveActivityIdsToSingleActivityId 使ç¨éå°é®é¢ï¼ ç¸å
³ issue https://gitee.com/zhijiantianya/yudao-cloud/issues/IJM8MS |
| | | // æ¹æ moveExecutionsToSingleActivityId 好å并没æéå° â¡ æå°çè¶
æ¶æé失æçé®é¢ãææ¶å
æ¹å moveExecutionsToSingleActivityId |
| | | // ⣠moveExecutionsToSingleActivityId åéå¤å®ä¾çæ¶åä¸ä¼å»å é¤å¤å®ä¾æ ¹, åºæ¹æ moveActivityIdsToSingleActivityId |
| | | // flowable 8.0.0 ä¿®å¤ä¸é¢ç¸å
³é®é¢ï¼ è¿ä¿®å¤äºå¹¶è¡åæ¯åéçé®é¢ https://t.zsxq.com/z4d9iã |
| | | // â¤ ä½¿ç¨ moveExecutionsToSingleActivityId æ¹æ³è¿è¡åéæä½æ¶ï¼å¦ææ¯å¤å®ä¾çç¨æ·ä»»å¡ãèéç¨æ·ä»»å¡é»è®¤ä¸ºå¤å®ä¾ãï¼ä¸ä¼å é¤å¤å®ä¾ä»»å¡çæ ¹æ°æ® ACT_RU_EXECUTION |
| | | // ä¼å¯¼è´æä¸äºé®é¢ï¼æä»¥ä½¿ç¨ moveActivityIdsToSingleActivityIdã 使¯è¯¥æ¹æ³å¨ flowable 6.8.1 ~ 7.1.0 ççæ¬ä¼æ bug é»å¡åéåè½ |
| | | // ç¸å
³ issue: https://github.com/flowable/flowable-engine/issues/3944 |
| | | runtimeService.createChangeActivityStateBuilder() |
| | | .processInstanceId(currentTask.getProcessInstanceId()) |
| | | .moveActivityIdsToSingleActivityId(returnTaskKeyList, reqVO.getTargetTaskDefinitionKey()) |
| | | // 设置éè¦é¢æµçä»»å¡ ids çæµç¨åéï¼ç¨äºè¾
å©é¢æµ |
| | | .processVariable(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_NEED_SIMULATE_TASK_IDS, needSimulateTaskDefinitionKeys) |
| | | // 设置æµç¨åéï¼localï¼èç¹éåæ è®°, ç¨äºéåå°èç¹ï¼ä¸æ§è¡ BpmUserTaskAssignStartUserHandlerTypeEnum çç¥ï¼å¯¼è´èªå¨éè¿ |
| | | .localVariable(reqVO.getTargetTaskDefinitionKey(), |
| | | String.format(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_RETURN_FLAG, reqVO.getTargetTaskDefinitionKey()), Boolean.TRUE) |
| | | // 设置æµç¨åéèç¹éåæ è®°, ç¨äºéåå°èç¹ï¼ä¸æ§è¡ BpmUserTaskAssignStartUserHandlerTypeEnum çç¥ï¼å¯¼è´èªå¨éè¿ |
| | | .processVariable(String.format(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_RETURN_FLAG, reqVO.getTargetTaskDefinitionKey()), Boolean.TRUE) |
| | | .changeState(); |
| | | } |
| | | |
| | |
| | | return; |
| | | } |
| | | |
| | | // èªå¨å»éï¼éè¿èªå¨å®¡æ¹çæ¹å¼ |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = bpmProcessDefinitionService.getProcessDefinitionInfo(task.getProcessDefinitionId()); |
| | | if (processDefinitionInfo == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨å®ä¹({})]", task.getId(), task.getProcessDefinitionId()); |
| | | return; |
| | | } |
| | | if (processDefinitionInfo.getAutoApprovalType() != null) { |
| | | HistoricTaskInstanceQuery sameAssigneeQuery = historyService.createHistoricTaskInstanceQuery() |
| | | .processInstanceId(task.getProcessInstanceId()) |
| | | .taskAssignee(task.getAssignee()) // ç¸å审æ¹äºº |
| | | .taskVariableValueEquals(BpmnVariableConstants.TASK_VARIABLE_STATUS, BpmTaskStatusEnum.APPROVE.getStatus()) |
| | | .finished(); |
| | | if (BpmAutoApproveTypeEnum.APPROVE_ALL.getType().equals(processDefinitionInfo.getAutoApprovalType()) |
| | | && sameAssigneeQuery.count() > 0) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmAutoApproveTypeEnum.APPROVE_ALL.getName())); |
| | | // éè¦åºäº instance è®¾ç½®ç§æ·ç¼å·ï¼é¿å
Flowable å
é¨å¼æ¥æ§è¡æ¶ãä¾å¦ï¼è¶
æ¶èªå¨éè¿ã ä¸¢å¤±ç§æ·ç¼å· |
| | | FlowableUtils.execute(processInstance.getTenantId(), () -> { |
| | | // èªå¨å»éï¼éè¿èªå¨å®¡æ¹çæ¹å¼ |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = bpmProcessDefinitionService.getProcessDefinitionInfo(task.getProcessDefinitionId()); |
| | | if (processDefinitionInfo == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨å®ä¹({})]", task.getId(), task.getProcessDefinitionId()); |
| | | return; |
| | | } |
| | | if (BpmAutoApproveTypeEnum.APPROVE_SEQUENT.getType().equals(processDefinitionInfo.getAutoApprovalType())) { |
| | | BpmnModel bpmnModel = modelService.getBpmnModelByDefinitionId(processInstance.getProcessDefinitionId()); |
| | | if (bpmnModel == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨æ¨¡å({})]", task.getId(), task.getProcessDefinitionId()); |
| | | return; |
| | | } |
| | | List<String> sourceTaskIds = convertList(BpmnModelUtils.getElementIncomingFlows( // è·åææä¸ä¸ä¸ªèç¹ |
| | | BpmnModelUtils.getFlowElementById(bpmnModel, task.getTaskDefinitionKey())), |
| | | SequenceFlow::getSourceRef); |
| | | if (sameAssigneeQuery.taskDefinitionKeys(sourceTaskIds).count() > 0) { |
| | | if (processDefinitionInfo.getAutoApprovalType() != null) { |
| | | HistoricTaskInstanceQuery approvedTaskQuery = historyService.createHistoricTaskInstanceQuery() |
| | | .processInstanceId(task.getProcessInstanceId()) |
| | | .taskVariableValueEquals(BpmnVariableConstants.TASK_VARIABLE_STATUS, BpmTaskStatusEnum.APPROVE.getStatus()) |
| | | .finished(); |
| | | if (BpmAutoApproveTypeEnum.APPROVE_ALL.getType().equals(processDefinitionInfo.getAutoApprovalType()) |
| | | && approvedTaskQuery.taskAssignee(task.getAssignee()).count() > 0) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmAutoApproveTypeEnum.APPROVE_SEQUENT.getName())); |
| | | .setReason(BpmAutoApproveTypeEnum.APPROVE_ALL.getName())); |
| | | return; |
| | | } |
| | | } |
| | | } |
| | | |
| | | // è·åå起人èç¹ |
| | | BpmnModel bpmnModel = modelService.getBpmnModelByDefinitionId(processInstance.getProcessDefinitionId()); |
| | | if (bpmnModel == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨æ¨¡å]", task.getId()); |
| | | return; |
| | | } |
| | | FlowElement userTaskElement = BpmnModelUtils.getFlowElementById(bpmnModel, task.getTaskDefinitionKey()); |
| | | // 夿æ¯å¦ä¸ºéåæè
驳åï¼å¦ææ¯éåæè
驳åä¸èµ°è¿ä¸ªçç¥ï¼ä½¿ç¨ local variableï¼ |
| | | Boolean returnTaskFlag = runtimeService.getVariableLocal(task.getExecutionId(), |
| | | String.format(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_RETURN_FLAG, task.getTaskDefinitionKey()), Boolean.class); |
| | | Boolean skipStartUserNodeFlag = Convert.toBool(runtimeService.getVariable(processInstance.getProcessInstanceId(), |
| | | BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_SKIP_START_USER_NODE, String.class)); |
| | | if (userTaskElement.getId().equals(START_USER_NODE_ID) |
| | | && (skipStartUserNodeFlag == null // ç®çï¼ä¸è¬æ¯â主æµç¨âï¼å起人èç¹ï¼èªå¨éè¿å®¡æ ¸ |
| | | || BooleanUtil.isTrue(skipStartUserNodeFlag)) // ç®çï¼ä¸è¬æ¯âåæµç¨âï¼å起人èç¹ï¼æé
ç½®èªå¨éè¿å®¡æ ¸ |
| | | && ObjUtil.notEqual(returnTaskFlag, Boolean.TRUE)) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_SKIP_START_USER_NODE.getReason())); |
| | | return; |
| | | } |
| | | // å½ä¸ä¸ºå起人èç¹æ¶ï¼å®¡æ¹äººä¸æäº¤äººä¸ºåä¸äººæ¶ï¼æ ¹æ® BpmUserTaskAssignStartUserHandlerTypeEnum çç¥è¿è¡å¤ç |
| | | if (ObjectUtil.notEqual(userTaskElement.getId(), START_USER_NODE_ID) |
| | | && StrUtil.equals(task.getAssignee(), processInstance.getStartUserId())) { |
| | | if (ObjUtil.notEqual(returnTaskFlag, Boolean.TRUE)) { |
| | | Integer assignStartUserHandlerType = BpmnModelUtils.parseAssignStartUserHandlerType(userTaskElement); |
| | | |
| | | // æ
åµä¸ï¼èªå¨è·³è¿ |
| | | if (ObjectUtils.equalsAny(assignStartUserHandlerType, |
| | | BpmUserTaskAssignStartUserHandlerTypeEnum.SKIP.getType())) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_SKIP.getReason())); |
| | | return; |
| | | } |
| | | // æ
åµäºï¼è½¬äº¤ç»é¨é¨è´è´£äººå®¡æ¹ |
| | | if (ObjectUtils.equalsAny(assignStartUserHandlerType, |
| | | BpmUserTaskAssignStartUserHandlerTypeEnum.TRANSFER_DEPT_LEADER.getType())) { |
| | | AdminUserRespDTO startUser = adminUserApi.getUser(Long.valueOf(processInstance.getStartUserId())); |
| | | Assert.notNull(startUser, "æäº¤äºº({})ä¿¡æ¯ä¸ºç©º", processInstance.getStartUserId()); |
| | | DeptRespDTO dept = startUser.getDeptId() != null ? deptApi.getDept(startUser.getDeptId()) : null; |
| | | Assert.notNull(dept, "æäº¤äºº({})é¨é¨({})ä¿¡æ¯ä¸ºç©º", processInstance.getStartUserId(), startUser.getDeptId()); |
| | | // æ¾ä¸å°é¨é¨è´è´£äººçæ
åµä¸ï¼èªå¨å®¡æ¹éè¿ |
| | | // noinspection DataFlowIssue |
| | | if (dept.getLeaderUserId() == null) { |
| | | // è¿ç»å®¡æ¹çèç¹èªå¨éè¿ |
| | | if (BpmAutoApproveTypeEnum.APPROVE_SEQUENT.getType().equals(processDefinitionInfo.getAutoApprovalType())) { |
| | | BpmnModel bpmnModel = modelService.getBpmnModelByDefinitionId(processInstance.getProcessDefinitionId()); |
| | | if (bpmnModel == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨æ¨¡å({})]", task.getId(), task.getProcessDefinitionId()); |
| | | return; |
| | | } |
| | | List<String> sourceTaskIds = convertList(BpmnModelUtils.getElementIncomingUserTaskFlows( // è·åææçä¸ä¸ä¸ª UserTask èç¹è¿çº¿ |
| | | BpmnModelUtils.getFlowElementById(bpmnModel, task.getTaskDefinitionKey())), |
| | | SequenceFlow::getSourceRef); |
| | | approvedTaskQuery.taskDefinitionKeys(sourceTaskIds).orderByTaskCreateTime().desc(); // 设置 taskIds, å¹¶æå建æ¶é´ååºæåº |
| | | HistoricTaskInstance firstHisTask = CollUtil.getFirst(approvedTaskQuery.list()); |
| | | if (firstHisTask != null && StrUtil.equals(firstHisTask.getAssignee(), task.getAssignee())) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_DEPT_LEADER_NOT_FOUND.getReason())); |
| | | .setReason(BpmAutoApproveTypeEnum.APPROVE_SEQUENT.getName())); |
| | | return; |
| | | } |
| | | // æ¾å¾å°é¨é¨è´è´£äººçæ
åµä¸ï¼ä¿®æ¹è´è´£äºº |
| | | if (ObjectUtil.notEqual(dept.getLeaderUserId(), startUser.getId())) { |
| | | getSelf().transferTask(Long.valueOf(task.getAssignee()), new BpmTaskTransferReqVO() |
| | | .setId(task.getId()).setAssigneeUserId(dept.getLeaderUserId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_TRANSFER_DEPT_LEADER.getReason())); |
| | | return; |
| | | } |
| | | // 妿é¨é¨è´è´£äººæ¯èªå·±ï¼è¿æ¯èªå·±å®¡æ¹å§~ |
| | | } |
| | | } |
| | | } |
| | | // 注æï¼éè¦åºäº instance è®¾ç½®ç§æ·ç¼å·ï¼é¿å
Flowable å
é¨å¼æ¥æ¶ï¼ä¸¢å¤±ç§æ·ç¼å· |
| | | FlowableUtils.execute(processInstance.getTenantId(), () -> { |
| | | |
| | | // è·åå起人èç¹ |
| | | BpmnModel bpmnModel = modelService.getBpmnModelByDefinitionId(processInstance.getProcessDefinitionId()); |
| | | if (bpmnModel == null) { |
| | | log.error("[processTaskAssigned][taskId({}) æ²¡ææ¾å°æµç¨æ¨¡å]", task.getId()); |
| | | return; |
| | | } |
| | | FlowElement userTaskElement = BpmnModelUtils.getFlowElementById(bpmnModel, task.getTaskDefinitionKey()); |
| | | // 夿æ¯å¦ä¸ºéåæè
驳åï¼å¦ææ¯éåæè
驳åä¸èµ°è¿ä¸ªçç¥ |
| | | Boolean returnTaskFlag = runtimeService.getVariable(processInstance.getProcessInstanceId(), |
| | | String.format(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_RETURN_FLAG, task.getTaskDefinitionKey()), Boolean.class); |
| | | Boolean skipStartUserNodeFlag = Convert.toBool(runtimeService.getVariable(processInstance.getProcessInstanceId(), |
| | | BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_SKIP_START_USER_NODE, String.class)); |
| | | if (userTaskElement.getId().equals(START_USER_NODE_ID) |
| | | && (skipStartUserNodeFlag == null // ç®çï¼ä¸è¬æ¯â主æµç¨âï¼å起人èç¹ï¼èªå¨éè¿å®¡æ ¸ |
| | | || BooleanUtil.isTrue(skipStartUserNodeFlag)) // ç®çï¼ä¸è¬æ¯âåæµç¨âï¼å起人èç¹ï¼æé
ç½®èªå¨éè¿å®¡æ ¸ |
| | | && ObjUtil.notEqual(returnTaskFlag, Boolean.TRUE)) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_SKIP_START_USER_NODE.getReason())); |
| | | return; |
| | | } |
| | | // å½ä¸ä¸ºå起人èç¹æ¶ï¼å®¡æ¹äººä¸æäº¤äººä¸ºåä¸äººæ¶ï¼æ ¹æ® BpmUserTaskAssignStartUserHandlerTypeEnum çç¥è¿è¡å¤ç |
| | | if (ObjectUtil.notEqual(userTaskElement.getId(), START_USER_NODE_ID) |
| | | && StrUtil.equals(task.getAssignee(), processInstance.getStartUserId())) { |
| | | if (ObjUtil.notEqual(returnTaskFlag, Boolean.TRUE)) { |
| | | Integer assignStartUserHandlerType = BpmnModelUtils.parseAssignStartUserHandlerType(userTaskElement); |
| | | |
| | | // æ
åµä¸ï¼èªå¨è·³è¿ |
| | | if (ObjectUtils.equalsAny(assignStartUserHandlerType, |
| | | BpmUserTaskAssignStartUserHandlerTypeEnum.SKIP.getType())) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_SKIP.getReason())); |
| | | return; |
| | | } |
| | | // æ
åµäºï¼è½¬äº¤ç»é¨é¨è´è´£äººå®¡æ¹ |
| | | if (ObjectUtils.equalsAny(assignStartUserHandlerType, |
| | | BpmUserTaskAssignStartUserHandlerTypeEnum.TRANSFER_DEPT_LEADER.getType())) { |
| | | AdminUserRespDTO startUser = adminUserApi.getUser(Long.valueOf(processInstance.getStartUserId())); |
| | | Assert.notNull(startUser, "æäº¤äºº({})ä¿¡æ¯ä¸ºç©º", processInstance.getStartUserId()); |
| | | DeptRespDTO dept = startUser.getDeptId() != null ? deptApi.getDept(startUser.getDeptId()) : null; |
| | | Assert.notNull(dept, "æäº¤äºº({})é¨é¨({})ä¿¡æ¯ä¸ºç©º", processInstance.getStartUserId(), startUser.getDeptId()); |
| | | // æ¾ä¸å°é¨é¨è´è´£äººçæ
åµä¸ï¼èªå¨å®¡æ¹éè¿ |
| | | // noinspection DataFlowIssue |
| | | if (dept.getLeaderUserId() == null) { |
| | | getSelf().approveTask(Long.valueOf(task.getAssignee()), new BpmTaskApproveReqVO().setId(task.getId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_APPROVE_WHEN_DEPT_LEADER_NOT_FOUND.getReason())); |
| | | return; |
| | | } |
| | | // æ¾å¾å°é¨é¨è´è´£äººçæ
åµä¸ï¼ä¿®æ¹è´è´£äºº |
| | | if (ObjectUtil.notEqual(dept.getLeaderUserId(), startUser.getId())) { |
| | | getSelf().transferTask(Long.valueOf(task.getAssignee()), new BpmTaskTransferReqVO() |
| | | .setId(task.getId()).setAssigneeUserId(dept.getLeaderUserId()) |
| | | .setReason(BpmReasonEnum.ASSIGN_START_USER_TRANSFER_DEPT_LEADER.getReason())); |
| | | return; |
| | | } |
| | | // 妿é¨é¨è´è´£äººæ¯èªå·±ï¼è¿æ¯èªå·±å®¡æ¹å§~ |
| | | } |
| | | } |
| | | } |
| | | |
| | | // åéæ¶æ¯ |
| | | AdminUserRespDTO startUser = adminUserApi.getUser(Long.valueOf(processInstance.getStartUserId())); |
| | | messageService.sendMessageWhenTaskAssigned(BpmTaskConvert.INSTANCE.convert(processInstance, startUser, task)); |
| | | }); |
| | |
| | | package cn.iocoder.yudao.module.bpm.framework.flowable.core.candidate; |
| | | |
| | | import cn.hutool.core.collection.ListUtil; |
| | | import cn.hutool.core.map.MapUtil; |
| | | import cn.hutool.extra.spring.SpringUtil; |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | |
| | | public void setUp() { |
| | | userStrategy = new BpmTaskCandidateUserStrategy(); // å建 strategy å®ä¾ |
| | | when(emptyStrategy.getStrategy()).thenReturn(BpmTaskCandidateStrategyEnum.ASSIGN_EMPTY); |
| | | strategyList = List.of(userStrategy, emptyStrategy); // å建 strategyList |
| | | strategyList = ListUtil.of(userStrategy, emptyStrategy); // å建 strategyList |
| | | taskCandidateInvoker = new BpmTaskCandidateInvoker(strategyList, adminUserApi); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.bpm.framework.flowable.core.candidate.strategy.dept; |
| | | |
| | | import cn.hutool.core.collection.ListUtil; |
| | | import cn.hutool.core.map.MapUtil; |
| | | import cn.iocoder.yudao.framework.test.core.ut.BaseMockitoUnitTest; |
| | | import cn.iocoder.yudao.module.bpm.framework.flowable.core.enums.BpmnVariableConstants; |
| | |
| | | import org.mockito.Mock; |
| | | |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | |
| | |
| | | // mock æ¹æ³ï¼FlowableUtilsï¼ |
| | | Map<String, Object> processVariables = new HashMap<>(); |
| | | processVariables.put(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_START_USER_SELECT_ASSIGNEES, |
| | | MapUtil.of("activity_001", List.of(1L, 2L))); |
| | | MapUtil.of("activity_001", ListUtil.of(1L, 2L))); |
| | | when(processInstance.getProcessVariables()).thenReturn(processVariables); |
| | | |
| | | // è°ç¨ |
| | |
| | | String activityId = "activity_001"; |
| | | Map<String, Object> processVariables = new HashMap<>(); |
| | | processVariables.put(BpmnVariableConstants.PROCESS_INSTANCE_VARIABLE_START_USER_SELECT_ASSIGNEES, |
| | | MapUtil.of("activity_001", List.of(1L, 2L))); |
| | | MapUtil.of("activity_001", ListUtil.of(1L, 2L))); |
| | | |
| | | // è°ç¨ |
| | | Set<Long> userIds = strategy.calculateUsersByActivity(null, activityId, null, |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.bpm.framework.flowable.core.util; |
| | | |
| | | import cn.iocoder.yudao.framework.common.core.KeyValue; |
| | | import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model.BpmModelMetaInfoVO; |
| | | import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmProcessDefinitionInfoDO; |
| | | import cn.iocoder.yudao.module.bpm.enums.definition.BpmModelFormTypeEnum; |
| | | import org.junit.jupiter.api.Test; |
| | | |
| | | import java.util.Arrays; |
| | | import java.util.Collections; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static org.junit.jupiter.api.Assertions.assertEquals; |
| | | import static org.junit.jupiter.api.Assertions.assertNull; |
| | | |
| | | /** |
| | | * {@link FlowableUtils} çåå
æµè¯ã |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | class FlowableUtilsTest { |
| | | |
| | | @Test |
| | | public void testGetSummary_customSummary_parseDbFormFields() { |
| | | // åå¤åæ°ï¼æ¨¡æ DB ä¸ form_fields åæ®µï¼åè¡¨éæ¯ä¸ªå
ç´ é½æ¯ä¸ä¸ª form-create åæ®µ JSONã |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = processDefinitionInfo(dbFormFields(), |
| | | summarySetting(true, "reason", "days", "notExists", "startTime")); |
| | | Map<String, Object> processVariables = processVariables(); |
| | | |
| | | // è°ç¨ |
| | | List<KeyValue<String, String>> summary = FlowableUtils.getSummary(processDefinitionInfo, processVariables); |
| | | |
| | | // æè¨ |
| | | assertEquals(Arrays.asList( |
| | | new KeyValue<>("请ååå ", "äºå"), |
| | | new KeyValue<>("请å天æ°", "3"), |
| | | new KeyValue<>("å¼å§æ¶é´", "2026-05-31 09:00:00")), |
| | | summary); |
| | | } |
| | | |
| | | @Test |
| | | public void testGetSummary_defaultSummary_parseFirstThreeFieldsByFormOrder() { |
| | | // åå¤åæ°ï¼æªå¼å¯èªå®ä¹æè¦æ¶ï¼é»è®¤å表åé
置顺åºéçåä¸ä¸ªçå®å段ã |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = processDefinitionInfo(dbFormFields(), null); |
| | | Map<String, Object> processVariables = processVariables(); |
| | | |
| | | // è°ç¨ |
| | | List<KeyValue<String, String>> summary = FlowableUtils.getSummary(processDefinitionInfo, processVariables); |
| | | |
| | | // æè¨ |
| | | assertEquals(Arrays.asList( |
| | | new KeyValue<>("请ååå ", "äºå"), |
| | | new KeyValue<>("å¼å§æ¶é´", "2026-05-31 09:00:00"), |
| | | new KeyValue<>("请å天æ°", "3")), |
| | | summary); |
| | | } |
| | | |
| | | @Test |
| | | public void testGetSummary_summaryDisabled_useDefaultSummary() { |
| | | // åå¤åæ°ï¼æè¦è®¾ç½®åå¨ä½æªå¯ç¨æ¶ï¼ä»èµ°é»è®¤æè¦é»è¾ã |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = processDefinitionInfo(dbFormFields(), |
| | | summarySetting(false, "remark")); |
| | | Map<String, Object> processVariables = processVariables(); |
| | | |
| | | // è°ç¨ |
| | | List<KeyValue<String, String>> summary = FlowableUtils.getSummary(processDefinitionInfo, processVariables); |
| | | |
| | | // æè¨ |
| | | assertEquals(Arrays.asList( |
| | | new KeyValue<>("请ååå ", "äºå"), |
| | | new KeyValue<>("å¼å§æ¶é´", "2026-05-31 09:00:00"), |
| | | new KeyValue<>("请å天æ°", "3")), |
| | | summary); |
| | | } |
| | | |
| | | @Test |
| | | public void testGetSummary_displayComponentsOnly_returnEmpty() { |
| | | // åå¤åæ°ï¼åå²çº¿ãæ ç¾ãæåçå±ç¤ºç»ä»¶ç children æ¯å符串æ°ç»ï¼ä¸æ¯è¡¨ååæ®µå¯¹è±¡ã |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = processDefinitionInfo(Arrays.asList( |
| | | DIVIDER_FIELD, |
| | | TEXT_FIELD, |
| | | TAG_FIELD), null); |
| | | |
| | | // è°ç¨ |
| | | List<KeyValue<String, String>> summary = FlowableUtils.getSummary(processDefinitionInfo, |
| | | Collections.emptyMap()); |
| | | |
| | | // æè¨ |
| | | assertEquals(Collections.emptyList(), summary); |
| | | } |
| | | |
| | | @Test |
| | | public void testGetSummary_notNormalForm_returnNull() { |
| | | // åå¤åæ° |
| | | BpmProcessDefinitionInfoDO processDefinitionInfo = BpmProcessDefinitionInfoDO.builder() |
| | | .formType(BpmModelFormTypeEnum.CUSTOM.getType()) |
| | | .build(); |
| | | |
| | | // è°ç¨ & æè¨ |
| | | assertNull(FlowableUtils.getSummary(null, Collections.emptyMap())); |
| | | assertNull(FlowableUtils.getSummary(processDefinitionInfo, Collections.emptyMap())); |
| | | } |
| | | |
| | | private static BpmProcessDefinitionInfoDO processDefinitionInfo(List<String> formFields, |
| | | BpmModelMetaInfoVO.SummarySetting summarySetting) { |
| | | return BpmProcessDefinitionInfoDO.builder() |
| | | .formType(BpmModelFormTypeEnum.NORMAL.getType()) |
| | | .formFields(formFields) |
| | | .summarySetting(summarySetting) |
| | | .build(); |
| | | } |
| | | |
| | | private static BpmModelMetaInfoVO.SummarySetting summarySetting(Boolean enable, String... fields) { |
| | | BpmModelMetaInfoVO.SummarySetting summarySetting = new BpmModelMetaInfoVO.SummarySetting(); |
| | | summarySetting.setEnable(enable); |
| | | summarySetting.setSummary(Arrays.asList(fields)); |
| | | return summarySetting; |
| | | } |
| | | |
| | | private static List<String> dbFormFields() { |
| | | return Arrays.asList( |
| | | DIVIDER_FIELD, |
| | | "{\"type\":\"input\",\"field\":\"reason\",\"title\":\"请ååå \",\"value\":\"\"," |
| | | + "\"props\":{\"type\":\"textarea\",\"placeholder\":\"请è¾å
¥è¯·ååå \"}," |
| | | + "\"$required\":\"请è¾å
¥è¯·ååå \",\"_fc_id\":\"id_F1\",\"_fc_drag_tag\":\"input\"," |
| | | + "\"hidden\":false,\"display\":true}", |
| | | TEXT_FIELD, |
| | | "{\"type\":\"elRow\",\"title\":\"æ
æ ¼å¸å±\",\"children\":[" |
| | | + "{\"type\":\"elCol\",\"props\":{\"span\":12},\"children\":[" |
| | | + "{\"type\":\"DatePicker\",\"field\":\"startTime\",\"title\":\"å¼å§æ¶é´\"," |
| | | + "\"props\":{\"type\":\"datetime\",\"placeholder\":\"è¯·éæ©å¼å§æ¶é´\"}," |
| | | + "\"_fc_id\":\"id_F2\",\"_fc_drag_tag\":\"datePicker\"}]}," |
| | | + "\"åæ®µè¯´æ\"," |
| | | + "{\"type\":\"elCol\",\"props\":{\"span\":12},\"children\":[" |
| | | + "{\"type\":\"inputNumber\",\"field\":\"days\",\"title\":\"请å天æ°\"," |
| | | + "\"props\":{\"min\":0,\"precision\":1},\"_fc_id\":\"id_F3\"," |
| | | + "\"_fc_drag_tag\":\"inputNumber\"}]}],\"_fc_id\":\"id_LAYOUT\"," |
| | | + "\"_fc_drag_tag\":\"row\"}", |
| | | TAG_FIELD, |
| | | "{\"type\":\"input\",\"field\":\"remark\",\"title\":\"夿³¨\",\"value\":\"\"," |
| | | + "\"props\":{\"placeholder\":\"请è¾å
¥å¤æ³¨\"},\"_fc_id\":\"id_F4\"," |
| | | + "\"_fc_drag_tag\":\"input\",\"hidden\":false,\"display\":true}"); |
| | | } |
| | | |
| | | private static Map<String, Object> processVariables() { |
| | | Map<String, Object> processVariables = new HashMap<>(); |
| | | processVariables.put("reason", "äºå"); |
| | | processVariables.put("startTime", "2026-05-31 09:00:00"); |
| | | processVariables.put("days", 3); |
| | | processVariables.put("remark", "ä¸åå°å®¶"); |
| | | return processVariables; |
| | | } |
| | | |
| | | private static final String DIVIDER_FIELD = "{\"type\":\"elDivider\",\"children\":[\"åºç¡ä¿¡æ¯\"]," |
| | | + "\"props\":{\"contentPosition\":\"left\"},\"_fc_id\":\"id_DIVIDER\"," |
| | | + "\"_fc_drag_tag\":\"elDivider\"}"; |
| | | |
| | | private static final String TEXT_FIELD = "{\"type\":\"div\",\"children\":[\"请æå®é
æ
åµå¡«å\"]," |
| | | + "\"props\":{\"style\":{\"color\":\"#909399\"}},\"_fc_id\":\"id_TEXT\"," |
| | | + "\"_fc_drag_tag\":\"text\"}"; |
| | | |
| | | private static final String TAG_FIELD = "{\"type\":\"elTag\",\"children\":[\"éè¦\"]," |
| | | + "\"props\":{\"type\":\"warning\"},\"_fc_id\":\"id_TAG\",\"_fc_drag_tag\":\"elTag\"}"; |
| | | |
| | | } |
| | |
| | | .setCustomerId(business.getCustomerId()))); |
| | | } |
| | | |
| | | @GetMapping("/list-by-customer") |
| | | @Operation(summary = "è·å¾åæºå表ï¼åºäºæå®å®¢æ·") |
| | | @Parameter(name = "customerId", description = "客æ·ç¼å·", required = true) |
| | | @PreAuthorize("@ss.hasPermission('crm:business:query')") |
| | | public CommonResult<List<CrmBusinessRespVO>> getBusinessListByCustomer(@RequestParam("customerId") Long customerId) { |
| | | List<CrmBusinessDO> list = businessService.getBusinessListByCustomerId(customerId); |
| | | return success(convertList(list, business -> // åªè¿å idãname åæ®µ |
| | | new CrmBusinessRespVO().setId(business.getId()).setName(business.getName()) |
| | | .setCustomerId(business.getCustomerId()))); |
| | | } |
| | | |
| | | @GetMapping("/list-by-contact") |
| | | @Operation(summary = "è·å¾åæºå表ï¼åºäºæå®è系人") |
| | | @Parameter(name = "contactId", description = "è系人ç¼å·", required = true) |
| | | @PreAuthorize("@ss.hasPermission('crm:business:query')") |
| | | public CommonResult<List<CrmBusinessRespVO>> getBusinessListByContact(@RequestParam("contactId") Long contactId) { |
| | | List<CrmBusinessDO> list = businessService.getBusinessListByContact(contactId); |
| | | return success(buildBusinessDetailList(list)); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾åæºå页") |
| | | @PreAuthorize("@ss.hasPermission('crm:business:query')") |
| | |
| | | .setCustomerId(contact.getCustomerId()))); |
| | | } |
| | | |
| | | @GetMapping("/list-by-customer") |
| | | @Operation(summary = "è·å¾è系人å表ï¼åºäºæå®å®¢æ·") |
| | | @Parameter(name = "customerId", description = "客æ·ç¼å·", required = true) |
| | | @PreAuthorize("@ss.hasPermission('crm:contact:query')") |
| | | public CommonResult<List<CrmContactRespVO>> getContactListByCustomer(@RequestParam("customerId") Long customerId) { |
| | | List<CrmContactDO> list = contactService.getContactListByCustomerId(customerId); |
| | | return success(convertList(list, contact -> // åªè¿å idãname åæ®µ |
| | | new CrmContactRespVO().setId(contact.getId()).setName(contact.getName()) |
| | | .setCustomerId(contact.getCustomerId()))); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾è系人å页") |
| | | @PreAuthorize("@ss.hasPermission('crm:contact:query')") |
| | |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessDO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.contact.CrmContactDO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.followup.CrmFollowUpRecordDO; |
| | | import cn.iocoder.yudao.module.crm.enums.common.CrmBizTypeEnum; |
| | | import cn.iocoder.yudao.module.crm.enums.permission.CrmPermissionLevelEnum; |
| | | import cn.iocoder.yudao.module.crm.service.business.CrmBusinessService; |
| | | import cn.iocoder.yudao.module.crm.service.contact.CrmContactService; |
| | | import cn.iocoder.yudao.module.crm.service.followup.CrmFollowUpRecordService; |
| | | import cn.iocoder.yudao.module.crm.service.permission.CrmPermissionService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | |
| | | import java.util.ArrayList; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.CRM_PERMISSION_DENIED; |
| | | import static cn.iocoder.yudao.module.crm.enums.ErrorCodeConstants.FOLLOW_UP_RECORD_NOT_EXISTS; |
| | | |
| | | |
| | | @Tag(name = "管çåå° - è·è¿è®°å½") |
| | |
| | | private CrmContactService contactService; |
| | | @Resource |
| | | private CrmBusinessService businessService; |
| | | @Resource |
| | | private CrmPermissionService permissionService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | public CommonResult<CrmFollowUpRecordRespVO> getFollowUpRecord(@RequestParam("id") Long id) { |
| | | CrmFollowUpRecordDO followUpRecord = followUpRecordService.getFollowUpRecord(id); |
| | | if (followUpRecord == null) { |
| | | throw exception(FOLLOW_UP_RECORD_NOT_EXISTS); |
| | | } |
| | | if (!permissionService.hasPermission(followUpRecord.getBizType(), followUpRecord.getBizId(), |
| | | getLoginUserId(), CrmPermissionLevelEnum.READ)) { |
| | | throw exception(CRM_PERMISSION_DENIED, CrmBizTypeEnum.getNameByType(followUpRecord.getBizType())); |
| | | } |
| | | return success(BeanUtils.toBean(followUpRecord, CrmFollowUpRecordRespVO.class)); |
| | | } |
| | | |
| | |
| | | .eq(CrmBusinessDO::getOwnerUserId, ownerUserId)); |
| | | } |
| | | |
| | | default List<CrmBusinessDO> selectListByCustomerId(Long customerId) { |
| | | return selectList(CrmBusinessDO::getCustomerId, customerId); |
| | | } |
| | | |
| | | default PageResult<CrmBusinessDO> selectPage(CrmStatisticsFunnelReqVO pageVO) { |
| | | return selectPage(pageVO, new LambdaQueryWrapperX<CrmBusinessDO>() |
| | | .in(CrmBusinessDO::getOwnerUserId, pageVO.getUserIds()) |
| | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; |
| | | import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; |
| | | import cn.iocoder.yudao.framework.mybatis.core.util.MyBatisUtils; |
| | | import cn.iocoder.yudao.module.crm.controller.admin.customer.vo.limitconfig.CrmCustomerLimitConfigPageReqVO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.customer.CrmCustomerLimitConfigDO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | |
| | | LambdaQueryWrapperX<CrmCustomerLimitConfigDO> query = new LambdaQueryWrapperX<CrmCustomerLimitConfigDO>() |
| | | .eq(CrmCustomerLimitConfigDO::getType, type); |
| | | query.and(w -> { |
| | | w.apply("FIND_IN_SET({0}, user_ids) > 0", userId); |
| | | w.apply(MyBatisUtils.findInSet("user_ids"), userId); |
| | | if (deptId != null) { |
| | | w.or().apply("FIND_IN_SET({0}, dept_ids) > 0", deptId); |
| | | w.or().apply(MyBatisUtils.findInSet("dept_ids"), deptId); |
| | | } |
| | | }); |
| | | return selectList(query); |
| | |
| | | ErrorCode BUSINESS_DELETE_FAIL_CONTRACT_EXISTS = new ErrorCode(1_020_002_001, "åæºå·²å
³èååï¼ä¸è½å é¤"); |
| | | ErrorCode BUSINESS_UPDATE_STATUS_FAIL_END_STATUS = new ErrorCode(1_020_002_002, "æ´æ°åæºç¶æå¤±è´¥ï¼åå ï¼å·²ç»æ¯ç»æç¶æ"); |
| | | ErrorCode BUSINESS_UPDATE_STATUS_FAIL_STATUS_EQUALS = new ErrorCode(1_020_002_003, "æ´æ°åæºç¶æå¤±è´¥ï¼åå ï¼å·²ç»æ¯è¯¥ç¶æ"); |
| | | ErrorCode BUSINESS_CONTACT_CUSTOMER_NOT_MATCH = new ErrorCode(1_020_002_004, "åæºå
³èçè系人ä¸å±äºè¯¥å®¢æ·"); |
| | | |
| | | // ========== è系人管ç 1-020-003-000 ========== |
| | | ErrorCode CONTACT_NOT_EXISTS = new ErrorCode(1_020_003_000, "è系人ä¸åå¨"); |
| | |
| | | List<CrmBusinessDO> getBusinessListByCustomerIdOwnerUserId(Long customerId, Long ownerUserId); |
| | | |
| | | /** |
| | | * è·å¾åæºå表ï¼åºäºæå®å®¢æ· |
| | | * |
| | | * @param customerId 客æ·ç¼å· |
| | | * @return åæºå表 |
| | | */ |
| | | List<CrmBusinessDO> getBusinessListByCustomerId(Long customerId); |
| | | |
| | | /** |
| | | * è·å¾åæºå表ï¼åºäºæå®è系人 |
| | | * |
| | | * @param contactId è系人ç¼å· |
| | | * @return åæºå表 |
| | | */ |
| | | List<CrmBusinessDO> getBusinessListByContact(Long contactId); |
| | | |
| | | /** |
| | | * è·å¾åæºå页ï¼ç®åç¨äºãæ°æ®ç»è®¡ã |
| | | * |
| | | * @param pageVO è¯·æ± |
| | |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.collection.ListUtil; |
| | | import cn.hutool.core.util.ObjUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.number.MoneyUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessProductDO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.business.CrmBusinessStatusDO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.contact.CrmContactBusinessDO; |
| | | import cn.iocoder.yudao.module.crm.dal.dataobject.contact.CrmContactDO; |
| | | import cn.iocoder.yudao.module.crm.dal.mysql.business.CrmBusinessMapper; |
| | | import cn.iocoder.yudao.module.crm.dal.mysql.business.CrmBusinessProductMapper; |
| | | import cn.iocoder.yudao.module.crm.enums.common.CrmBizTypeEnum; |
| | |
| | | if (saveReqVO.getCustomerId() != null) { |
| | | customerService.validateCustomer(saveReqVO.getCustomerId()); |
| | | } |
| | | // æ ¡éªè系人 |
| | | // æ ¡éªè系人ï¼ä¸å¿
é¡»ä¸åæºå±äºåä¸å®¢æ·ï¼é¿å
跨客æ·å
³èï¼ |
| | | if (saveReqVO.getContactId() != null) { |
| | | contactService.validateContact(saveReqVO.getContactId()); |
| | | if (saveReqVO.getCustomerId() != null) { |
| | | CrmContactDO contact = contactService.getContact(saveReqVO.getContactId()); |
| | | if (ObjUtil.notEqual(saveReqVO.getCustomerId(), contact.getCustomerId())) { |
| | | throw exception(BUSINESS_CONTACT_CUSTOMER_NOT_MATCH); |
| | | } |
| | | } |
| | | } |
| | | // æ ¡éªè´è´£äºº |
| | | if (saveReqVO.getOwnerUserId() != null) { |
| | |
| | | } |
| | | |
| | | @Override |
| | | @CrmPermission(bizType = CrmBizTypeEnum.CRM_CUSTOMER, bizId = "#customerId", level = CrmPermissionLevelEnum.READ) |
| | | public List<CrmBusinessDO> getBusinessListByCustomerId(Long customerId) { |
| | | return businessMapper.selectListByCustomerId(customerId); |
| | | } |
| | | |
| | | @Override |
| | | @CrmPermission(bizType = CrmBizTypeEnum.CRM_CONTACT, bizId = "#contactId", level = CrmPermissionLevelEnum.READ) |
| | | public List<CrmBusinessDO> getBusinessListByContact(Long contactId) { |
| | | // 1. æ¥è¯¢å
³èçåæºç¼å· |
| | | List<CrmContactBusinessDO> contactBusinessList = contactBusinessService.getContactBusinessListByContactId(contactId); |
| | | if (CollUtil.isEmpty(contactBusinessList)) { |
| | | return ListUtil.empty(); |
| | | } |
| | | // 2. æ¥è¯¢åæºå表 |
| | | return businessMapper.selectByIds(convertSet(contactBusinessList, CrmContactBusinessDO::getBusinessId)); |
| | | } |
| | | |
| | | @Override |
| | | public PageResult<CrmBusinessDO> getBusinessPageByDate(CrmStatisticsFunnelReqVO pageVO) { |
| | | return businessMapper.selectPage(pageVO); |
| | | } |
| | |
| | | */ |
| | | List<CrmContactDO> getContactListByCustomerIdOwnerUserId(Long customerId, Long ownerUserId); |
| | | |
| | | /** |
| | | * è·å¾è系人å表ï¼åºäºæå®å®¢æ· |
| | | * |
| | | * @param customerId 客æ·ç¼å· |
| | | * @return è系人å表 |
| | | */ |
| | | List<CrmContactDO> getContactListByCustomerId(Long customerId); |
| | | |
| | | } |
| | |
| | | return contactMapper.selectListByCustomerIdOwnerUserId(customerId, ownerUserId); |
| | | } |
| | | |
| | | @Override |
| | | @CrmPermission(bizType = CrmBizTypeEnum.CRM_CUSTOMER, bizId = "#customerId", level = CrmPermissionLevelEnum.READ) |
| | | public List<CrmContactDO> getContactListByCustomerId(Long customerId) { |
| | | return contactMapper.selectListByCustomerId(customerId); |
| | | } |
| | | |
| | | } |
| | |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | |
| | | <!-- MDM ä¸»æ°æ®ç®¡ç模å API --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-module-mdm</artifactId> |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | |
| | | <!-- WMS ä»åºç®¡ç模å --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-module-wms</artifactId> |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | |
| | | <!-- BPM æµç¨æ¨¡å --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-module-bpm</artifactId> |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | |
| | | <!-- ä¸å¡ç»ä»¶ --> |
| | | |
| | | <!-- Web ç¸å
³ --> |
| | |
| | | @Schema(description = "产ååç±»ç¼å·", example = "11161") |
| | | private Long categoryId; |
| | | |
| | | @Schema(description = "产åç¶æ", example = "0") |
| | | private Integer status; |
| | | |
| | | @Schema(description = "å建æ¶é´") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - ERP éè´å
¥åº") |
| | | @RestController |
| | |
| | | public CommonResult<Boolean> updatePurchaseInStatus(@RequestParam("id") Long id, |
| | | @RequestParam("status") Integer status) { |
| | | purchaseInService.updatePurchaseInStatus(id, status); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/submit") |
| | | @Operation(summary = "æäº¤éè´å
¥åºå®¡æ¹") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('erp:purchase-in:update')") |
| | | public CommonResult<Boolean> submitPurchaseIn(@RequestParam("id") Long id) { |
| | | purchaseInService.submitPurchaseIn(id, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - ERP éè´è®¢å") |
| | | @RestController |
| | |
| | | public CommonResult<Boolean> updatePurchaseOrderStatus(@RequestParam("id") Long id, |
| | | @RequestParam("status") Integer status) { |
| | | purchaseOrderService.updatePurchaseOrderStatus(id, status); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/submit") |
| | | @Operation(summary = "æäº¤éè´è®¢å审æ¹") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('erp:purchase-order:update')") |
| | | public CommonResult<Boolean> submitPurchaseOrder(@RequestParam("id") Long id) { |
| | | purchaseOrderService.submitPurchaseOrder(id, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - ERP éå®è®¢å") |
| | | @RestController |
| | |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "å建éå®è®¢å") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:create')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:create')") |
| | | public CommonResult<Long> createSaleOrder(@Valid @RequestBody ErpSaleOrderSaveReqVO createReqVO) { |
| | | return success(saleOrderService.createSaleOrder(createReqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "æ´æ°éå®è®¢å") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:update')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:update')") |
| | | public CommonResult<Boolean> updateSaleOrder(@Valid @RequestBody ErpSaleOrderSaveReqVO updateReqVO) { |
| | | saleOrderService.updateSaleOrder(updateReqVO); |
| | | return success(true); |
| | |
| | | |
| | | @PutMapping("/update-status") |
| | | @Operation(summary = "æ´æ°éå®è®¢åçç¶æ") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:update-status')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:update-status')") |
| | | public CommonResult<Boolean> updateSaleOrderStatus(@RequestParam("id") Long id, |
| | | @RequestParam("status") Integer status) { |
| | | saleOrderService.updateSaleOrderStatus(id, status); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/submit") |
| | | @Operation(summary = "æäº¤éå®è®¢å审æ¹") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:update')") |
| | | public CommonResult<Boolean> submitSaleOrder(@RequestParam("id") Long id) { |
| | | saleOrderService.submitSaleOrder(id, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤éå®è®¢å") |
| | | @Parameter(name = "ids", description = "ç¼å·æ°ç»", required = true) |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:delete')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:delete')") |
| | | public CommonResult<Boolean> deleteSaleOrder(@RequestParam("ids") List<Long> ids) { |
| | | saleOrderService.deleteSaleOrder(ids); |
| | | return success(true); |
| | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾éå®è®¢å") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:query')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:query')") |
| | | public CommonResult<ErpSaleOrderRespVO> getSaleOrder(@RequestParam("id") Long id) { |
| | | ErpSaleOrderDO saleOrder = saleOrderService.getSaleOrder(id); |
| | | if (saleOrder == null) { |
| | |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾éå®è®¢åå页") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:query')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:query')") |
| | | public CommonResult<PageResult<ErpSaleOrderRespVO>> getSaleOrderPage(@Valid ErpSaleOrderPageReqVO pageReqVO) { |
| | | PageResult<ErpSaleOrderDO> pageResult = saleOrderService.getSaleOrderPage(pageReqVO); |
| | | return success(buildSaleOrderVOPageResult(pageResult)); |
| | |
| | | |
| | | @GetMapping("/export-excel") |
| | | @Operation(summary = "导åºéå®è®¢å Excel") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:export')") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-order:export')") |
| | | @ApiAccessLog(operateType = EXPORT) |
| | | public void exportSaleOrderExcel(@Valid ErpSaleOrderPageReqVO pageReqVO, |
| | | HttpServletResponse response) throws IOException { |
| | |
| | | }); |
| | | } |
| | | |
| | | } |
| | | } |
| | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - ERP éå®åºåº") |
| | | @RestController |
| | |
| | | public CommonResult<Boolean> updateSaleOutStatus(@RequestParam("id") Long id, |
| | | @RequestParam("status") Integer status) { |
| | | saleOutService.updateSaleOutStatus(id, status); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/submit") |
| | | @Operation(summary = "æäº¤éå®åºåºå®¡æ¹") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('erp:sale-out:update')") |
| | | public CommonResult<Boolean> submitSaleOut(@RequestParam("id") Long id) { |
| | | saleOutService.submitSaleOut(id, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | |
| | | */ |
| | | private String remark; |
| | | |
| | | // ========== BPM æµç¨å®¡æ¹ ========== |
| | | /** |
| | | * BPM æµç¨å®ä¾ç¼å· |
| | | */ |
| | | private String processInstanceId; |
| | | |
| | | } |
| | |
| | | */ |
| | | private String remark; |
| | | |
| | | // ========== BPM æµç¨å®¡æ¹ ========== |
| | | /** |
| | | * BPM æµç¨å®ä¾ç¼å· |
| | | */ |
| | | private String processInstanceId; |
| | | |
| | | // ========== éè´å
¥åº ========== |
| | | /** |
| | | * éè´å
¥åºæ°é |
| | |
| | | */ |
| | | private String remark; |
| | | |
| | | // ========== BPM æµç¨å®¡æ¹ ========== |
| | | /** |
| | | * BPM æµç¨å®ä¾ç¼å· |
| | | */ |
| | | private String processInstanceId; |
| | | |
| | | // ========== éå®åºåº ========== |
| | | /** |
| | | * éå®åºåºæ°é |
| | |
| | | */ |
| | | private String remark; |
| | | |
| | | // ========== BPM æµç¨å®¡æ¹ ========== |
| | | /** |
| | | * BPM æµç¨å®ä¾ç¼å· |
| | | */ |
| | | private String processInstanceId; |
| | | |
| | | } |
| | |
| | | @Getter |
| | | public enum ErpAuditStatus implements ArrayValuable<Integer> { |
| | | |
| | | DRAFT(0, "è稿"), // èç¨¿ç¶æï¼æªæäº¤å®¡æ¹ |
| | | PROCESS(10, "审æ¹ä¸"), // 审æ¹ä¸ |
| | | APPROVE(20, "审æ¹éè¿"), // 审æ¹éè¿ |
| | | REJECT(30, "审æ¹ä¸éè¿"); // 审æ¹ä¸éè¿ |
| | | PROCESS(10, "æªå®¡æ ¸"), // å®¡æ ¸ä¸ |
| | | APPROVE(20, "å·²å®¡æ ¸"); // å®¡æ ¸éè¿ |
| | | |
| | | public static final Integer[] ARRAYS = Arrays.stream(values()).map(ErpAuditStatus::getStatus).toArray(Integer[]::new); |
| | | |
| | |
| | | ErrorCode PURCHASE_ORDER_PROCESS_FAIL_EXISTS_IN = new ErrorCode(1_030_101_008, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºçéè´å
¥åºå"); |
| | | ErrorCode PURCHASE_ORDER_ITEM_RETURN_FAIL_IN_EXCEED = new ErrorCode(1_030_101_009, "éè´è®¢å项({})è¶
è¿æå¤§å
许éè´§æ°é({})"); |
| | | ErrorCode PURCHASE_ORDER_PROCESS_FAIL_EXISTS_RETURN = new ErrorCode(1_030_101_010, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºçéè´éè´§å"); |
| | | ErrorCode PURCHASE_ORDER_SUBMIT_FAIL_NOT_DRAFT = new ErrorCode(1_030_101_011, "æäº¤å®¡æ¹å¤±è´¥ï¼åªæèç¨¿ç¶æçéè´è®¢åæè½æäº¤å®¡æ¹"); |
| | | ErrorCode PURCHASE_ORDER_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS = new ErrorCode(1_030_101_012, "æ´æ°å®¡æ¹ç¶æå¤±è´¥ï¼åªæå®¡æ¹ä¸çéè´è®¢åæè½æ´æ°å®¡æ¹ç¶æ"); |
| | | |
| | | // ========== ERP éè´å
¥åºï¼1-030-102-000ï¼ ========== |
| | | ErrorCode PURCHASE_IN_NOT_EXISTS = new ErrorCode(1_030_102_000, "éè´å
¥åºåä¸åå¨"); |
| | |
| | | ErrorCode PURCHASE_IN_NOT_APPROVE = new ErrorCode(1_030_102_006, "éè´å
¥åºåæªå®¡æ ¸ï¼æ æ³æä½"); |
| | | ErrorCode PURCHASE_IN_FAIL_PAYMENT_PRICE_EXCEED = new ErrorCode(1_030_102_007, "仿¬¾éé¢({})è¶
è¿éè´å
¥åºåæ»éé¢({})"); |
| | | ErrorCode PURCHASE_IN_PROCESS_FAIL_EXISTS_PAYMENT = new ErrorCode(1_030_102_008, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºç仿¬¾å"); |
| | | ErrorCode PURCHASE_IN_SUBMIT_FAIL_NOT_DRAFT = new ErrorCode(1_030_102_009, "æäº¤å®¡æ¹å¤±è´¥ï¼åªæèç¨¿ç¶æçéè´å
¥åºåæè½æäº¤å®¡æ¹"); |
| | | ErrorCode PURCHASE_IN_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS = new ErrorCode(1_030_102_010, "æ´æ°å®¡æ¹ç¶æå¤±è´¥ï¼åªæå®¡æ¹ä¸çéè´å
¥åºåæè½æ´æ°å®¡æ¹ç¶æ"); |
| | | |
| | | // ========== ERP éè´éè´§ï¼1-030-103-000ï¼ ========== |
| | | ErrorCode PURCHASE_RETURN_NOT_EXISTS = new ErrorCode(1_030_103_000, "éè´éè´§åä¸åå¨"); |
| | |
| | | ErrorCode SALE_ORDER_PROCESS_FAIL_EXISTS_OUT = new ErrorCode(1_020_201_008, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºçéå®åºåºå"); |
| | | ErrorCode SALE_ORDER_ITEM_RETURN_FAIL_OUT_EXCEED = new ErrorCode(1_020_201_009, "éå®è®¢å项({})è¶
è¿æå¤§å
许éè´§æ°é({})"); |
| | | ErrorCode SALE_ORDER_PROCESS_FAIL_EXISTS_RETURN = new ErrorCode(1_020_201_010, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºçéå®éè´§å"); |
| | | ErrorCode SALE_ORDER_SUBMIT_FAIL_NOT_DRAFT = new ErrorCode(1_020_201_011, "æäº¤å®¡æ¹å¤±è´¥ï¼åªæèç¨¿ç¶æçéå®è®¢åæè½æäº¤å®¡æ¹"); |
| | | ErrorCode SALE_ORDER_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS = new ErrorCode(1_020_201_012, "æ´æ°å®¡æ¹ç¶æå¤±è´¥ï¼åªæå®¡æ¹ä¸çéå®è®¢åæè½æ´æ°å®¡æ¹ç¶æ"); |
| | | |
| | | // ========== ERP éå®åºåºï¼1-030-202-000ï¼ ========== |
| | | ErrorCode SALE_OUT_NOT_EXISTS = new ErrorCode(1_020_202_000, "éå®åºåºåä¸åå¨"); |
| | |
| | | ErrorCode SALE_OUT_NOT_APPROVE = new ErrorCode(1_020_202_006, "éå®åºåºåæªå®¡æ ¸ï¼æ æ³æä½"); |
| | | ErrorCode SALE_OUT_FAIL_RECEIPT_PRICE_EXCEED = new ErrorCode(1_020_202_007, "æ¶æ¬¾éé¢({})è¶
è¿éå®åºåºåæ»éé¢({})"); |
| | | ErrorCode SALE_OUT_PROCESS_FAIL_EXISTS_RECEIPT = new ErrorCode(1_020_202_008, "åå®¡æ ¸å¤±è´¥ï¼å·²åå¨å¯¹åºçæ¶æ¬¾å"); |
| | | ErrorCode SALE_OUT_SUBMIT_FAIL_NOT_DRAFT = new ErrorCode(1_020_202_009, "æäº¤å®¡æ¹å¤±è´¥ï¼åªæèç¨¿ç¶æçéå®åºåºåæè½æäº¤å®¡æ¹"); |
| | | ErrorCode SALE_OUT_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS = new ErrorCode(1_020_202_010, "æ´æ°å®¡æ¹ç¶æå¤±è´¥ï¼åªæå®¡æ¹ä¸çéå®åºåºåæè½æ´æ°å®¡æ¹ç¶æ"); |
| | | |
| | | // ========== ERP éå®éè´§ï¼1-030-203-000ï¼ ========== |
| | | ErrorCode SALE_RETURN_NOT_EXISTS = new ErrorCode(1_020_203_000, "éå®éè´§åä¸åå¨"); |
| | |
| | | // ========== ERP 产å 1-030-500-000 ========== |
| | | ErrorCode PRODUCT_NOT_EXISTS = new ErrorCode(1_030_500_000, "产åä¸åå¨"); |
| | | ErrorCode PRODUCT_NOT_ENABLE = new ErrorCode(1_030_500_001, "产å({})æªå¯ç¨"); |
| | | ErrorCode PRODUCT_BAR_CODE_EXISTS = new ErrorCode(1_030_500_002, "äº§åæ¡ç å·²åå¨"); |
| | | |
| | | // ========== ERP 产ååç±» 1-030-501-000 ========== |
| | | ErrorCode PRODUCT_CATEGORY_NOT_EXISTS = new ErrorCode(1_030_501_000, "产ååç±»ä¸åå¨"); |
| | |
| | | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ErpProductRespVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.product.vo.product.ProductSaveReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductCategoryDO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; |
| | | import cn.iocoder.yudao.module.mdm.api.item.MdmItemApi; |
| | | import cn.iocoder.yudao.module.mdm.api.item.dto.MdmItemCreateReqDTO; |
| | | import cn.iocoder.yudao.module.mdm.api.item.dto.MdmItemRespDTO; |
| | | import cn.iocoder.yudao.module.mdm.api.item.dto.MdmItemUpdateReqDTO; |
| | | import cn.iocoder.yudao.module.mdm.api.category.MdmItemCategoryApi; |
| | | import cn.iocoder.yudao.module.mdm.api.category.dto.MdmItemCategoryRespDTO; |
| | | import cn.iocoder.yudao.module.mdm.api.unit.MdmUnitMeasureApi; |
| | | import cn.iocoder.yudao.module.mdm.api.unit.dto.MdmUnitMeasureRespDTO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductUnitDO; |
| | | import cn.iocoder.yudao.module.erp.dal.mysql.product.ErpProductMapper; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.validation.annotation.Validated; |
| | |
| | | /** |
| | | * ERP 产å Service å®ç°ç±» |
| | | * |
| | | * æ¹é 说æï¼ERP äº§åæ°æ®æ¥æºäº MDM ç©æä¸»æ°æ® |
| | | * - ææäº§åæä½åè°ç¨ MDM API |
| | | * - ERP 产åå¯¹åº MDM ç©æç±»å = æåï¼itemType = 2ï¼ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Service |
| | | @Validated |
| | | public class ErpProductServiceImpl implements ErpProductService { |
| | | |
| | | /** ERP 产å对åºç MDM ç©æç±»åï¼æå */ |
| | | private static final int MDM_ITEM_TYPE_PRODUCT = 2; |
| | | @Resource |
| | | private ErpProductMapper productMapper; |
| | | |
| | | @Resource |
| | | private MdmItemApi mdmItemApi; |
| | | |
| | | private ErpProductCategoryService productCategoryService; |
| | | @Resource |
| | | private MdmItemCategoryApi mdmItemCategoryApi; |
| | | |
| | | @Resource |
| | | private MdmUnitMeasureApi mdmUnitMeasureApi; |
| | | private ErpProductUnitService productUnitService; |
| | | |
| | | @Override |
| | | public Long createProduct(ProductSaveReqVO createReqVO) { |
| | | // 1. æ ¡éªæ¡ç å¯ä¸ |
| | | validateProductBarCodeUnique(null, createReqVO.getBarCode()); |
| | | |
| | | // 2. æå»ºå建请æ±å¹¶è°ç¨ MDM API |
| | | MdmItemCreateReqDTO createReqDTO = buildCreateReqDTO(createReqVO); |
| | | return mdmItemApi.createItem(createReqDTO).getCheckedData(); |
| | | // TODO èè¿ï¼æ ¡éªåç±» |
| | | // æå
¥ |
| | | ErpProductDO product = BeanUtils.toBean(createReqVO, ErpProductDO.class); |
| | | productMapper.insert(product); |
| | | // è¿å |
| | | return product.getId(); |
| | | } |
| | | |
| | | @Override |
| | | public void updateProduct(ProductSaveReqVO updateReqVO) { |
| | | // 1. æ ¡éªåå¨ |
| | | // TODO èè¿ï¼æ ¡éªåç±» |
| | | // æ ¡éªåå¨ |
| | | validateProductExists(updateReqVO.getId()); |
| | | |
| | | // 2. æ ¡éªæ¡ç å¯ä¸ |
| | | validateProductBarCodeUnique(updateReqVO.getId(), updateReqVO.getBarCode()); |
| | | |
| | | // 3. æå»ºæ´æ°è¯·æ±å¹¶è°ç¨ MDM API |
| | | MdmItemUpdateReqDTO updateReqDTO = buildUpdateReqDTO(updateReqVO); |
| | | mdmItemApi.updateItem(updateReqDTO); |
| | | // æ´æ° |
| | | ErpProductDO updateObj = BeanUtils.toBean(updateReqVO, ErpProductDO.class); |
| | | productMapper.updateById(updateObj); |
| | | } |
| | | |
| | | @Override |
| | | public void deleteProduct(Long id) { |
| | | // æ ¡éªåå¨ |
| | | validateProductExists(id); |
| | | // ERP 产åå é¤å®é
为ç¦ç¨ï¼MDM ç©æä¸è½ç©çå é¤ï¼ |
| | | mdmItemApi.updateItemStatus(id, CommonStatusEnum.DISABLE.getStatus()); |
| | | // å é¤ |
| | | productMapper.deleteById(id); |
| | | } |
| | | |
| | | @Override |
| | |
| | | if (CollUtil.isEmpty(ids)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | |
| | | // 1. è°ç¨ MDM API è·åç©æå表 |
| | | List<MdmItemRespDTO> itemList = mdmItemApi.getItemList(ids).getCheckedData(); |
| | | Map<Long, MdmItemRespDTO> itemMap = convertMap(itemList, MdmItemRespDTO::getId); |
| | | |
| | | // 2. æ ¡éªæ¯ä¸ªäº§å |
| | | List<ErpProductDO> list = productMapper.selectByIds(ids); |
| | | Map<Long, ErpProductDO> productMap = convertMap(list, ErpProductDO::getId); |
| | | for (Long id : ids) { |
| | | MdmItemRespDTO item = itemMap.get(id); |
| | | if (item == null) { |
| | | ErpProductDO product = productMap.get(id); |
| | | if (productMap.get(id) == null) { |
| | | throw exception(PRODUCT_NOT_EXISTS); |
| | | } |
| | | if (CommonStatusEnum.isDisable(item.getStatus())) { |
| | | throw exception(PRODUCT_NOT_ENABLE, item.getName()); |
| | | if (CommonStatusEnum.isDisable(product.getStatus())) { |
| | | throw exception(PRODUCT_NOT_ENABLE, product.getName()); |
| | | } |
| | | } |
| | | return list; |
| | | } |
| | | |
| | | // 3. 转æ¢ä¸º ERP Product DOï¼æå¨æ å°åæ®µï¼ |
| | | return convertToErpProductDOList(itemList); |
| | | private void validateProductExists(Long id) { |
| | | if (productMapper.selectById(id) == null) { |
| | | throw exception(PRODUCT_NOT_EXISTS); |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public ErpProductDO getProduct(Long id) { |
| | | MdmItemRespDTO item = mdmItemApi.getItem(id).getCheckedData(); |
| | | return convertToErpProductDO(item); |
| | | return productMapper.selectById(id); |
| | | } |
| | | |
| | | @Override |
| | | public List<ErpProductRespVO> getProductVOListByStatus(Integer status) { |
| | | List<MdmItemRespDTO> itemList = mdmItemApi.getItemListByStatus(status).getCheckedData(); |
| | | return buildProductVOList(itemList); |
| | | List<ErpProductDO> list = productMapper.selectListByStatus(status); |
| | | return buildProductVOList(list); |
| | | } |
| | | |
| | | @Override |
| | |
| | | if (CollUtil.isEmpty(ids)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | List<MdmItemRespDTO> itemList = mdmItemApi.getItemList(ids).getCheckedData(); |
| | | return buildProductVOList(itemList); |
| | | List<ErpProductDO> list = productMapper.selectByIds(ids); |
| | | return buildProductVOList(list); |
| | | } |
| | | |
| | | @Override |
| | | public PageResult<ErpProductRespVO> getProductVOPage(ErpProductPageReqVO pageReqVO) { |
| | | // è°ç¨ MDM API å页æ¥è¯¢ |
| | | PageResult<MdmItemRespDTO> mdmPageResult = mdmItemApi.getItemPage( |
| | | MDM_ITEM_TYPE_PRODUCT, |
| | | pageReqVO.getStatus(), |
| | | pageReqVO.getPageNo(), |
| | | pageReqVO.getPageSize() |
| | | ).getCheckedData(); |
| | | PageResult<ErpProductDO> pageResult = productMapper.selectPage(pageReqVO); |
| | | return new PageResult<>(buildProductVOList(pageResult.getList()), pageResult.getTotal()); |
| | | } |
| | | |
| | | List<ErpProductRespVO> productVOList = buildProductVOList(mdmPageResult.getList()); |
| | | return new PageResult<>(productVOList, mdmPageResult.getTotal()); |
| | | private List<ErpProductRespVO> buildProductVOList(List<ErpProductDO> list) { |
| | | if (CollUtil.isEmpty(list)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | Map<Long, ErpProductCategoryDO> categoryMap = productCategoryService.getProductCategoryMap( |
| | | convertSet(list, ErpProductDO::getCategoryId)); |
| | | Map<Long, ErpProductUnitDO> unitMap = productUnitService.getProductUnitMap( |
| | | convertSet(list, ErpProductDO::getUnitId)); |
| | | return BeanUtils.toBean(list, ErpProductRespVO.class, product -> { |
| | | MapUtils.findAndThen(categoryMap, product.getCategoryId(), |
| | | category -> product.setCategoryName(category.getName())); |
| | | MapUtils.findAndThen(unitMap, product.getUnitId(), |
| | | unit -> product.setUnitName(unit.getName())); |
| | | }); |
| | | } |
| | | |
| | | @Override |
| | | public Long getProductCountByCategoryId(Long categoryId) { |
| | | return mdmItemApi.getItemCountByCategoryId(categoryId).getCheckedData(); |
| | | return productMapper.selectCountByCategoryId(categoryId); |
| | | } |
| | | |
| | | @Override |
| | | public Long getProductCountByUnitId(Long unitId) { |
| | | return mdmItemApi.getItemCountByUnitMeasureId(unitId).getCheckedData(); |
| | | return productMapper.selectCountByUnitId(unitId); |
| | | } |
| | | |
| | | // ==================== ç§ææ¹æ³ ==================== |
| | | |
| | | /** |
| | | * æ ¡éªäº§ååå¨ |
| | | */ |
| | | private void validateProductExists(Long id) { |
| | | mdmItemApi.validateItemExists(id).getCheckedData(); |
| | | } |
| | | |
| | | /** |
| | | * æ ¡éªäº§åæ¡ç å¯ä¸ |
| | | */ |
| | | private void validateProductBarCodeUnique(Long id, String barCode) { |
| | | if (barCode == null) { |
| | | return; |
| | | } |
| | | MdmItemRespDTO existItem = mdmItemApi.getItemByBarCode(barCode).getCheckedData(); |
| | | if (existItem != null && !existItem.getId().equals(id)) { |
| | | throw exception(PRODUCT_BAR_CODE_EXISTS); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æå»ºåå»ºè¯·æ± DTO |
| | | * 注æï¼ProductSaveReqVO ä½¿ç¨ standard åæ®µä½ä¸ºè§æ ¼ï¼MDM ä½¿ç¨ specification |
| | | */ |
| | | private MdmItemCreateReqDTO buildCreateReqDTO(ProductSaveReqVO saveReqVO) { |
| | | MdmItemCreateReqDTO createReqDTO = new MdmItemCreateReqDTO(); |
| | | createReqDTO.setCode(saveReqVO.getBarCode()); // ä½¿ç¨æ¡ç ä½ä¸ºç¼ç |
| | | createReqDTO.setName(saveReqVO.getName()); |
| | | createReqDTO.setBarCode(saveReqVO.getBarCode()); |
| | | createReqDTO.setSpecification(saveReqVO.getStandard()); // standard -> specification |
| | | createReqDTO.setCategoryId(saveReqVO.getCategoryId()); |
| | | createReqDTO.setUnitMeasureId(saveReqVO.getUnitId()); // unitId -> unitMeasureId |
| | | createReqDTO.setItemType(MDM_ITEM_TYPE_PRODUCT); |
| | | createReqDTO.setStatus(saveReqVO.getStatus() != null ? saveReqVO.getStatus() : CommonStatusEnum.ENABLE.getStatus()); |
| | | createReqDTO.setPurchasePrice(saveReqVO.getPurchasePrice()); |
| | | createReqDTO.setSalesPrice(saveReqVO.getSalePrice()); |
| | | createReqDTO.setCostPrice(saveReqVO.getMinPrice()); // minPrice -> costPrice |
| | | createReqDTO.setExpiryDay(saveReqVO.getExpiryDay()); |
| | | createReqDTO.setWeight(saveReqVO.getWeight()); |
| | | createReqDTO.setRemark(saveReqVO.getRemark()); |
| | | return createReqDTO; |
| | | } |
| | | |
| | | /** |
| | | * æå»ºæ´æ°è¯·æ± DTO |
| | | */ |
| | | private MdmItemUpdateReqDTO buildUpdateReqDTO(ProductSaveReqVO saveReqVO) { |
| | | MdmItemUpdateReqDTO updateReqDTO = new MdmItemUpdateReqDTO(); |
| | | updateReqDTO.setId(saveReqVO.getId()); |
| | | updateReqDTO.setCode(saveReqVO.getBarCode()); |
| | | updateReqDTO.setName(saveReqVO.getName()); |
| | | updateReqDTO.setBarCode(saveReqVO.getBarCode()); |
| | | updateReqDTO.setSpecification(saveReqVO.getStandard()); // standard -> specification |
| | | updateReqDTO.setCategoryId(saveReqVO.getCategoryId()); |
| | | updateReqDTO.setUnitMeasureId(saveReqVO.getUnitId()); // unitId -> unitMeasureId |
| | | updateReqDTO.setStatus(saveReqVO.getStatus()); |
| | | updateReqDTO.setPurchasePrice(saveReqVO.getPurchasePrice()); |
| | | updateReqDTO.setSalesPrice(saveReqVO.getSalePrice()); |
| | | updateReqDTO.setCostPrice(saveReqVO.getMinPrice()); |
| | | updateReqDTO.setExpiryDay(saveReqVO.getExpiryDay()); |
| | | updateReqDTO.setWeight(saveReqVO.getWeight()); |
| | | updateReqDTO.setRemark(saveReqVO.getRemark()); |
| | | return updateReqDTO; |
| | | } |
| | | |
| | | /** |
| | | * æå»ºäº§å VO å表ï¼å
å«åç±»ååä½åç§°ï¼ |
| | | * 注æï¼MDM å ERP åæ®µåæå·®å¼ï¼éè¦æå¨æ å° |
| | | */ |
| | | private List<ErpProductRespVO> buildProductVOList(List<MdmItemRespDTO> itemList) { |
| | | if (CollUtil.isEmpty(itemList)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | |
| | | // 1. è·ååç±»ååä½ä¿¡æ¯ |
| | | Set<Long> categoryIds = convertSet(itemList, MdmItemRespDTO::getCategoryId); |
| | | Set<Long> unitIds = convertSet(itemList, MdmItemRespDTO::getUnitMeasureId); |
| | | |
| | | Map<Long, MdmItemCategoryRespDTO> categoryMap = CollUtil.isEmpty(categoryIds) |
| | | ? Collections.emptyMap() |
| | | : convertMap(mdmItemCategoryApi.getItemCategoryList(categoryIds).getCheckedData(), MdmItemCategoryRespDTO::getId); |
| | | |
| | | Map<Long, MdmUnitMeasureRespDTO> unitMap = CollUtil.isEmpty(unitIds) |
| | | ? Collections.emptyMap() |
| | | : convertMap(mdmUnitMeasureApi.getUnitMeasureList(unitIds).getCheckedData(), MdmUnitMeasureRespDTO::getId); |
| | | |
| | | // 2. æå¨è½¬æ¢å¹¶å¡«å
å
³èä¿¡æ¯ï¼å¤çåæ®µåå·®å¼ï¼ |
| | | List<ErpProductRespVO> result = new ArrayList<>(); |
| | | for (MdmItemRespDTO mdmItem : itemList) { |
| | | ErpProductRespVO product = new ErpProductRespVO(); |
| | | product.setId(mdmItem.getId()); |
| | | product.setName(mdmItem.getName()); |
| | | product.setBarCode(mdmItem.getBarCode()); |
| | | product.setStandard(mdmItem.getSpecification()); // specification -> standard |
| | | product.setCategoryId(mdmItem.getCategoryId()); |
| | | product.setUnitId(mdmItem.getUnitMeasureId()); // unitMeasureId -> unitId |
| | | product.setStatus(mdmItem.getStatus()); |
| | | product.setPurchasePrice(mdmItem.getPurchasePrice()); |
| | | product.setSalePrice(mdmItem.getSalesPrice()); // salesPrice -> salePrice |
| | | product.setMinPrice(mdmItem.getCostPrice()); // costPrice -> minPrice |
| | | product.setExpiryDay(mdmItem.getExpiryDay()); |
| | | product.setWeight(mdmItem.getWeight()); |
| | | product.setRemark(mdmItem.getRemark()); |
| | | |
| | | // 设置åç±»ååä½åç§° |
| | | MapUtils.findAndThen(categoryMap, mdmItem.getCategoryId(), |
| | | category -> product.setCategoryName(category.getName())); |
| | | MapUtils.findAndThen(unitMap, mdmItem.getUnitMeasureId(), |
| | | unit -> product.setUnitName(unit.getName())); |
| | | |
| | | result.add(product); |
| | | } |
| | | return result; |
| | | } |
| | | |
| | | /** |
| | | * è½¬æ¢ MDM ç©æä¸º ERP 产å DO |
| | | * 注æï¼å段åå·®å¼éè¦æå¨æ å° |
| | | */ |
| | | private ErpProductDO convertToErpProductDO(MdmItemRespDTO mdmItem) { |
| | | if (mdmItem == null) { |
| | | return null; |
| | | } |
| | | ErpProductDO product = new ErpProductDO(); |
| | | product.setId(mdmItem.getId()); |
| | | product.setName(mdmItem.getName()); |
| | | product.setBarCode(mdmItem.getBarCode()); |
| | | product.setStandard(mdmItem.getSpecification()); // specification -> standard |
| | | product.setCategoryId(mdmItem.getCategoryId()); |
| | | product.setUnitId(mdmItem.getUnitMeasureId()); // unitMeasureId -> unitId |
| | | product.setStatus(mdmItem.getStatus()); |
| | | product.setPurchasePrice(mdmItem.getPurchasePrice()); |
| | | product.setSalePrice(mdmItem.getSalesPrice()); // salesPrice -> salePrice |
| | | product.setMinPrice(mdmItem.getCostPrice()); // costPrice -> minPrice |
| | | product.setExpiryDay(mdmItem.getExpiryDay()); |
| | | product.setWeight(mdmItem.getWeight()); |
| | | product.setRemark(mdmItem.getRemark()); |
| | | return product; |
| | | } |
| | | |
| | | /** |
| | | * æ¹éè½¬æ¢ MDM ç©æå表为 ERP 产åå表 |
| | | */ |
| | | private List<ErpProductDO> convertToErpProductDOList(List<MdmItemRespDTO> mdmItemList) { |
| | | if (CollUtil.isEmpty(mdmItemList)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | List<ErpProductDO> result = new ArrayList<>(); |
| | | for (MdmItemRespDTO mdmItem : mdmItemList) { |
| | | result.add(convertToErpProductDO(mdmItem)); |
| | | } |
| | | return result; |
| | | } |
| | | |
| | | } |
| | | } |
| | |
| | | void updatePurchaseInStatus(Long id, Integer status); |
| | | |
| | | /** |
| | | * æäº¤éè´å
¥åºå®¡æ¹ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param userId ç¨æ·ç¼å· |
| | | */ |
| | | void submitPurchaseIn(Long id, Long userId); |
| | | |
| | | /** |
| | | * æ´æ°éè´å
¥åºç审æ¹ç¶æ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | */ |
| | | void updatePurchaseInAuditStatus(Long id, Integer bpmResult); |
| | | |
| | | /** |
| | | * æ´æ°éè´å
¥åºç仿¬¾éé¢ |
| | | * |
| | | * @param id ç¼å· |
| | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.number.MoneyUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.bpm.api.task.BpmProcessInstanceApi; |
| | | import cn.iocoder.yudao.module.bpm.api.task.dto.BpmProcessInstanceCreateReqDTO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.in.ErpPurchaseInSaveReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; |
| | |
| | | import cn.iocoder.yudao.module.erp.service.stock.bo.ErpStockRecordCreateReqBO; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import jakarta.annotation.Resource; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.context.annotation.Lazy; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.*; |
| | | |
| | | // TODO èè¿ï¼è®°å½æä½æ¥å¿ |
| | | |
| | | /** |
| | | * ERP éè´å
¥åº Service å®ç°ç±» |
| | | * |
| | |
| | | */ |
| | | @Service |
| | | @Validated |
| | | @Slf4j |
| | | public class ErpPurchaseInServiceImpl implements ErpPurchaseInService { |
| | | |
| | | /** |
| | | * BPM éè´å
¥åºå®¡æ¹æµç¨æ è¯ |
| | | */ |
| | | public static final String BPM_PROCESS_DEFINITION_KEY = "erp-purchase-in-audit"; |
| | | |
| | | @Resource |
| | | private ErpPurchaseInMapper purchaseInMapper; |
| | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @Resource |
| | | private BpmProcessInstanceApi bpmProcessInstanceApi; |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public Long createPurchaseIn(ErpPurchaseInSaveReqVO createReqVO) { |
| | |
| | | |
| | | // 2.1 æå
¥å
¥åº |
| | | ErpPurchaseInDO purchaseIn = BeanUtils.toBean(createReqVO, ErpPurchaseInDO.class, in -> in |
| | | .setNo(no).setStatus(ErpAuditStatus.DRAFT.getStatus())) |
| | | .setNo(no).setStatus(ErpAuditStatus.PROCESS.getStatus())) |
| | | .setOrderNo(purchaseOrder.getNo()).setSupplierId(purchaseOrder.getSupplierId()); |
| | | calculateTotalPrice(purchaseIn, purchaseInItems); |
| | | purchaseInMapper.insert(purchaseIn); |
| | |
| | | : ErpStockRecordBizTypeEnum.PURCHASE_IN_CANCEL.getType(); |
| | | purchaseInItems.forEach(purchaseInItem -> { |
| | | BigDecimal count = approve ? purchaseInItem.getCount() : purchaseInItem.getCount().negate(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(purchaseInItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(purchaseInItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(purchaseInItem.getInId()); |
| | | stockRecordBO.setBizItemId(purchaseInItem.getId()); |
| | | stockRecordBO.setBizNo(purchaseIn.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | purchaseInItem.getProductId(), purchaseInItem.getWarehouseId(), count, |
| | | bizType, purchaseInItem.getInId(), purchaseInItem.getId(), purchaseIn.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | return Collections.emptyList(); |
| | | } |
| | | return purchaseInItemMapper.selectListByInIds(inIds); |
| | | } |
| | | |
| | | // ==================== BPM æµç¨å®¡æ¹ ==================== |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void submitPurchaseIn(Long id, Long userId) { |
| | | // 1. æ ¡éªéè´å
¥åºå¤äºèç¨¿ç¶æ |
| | | ErpPurchaseInDO purchaseIn = validatePurchaseInExists(id); |
| | | if (ObjectUtil.notEqual(purchaseIn.getStatus(), ErpAuditStatus.DRAFT.getStatus())) { |
| | | throw exception(PURCHASE_IN_SUBMIT_FAIL_NOT_DRAFT); |
| | | } |
| | | |
| | | // 2. å建éè´å
¥åºå®¡æ¹æµç¨å®ä¾ |
| | | String processInstanceId = bpmProcessInstanceApi.createProcessInstance(userId, new BpmProcessInstanceCreateReqDTO() |
| | | .setProcessDefinitionKey(BPM_PROCESS_DEFINITION_KEY) |
| | | .setBusinessKey(String.valueOf(id))); |
| | | |
| | | // 3. æ´æ°éè´å
¥åºå·¥ä½æµç¼å·ãç¶æ |
| | | purchaseInMapper.updateById(new ErpPurchaseInDO() |
| | | .setId(id) |
| | | .setProcessInstanceId(processInstanceId) |
| | | .setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | } |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void updatePurchaseInAuditStatus(Long id, Integer bpmResult) { |
| | | // 1. æ ¡éªéè´å
¥åºåå¨ |
| | | ErpPurchaseInDO purchaseIn = validatePurchaseInExists(id); |
| | | |
| | | // 2. æ ¡éªéè´å
¥åºå¤äºå®¡æ¹ä¸ |
| | | if (ObjectUtil.notEqual(purchaseIn.getStatus(), ErpAuditStatus.PROCESS.getStatus())) { |
| | | log.error("[updatePurchaseInAuditStatus][purchaseIn({}) ä¸å¤äºå®¡æ¹ä¸ï¼æ æ³æ´æ°å®¡æ¹ç»æ({})]", |
| | | purchaseIn.getId(), bpmResult); |
| | | throw exception(PURCHASE_IN_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS); |
| | | } |
| | | |
| | | // 3. æ´æ°éè´å
¥åºå®¡æ¹ç»æ |
| | | Integer auditStatus = convertBpmResultToAuditStatus(bpmResult); |
| | | purchaseInMapper.updateById(new ErpPurchaseInDO() |
| | | .setId(id) |
| | | .setStatus(auditStatus)); |
| | | |
| | | // 4. 审æ¹éè¿æ¶åæ´åºå |
| | | if (ErpAuditStatus.APPROVE.getStatus().equals(auditStatus)) { |
| | | List<ErpPurchaseInItemDO> purchaseInItems = purchaseInItemMapper.selectListByInId(id); |
| | | purchaseInItems.forEach(purchaseInItem -> { |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(purchaseInItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(purchaseInItem.getWarehouseId()); |
| | | stockRecordBO.setCount(purchaseInItem.getCount()); |
| | | stockRecordBO.setBizType(ErpStockRecordBizTypeEnum.PURCHASE_IN.getType()); |
| | | stockRecordBO.setBizId(purchaseInItem.getInId()); |
| | | stockRecordBO.setBizItemId(purchaseInItem.getId()); |
| | | stockRecordBO.setBizNo(purchaseIn.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | }); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * å° BPM 审æ¹ç»æè½¬æ¢ä¸º ERP 审æ¹ç¶æ |
| | | * |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | * @return ERP 审æ¹ç¶æ |
| | | */ |
| | | private Integer convertBpmResultToAuditStatus(Integer bpmResult) { |
| | | // BPM 审æ¹ç»æï¼2=éè¿ï¼3=ä¸éè¿ï¼4=已忶 |
| | | if (bpmResult == 2) { |
| | | return ErpAuditStatus.APPROVE.getStatus(); |
| | | } else if (bpmResult == 3) { |
| | | return ErpAuditStatus.REJECT.getStatus(); |
| | | } else if (bpmResult == 4) { |
| | | return ErpAuditStatus.DRAFT.getStatus(); |
| | | } else { |
| | | log.warn("[convertBpmResultToAuditStatus][æªç¥ç BPM 审æ¹ç»æ({})]", bpmResult); |
| | | return ErpAuditStatus.PROCESS.getStatus(); |
| | | } |
| | | } |
| | | |
| | | } |
| | |
| | | void updatePurchaseOrderStatus(Long id, Integer status); |
| | | |
| | | /** |
| | | * æäº¤éè´è®¢åå®¡æ¹ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param userId ç¨æ·ç¼å· |
| | | */ |
| | | void submitPurchaseOrder(Long id, Long userId); |
| | | |
| | | /** |
| | | * æ´æ°éè´è®¢åç审æ¹ç¶æ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | */ |
| | | void updatePurchaseOrderAuditStatus(Long id, Integer bpmResult); |
| | | |
| | | /** |
| | | * æ´æ°éè´è®¢åçå
¥åºæ°é |
| | | * |
| | | * @param id ç¼å· |
| | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.number.MoneyUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.bpm.api.task.BpmProcessInstanceApi; |
| | | import cn.iocoder.yudao.module.bpm.api.task.dto.BpmProcessInstanceCreateReqDTO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.purchase.vo.order.ErpPurchaseOrderSaveReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; |
| | |
| | | import cn.iocoder.yudao.module.erp.service.finance.ErpAccountService; |
| | | import cn.iocoder.yudao.module.erp.service.product.ErpProductService; |
| | | import jakarta.annotation.Resource; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.validation.annotation.Validated; |
| | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.*; |
| | | |
| | | // TODO èè¿ï¼è®°å½æä½æ¥å¿ |
| | | |
| | | /** |
| | | * ERP éè´è®¢å Service å®ç°ç±» |
| | | * |
| | |
| | | */ |
| | | @Service |
| | | @Validated |
| | | @Slf4j |
| | | public class ErpPurchaseOrderServiceImpl implements ErpPurchaseOrderService { |
| | | |
| | | /** |
| | | * BPM éè´è®¢åå®¡æ¹æµç¨æ è¯ |
| | | */ |
| | | public static final String BPM_PROCESS_DEFINITION_KEY = "erp-purchase-order-audit"; |
| | | |
| | | @Resource |
| | | private ErpPurchaseOrderMapper purchaseOrderMapper; |
| | |
| | | private ErpSupplierService supplierService; |
| | | @Resource |
| | | private ErpAccountService accountService; |
| | | |
| | | @Resource |
| | | private BpmProcessInstanceApi bpmProcessInstanceApi; |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | |
| | | |
| | | // 2.1 æå
¥è®¢å |
| | | ErpPurchaseOrderDO purchaseOrder = BeanUtils.toBean(createReqVO, ErpPurchaseOrderDO.class, in -> in |
| | | .setNo(no).setStatus(ErpAuditStatus.DRAFT.getStatus())); |
| | | .setNo(no).setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | calculateTotalPrice(purchaseOrder, purchaseOrderItems); |
| | | purchaseOrderMapper.insert(purchaseOrder); |
| | | // 2.2 æå
¥è®¢å项 |
| | |
| | | return Collections.emptyList(); |
| | | } |
| | | return purchaseOrderItemMapper.selectListByOrderIds(orderIds); |
| | | } |
| | | |
| | | // ==================== BPM æµç¨å®¡æ¹ ==================== |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void submitPurchaseOrder(Long id, Long userId) { |
| | | // 1. æ ¡éªéè´è®¢åå¤äºèç¨¿ç¶æ |
| | | ErpPurchaseOrderDO purchaseOrder = validatePurchaseOrderExists(id); |
| | | if (ObjectUtil.notEqual(purchaseOrder.getStatus(), ErpAuditStatus.DRAFT.getStatus())) { |
| | | throw exception(PURCHASE_ORDER_SUBMIT_FAIL_NOT_DRAFT); |
| | | } |
| | | |
| | | // 2. å建éè´è®¢åå®¡æ¹æµç¨å®ä¾ |
| | | String processInstanceId = bpmProcessInstanceApi.createProcessInstance(userId, new BpmProcessInstanceCreateReqDTO() |
| | | .setProcessDefinitionKey(BPM_PROCESS_DEFINITION_KEY) |
| | | .setBusinessKey(String.valueOf(id))); |
| | | |
| | | // 3. æ´æ°éè´è®¢å工使µç¼å·ãç¶æ |
| | | purchaseOrderMapper.updateById(new ErpPurchaseOrderDO() |
| | | .setId(id) |
| | | .setProcessInstanceId(processInstanceId) |
| | | .setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | } |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void updatePurchaseOrderAuditStatus(Long id, Integer bpmResult) { |
| | | // 1. æ ¡éªéè´è®¢ååå¨ |
| | | ErpPurchaseOrderDO purchaseOrder = validatePurchaseOrderExists(id); |
| | | |
| | | // 2. æ ¡éªéè´è®¢åå¤äºå®¡æ¹ä¸ |
| | | if (ObjectUtil.notEqual(purchaseOrder.getStatus(), ErpAuditStatus.PROCESS.getStatus())) { |
| | | log.error("[updatePurchaseOrderAuditStatus][purchaseOrder({}) ä¸å¤äºå®¡æ¹ä¸ï¼æ æ³æ´æ°å®¡æ¹ç»æ({})]", |
| | | purchaseOrder.getId(), bpmResult); |
| | | throw exception(PURCHASE_ORDER_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS); |
| | | } |
| | | |
| | | // 3. æ´æ°éè´è®¢å审æ¹ç»æ |
| | | Integer auditStatus = convertBpmResultToAuditStatus(bpmResult); |
| | | purchaseOrderMapper.updateById(new ErpPurchaseOrderDO() |
| | | .setId(id) |
| | | .setStatus(auditStatus)); |
| | | } |
| | | |
| | | /** |
| | | * å° BPM 审æ¹ç»æè½¬æ¢ä¸º ERP 审æ¹ç¶æ |
| | | * |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | * @return ERP 审æ¹ç¶æ |
| | | */ |
| | | private Integer convertBpmResultToAuditStatus(Integer bpmResult) { |
| | | // BPM 审æ¹ç»æï¼2=éè¿ï¼3=ä¸éè¿ï¼4=已忶 |
| | | if (bpmResult == 2) { |
| | | return ErpAuditStatus.APPROVE.getStatus(); |
| | | } else if (bpmResult == 3) { |
| | | return ErpAuditStatus.REJECT.getStatus(); |
| | | } else if (bpmResult == 4) { |
| | | return ErpAuditStatus.DRAFT.getStatus(); |
| | | } else { |
| | | log.warn("[convertBpmResultToAuditStatus][æªç¥ç BPM 审æ¹ç»æ({})]", bpmResult); |
| | | return ErpAuditStatus.PROCESS.getStatus(); |
| | | } |
| | | } |
| | | |
| | | } |
| | |
| | | : ErpStockRecordBizTypeEnum.PURCHASE_RETURN_CANCEL.getType(); |
| | | purchaseReturnItems.forEach(purchaseReturnItem -> { |
| | | BigDecimal count = approve ? purchaseReturnItem.getCount().negate() : purchaseReturnItem.getCount(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(purchaseReturnItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(purchaseReturnItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(purchaseReturnItem.getReturnId()); |
| | | stockRecordBO.setBizItemId(purchaseReturnItem.getId()); |
| | | stockRecordBO.setBizNo(purchaseReturn.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | purchaseReturnItem.getProductId(), purchaseReturnItem.getWarehouseId(), count, |
| | | bizType, purchaseReturnItem.getReturnId(), purchaseReturnItem.getId(), purchaseReturn.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | void updateSaleOrderStatus(Long id, Integer status); |
| | | |
| | | /** |
| | | * æäº¤éå®è®¢åå®¡æ¹ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param userId ç¨æ·ç¼å· |
| | | */ |
| | | void submitSaleOrder(Long id, Long userId); |
| | | |
| | | /** |
| | | * æ´æ°éå®è®¢åç审æ¹ç¶æ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | */ |
| | | void updateSaleOrderAuditStatus(Long id, Integer bpmResult); |
| | | |
| | | /** |
| | | * æ´æ°éå®è®¢åçåºåºæ°é |
| | | * |
| | | * @param id ç¼å· |
| | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.number.MoneyUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.bpm.api.task.BpmProcessInstanceApi; |
| | | import cn.iocoder.yudao.module.bpm.api.task.dto.BpmProcessInstanceCreateReqDTO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.order.ErpSaleOrderSaveReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; |
| | |
| | | import cn.iocoder.yudao.module.erp.service.product.ErpProductService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import jakarta.annotation.Resource; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.validation.annotation.Validated; |
| | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.*; |
| | | |
| | | // TODO èè¿ï¼è®°å½æä½æ¥å¿ |
| | | |
| | | /** |
| | | * ERP éå®è®¢å Service å®ç°ç±» |
| | | * |
| | |
| | | */ |
| | | @Service |
| | | @Validated |
| | | @Slf4j |
| | | public class ErpSaleOrderServiceImpl implements ErpSaleOrderService { |
| | | |
| | | /** |
| | | * BPM éå®è®¢åå®¡æ¹æµç¨æ è¯ |
| | | */ |
| | | public static final String BPM_PROCESS_DEFINITION_KEY = "erp-sale-order-audit"; |
| | | |
| | | @Resource |
| | | private ErpSaleOrderMapper saleOrderMapper; |
| | |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @Resource |
| | | private BpmProcessInstanceApi bpmProcessInstanceApi; |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | |
| | | |
| | | // 2.1 æå
¥è®¢å |
| | | ErpSaleOrderDO saleOrder = BeanUtils.toBean(createReqVO, ErpSaleOrderDO.class, in -> in |
| | | .setNo(no).setStatus(ErpAuditStatus.DRAFT.getStatus())); |
| | | .setNo(no).setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | calculateTotalPrice(saleOrder, saleOrderItems); |
| | | saleOrderMapper.insert(saleOrder); |
| | | // 2.2 æå
¥è®¢å项 |
| | |
| | | return Collections.emptyList(); |
| | | } |
| | | return saleOrderItemMapper.selectListByOrderIds(orderIds); |
| | | } |
| | | |
| | | // ==================== BPM æµç¨å®¡æ¹ ==================== |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void submitSaleOrder(Long id, Long userId) { |
| | | // 1. æ ¡éªéå®è®¢åå¤äºèç¨¿ç¶æ |
| | | ErpSaleOrderDO saleOrder = validateSaleOrderExists(id); |
| | | if (ObjectUtil.notEqual(saleOrder.getStatus(), ErpAuditStatus.DRAFT.getStatus())) { |
| | | throw exception(SALE_ORDER_SUBMIT_FAIL_NOT_DRAFT); |
| | | } |
| | | |
| | | // 2. å建éå®è®¢åå®¡æ¹æµç¨å®ä¾ |
| | | String processInstanceId = bpmProcessInstanceApi.createProcessInstance(userId, new BpmProcessInstanceCreateReqDTO() |
| | | .setProcessDefinitionKey(BPM_PROCESS_DEFINITION_KEY) |
| | | .setBusinessKey(String.valueOf(id))); |
| | | |
| | | // 3. æ´æ°éå®è®¢å工使µç¼å·ãç¶æ |
| | | saleOrderMapper.updateById(new ErpSaleOrderDO() |
| | | .setId(id) |
| | | .setProcessInstanceId(processInstanceId) |
| | | .setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | } |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void updateSaleOrderAuditStatus(Long id, Integer bpmResult) { |
| | | // 1. æ ¡éªéå®è®¢ååå¨ |
| | | ErpSaleOrderDO saleOrder = validateSaleOrderExists(id); |
| | | |
| | | // 2. æ ¡éªéå®è®¢åå¤äºå®¡æ¹ä¸ |
| | | if (ObjectUtil.notEqual(saleOrder.getStatus(), ErpAuditStatus.PROCESS.getStatus())) { |
| | | log.error("[updateSaleOrderAuditStatus][saleOrder({}) ä¸å¤äºå®¡æ¹ä¸ï¼æ æ³æ´æ°å®¡æ¹ç»æ({})]", |
| | | saleOrder.getId(), bpmResult); |
| | | throw exception(SALE_ORDER_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS); |
| | | } |
| | | |
| | | // 3. æ´æ°éå®è®¢å审æ¹ç»æ |
| | | Integer auditStatus = convertBpmResultToAuditStatus(bpmResult); |
| | | saleOrderMapper.updateById(new ErpSaleOrderDO() |
| | | .setId(id) |
| | | .setStatus(auditStatus)); |
| | | } |
| | | |
| | | /** |
| | | * å° BPM 审æ¹ç»æè½¬æ¢ä¸º ERP 审æ¹ç¶æ |
| | | * |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | * @return ERP 审æ¹ç¶æ |
| | | */ |
| | | private Integer convertBpmResultToAuditStatus(Integer bpmResult) { |
| | | // BPM 审æ¹ç»æï¼2=éè¿ï¼3=ä¸éè¿ï¼4=已忶 |
| | | if (bpmResult == 2) { |
| | | return ErpAuditStatus.APPROVE.getStatus(); |
| | | } else if (bpmResult == 3) { |
| | | return ErpAuditStatus.REJECT.getStatus(); |
| | | } else if (bpmResult == 4) { |
| | | return ErpAuditStatus.DRAFT.getStatus(); |
| | | } else { |
| | | log.warn("[convertBpmResultToAuditStatus][æªç¥ç BPM 审æ¹ç»æ({})]", bpmResult); |
| | | return ErpAuditStatus.PROCESS.getStatus(); |
| | | } |
| | | } |
| | | |
| | | } |
| | |
| | | void updateSaleOutStatus(Long id, Integer status); |
| | | |
| | | /** |
| | | * æäº¤éå®åºåºå®¡æ¹ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param userId ç¨æ·ç¼å· |
| | | */ |
| | | void submitSaleOut(Long id, Long userId); |
| | | |
| | | /** |
| | | * æ´æ°éå®åºåºç审æ¹ç¶æ |
| | | * |
| | | * @param id ç¼å· |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | */ |
| | | void updateSaleOutAuditStatus(Long id, Integer bpmResult); |
| | | |
| | | /** |
| | | * æ´æ°éå®åºåºçæ¶æ¬¾éé¢ |
| | | * |
| | | * @param id ç¼å· |
| | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.number.MoneyUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.bpm.api.task.BpmProcessInstanceApi; |
| | | import cn.iocoder.yudao.module.bpm.api.task.dto.BpmProcessInstanceCreateReqDTO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.sale.vo.out.ErpSaleOutSaveReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.product.ErpProductDO; |
| | |
| | | import cn.iocoder.yudao.module.erp.service.stock.bo.ErpStockRecordCreateReqBO; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import jakarta.annotation.Resource; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.context.annotation.Lazy; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.*; |
| | | |
| | | // TODO èè¿ï¼è®°å½æä½æ¥å¿ |
| | | |
| | | /** |
| | | * ERP éå®åºåº Service å®ç°ç±» |
| | | * |
| | |
| | | */ |
| | | @Service |
| | | @Validated |
| | | @Slf4j |
| | | public class ErpSaleOutServiceImpl implements ErpSaleOutService { |
| | | |
| | | /** |
| | | * BPM éå®åºåºå®¡æ¹æµç¨æ è¯ |
| | | */ |
| | | public static final String BPM_PROCESS_DEFINITION_KEY = "erp-sale-out-audit"; |
| | | |
| | | @Resource |
| | | private ErpSaleOutMapper saleOutMapper; |
| | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @Resource |
| | | private BpmProcessInstanceApi bpmProcessInstanceApi; |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public Long createSaleOut(ErpSaleOutSaveReqVO createReqVO) { |
| | |
| | | |
| | | // 2.1 æå
¥åºåº |
| | | ErpSaleOutDO saleOut = BeanUtils.toBean(createReqVO, ErpSaleOutDO.class, in -> in |
| | | .setNo(no).setStatus(ErpAuditStatus.DRAFT.getStatus())) |
| | | .setNo(no).setStatus(ErpAuditStatus.PROCESS.getStatus())) |
| | | .setOrderNo(saleOrder.getNo()).setCustomerId(saleOrder.getCustomerId()); |
| | | calculateTotalPrice(saleOut, saleOutItems); |
| | | saleOutMapper.insert(saleOut); |
| | |
| | | : ErpStockRecordBizTypeEnum.SALE_OUT_CANCEL.getType(); |
| | | saleOutItems.forEach(saleOutItem -> { |
| | | BigDecimal count = approve ? saleOutItem.getCount().negate() : saleOutItem.getCount(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(saleOutItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(saleOutItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(saleOutItem.getOutId()); |
| | | stockRecordBO.setBizItemId(saleOutItem.getId()); |
| | | stockRecordBO.setBizNo(saleOut.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | saleOutItem.getProductId(), saleOutItem.getWarehouseId(), count, |
| | | bizType, saleOutItem.getOutId(), saleOutItem.getId(), saleOut.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | return Collections.emptyList(); |
| | | } |
| | | return saleOutItemMapper.selectListByOutIds(outIds); |
| | | } |
| | | |
| | | // ==================== BPM æµç¨å®¡æ¹ ==================== |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void submitSaleOut(Long id, Long userId) { |
| | | // 1. æ ¡éªéå®åºåºå¤äºèç¨¿ç¶æ |
| | | ErpSaleOutDO saleOut = validateSaleOutExists(id); |
| | | if (ObjectUtil.notEqual(saleOut.getStatus(), ErpAuditStatus.DRAFT.getStatus())) { |
| | | throw exception(SALE_OUT_SUBMIT_FAIL_NOT_DRAFT); |
| | | } |
| | | |
| | | // 2. å建éå®åºåºå®¡æ¹æµç¨å®ä¾ |
| | | String processInstanceId = bpmProcessInstanceApi.createProcessInstance(userId, new BpmProcessInstanceCreateReqDTO() |
| | | .setProcessDefinitionKey(BPM_PROCESS_DEFINITION_KEY) |
| | | .setBusinessKey(String.valueOf(id))); |
| | | |
| | | // 3. æ´æ°éå®åºåºå·¥ä½æµç¼å·ãç¶æ |
| | | saleOutMapper.updateById(new ErpSaleOutDO() |
| | | .setId(id) |
| | | .setProcessInstanceId(processInstanceId) |
| | | .setStatus(ErpAuditStatus.PROCESS.getStatus())); |
| | | } |
| | | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void updateSaleOutAuditStatus(Long id, Integer bpmResult) { |
| | | // 1. æ ¡éªéå®åºåºåå¨ |
| | | ErpSaleOutDO saleOut = validateSaleOutExists(id); |
| | | |
| | | // 2. æ ¡éªéå®åºåºå¤äºå®¡æ¹ä¸ |
| | | if (ObjectUtil.notEqual(saleOut.getStatus(), ErpAuditStatus.PROCESS.getStatus())) { |
| | | log.error("[updateSaleOutAuditStatus][saleOut({}) ä¸å¤äºå®¡æ¹ä¸ï¼æ æ³æ´æ°å®¡æ¹ç»æ({})]", |
| | | saleOut.getId(), bpmResult); |
| | | throw exception(SALE_OUT_UPDATE_AUDIT_STATUS_FAIL_NOT_PROCESS); |
| | | } |
| | | |
| | | // 3. æ´æ°éå®åºåºå®¡æ¹ç»æ |
| | | Integer auditStatus = convertBpmResultToAuditStatus(bpmResult); |
| | | saleOutMapper.updateById(new ErpSaleOutDO() |
| | | .setId(id) |
| | | .setStatus(auditStatus)); |
| | | |
| | | // 4. 审æ¹éè¿æ¶åæ´åºåï¼åå°åºåï¼ |
| | | if (ErpAuditStatus.APPROVE.getStatus().equals(auditStatus)) { |
| | | List<ErpSaleOutItemDO> saleOutItems = saleOutItemMapper.selectListByOutId(id); |
| | | saleOutItems.forEach(saleOutItem -> { |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(saleOutItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(saleOutItem.getWarehouseId()); |
| | | stockRecordBO.setCount(saleOutItem.getCount().negate()); |
| | | stockRecordBO.setBizType(ErpStockRecordBizTypeEnum.SALE_OUT.getType()); |
| | | stockRecordBO.setBizId(saleOutItem.getOutId()); |
| | | stockRecordBO.setBizItemId(saleOutItem.getId()); |
| | | stockRecordBO.setBizNo(saleOut.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | }); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * å° BPM 审æ¹ç»æè½¬æ¢ä¸º ERP 审æ¹ç¶æ |
| | | * |
| | | * @param bpmResult BPM 审æ¹ç»æ |
| | | * @return ERP 审æ¹ç¶æ |
| | | */ |
| | | private Integer convertBpmResultToAuditStatus(Integer bpmResult) { |
| | | // BPM 审æ¹ç»æï¼2=éè¿ï¼3=ä¸éè¿ï¼4=已忶 |
| | | if (bpmResult == 2) { |
| | | return ErpAuditStatus.APPROVE.getStatus(); |
| | | } else if (bpmResult == 3) { |
| | | return ErpAuditStatus.REJECT.getStatus(); |
| | | } else if (bpmResult == 4) { |
| | | return ErpAuditStatus.DRAFT.getStatus(); |
| | | } else { |
| | | log.warn("[convertBpmResultToAuditStatus][æªç¥ç BPM 审æ¹ç»æ({})]", bpmResult); |
| | | return ErpAuditStatus.PROCESS.getStatus(); |
| | | } |
| | | } |
| | | |
| | | } |
| | |
| | | : ErpStockRecordBizTypeEnum.SALE_RETURN_CANCEL.getType(); |
| | | saleReturnItems.forEach(saleReturnItem -> { |
| | | BigDecimal count = approve ? saleReturnItem.getCount() : saleReturnItem.getCount().negate(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(saleReturnItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(saleReturnItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(saleReturnItem.getReturnId()); |
| | | stockRecordBO.setBizItemId(saleReturnItem.getId()); |
| | | stockRecordBO.setBizNo(saleReturn.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | saleReturnItem.getProductId(), saleReturnItem.getWarehouseId(), count, |
| | | bizType, saleReturnItem.getReturnId(), saleReturnItem.getId(), saleReturn.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | bizType = count.compareTo(BigDecimal.ZERO) > 0 ? ErpStockRecordBizTypeEnum.CHECK_MORE_IN_CANCEL.getType() |
| | | : ErpStockRecordBizTypeEnum.CHECK_LESS_OUT_CANCEL.getType(); |
| | | } |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(stockCheckItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(stockCheckItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(stockCheckItem.getCheckId()); |
| | | stockRecordBO.setBizItemId(stockCheckItem.getId()); |
| | | stockRecordBO.setBizNo(stockCheck.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | stockCheckItem.getProductId(), stockCheckItem.getWarehouseId(), count, |
| | | bizType, stockCheckItem.getCheckId(), stockCheckItem.getId(), stockCheck.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | : ErpStockRecordBizTypeEnum.OTHER_IN_CANCEL.getType(); |
| | | stockInItems.forEach(stockInItem -> { |
| | | BigDecimal count = approve ? stockInItem.getCount() : stockInItem.getCount().negate(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(stockInItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(stockInItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(stockInItem.getInId()); |
| | | stockRecordBO.setBizItemId(stockInItem.getId()); |
| | | stockRecordBO.setBizNo(stockIn.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | stockInItem.getProductId(), stockInItem.getWarehouseId(), count, |
| | | bizType, stockInItem.getInId(), stockInItem.getId(), stockIn.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | stockMoveItems.forEach(stockMoveItem -> { |
| | | BigDecimal fromCount = approve ? stockMoveItem.getCount().negate() : stockMoveItem.getCount(); |
| | | BigDecimal toCount = approve ? stockMoveItem.getCount() : stockMoveItem.getCount().negate(); |
| | | ErpStockRecordCreateReqBO fromStockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | fromStockRecordBO.setProductId(stockMoveItem.getProductId()); |
| | | fromStockRecordBO.setWarehouseId(stockMoveItem.getFromWarehouseId()); |
| | | fromStockRecordBO.setCount(fromCount); |
| | | fromStockRecordBO.setBizType(fromBizType); |
| | | fromStockRecordBO.setBizId(stockMoveItem.getMoveId()); |
| | | fromStockRecordBO.setBizItemId(stockMoveItem.getId()); |
| | | fromStockRecordBO.setBizNo(stockMove.getNo()); |
| | | stockRecordService.createStockRecord(fromStockRecordBO); |
| | | ErpStockRecordCreateReqBO toStockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | toStockRecordBO.setProductId(stockMoveItem.getProductId()); |
| | | toStockRecordBO.setWarehouseId(stockMoveItem.getToWarehouseId()); |
| | | toStockRecordBO.setCount(toCount); |
| | | toStockRecordBO.setBizType(toBizType); |
| | | toStockRecordBO.setBizId(stockMoveItem.getMoveId()); |
| | | toStockRecordBO.setBizItemId(stockMoveItem.getId()); |
| | | toStockRecordBO.setBizNo(stockMove.getNo()); |
| | | stockRecordService.createStockRecord(toStockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | stockMoveItem.getProductId(), stockMoveItem.getFromWarehouseId(), fromCount, |
| | | fromBizType, stockMoveItem.getMoveId(), stockMoveItem.getId(), stockMove.getNo())); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | stockMoveItem.getProductId(), stockMoveItem.getToWarehouseId(), toCount, |
| | | toBizType, stockMoveItem.getMoveId(), stockMoveItem.getId(), stockMove.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | : ErpStockRecordBizTypeEnum.OTHER_OUT_CANCEL.getType(); |
| | | stockOutItems.forEach(stockOutItem -> { |
| | | BigDecimal count = approve ? stockOutItem.getCount().negate() : stockOutItem.getCount(); |
| | | ErpStockRecordCreateReqBO stockRecordBO = new ErpStockRecordCreateReqBO(); |
| | | stockRecordBO.setProductId(stockOutItem.getProductId()); |
| | | stockRecordBO.setWarehouseId(stockOutItem.getWarehouseId()); |
| | | stockRecordBO.setCount(count); |
| | | stockRecordBO.setBizType(bizType); |
| | | stockRecordBO.setBizId(stockOutItem.getOutId()); |
| | | stockRecordBO.setBizItemId(stockOutItem.getId()); |
| | | stockRecordBO.setBizNo(stockOut.getNo()); |
| | | stockRecordService.createStockRecord(stockRecordBO); |
| | | stockRecordService.createStockRecord(new ErpStockRecordCreateReqBO( |
| | | stockOutItem.getProductId(), stockOutItem.getWarehouseId(), count, |
| | | bizType, stockOutItem.getOutId(), stockOutItem.getId(), stockOut.getNo())); |
| | | }); |
| | | } |
| | | |
| | |
| | | package cn.iocoder.yudao.module.erp.service.stock; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.record.ErpStockRecordPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockRecordDO; |
| | | import cn.iocoder.yudao.module.erp.dal.mysql.stock.ErpStockRecordMapper; |
| | | import cn.iocoder.yudao.module.erp.service.stock.bo.ErpStockRecordCreateReqBO; |
| | | import cn.iocoder.yudao.module.mdm.api.item.MdmItemSkuApi; |
| | | import cn.iocoder.yudao.module.mdm.api.item.dto.MdmItemSkuRespDTO; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.WmsInventoryApi; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.dto.WmsReceiptReqDTO; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.dto.WmsShipmentReqDTO; |
| | | import cn.iocoder.yudao.module.wms.enums.inventory.WmsInventoryBizTypeEnum; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.validation.annotation.Validated; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * ERP 产ååºåæç» Service å®ç°ç±» |
| | | * |
| | | * æ¹é 说æï¼åºååæ´è°ç¨ WMS åºå API |
| | | * - å
¥åºæä½è°ç¨ WmsInventoryApi.receipt() |
| | | * - åºåºæä½è°ç¨ WmsInventoryApi.shipment() |
| | | * - productId å¯¹åº MDM itemIdï¼éè¿ SKU API è·åé»è®¤ SKU |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | |
| | | |
| | | @Resource |
| | | private ErpStockService stockService; |
| | | |
| | | @Resource |
| | | private WmsInventoryApi wmsInventoryApi; |
| | | |
| | | @Resource |
| | | private MdmItemSkuApi mdmItemSkuApi; |
| | | |
| | | @Override |
| | | public ErpStockRecordDO getStockRecord(Long id) { |
| | |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void createStockRecord(ErpStockRecordCreateReqBO createReqBO) { |
| | | // 1. è·å产åçé»è®¤ SKU IDï¼ERP productId = MDM itemIdï¼ |
| | | Long skuId = getDefaultSkuId(createReqBO.getProductId()); |
| | | if (skuId == null) { |
| | | // å¦ææ²¡æ SKUï¼ä½¿ç¨åæé»è¾æ´æ°åºå |
| | | BigDecimal totalCount = stockService.updateStockCountIncrement( |
| | | createReqBO.getProductId(), createReqBO.getWarehouseId(), createReqBO.getCount()); |
| | | ErpStockRecordDO stockRecord = BeanUtils.toBean(createReqBO, ErpStockRecordDO.class) |
| | | .setTotalCount(totalCount); |
| | | stockRecordMapper.insert(stockRecord); |
| | | return; |
| | | } |
| | | |
| | | // 2. æ ¹æ® count æ£è´å¤æå
¥åºè¿æ¯åºåº |
| | | BigDecimal count = createReqBO.getCount(); |
| | | if (count.compareTo(BigDecimal.ZERO) > 0) { |
| | | // å
¥åºæä½ |
| | | WmsReceiptReqDTO receiptReq = buildReceiptReqDTO(createReqBO, skuId); |
| | | wmsInventoryApi.receipt(receiptReq); |
| | | } else if (count.compareTo(BigDecimal.ZERO) < 0) { |
| | | // åºåºæä½ï¼æ°éè½¬ä¸ºæ£æ°ï¼ |
| | | WmsShipmentReqDTO shipmentReq = buildShipmentReqDTO(createReqBO, skuId); |
| | | wmsInventoryApi.shipment(shipmentReq); |
| | | } |
| | | |
| | | // 3. å建åºåæç»ï¼è®°å½æä½ï¼ |
| | | BigDecimal currentStock = wmsInventoryApi.getAvailableQuantity(skuId, createReqBO.getWarehouseId()).getCheckedData(); |
| | | // 1. æ´æ°åºå |
| | | BigDecimal totalCount = stockService.updateStockCountIncrement( |
| | | createReqBO.getProductId(), createReqBO.getWarehouseId(), createReqBO.getCount()); |
| | | // 2. å建åºåæç» |
| | | ErpStockRecordDO stockRecord = BeanUtils.toBean(createReqBO, ErpStockRecordDO.class) |
| | | .setTotalCount(currentStock != null ? currentStock : BigDecimal.ZERO); |
| | | .setTotalCount(totalCount); |
| | | stockRecordMapper.insert(stockRecord); |
| | | } |
| | | |
| | | /** |
| | | * è·å产åçé»è®¤ SKU ID |
| | | */ |
| | | private Long getDefaultSkuId(Long productId) { |
| | | if (productId == null) { |
| | | return null; |
| | | } |
| | | List<MdmItemSkuRespDTO> skuList = mdmItemSkuApi.getItemSkuListByItemId(productId).getCheckedData(); |
| | | if (CollUtil.isEmpty(skuList)) { |
| | | return null; |
| | | } |
| | | return skuList.get(0).getId(); |
| | | } |
| | | |
| | | /** |
| | | * æå»ºå
¥åºè¯·æ± |
| | | */ |
| | | private WmsReceiptReqDTO buildReceiptReqDTO(ErpStockRecordCreateReqBO createReqBO, Long skuId) { |
| | | WmsReceiptReqDTO receiptReq = new WmsReceiptReqDTO(); |
| | | receiptReq.setBizType(convertBizType(createReqBO.getBizType())); |
| | | receiptReq.setBizId(createReqBO.getBizId()); |
| | | receiptReq.setBizNo(createReqBO.getBizNo()); |
| | | receiptReq.setWarehouseId(createReqBO.getWarehouseId()); |
| | | receiptReq.setRemark(createReqBO.getRemark()); |
| | | |
| | | WmsReceiptReqDTO.Item item = new WmsReceiptReqDTO.Item(); |
| | | item.setSkuId(skuId); |
| | | item.setQuantity(createReqBO.getCount()); |
| | | receiptReq.setItems(List.of(item)); |
| | | return receiptReq; |
| | | } |
| | | |
| | | /** |
| | | * æå»ºåºåºè¯·æ± |
| | | */ |
| | | private WmsShipmentReqDTO buildShipmentReqDTO(ErpStockRecordCreateReqBO createReqBO, Long skuId) { |
| | | WmsShipmentReqDTO shipmentReq = new WmsShipmentReqDTO(); |
| | | shipmentReq.setBizType(convertBizType(createReqBO.getBizType())); |
| | | shipmentReq.setBizId(createReqBO.getBizId()); |
| | | shipmentReq.setBizNo(createReqBO.getBizNo()); |
| | | shipmentReq.setWarehouseId(createReqBO.getWarehouseId()); |
| | | shipmentReq.setRemark(createReqBO.getRemark()); |
| | | |
| | | WmsShipmentReqDTO.Item item = new WmsShipmentReqDTO.Item(); |
| | | item.setSkuId(skuId); |
| | | item.setQuantity(createReqBO.getCount().negate()); // åºåºæ°éä¸ºæ£æ° |
| | | shipmentReq.setItems(List.of(item)); |
| | | return shipmentReq; |
| | | } |
| | | |
| | | /** |
| | | * 转æ¢ä¸å¡ç±»åï¼ERP ä¸å¡ç±»åæ å°å° WMS ä¸å¡ç±»åï¼ |
| | | */ |
| | | private Integer convertBizType(Integer erpBizType) { |
| | | // ERP ä¸å¡ç±»åæ å°å° WMS ä¸å¡ç±»å |
| | | // å¯ä»¥æ ¹æ®å®é
ä¸å¡éæ±æ©å±æ å°å
³ç³» |
| | | if (erpBizType == null) { |
| | | return WmsInventoryBizTypeEnum.OTHER.getType(); |
| | | } |
| | | // é»è®¤è¿å OTHER ç±»åï¼åç»å¯æ ¹æ® ERP ä¸å¡ç±»åæä¸¾æ©å± |
| | | return WmsInventoryBizTypeEnum.OTHER.getType(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.erp.service.stock; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.module.erp.controller.admin.stock.vo.stock.ErpStockPageReqVO; |
| | | import cn.iocoder.yudao.module.erp.dal.dataobject.stock.ErpStockDO; |
| | | import cn.iocoder.yudao.module.erp.dal.mysql.stock.ErpStockMapper; |
| | | import cn.iocoder.yudao.module.erp.service.product.ErpProductService; |
| | | import cn.iocoder.yudao.module.erp.service.stock.ErpWarehouseService; |
| | | import cn.iocoder.yudao.module.mdm.api.item.MdmItemSkuApi; |
| | | import cn.iocoder.yudao.module.mdm.api.item.dto.MdmItemSkuRespDTO; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.WmsInventoryApi; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.dto.WmsInventoryQueryReqDTO; |
| | | import cn.iocoder.yudao.module.wms.api.inventory.dto.WmsInventoryRespDTO; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.validation.annotation.Validated; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.*; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.STOCK_COUNT_NEGATIVE; |
| | | import static cn.iocoder.yudao.module.erp.enums.ErrorCodeConstants.STOCK_COUNT_NEGATIVE2; |
| | | |
| | | /** |
| | | * ERP 产ååºå Service å®ç°ç±» |
| | | * |
| | | * æ¹é 说æï¼ERP åºåè°ç¨ WMS åºå API |
| | | * - productId å¯¹åº MDM itemId |
| | | * - éè¿ MDM SKU API è·åç©æçé»è®¤ SKU |
| | | * - åºåæä½è°ç¨ WMS Inventory API |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | |
| | | |
| | | /** |
| | | * å
许åºåä¸ºè´æ° |
| | | * |
| | | * TODO èè¿ï¼åç»åæ db é
ç½® |
| | | */ |
| | | private static final Boolean NEGATIVE_STOCK_COUNT_ENABLE = false; |
| | | |
| | | @Resource |
| | | private ErpProductService productService; |
| | | |
| | | @Resource |
| | | private ErpWarehouseService warehouseService; |
| | | |
| | | @Resource |
| | | private ErpStockMapper stockMapper; |
| | | |
| | | @Resource |
| | | private WmsInventoryApi wmsInventoryApi; |
| | | |
| | | @Resource |
| | | private MdmItemSkuApi mdmItemSkuApi; |
| | | |
| | | @Override |
| | | public ErpStockDO getStock(Long id) { |
| | |
| | | |
| | | @Override |
| | | public ErpStockDO getStock(Long productId, Long warehouseId) { |
| | | // éè¿ MDM è·å产åçé»è®¤ SKUï¼ç¶åæ¥è¯¢ WMS åºå |
| | | Long skuId = getDefaultSkuId(productId); |
| | | if (skuId == null) { |
| | | return null; |
| | | } |
| | | |
| | | // æ¥è¯¢ WMS åºå |
| | | BigDecimal quantity = wmsInventoryApi.getAvailableQuantity(skuId, warehouseId).getCheckedData(); |
| | | if (quantity == null || quantity.compareTo(BigDecimal.ZERO) == 0) { |
| | | return null; |
| | | } |
| | | |
| | | // 转æ¢ä¸º ERP Stock DO |
| | | ErpStockDO stock = new ErpStockDO(); |
| | | stock.setProductId(productId); |
| | | stock.setWarehouseId(warehouseId); |
| | | stock.setCount(quantity); |
| | | return stock; |
| | | return stockMapper.selectByProductIdAndWarehouseId(productId, warehouseId); |
| | | } |
| | | |
| | | @Override |
| | | public BigDecimal getStockCount(Long productId) { |
| | | // éè¿ MDM è·å产åçé»è®¤ SKUï¼ç¶åæ¥è¯¢ WMS åºåæ»é |
| | | Long skuId = getDefaultSkuId(productId); |
| | | if (skuId == null) { |
| | | return BigDecimal.ZERO; |
| | | } |
| | | |
| | | // æ¥è¯¢è¯¥ SKU 卿æä»åºçåºå |
| | | WmsInventoryQueryReqDTO queryReq = new WmsInventoryQueryReqDTO(); |
| | | queryReq.setSkuIds(List.of(skuId)); |
| | | queryReq.setOnlyPositive(true); |
| | | |
| | | List<WmsInventoryRespDTO> inventories = wmsInventoryApi.getInventoryList(queryReq).getCheckedData(); |
| | | if (CollUtil.isEmpty(inventories)) { |
| | | return BigDecimal.ZERO; |
| | | } |
| | | |
| | | return inventories.stream() |
| | | .map(WmsInventoryRespDTO::getQuantity) |
| | | .filter(q -> q != null) |
| | | .reduce(BigDecimal.ZERO, BigDecimal::add); |
| | | BigDecimal count = stockMapper.selectSumByProductId(productId); |
| | | return count != null ? count : BigDecimal.ZERO; |
| | | } |
| | | |
| | | @Override |
| | | public PageResult<ErpStockDO> getStockPage(ErpStockPageReqVO pageReqVO) { |
| | | // ææ¶ä¿çåé»è¾ï¼åç»å¯æ¹ä¸ºè°ç¨ WMS å页 API |
| | | return stockMapper.selectPage(pageReqVO); |
| | | } |
| | | |
| | | @Override |
| | | public BigDecimal updateStockCountIncrement(Long productId, Long warehouseId, BigDecimal count) { |
| | | // éè¿ MDM è·å产åçé»è®¤ SKU |
| | | Long skuId = getDefaultSkuId(productId); |
| | | if (skuId == null) { |
| | | throw exception(STOCK_COUNT_NEGATIVE2, |
| | | productService.getProduct(productId).getName(), |
| | | warehouseService.getWarehouse(warehouseId).getName()); |
| | | } |
| | | |
| | | // æ¥è¯¢å½ååºå |
| | | BigDecimal currentStock = wmsInventoryApi.getAvailableQuantity(skuId, warehouseId).getCheckedData(); |
| | | if (currentStock == null) { |
| | | currentStock = BigDecimal.ZERO; |
| | | } |
| | | |
| | | // æ ¡éªåºåæ¯å¦å
è¶³ï¼åºåºæ¶ï¼ |
| | | if (!NEGATIVE_STOCK_COUNT_ENABLE && count.compareTo(BigDecimal.ZERO) < 0) { |
| | | BigDecimal afterStock = currentStock.add(count); |
| | | if (afterStock.compareTo(BigDecimal.ZERO) < 0) { |
| | | throw exception(STOCK_COUNT_NEGATIVE, |
| | | productService.getProduct(productId).getName(), |
| | | warehouseService.getWarehouse(warehouseId).getName(), |
| | | currentStock, count.abs()); |
| | | } |
| | | } |
| | | |
| | | // TODO: è°ç¨ WMS åºååæ´ APIï¼éè¦ WMS æä¾ increment/decrement æ¹æ³ï¼ |
| | | // ææ¶ä¿çåé»è¾ï¼ä½¿ç¨æ¬å°åºå表 |
| | | // 1.1 æ¥è¯¢å½ååºå |
| | | ErpStockDO stock = stockMapper.selectByProductIdAndWarehouseId(productId, warehouseId); |
| | | if (stock == null) { |
| | | stock = new ErpStockDO() |
| | | .setProductId(productId) |
| | | .setWarehouseId(warehouseId) |
| | | .setCount(BigDecimal.ZERO); |
| | | stock = new ErpStockDO().setProductId(productId).setWarehouseId(warehouseId).setCount(BigDecimal.ZERO); |
| | | stockMapper.insert(stock); |
| | | } |
| | | // 1.2 æ ¡éªåºåæ¯å¦å
è¶³ |
| | | if (!NEGATIVE_STOCK_COUNT_ENABLE && stock.getCount().add(count).compareTo(BigDecimal.ZERO) < 0) { |
| | | throw exception(STOCK_COUNT_NEGATIVE, productService.getProduct(productId).getName(), |
| | | warehouseService.getWarehouse(warehouseId).getName(), stock.getCount(), count); |
| | | } |
| | | |
| | | // 2. åºååæ´ |
| | | int updateCount = stockMapper.updateCountIncrement(stock.getId(), count, NEGATIVE_STOCK_COUNT_ENABLE); |
| | | if (updateCount == 0) { |
| | | throw exception(STOCK_COUNT_NEGATIVE2, |
| | | productService.getProduct(productId).getName(), |
| | | // æ¤æ¶ä¸å¥½å»æ¥è¯¢ææ°åºåï¼æä»¥ç´æ¥æåºè¯¥æç¤ºï¼ä¸æä¾å
·ä½åºåæ°å |
| | | throw exception(STOCK_COUNT_NEGATIVE2, productService.getProduct(productId).getName(), |
| | | warehouseService.getWarehouse(warehouseId).getName()); |
| | | } |
| | | |
| | | // 3. è¿åææ°åºå |
| | | return stock.getCount().add(count); |
| | | } |
| | | |
| | | /** |
| | | * è·å产åçé»è®¤ SKU ID |
| | | * ERP productId å¯¹åº MDM itemIdï¼é»è®¤ä½¿ç¨ç¬¬ä¸ä¸ª SKU |
| | | */ |
| | | private Long getDefaultSkuId(Long productId) { |
| | | if (productId == null) { |
| | | return null; |
| | | } |
| | | List<MdmItemSkuRespDTO> skuList = mdmItemSkuApi.getItemSkuListByItemId(productId).getCheckedData(); |
| | | if (CollUtil.isEmpty(skuList)) { |
| | | return null; |
| | | } |
| | | return skuList.get(0).getId(); |
| | | } |
| | | |
| | | } |
| | |
| | | package cn.iocoder.yudao.module.erp.service.stock.bo; |
| | | |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Data; |
| | | import lombok.NoArgsConstructor; |
| | | |
| | |
| | | */ |
| | | @Data |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ErpStockRecordCreateReqBO { |
| | | |
| | | /** |
| | |
| | | @NotNull(message = "ä¸å¡åå·ä¸è½ä¸ºç©º") |
| | | private String bizNo; |
| | | |
| | | /** |
| | | * 夿³¨ |
| | | */ |
| | | private String remark; |
| | | |
| | | } |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <project xmlns="http://maven.apache.org/POM/4.0.0" |
| | | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| | | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| | | <parent> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao</artifactId> |
| | | <version>${revision}</version> |
| | | </parent> |
| | | <modelVersion>4.0.0</modelVersion> |
| | | <artifactId>yudao-module-im</artifactId> |
| | | <packaging>jar</packaging> |
| | | |
| | | <name>${project.artifactId}</name> |
| | | <description> |
| | | im 模åï¼æä»¬æ¾å³æ¶é讯ä¸å¡ã |
| | | ä¾å¦è¯´ï¼åèã群èãæ¶æ¯æ¶åãæ¶æ¯æ¤åãæ¶æ¯å·²è¯»çç |
| | | </description> |
| | | |
| | | <dependencies> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-module-system</artifactId> |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-module-infra</artifactId> |
| | | <version>${revision}</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-common</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- Web ç¸å
³ --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-web</artifactId> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-security</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- DB ç¸å
³ --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-mybatis</artifactId> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-redis</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- å·¥å
·ç±»ç¸å
³ --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-excel</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- ææè¯æ£æµï¼sensitive-wordï¼trie æ 髿å¹é
ï¼æ¯æå¿½ç¥å¤§å°å / å
¨åè§ / æ°å飿 ¼ï¼ï¼çæ¬ç± yudao-dependencies ç»ä¸ç®¡ç --> |
| | | <dependency> |
| | | <groupId>com.github.houbb</groupId> |
| | | <artifactId>sensitive-word</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- æ±å转æ¼é³ï¼ä½ä¸º hutool PinyinUtil çåºå±å¼æï¼ä¸å¡ä¾§è°ç¨ StrUtils.toPinyin æ¶æéå¼å
¥ --> |
| | | <dependency> |
| | | <groupId>com.belerweb</groupId> |
| | | <artifactId>pinyin4j</artifactId> |
| | | </dependency> |
| | | |
| | | <!-- Test æµè¯ç¸å
³ --> |
| | | <dependency> |
| | | <groupId>cn.iocoder.boot</groupId> |
| | | <artifactId>yudao-spring-boot-starter-test</artifactId> |
| | | </dependency> |
| | | |
| | | </dependencies> |
| | | |
| | | </project> |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | /** |
| | | * @author anhaohao |
| | | * @since 2024/3/9 ä¸å8:59 |
| | | */ |
| | | package cn.iocoder.yudao.module.im.api; |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material.ImChannelMaterialRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelMaterialDO; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelMaterialService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | @Tag(name = "ç¨æ· APP - IM é¢éç´ æ") |
| | | @RestController |
| | | @RequestMapping("/im/channel/material") |
| | | @Validated |
| | | public class ImChannelMaterialController { |
| | | |
| | | @Resource |
| | | private ImChannelMaterialService channelMaterialService; |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·åç´ æè¯¦æ
ï¼ç¨äºå®¢æ·ç«¯ç¹å»å¾æå¡ç渲æè¯¦æ
页") |
| | | @Parameter(name = "id", description = "ç´ æç¼å·", required = true, example = "1024") |
| | | public CommonResult<ImChannelMaterialRespVO> getMaterial(@RequestParam("id") Long id) { |
| | | ImChannelMaterialDO material = channelMaterialService.validateMaterialExists(id); |
| | | return success(BeanUtils.toBean(material, ImChannelMaterialRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.conversation; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.conversation.vo.ImConversationReadRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.conversation.ImConversationReadDO; |
| | | import cn.iocoder.yudao.module.im.service.conversation.ImConversationReadService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.Parameters; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM ä¼è¯è¯»ä½ç½®") |
| | | @RestController |
| | | @RequestMapping("/im/conversation-read") |
| | | @Validated |
| | | public class ImConversationReadController { |
| | | |
| | | @Resource |
| | | private ImConversationReadService conversationReadService; |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "å¢éæåå½åç¨æ·çä¼è¯è¯»ä½ç½®ï¼éè¿ / 离线补å¿ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "lastUpdateTime", description = "䏿¬¡æåå°çææ°æ´æ°æ¶é´ï¼æ¯«ç§æ¶é´æ³ï¼ï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "lastId", description = "䏿¬¡æåå°çæå䏿¡è®°å½ idï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "limit", description = "忬¡æåæ¡æ°", required = true) |
| | | }) |
| | | public CommonResult<List<ImConversationReadRespVO>> pullMyConversationRead( |
| | | @RequestParam(value = "lastUpdateTime", required = false) Long lastUpdateTime, |
| | | @RequestParam(value = "lastId", required = false) Long lastId, |
| | | @RequestParam("limit") @Min(1) @Max(200) Integer limit) { |
| | | List<ImConversationReadDO> list = conversationReadService.pullConversationReadList( |
| | | getLoginUserId(), lastUpdateTime, lastId, limit); |
| | | return success(BeanUtils.toBean(list, ImConversationReadRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.conversation.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM ä¼è¯è¯»ä½ç½® Response VO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Schema(description = "管çåå° - IM ä¼è¯è¯»ä½ç½® Response VO") |
| | | @Data |
| | | public class ImConversationReadRespVO { |
| | | |
| | | @Schema(description = "读ä½ç½®ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ä¼è¯ç±»å", example = "1") |
| | | private Integer conversationType; // åè§ ImConversationTypeEnum æä¸¾ |
| | | |
| | | @Schema(description = "ç®æ ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long targetId; |
| | | |
| | | @Schema(description = "æå¤§å·²è¯»æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "4096") |
| | | private Long messageId; |
| | | |
| | | @Schema(description = "æè¿æ´æ°æ¶é´ï¼å¢éæå游æ ç¨ï¼") |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.face; |
| | | |
| | | import cn.hutool.core.collection.ListUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.face.vo.pack.ImFacePackUserRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFacePackDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFacePackItemDO; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFacePackItemService; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFacePackService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMultiMap; |
| | | |
| | | @Tag(name = "管çåå° - IM 表æ
å
") |
| | | @RestController |
| | | @RequestMapping("/im/face-pack") |
| | | @Validated |
| | | public class ImFacePackController { |
| | | |
| | | @Resource |
| | | private ImFacePackService facePackService; |
| | | @Resource |
| | | private ImFacePackItemService facePackItemService; |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾å¯ç¨ç表æ
å
å表ï¼å«è¡¨æ
ï¼") |
| | | public CommonResult<List<ImFacePackUserRespVO>> getFacePackList() { |
| | | // 1.1 æææå¯ç¨è¡¨æ
å
|
| | | List<ImFacePackDO> packs = facePackService.getEnabledFacePackList(); |
| | | if (packs.isEmpty()) { |
| | | return success(ListUtil.of()); |
| | | } |
| | | // 1.2 æè¿äºå
䏿æå¯ç¨è¡¨æ
ï¼æ packId åç» |
| | | List<ImFacePackItemDO> items = facePackItemService.getEnabledItemListByPackIds( |
| | | convertList(packs, ImFacePackDO::getId)); |
| | | Map<Long, List<ImFacePackItemDO>> itemsByPackId = convertMultiMap(items, ImFacePackItemDO::getPackId); |
| | | |
| | | // 2. æ¼è£
ï¼BeanUtils æ pack åæ®µæ å° + èªå·±å¡ items |
| | | List<ImFacePackUserRespVO> result = convertList(packs, pack -> { |
| | | ImFacePackUserRespVO vo = BeanUtils.toBean(pack, ImFacePackUserRespVO.class); |
| | | vo.setItems(BeanUtils.toBean(itemsByPackId.getOrDefault(pack.getId(), ListUtil.of()), ImFacePackUserRespVO.Item.class)); |
| | | return vo; |
| | | }); |
| | | return success(result); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.face.vo.useritem.ImFaceUserItemRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.face.vo.useritem.ImFaceUserItemSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFaceUserItemDO; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFaceUserItemService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM 个人表æ
") |
| | | @RestController |
| | | @RequestMapping("/im/face-user-item") |
| | | @Validated |
| | | public class ImFaceUserItemController { |
| | | |
| | | @Resource |
| | | private ImFaceUserItemService faceUserItemService; |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾æç个人表æ
å表") |
| | | public CommonResult<List<ImFaceUserItemRespVO>> getFaceUserItemList() { |
| | | List<ImFaceUserItemDO> items = faceUserItemService.getFaceUserItemList(getLoginUserId()); |
| | | return success(BeanUtils.toBean(items, ImFaceUserItemRespVO.class)); |
| | | } |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ·»å 个人表æ
") |
| | | public CommonResult<Long> createFaceUserItem(@Valid @RequestBody ImFaceUserItemSaveReqVO reqVO) { |
| | | return success(faceUserItemService.createFaceUserItem(getLoginUserId(), reqVO)); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤ä¸ªäººè¡¨æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "4096") |
| | | public CommonResult<Boolean> deleteFaceUserItem(@RequestParam("id") Long id) { |
| | | faceUserItemService.deleteFaceUserItem(getLoginUserId(), id); |
| | | return success(true); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.face.vo.pack; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "IM 表æ
å
ï¼ç¨æ·ç«¯ï¼ Response VO") |
| | | @Data |
| | | public class ImFacePackUserRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "表æ
å
åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ç«ä¸»å") |
| | | private String name; |
| | | |
| | | @Schema(description = "表æ
å
徿 ", example = "https://cdn.example.com/face/pack/cat.png") |
| | | private String icon; |
| | | |
| | | @Schema(description = "表æ
å表", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private List<Item> items; |
| | | |
| | | @Schema(description = "IM 表æ
å
项ï¼ç¨æ·ç«¯ï¼") |
| | | @Data |
| | | public static class Item { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long id; |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/pack/cat-001.png") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer height; |
| | | |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.face.vo.useritem; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "IM 个人表æ
Response VO") |
| | | @Data |
| | | public class ImFaceUserItemRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "4096") |
| | | private Long id; |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/user/abc.gif") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer height; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.face.vo.useritem; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "IM 个人表æ
æ°å¢ Request VO") |
| | | @Data |
| | | public class ImFaceUserItemSaveReqVO { |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/user/abc.gif") |
| | | @NotBlank(message = "表æ
å¾ URL ä¸è½ä¸ºç©º") |
| | | @Size(max = 512, message = "表æ
å¾ URL é¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | @Size(max = 64, message = "表æ
åé¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | @NotNull(message = "渲æå®½åº¦ä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "渲æå®½åº¦ä¸è½å°äº 1 åç´ ") |
| | | @Max(value = 2048, message = "渲æå®½åº¦ä¸è½å¤§äº 2048 åç´ ") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | @NotNull(message = "渲æé«åº¦ä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "渲æé«åº¦ä¸è½å°äº 1 åç´ ") |
| | | @Max(value = 2048, message = "渲æé«åº¦ä¸è½å¤§äº 2048 åç´ ") |
| | | private Integer height; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.framework.common.util.string.StrUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.friend.vo.ImFriendRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.friend.vo.ImFriendUpdateReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.friend.ImFriendDO; |
| | | import cn.iocoder.yudao.module.im.service.friend.ImFriendService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.Parameters; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Collection; |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.singleton; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM 好å") |
| | | @RestController |
| | | @RequestMapping("/im/friend") |
| | | @Validated |
| | | public class ImFriendController { |
| | | |
| | | @Resource |
| | | private ImFriendService friendService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾å½åç»å½ç¨æ·ç好åå表") |
| | | public CommonResult<List<ImFriendRespVO>> getMyFriendList() { |
| | | List<ImFriendDO> friends = friendService.getFriendList(getLoginUserId()); |
| | | return success(buildFriendRespVOList(friends)); |
| | | } |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "å¢éæåå½åç¨æ·ç好åå
³ç³»ï¼éè¿ / 离线补å¿ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "lastUpdateTime", description = "䏿¬¡æåå°çææ°æ´æ°æ¶é´ï¼æ¯«ç§æ¶é´æ³ï¼ï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "lastId", description = "䏿¬¡æåå°çæå䏿¡è®°å½ idï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "limit", description = "忬¡æåæ¡æ°", required = true) |
| | | }) |
| | | public CommonResult<List<ImFriendRespVO>> pullMyFriendList( |
| | | @RequestParam(value = "lastUpdateTime", required = false) Long lastUpdateTime, |
| | | @RequestParam(value = "lastId", required = false) Long lastId, |
| | | @RequestParam("limit") @Min(1) @Max(200) Integer limit) { |
| | | List<ImFriendDO> list = friendService.pullFriendList(getLoginUserId(), lastUpdateTime, lastId, limit); |
| | | return success(buildFriendRespVOList(list)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾å¥½å详æ
") |
| | | @Parameter(name = "friendUserId", description = "好åçç¨æ·ç¼å·", required = true, example = "2048") |
| | | public CommonResult<ImFriendRespVO> getFriend(@RequestParam("friendUserId") Long friendUserId) { |
| | | ImFriendDO friend = friendService.getFriend(getLoginUserId(), friendUserId); |
| | | return success(buildFriendRespVO(friend)); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤å¥½åï¼åå软å é¤ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "friendUserId", description = "好åçç¨æ·ç¼å·", required = true, example = "2048"), |
| | | @Parameter(name = "clear", description = "æ¯å¦çº§èæ¸
çæ¬ç«¯ç¸å
³æ°æ®ï¼å¦ç§èä¼è¯ï¼") |
| | | }) |
| | | public CommonResult<Boolean> deleteFriend( |
| | | @RequestParam("friendUserId") @NotNull(message = "好åç¨æ·ç¼å·ä¸è½ä¸ºç©º") Long friendUserId, |
| | | @RequestParam(value = "clear", required = false) Boolean clear) { |
| | | friendService.deleteFriend(getLoginUserId(), friendUserId, clear); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "æ´æ°å¥½ååè¾¹å±æ§ï¼å¤æ³¨ / å
ææ° / è系人置顶ï¼") |
| | | public CommonResult<Boolean> updateFriend(@Valid @RequestBody ImFriendUpdateReqVO reqVO) { |
| | | friendService.updateFriend(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/block") |
| | | @Operation(summary = "æé»å¥½åï¼å¿
é¡»å
æ¯å¥½åï¼åè¾¹å±è½å¯¹æ¹ç§èæ¶æ¯ï¼") |
| | | @Parameter(name = "friendUserId", description = "好åçç¨æ·ç¼å·", required = true, example = "2048") |
| | | public CommonResult<Boolean> blockFriend( |
| | | @RequestParam("friendUserId") @NotNull(message = "好åç¨æ·ç¼å·ä¸è½ä¸ºç©º") Long friendUserId) { |
| | | friendService.blockFriend(getLoginUserId(), friendUserId); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/unblock") |
| | | @Operation(summary = "ç§»åºé»åå") |
| | | @Parameter(name = "friendUserId", description = "好åçç¨æ·ç¼å·", required = true, example = "2048") |
| | | public CommonResult<Boolean> unblockFriend( |
| | | @RequestParam("friendUserId") @NotNull(message = "好åç¨æ·ç¼å·ä¸è½ä¸ºç©º") Long friendUserId) { |
| | | friendService.unblockFriend(getLoginUserId(), friendUserId); |
| | | return success(true); |
| | | } |
| | | |
| | | // ========== ç§ææ¹æ³ï¼VO ç»è£
========== |
| | | |
| | | private List<ImFriendRespVO> buildFriendRespVOList(Collection<ImFriendDO> friends) { |
| | | if (CollUtil.isEmpty(friends)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | // æ¹éèå AdminUser ä¿¡æ¯ï¼æµç§° / 头åï¼ï¼é¿å
N+1 |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertList(friends, ImFriendDO::getFriendUserId)); |
| | | return convertList(friends, friend -> { |
| | | ImFriendRespVO vo = BeanUtils.toBean(friend, ImFriendRespVO.class); |
| | | MapUtils.findAndThen(userMap, friend.getFriendUserId(), user -> |
| | | vo.setNickname(user.getNickname()).setAvatar(user.getAvatar())); |
| | | // 夿³¨ / æµç§°çæ¼é³ï¼ç»å端å忝忡¶ + æ¼é³æç´¢ |
| | | vo.setDisplayNamePinyin(StrUtils.toPinyin(vo.getDisplayName())) |
| | | .setNicknamePinyin(StrUtils.toPinyin(vo.getNickname())); |
| | | return vo; |
| | | }); |
| | | } |
| | | |
| | | private ImFriendRespVO buildFriendRespVO(ImFriendDO friend) { |
| | | if (friend == null) { |
| | | return null; |
| | | } |
| | | return CollUtil.getFirst(buildFriendRespVOList(singleton(friend))); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.ObjUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.friend.vo.request.ImFriendRequestApplyReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.friend.vo.request.ImFriendRequestRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.friend.ImFriendRequestDO; |
| | | import cn.iocoder.yudao.module.im.service.friend.ImFriendRequestService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.Parameters; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | /** |
| | | * IM 好åç³è¯·è®°å½ Controller |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Tag(name = "管çåå° - IM 好åç³è¯·") |
| | | @RestController |
| | | @RequestMapping("/im/friend-request") |
| | | @Validated |
| | | public class ImFriendRequestController { |
| | | |
| | | @Resource |
| | | private ImFriendRequestService friendRequestService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @PostMapping("/apply") |
| | | @Operation(summary = "å起好åç³è¯·") |
| | | public CommonResult<Long> applyFriend(@Valid @RequestBody ImFriendRequestApplyReqVO reqVO) { |
| | | ImFriendRequestDO request = friendRequestService.applyFriend(getLoginUserId(), reqVO); |
| | | return success(request != null ? request.getId() : null); |
| | | } |
| | | |
| | | @PutMapping("/agree") |
| | | @Operation(summary = "åæå¥½åç³è¯·") |
| | | @Parameter(name = "id", description = "ç³è¯·ç¼å·", required = true, example = "1024") |
| | | public CommonResult<Boolean> agreeFriendRequest( |
| | | @RequestParam("id") @NotNull(message = "ç³è¯·ç¼å·ä¸è½ä¸ºç©º") Long id) { |
| | | friendRequestService.agreeFriendRequest(getLoginUserId(), id); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/refuse") |
| | | @Operation(summary = "æç»å¥½åç³è¯·") |
| | | public CommonResult<Boolean> refuseFriendRequest( |
| | | @RequestParam("id") @NotNull(message = "ç³è¯·ç¼å·ä¸è½ä¸ºç©º") Long id, |
| | | @RequestParam(value = "handleContent", required = false) |
| | | @Size(max = 255, message = "å¤ççç±æå¤ 255 个å符") String handleContent) { |
| | | friendRequestService.refuseFriendRequest(getLoginUserId(), id, handleContent); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "æ¥è¯¢ãæç¸å
³ãç好åç³è¯·åè¡¨ï¼æ¸¸æ å页ï¼ä¼ maxId å è½½æ´å¤ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "maxId", description = "å½ååè¡¨ææ§è®°å½ç idï¼é¦é¡µä¸ä¼ "), |
| | | @Parameter(name = "limit", description = "忬¡æåæ¡æ°", required = true) |
| | | }) |
| | | public CommonResult<List<ImFriendRequestRespVO>> getMyFriendRequestList( |
| | | @RequestParam(value = "maxId", required = false) Long maxId, |
| | | @RequestParam("limit") @Min(1) @Max(200) Integer limit) { |
| | | List<ImFriendRequestDO> list = friendRequestService.getMyFriendRequestList(getLoginUserId(), maxId, limit); |
| | | return success(buildList(list)); |
| | | } |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "å¢éæåãæç¸å
³ãç好åç³è¯·ï¼éè¿ / 离线补å¿ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "lastUpdateTime", description = "䏿¬¡æåå°çææ°æ´æ°æ¶é´ï¼æ¯«ç§æ¶é´æ³ï¼ï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "lastId", description = "䏿¬¡æåå°çæå䏿¡è®°å½ idï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "limit", description = "忬¡æåæ¡æ°", required = true) |
| | | }) |
| | | public CommonResult<List<ImFriendRequestRespVO>> pullMyFriendRequestList( |
| | | @RequestParam(value = "lastUpdateTime", required = false) Long lastUpdateTime, |
| | | @RequestParam(value = "lastId", required = false) Long lastId, |
| | | @RequestParam("limit") @Min(1) @Max(200) Integer limit) { |
| | | List<ImFriendRequestDO> list = friendRequestService.pullFriendRequestList(getLoginUserId(), lastUpdateTime, lastId, limit); |
| | | return success(buildList(list)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "æ id 忥ãæç¸å
³ãçç³è¯·è®°å½ï¼å¸¦è¶æè¿æ»¤ï¼WebSocket éç¥å°è¾¾åç¨ï¼") |
| | | @Parameter(name = "id", description = "ç³è¯·è®°å½ç¼å·", required = true) |
| | | public CommonResult<ImFriendRequestRespVO> getMyFriendRequest(@RequestParam("id") Long id) { |
| | | ImFriendRequestDO request = friendRequestService.getFriendRequest(id); |
| | | // è¶æè¿æ»¤ï¼fromUser / toUser å¿
æä¸æ¹æ¯å½åç¨æ·ï¼å¦åå½ä¸åå¨è¿å null |
| | | Long currentUserId = getLoginUserId(); |
| | | if (request == null || (ObjUtil.notEqual(request.getFromUserId(), currentUserId) |
| | | && ObjUtil.notEqual(request.getToUserId(), currentUserId))) { |
| | | return success(null); |
| | | } |
| | | return success(CollUtil.getFirst(buildList(Collections.singletonList(request)))); |
| | | } |
| | | |
| | | // ========== ç§ææ¹æ³ï¼VO ç»è£
========== |
| | | |
| | | private List<ImFriendRequestRespVO> buildList(List<ImFriendRequestDO> list) { |
| | | if (CollUtil.isEmpty(list)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | // åå OR å表ï¼userIds å from + to 两ç»å¹¶é |
| | | Set<Long> userIds = convertSetByFlatMap(list, |
| | | request -> Stream.of(request.getFromUserId(), request.getToUserId())); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | return convertList(list, request -> { |
| | | ImFriendRequestRespVO vo = BeanUtils.toBean(request, ImFriendRequestRespVO.class); |
| | | MapUtils.findAndThen(userMap, request.getFromUserId(), user -> |
| | | vo.setFromNickname(user.getNickname()).setFromAvatar(user.getAvatar())); |
| | | MapUtils.findAndThen(userMap, request.getToUserId(), user -> |
| | | vo.setToNickname(user.getNickname()).setToAvatar(user.getAvatar())); |
| | | return vo; |
| | | }); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM 好å Response VO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Schema(description = "管çåå° - IM 好å Response VO") |
| | | @Data |
| | | public class ImFriendRespVO { |
| | | |
| | | @Schema(description = "å
³ç³»è®°å½ç¼å·", example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "好åçç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long friendUserId; |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°", example = "false") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "好åå±ç¤ºå¤æ³¨ï¼ä»
èªå·±å¯è§ï¼", example = "èå¼ ") |
| | | private String displayName; |
| | | |
| | | @Schema(description = "好åå±ç¤ºå¤æ³¨çæ¼é³ï¼å°åæ ç©ºæ ¼ï¼", example = "laozhang") |
| | | private String displayNamePinyin; |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImFriendAddSourceEnum æä¸¾ |
| | | |
| | | @Schema(description = "æ¯å¦ç½®é¡¶è系人", example = "false") |
| | | private Boolean pinned; |
| | | |
| | | @Schema(description = "æ¯å¦æé»ï¼ä»
èªå·±å¯è§ï¼", example = "false") |
| | | private Boolean blocked; |
| | | |
| | | @Schema(description = "好åç¶æ", example = "0") |
| | | private Integer status; |
| | | |
| | | @Schema(description = "æ·»å 好忶é´") |
| | | private LocalDateTime addTime; |
| | | |
| | | @Schema(description = "å é¤å¥½åæ¶é´") |
| | | private LocalDateTime deleteTime; |
| | | |
| | | @Schema(description = "æè¿æ´æ°æ¶é´ï¼å¢éæå游æ ç¨ï¼") |
| | | private LocalDateTime updateTime; |
| | | |
| | | // ========== ä¸é¢æ¯èååæ®µï¼æ¹ä¾¿å端æ¾ç¤º ========== |
| | | |
| | | @Schema(description = "å¥½åæµç§°ï¼å®æ¶èåèª AdminUserï¼", example = "èé") |
| | | private String nickname; |
| | | |
| | | @Schema(description = "å¥½åæµç§°çæ¼é³ï¼å°åæ ç©ºæ ¼ï¼", example = "yudao") |
| | | private String nicknamePinyin; |
| | | |
| | | @Schema(description = "好å头åï¼å®æ¶èåèª AdminUserï¼") |
| | | private String avatar; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM å¥½åæ´æ° Request VO") |
| | | @Data |
| | | public class ImFriendUpdateReqVO { |
| | | |
| | | @Schema(description = "好åçç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | @NotNull(message = "好åç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long friendUserId; |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°ï¼ä¸ä¼ 表示ä¸ä¿®æ¹", example = "true") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "好åå±ç¤ºå¤æ³¨ï¼ä»
èªå·±å¯è§ï¼ï¼ä¸ä¼ 表示ä¸ä¿®æ¹ï¼ä¼ 空串表示æ¸
空", example = "èå¼ ") |
| | | @Size(max = 16, message = "好å夿³¨æå¤ 16 个å符") |
| | | private String displayName; |
| | | |
| | | @Schema(description = "æ¯å¦ç½®é¡¶è系人ï¼ä¸ä¼ 表示ä¸ä¿®æ¹", example = "true") |
| | | private Boolean pinned; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend.vo.request; |
| | | |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import cn.iocoder.yudao.module.im.enums.friend.ImFriendAddSourceEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * IM 好åç³è¯· - åèµ· Request VO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Schema(description = "管çåå° - IM 好åç³è¯·åèµ· Request VO") |
| | | @Data |
| | | public class ImFriendRequestApplyReqVO { |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | @NotNull(message = "æ¥æ¶æ¹ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long toUserId; |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ¯èè¿ï¼ä¸ç§é£æï¼") |
| | | @Size(max = 255, message = "ç³è¯·çç±æå¤ 255 个å符") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "å¯¹æ¥æ¶æ¹ç夿³¨ï¼ä»
èªå·±å¯è§ï¼", example = "èå¼ ") |
| | | @Size(max = 16, message = "好å夿³¨æå¤ 16 个å符") |
| | | private String displayName; |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | @InEnum(ImFriendAddSourceEnum.class) |
| | | private Integer addSource; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.friend.vo.request; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM 好åç³è¯· Response VO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Schema(description = "管çåå° - IM 好åç³è¯· Response VO") |
| | | @Data |
| | | public class ImFriendRequestRespVO { |
| | | |
| | | @Schema(description = "ç³è¯·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "åèµ·æ¹ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "100") |
| | | private Long fromUserId; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Long toUserId; |
| | | |
| | | @Schema(description = "å¤çç»æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer handleResult; // åè§ ImFriendRequestHandleResultEnum æä¸¾ |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ¯èè¿ï¼ä¸ç§é£æï¼") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "å¤ççç±ï¼æ¥æ¶æ¹æç»æ¶å¯éå¡«ï¼", example = "æä¸éè¿") |
| | | private String handleContent; |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImFriendAddSourceEnum æä¸¾ |
| | | |
| | | @Schema(description = "å¤çæ¶é´") |
| | | private LocalDateTime handleTime; |
| | | |
| | | @Schema(description = "ç³è¯·å建æ¶é´") |
| | | private LocalDateTime createTime; |
| | | |
| | | @Schema(description = "æè¿æ´æ°æ¶é´ï¼å¢éæå游æ ç¨ï¼") |
| | | private LocalDateTime updateTime; |
| | | |
| | | // ========== ä¸é¢æ¯èååæ®µï¼æ¹ä¾¿å端æ¾ç¤º ========== |
| | | |
| | | @Schema(description = "åèµ·æ¹æµç§°ï¼å®æ¶èåèª AdminUserï¼", example = "èé") |
| | | private String fromNickname; |
| | | |
| | | @Schema(description = "åèµ·æ¹å¤´åï¼å®æ¶èåèª AdminUserï¼") |
| | | private String fromAvatar; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹æµç§°ï¼å®æ¶èåèª AdminUserï¼", example = "èå¼ ") |
| | | private String toNickname; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹å¤´åï¼å®æ¶èåèª AdminUserï¼") |
| | | private String toAvatar; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.*; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.member.ImGroupMemberInviteReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.member.ImGroupMemberRemoveReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.group.ImGroupMessageRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupMemberDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImGroupMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupMemberService; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.im.service.message.ImGroupMessageService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.*; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - 群") |
| | | @RestController |
| | | @RequestMapping("/im/group") |
| | | @Validated |
| | | public class ImGroupController { |
| | | |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | @Resource |
| | | private ImGroupMemberService groupMemberService; |
| | | @Resource |
| | | private ImGroupMessageService groupMessageService; |
| | | |
| | | // ==================== 群çåæä½ ==================== |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "å建群") |
| | | public CommonResult<ImGroupRespVO> createGroup(@Valid @RequestBody ImGroupCreateReqVO createReqVO) { |
| | | ImGroupDO group = groupService.createGroup(createReqVO, getLoginUserId()); |
| | | // æ°å»ºç¾¤å¿
æ pinnedMessagesï¼è·³è¿å
³èåå¡« |
| | | return success(BeanUtils.toBean(group, ImGroupRespVO.class)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "æ´æ°ç¾¤") |
| | | public CommonResult<ImGroupRespVO> updateGroup(@Valid @RequestBody ImGroupUpdateReqVO updateReqVO) { |
| | | ImGroupDO group = groupService.updateGroup(updateReqVO, getLoginUserId()); |
| | | return success(buildGroupRespVO(group, getLoginUserId())); |
| | | } |
| | | |
| | | @DeleteMapping("/dissolve") |
| | | @Operation(summary = "è§£æ£ç¾¤") |
| | | @Parameter(name = "id", description = "群ç¼å·", required = true) |
| | | public CommonResult<Boolean> dissolveGroup(@RequestParam("id") Long id) { |
| | | groupService.dissolveGroup(id, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | | // ==================== 群ç读æä½ ==================== |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç¾¤") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | public CommonResult<ImGroupRespVO> getGroup(@RequestParam("id") Long id) { |
| | | ImGroupDO group = groupService.getGroup(id); |
| | | return success(buildGroupRespVO(group, getLoginUserId())); |
| | | } |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾å½åç»å½ç¨æ·ç群å表") |
| | | public CommonResult<List<ImGroupRespVO>> getMyGroupList() { |
| | | Long loginUserId = getLoginUserId(); |
| | | List<ImGroupDO> groups = groupService.getMyGroupList(loginUserId); |
| | | return success(buildGroupRespVOList(groups, loginUserId)); |
| | | } |
| | | |
| | | // ==================== 群æåçåæä½ ==================== |
| | | |
| | | @PostMapping("/invite") |
| | | @Operation(summary = "éè¯·ç¨æ·å å
¥ç¾¤") |
| | | public CommonResult<Boolean> inviteGroupMember(@Valid @RequestBody ImGroupMemberInviteReqVO inviteReqVO) { |
| | | groupService.inviteGroupMember(getLoginUserId(), inviteReqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/quit") |
| | | @Operation(summary = "éåºç¾¤") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true) |
| | | public CommonResult<Boolean> quitGroup(@RequestParam("groupId") Long groupId) { |
| | | groupService.quitGroup(groupId, getLoginUserId()); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/kicking") |
| | | @Operation(summary = "ç§»é¤ç¾¤æå") |
| | | public CommonResult<Boolean> removeGroupMember(@Valid @RequestBody ImGroupMemberRemoveReqVO removeReqVO) { |
| | | groupService.removeGroupMember(getLoginUserId(), removeReqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/add-admin") |
| | | @Operation(summary = "æ·»å 群管çå") |
| | | public CommonResult<Boolean> addGroupAdmin(@Valid @RequestBody ImGroupAdminAddReqVO reqVO) { |
| | | groupService.addGroupAdmin(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/remove-admin") |
| | | @Operation(summary = "æ¤é群管çå") |
| | | public CommonResult<Boolean> removeGroupAdmin(@Valid @RequestBody ImGroupAdminRemoveReqVO reqVO) { |
| | | groupService.removeGroupAdmin(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/transfer-owner") |
| | | @Operation(summary = "转让群主") |
| | | public CommonResult<Boolean> transferGroupOwner(@Valid @RequestBody ImGroupTransferOwnerReqVO transferReqVO) { |
| | | groupService.transferGroupOwner(getLoginUserId(), transferReqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | // ==================== ç¾¤æ¶æ¯ç½®é¡¶ ==================== |
| | | |
| | | @PutMapping("/pin-message") |
| | | @Operation(summary = "ç½®é¡¶ç¾¤æ¶æ¯ï¼ç¾¤ä¸» / 管çåï¼") |
| | | public CommonResult<Boolean> pinGroupMessage(@Valid @RequestBody ImGroupMessagePinReqVO reqVO) { |
| | | groupService.pinGroupMessage(getLoginUserId(), reqVO.getId(), reqVO.getMessageId()); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/unpin-message") |
| | | @Operation(summary = "åæ¶ç½®é¡¶ç¾¤æ¶æ¯ï¼ç¾¤ä¸» / 管çåï¼") |
| | | public CommonResult<Boolean> unpinGroupMessage(@Valid @RequestBody ImGroupMessagePinReqVO reqVO) { |
| | | groupService.unpinGroupMessage(getLoginUserId(), reqVO.getId(), reqVO.getMessageId()); |
| | | return success(true); |
| | | } |
| | | |
| | | // ==================== 群ç¦è¨ ==================== |
| | | |
| | | @PutMapping("/mute-all") |
| | | @Operation(summary = "å
¨ç¾¤ç¦è¨ / åæ¶ï¼ç¾¤ä¸» / 管çåï¼") |
| | | public CommonResult<Boolean> muteAll(@Valid @RequestBody ImGroupMuteAllReqVO reqVO) { |
| | | groupService.muteAll(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/mute-member") |
| | | @Operation(summary = "ç¦è¨æå") |
| | | public CommonResult<Boolean> muteMember(@Valid @RequestBody ImGroupMuteMemberReqVO reqVO) { |
| | | groupService.muteMember(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/cancel-mute-member") |
| | | @Operation(summary = "åæ¶æåç¦è¨") |
| | | public CommonResult<Boolean> cancelMuteMember(@Valid @RequestBody ImGroupCancelMuteMemberReqVO reqVO) { |
| | | groupService.cancelMuteMember(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | /** å群转 VO + å
³èåå¡« pinnedMessagesï¼ä»
å½ç»å½ç¨æ·æ¯è¯¥ç¾¤æææåï¼ */ |
| | | private ImGroupRespVO buildGroupRespVO(ImGroupDO group, Long loginUserId) { |
| | | if (group == null) { |
| | | return null; |
| | | } |
| | | return buildGroupRespVOList(Collections.singletonList(group), loginUserId).get(0); |
| | | } |
| | | |
| | | /** |
| | | * 群å表æ¹é转 VO + å
³èåå¡« pinnedMessages |
| | | * <p> |
| | | * ä»
å½ç»å½ç¨æ·æ¯æç¾¤çæææåæ¶æå填该群ç pinnedMessagesï¼é¿å
éæå / å·²éç¾¤ç¨æ·è¶ææ¿å°ç½®é¡¶æ¶æ¯å
容 |
| | | */ |
| | | private List<ImGroupRespVO> buildGroupRespVOList(List<ImGroupDO> groups, Long loginUserId) { |
| | | if (CollUtil.isEmpty(groups)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | // ä»
å½åç¨æ·æ¯æææåç群æå
许åå¡«ç½®é¡¶æ¶æ¯ |
| | | Map<Long, ImGroupMemberDO> memberMap = convertMap( |
| | | groupMemberService.getGroupMemberListByUserId(loginUserId), ImGroupMemberDO::getGroupId); |
| | | Set<Long> activeGroupIds = convertSet(memberMap.values(), ImGroupMemberDO::getGroupId, |
| | | member -> CommonStatusEnum.ENABLE.getStatus().equals(member.getStatus())); |
| | | Set<Long> allMessageIds = convertSetByFlatMap(groups, group -> activeGroupIds.contains(group.getId()) |
| | | ? CollUtil.emptyIfNull(group.getPinnedMessageIds()).stream() : Stream.empty()); |
| | | Map<Long, ImGroupMessageDO> messageMap = groupMessageService.getGroupMessageMap(allMessageIds); |
| | | // 转æ¢è¾åº |
| | | return convertList(groups, group -> { |
| | | ImGroupRespVO groupVO = BeanUtils.toBean(group, ImGroupRespVO.class); |
| | | // æ è®°ç»å½ç¨æ·å¨è¯¥ç¾¤çæåç¶æï¼ä¾å端åºåå½å群ä¸åå²é群 |
| | | boolean joined = activeGroupIds.contains(group.getId()); |
| | | groupVO.setJoinStatus(joined ? CommonStatusEnum.ENABLE.getStatus() : CommonStatusEnum.DISABLE.getStatus()); |
| | | MapUtils.findAndThen(memberMap, group.getId(), member -> |
| | | groupVO.setGroupRemark(member.getGroupRemark()).setSilent(Boolean.TRUE.equals(member.getSilent()))); |
| | | if (!joined || CollUtil.isEmpty(group.getPinnedMessageIds())) { |
| | | return groupVO; |
| | | } |
| | | // æ pin 顺åºè¾åºï¼å·²è¢«å é¤çæ¶æ¯ï¼messageMap 没å½ä¸ï¼è·³è¿ |
| | | List<ImGroupMessageDO> pinnedMesages = convertList(group.getPinnedMessageIds(), messageMap::get); |
| | | return groupVO.setPinnedMessages(BeanUtils.toBean(pinnedMesages, ImGroupMessageRespVO.class)); |
| | | }); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.ObjUtil; |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.member.ImGroupMemberRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.member.ImGroupMemberUpdateReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupMemberDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupMemberService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.Parameters; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception; |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | import static cn.iocoder.yudao.module.im.enums.ErrorCodeConstants.GROUP_MEMBER_NOT_IN_GROUP; |
| | | |
| | | @Tag(name = "管çåå° - 群æå") |
| | | @RestController |
| | | @RequestMapping("/im/group-member") |
| | | @Validated |
| | | public class ImGroupMemberController { |
| | | |
| | | @Resource |
| | | private ImGroupMemberService groupMemberService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "æ´æ°ç¾¤æå") |
| | | public CommonResult<Boolean> updateGroupMember(@Valid @RequestBody ImGroupMemberUpdateReqVO updateReqVO) { |
| | | groupMemberService.updateGroupMember(getLoginUserId(), updateReqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç¾¤æå") |
| | | @Parameters({ |
| | | @Parameter(name = "id", description = "ç¼å·ï¼ä¸ groupId + userId äºéä¸ï¼", example = "1024"), |
| | | @Parameter(name = "groupId", description = "群ç¼å·ï¼ä¸ userId é
忥ï¼", example = "1"), |
| | | @Parameter(name = "userId", description = "ç¨æ·ç¼å·ï¼ä¸ groupId é
忥ï¼", example = "100") |
| | | }) |
| | | public CommonResult<ImGroupMemberRespVO> getGroupMember(@RequestParam(value = "id", required = false) Long id, |
| | | @RequestParam(value = "groupId", required = false) Long groupId, |
| | | @RequestParam(value = "userId", required = false) Long userId) { |
| | | // 1. æ¥è¯¢ç¾¤æå |
| | | ImGroupMemberDO member; |
| | | if (id != null) { |
| | | member = groupMemberService.getGroupMember(id); |
| | | } else if (groupId != null && userId != null) { |
| | | member = groupMemberService.getGroupMember(groupId, userId); |
| | | } else { |
| | | // é¿å
selectByGroupIdAndUserId æ¶å° null åæ°èµ°å
¨è¡¨æ« / æ SQL å¼å¸¸ |
| | | throw new IllegalArgumentException("åæ°ç¼ºå¤±ï¼éä¼ id æ (groupId, userId)"); |
| | | } |
| | | if (member == null) { |
| | | return success(null); |
| | | } |
| | | |
| | | // 2. æ ¡éªå½åç»å½ç¨æ·æ¯è¯¥æåæå¨ç¾¤çæææå |
| | | Long loginUserId = getLoginUserId(); |
| | | groupMemberService.validateMemberInGroup(member.getGroupId(), loginUserId); |
| | | |
| | | // 3. 转å VO |
| | | ImGroupMemberRespVO memberVO = BeanUtils.toBean(member, ImGroupMemberRespVO.class); |
| | | AdminUserRespDTO user = adminUserApi.getUser(member.getUserId()); |
| | | if (user != null) { |
| | | memberVO.setNickname(user.getNickname()).setAvatar(user.getAvatar()); |
| | | } |
| | | hidePrivateFieldsIfNotSelf(memberVO, member.getUserId(), loginUserId); |
| | | return success(memberVO); |
| | | } |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾æå®ç¾¤çæååè¡¨ï¼æç¾¤å
¨éæåï¼ä½ä¸ºå端æ¬å°æå cache ç宿´åºçº¿ï¼") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "1024") |
| | | public CommonResult<List<ImGroupMemberRespVO>> getGroupMemberList(@RequestParam("groupId") Long groupId) { |
| | | // 1.1 æ¥è¯¢ç¾¤æåå表ï¼å
å« DISABLE å·²é群çæåï¼ä¸ææ¶é´è¿æ»¤ï¼ |
| | | // 说æï¼ä¿çå·²é群æåï¼æ¯ä¸ºäºå端å±ç¤ºå岿¶æ¯æ¶ï¼ä»è½éè¿è¯¥æ¥å£æ¿å°å·²é群æåçæµç§° / 头åä¿¡æ¯ï¼é¿å
æ¾ç¤ºä¸ºç©º |
| | | List<ImGroupMemberDO> members = groupMemberService.getGroupMemberListByGroupId(groupId); |
| | | // 1.2 æ ¡éªå½åç»å½ç¨æ·æ¯å¦ä¸ºç¾¤çæææåï¼éæåä¸å¯æ¥ç |
| | | Long loginUserId = getLoginUserId(); |
| | | if (CollUtil.findOne(members, member -> loginUserId.equals(member.getUserId()) |
| | | && CommonStatusEnum.ENABLE.getStatus().equals(member.getStatus())) == null) { |
| | | throw exception(GROUP_MEMBER_NOT_IN_GROUP); |
| | | } |
| | | |
| | | // 2. æ¹éèåæµç§° / 头åï¼å¹¶å¯¹éæ¬äººç½®ç©ºç§äººå段 |
| | | return success(buildGroupMemberRespVOList(members)); |
| | | } |
| | | |
| | | // ========== ç§ææ¹æ³ï¼VO ç»è£
========== |
| | | |
| | | /** |
| | | * 群æåå表æ¹é转 VO ï¼ å
³èåå¡«æµç§° ï¼ å¤´åï¼å¹¶å¯¹éæ¬äººç½®ç©ºç§äººå段 |
| | | */ |
| | | private List<ImGroupMemberRespVO> buildGroupMemberRespVOList(List<ImGroupMemberDO> members) { |
| | | if (CollUtil.isEmpty(members)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | Long loginUserId = getLoginUserId(); |
| | | // æ¹éèå AdminUser ä¿¡æ¯ï¼æµç§° ï¼ å¤´åï¼ï¼é¿å
N+1 |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertList(members, ImGroupMemberDO::getUserId)); |
| | | return convertList(members, member -> { |
| | | ImGroupMemberRespVO vo = BeanUtils.toBean(member, ImGroupMemberRespVO.class); |
| | | MapUtils.findAndThen(userMap, member.getUserId(), user -> |
| | | vo.setNickname(user.getNickname()).setAvatar(user.getAvatar())); |
| | | hidePrivateFieldsIfNotSelf(vo, member.getUserId(), loginUserId); |
| | | return vo; |
| | | }); |
| | | } |
| | | |
| | | /** |
| | | * éæ¬äººæ¥çæ¶ï¼ç½®ç©ºæåçç§äººè®¾ç½®å段ï¼groupRemark / silentï¼ |
| | | */ |
| | | private void hidePrivateFieldsIfNotSelf(ImGroupMemberRespVO vo, Long memberUserId, Long loginUserId) { |
| | | if (ObjUtil.notEqual(loginUserId, memberUserId)) { |
| | | vo.setGroupRemark(null).setSilent(null); |
| | | } |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.util.ObjUtil; |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.request.ImGroupRequestApplyReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.group.vo.request.ImGroupRequestRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupMemberDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupRequestDO; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupMemberRoleEnum; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupMemberService; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupRequestService; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.Parameters; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.*; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | /** |
| | | * IM å 群ç³è¯· Controller |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Tag(name = "管çåå° - IM å 群ç³è¯·") |
| | | @RestController |
| | | @RequestMapping("/im/group-request") |
| | | @Validated |
| | | public class ImGroupRequestController { |
| | | |
| | | @Resource |
| | | private ImGroupRequestService groupRequestService; |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | @Resource |
| | | private ImGroupMemberService groupMemberService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @PostMapping("/apply") |
| | | @Operation(summary = "ç³è¯·å 群") |
| | | public CommonResult<Long> applyJoinGroup(@Valid @RequestBody ImGroupRequestApplyReqVO reqVO) { |
| | | ImGroupRequestDO request = groupRequestService.applyJoinGroup(getLoginUserId(), reqVO); |
| | | return success(request != null ? request.getId() : null); |
| | | } |
| | | |
| | | @PutMapping("/agree") |
| | | @Operation(summary = "åæå 群ç³è¯·ï¼ç¾¤ä¸»æç®¡çåï¼") |
| | | @Parameter(name = "id", description = "ç³è¯·ç¼å·", required = true, example = "1024") |
| | | public CommonResult<Boolean> agreeGroupRequest( |
| | | @RequestParam("id") @NotNull(message = "ç³è¯·ç¼å·ä¸è½ä¸ºç©º") Long id) { |
| | | groupRequestService.agreeGroupRequest(getLoginUserId(), id); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/refuse") |
| | | @Operation(summary = "æç»å 群ç³è¯·ï¼ç¾¤ä¸»æç®¡çåï¼") |
| | | public CommonResult<Boolean> refuseGroupRequest( |
| | | @RequestParam("id") @NotNull(message = "ç³è¯·ç¼å·ä¸è½ä¸ºç©º") Long id, |
| | | @RequestParam(value = "handleContent", required = false) |
| | | @Size(max = 255, message = "å¤ççç±æå¤ 255 个å符") String handleContent) { |
| | | groupRequestService.refuseGroupRequest(getLoginUserId(), id, handleContent); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/unhandled-list") |
| | | @Operation(summary = "æ¥è¯¢ãæç®¡ççææç¾¤ãä¸çæªå¤çå 群ç³è¯·å表ï¼ä¸å页ï¼ï¼å端 store æ®æ¤æ´¾ç横å¹
çº¢ç¹ + Drawer å表") |
| | | public CommonResult<List<ImGroupRequestRespVO>> getUnhandledRequestList() { |
| | | List<ImGroupRequestDO> list = groupRequestService.getUnhandledRequestListByOwnerOrAdmin(getLoginUserId()); |
| | | return success(buildVOList(list)); |
| | | } |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "å¢éæåãæç®¡çç群ãä¸çå 群ç³è¯·ï¼éè¿ / 离线补å¿ï¼") |
| | | @Parameters({ |
| | | @Parameter(name = "lastUpdateTime", description = "䏿¬¡æåå°çææ°æ´æ°æ¶é´ï¼æ¯«ç§æ¶é´æ³ï¼ï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "lastId", description = "䏿¬¡æåå°çæå䏿¡è®°å½ idï¼é¦æ¬¡æåä¸ä¼ "), |
| | | @Parameter(name = "limit", description = "忬¡æåæ¡æ°", required = true) |
| | | }) |
| | | public CommonResult<List<ImGroupRequestRespVO>> pullMyGroupRequestList( |
| | | @RequestParam(value = "lastUpdateTime", required = false) Long lastUpdateTime, |
| | | @RequestParam(value = "lastId", required = false) Long lastId, |
| | | @RequestParam("limit") @Min(1) @Max(200) Integer limit) { |
| | | List<ImGroupRequestDO> list = groupRequestService.pullGroupRequestList( |
| | | getLoginUserId(), lastUpdateTime, lastId, limit); |
| | | return success(buildVOList(list)); |
| | | } |
| | | |
| | | @GetMapping("/list-by-group") |
| | | @Operation(summary = "æ¥è¯¢æå®ç¾¤ä¸çå
¨é¨å 群ç³è¯·ï¼å«å·²å¤çï¼ï¼ä»
群主 / 管çå坿¥") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "1024") |
| | | public CommonResult<List<ImGroupRequestRespVO>> getGroupRequestListByGroupId( |
| | | @RequestParam("groupId") @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") Long groupId) { |
| | | List<ImGroupRequestDO> list = groupRequestService.getGroupRequestListByGroupId(getLoginUserId(), groupId); |
| | | return success(buildVOList(list)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "æ id 忥ç³è¯·è®°å½ï¼å¸¦è¶æè¿æ»¤ï¼WebSocket éç¥å°è¾¾åç¨ï¼") |
| | | @Parameter(name = "id", description = "ç³è¯·è®°å½ç¼å·", required = true) |
| | | public CommonResult<ImGroupRequestRespVO> getGroupRequest(@RequestParam("id") Long id) { |
| | | ImGroupRequestDO request = groupRequestService.getGroupRequest(id); |
| | | if (request == null) { |
| | | return success(null); |
| | | } |
| | | // è¶æè¿æ»¤ï¼ç³è¯·äºº / é请人 / 群主 / 管çåä¹å¤ï¼å½ä¸åå¨è¿å null |
| | | Long currentUserId = getLoginUserId(); |
| | | boolean canSee = ObjUtil.equal(request.getUserId(), currentUserId) |
| | | || ObjUtil.equal(request.getInviterUserId(), currentUserId) |
| | | || isGroupOwnerOrAdmin(request.getGroupId(), currentUserId); |
| | | if (!canSee) { |
| | | return success(null); |
| | | } |
| | | |
| | | // 转æ¢å¹¶è¿å |
| | | return success(CollUtil.getFirst(buildVOList(Collections.singletonList(request)))); |
| | | } |
| | | |
| | | /** |
| | | * å½åç¨æ·æ¯å¦è¯¥ç¾¤çææç¾¤ä¸» / 管çå |
| | | */ |
| | | private boolean isGroupOwnerOrAdmin(Long groupId, Long userId) { |
| | | ImGroupMemberDO member = groupMemberService.getGroupMember(groupId, userId); |
| | | return member != null |
| | | && !CommonStatusEnum.DISABLE.getStatus().equals(member.getStatus()) |
| | | && ImGroupMemberRoleEnum.isOwnerOrAdmin(member.getRole()); |
| | | } |
| | | |
| | | /** ç³è¯·è®°å½å表æ¹é转 VO + å
³èåå¡«ç¨æ· / ç¾¤ä¿¡æ¯ */ |
| | | private List<ImGroupRequestRespVO> buildVOList(List<ImGroupRequestDO> list) { |
| | | if (CollUtil.isEmpty(list)) { |
| | | return Collections.emptyList(); |
| | | } |
| | | // 1. èå user / inviter ç¨æ·ä¿¡æ¯ï¼convertSetByFlatMap å
é¨å·²è¿æ»¤ null |
| | | Set<Long> userIds = convertSetByFlatMap(list, |
| | | request -> Stream.of(request.getUserId(), request.getInviterUserId())); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | // 2. èå群信æ¯ï¼å°ç¦ / è§£æ£ç¾¤ä¹è¦åå¡«ï¼ä¾¿äºå端å±ç¤ºåå²ï¼ |
| | | Set<Long> groupIds = convertSet(list, ImGroupRequestDO::getGroupId); |
| | | Map<Long, ImGroupDO> groupMap = groupService.getGroupMap(groupIds); |
| | | return convertList(list, request -> { |
| | | ImGroupRequestRespVO vo = BeanUtils.toBean(request, ImGroupRequestRespVO.class); |
| | | MapUtils.findAndThen(userMap, request.getUserId(), user -> |
| | | vo.setUserNickname(user.getNickname()).setUserAvatar(user.getAvatar())); |
| | | MapUtils.findAndThen(userMap, request.getInviterUserId(), user -> |
| | | vo.setInviterNickname(user.getNickname()).setInviterAvatar(user.getAvatar())); |
| | | MapUtils.findAndThen(groupMap, request.getGroupId(), group -> |
| | | vo.setGroupName(group.getName()).setGroupAvatar(group.getAvatar())); |
| | | return vo; |
| | | }); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - æ·»å 群管çå Request VO") |
| | | @Data |
| | | public class ImGroupAdminAddReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ç®æ ç¨æ·ç¼å·å表", requiredMode = Schema.RequiredMode.REQUIRED, example = "[101, 102]") |
| | | @NotEmpty(message = "ç®æ ç¨æ·ç¼å·å表ä¸è½ä¸ºç©º") |
| | | private List<Long> userIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - æ¤é群管çå Request VO") |
| | | @Data |
| | | public class ImGroupAdminRemoveReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ç®æ ç¨æ·ç¼å·å表", requiredMode = Schema.RequiredMode.REQUIRED, example = "[101, 102]") |
| | | @NotEmpty(message = "ç®æ ç¨æ·ç¼å·å表ä¸è½ä¸ºç©º") |
| | | private List<Long> userIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - åæ¶æåç¦è¨ Request VO") |
| | | @Data |
| | | public class ImGroupCancelMuteMemberReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "è¢«åæ¶ç¦è¨çç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | @NotNull(message = "ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long userId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - 群å建 Request VO") |
| | | @Data |
| | | public class ImGroupCreateReqVO { |
| | | |
| | | @Schema(description = "群åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "èéææ¯äº¤æµç¾¤") |
| | | @NotBlank(message = "群åç§°ä¸è½ä¸ºç©º") |
| | | @Size(max = 64, message = "群åç§°é¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "åå§æåç¨æ·ç¼å·å表ï¼å»ºç¾¤åæ¶é请ç好åï¼ä¸å«å建è
èªå·±ï¼", example = "[1024, 2048]") |
| | | private List<Long> memberUserIds; |
| | | |
| | | @Schema(description = "è¿ç¾¤æ¯å¦é群主 / 管çå审æ¹ï¼ä¸ä¼ é»è®¤ false èªç±è¿ç¾¤", example = "false") |
| | | private Boolean joinApproval; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * 管çåå° - ç¾¤æ¶æ¯ç½®é¡¶ / åæ¶ç½®é¡¶ Request VO |
| | | */ |
| | | @Schema(description = "管çåå° - ç¾¤æ¶æ¯ç½®é¡¶ / åæ¶ç½®é¡¶ Request VO") |
| | | @Data |
| | | public class ImGroupMessagePinReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "9527") |
| | | @NotNull(message = "æ¶æ¯ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long messageId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - å
¨ç¾¤ç¦è¨ / åæ¶ Request VO") |
| | | @Data |
| | | public class ImGroupMuteAllReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æ¯å¦å
¨ç¾¤ç¦è¨", requiredMode = Schema.RequiredMode.REQUIRED, example = "true") |
| | | @NotNull(message = "æ¯å¦å
¨ç¾¤ç¦è¨ä¸è½ä¸ºç©º") |
| | | private Boolean mutedAll; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - æåç¦è¨ Request VO") |
| | | @Data |
| | | public class ImGroupMuteMemberReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "被ç¦è¨çç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | @NotNull(message = "ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç¦è¨æ¶é¿ï¼ç§ï¼ï¼0 表示永ä¹
ç¦è¨", requiredMode = Schema.RequiredMode.REQUIRED, example = "600") |
| | | @NotNull(message = "ç¦è¨æ¶é¿ä¸è½ä¸ºç©º") |
| | | @Min(value = 0, message = "ç¦è¨æ¶é¿ä¸è½å°äº 0 ç§") |
| | | private Integer mutedSeconds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import lombok.*; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - 群å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | public class ImGroupPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "群åç§°", example = "èè¿") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¾¤ä¸»ç¨æ·ç¼å·", example = "31460") |
| | | private Long ownerUserId; |
| | | |
| | | @Schema(description = "群å
Œ") |
| | | private String notice; |
| | | |
| | | @Schema(description = "å建æ¶é´") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.group.ImGroupMessageRespVO; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - 群 Response VO") |
| | | @Data |
| | | public class ImGroupRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1003") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群åç§°", example = "èè¿") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¾¤ä¸»ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "31460") |
| | | private Long ownerUserId; |
| | | |
| | | @Schema(description = "群头å") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "群å
Œ") |
| | | private String notice; |
| | | |
| | | @Schema(description = "æ¯å¦å°ç¦") |
| | | private Boolean banned; |
| | | |
| | | @Schema(description = "æ¯å¦å
¨ç¾¤ç¦è¨") |
| | | private Boolean mutedAll; |
| | | |
| | | @Schema(description = "è¿ç¾¤æ¯å¦é群主 / 管çå审æ¹", example = "false") |
| | | private Boolean joinApproval; |
| | | |
| | | @Schema(description = "å°ç¦æ¶é´") |
| | | private LocalDateTime bannedTime; |
| | | |
| | | @Schema(description = "ç¾¤ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private Integer status; |
| | | |
| | | @Schema(description = "è§£æ£æ¶é´") |
| | | private LocalDateTime dissolvedTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | @Schema(description = "å½åç»å½ç¨æ·å¨è¯¥ç¾¤çæåç¶æï¼å¨ç¾¤ / å·²é群ï¼åå²é群群ä»è¿åï¼ä¾å端å±ç¤ºç¦»çº¿æ¶æ¯ç群å / 头åï¼") |
| | | private Integer joinStatus; // åè§ CommonStatusEnum æä¸¾ |
| | | |
| | | @Schema(description = "å½åç»å½ç¨æ·å¯¹è¯¥ç¾¤ç夿³¨") |
| | | private String groupRemark; |
| | | |
| | | @Schema(description = "å½åç»å½ç¨æ·æ¯å¦å
ææ°") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "ç¾¤ç½®é¡¶æ¶æ¯åè¡¨ï¼æ pin 顺åºï¼æå
置顶çå¨åï¼ï¼éè¯¥ç¾¤æææåæ¶ä¸ºç©º") |
| | | private List<ImGroupMessageRespVO> pinnedMessages; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.*; |
| | | import jakarta.validation.constraints.*; |
| | | |
| | | @Schema(description = "管çåå° - 群æ°å¢/ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImGroupSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1003") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群åç§°", example = "èè¿") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¾¤ä¸»ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "31460") |
| | | @NotNull(message = "ç¾¤ä¸»ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long ownerUserId; |
| | | |
| | | @Schema(description = "群头å") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "群å
Œ") |
| | | private String notice; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - 群主转让 Request VO") |
| | | @Data |
| | | public class ImGroupTransferOwnerReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æ°ç¾¤ä¸»ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "202") |
| | | @NotNull(message = "æ°ç¾¤ä¸»ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long newOwnerUserId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.fasterxml.jackson.annotation.JsonIgnore; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.AssertTrue; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - ç¾¤æ´æ° Request VO") |
| | | @Data |
| | | public class ImGroupUpdateReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1003") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群åç§°", example = "èéææ¯äº¤æµç¾¤") |
| | | @Size(max = 64, message = "群åç§°é¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "群头å") |
| | | @Size(max = 512, message = "群头åé¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "群å
Œ") |
| | | @Size(max = 2048, message = "群å
¬åé¿åº¦ä¸è½è¶
è¿ 2048") |
| | | private String notice; |
| | | |
| | | @Schema(description = "è¿ç¾¤æ¯å¦é群主 / 管çå审æ¹", example = "true") |
| | | private Boolean joinApproval; |
| | | |
| | | @AssertTrue(message = "群åç§°ä¸è½ä¸ºç©º") |
| | | @JsonIgnore |
| | | public boolean isNameValid() { |
| | | return name == null || StrUtil.isNotBlank(name); |
| | | } |
| | | |
| | | @AssertTrue(message = "群头åä¸è½ä¸ºç©º") |
| | | @JsonIgnore |
| | | public boolean isAvatarValid() { |
| | | return avatar == null || StrUtil.isNotBlank(avatar); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - 群æåé请 Request VO") |
| | | @Data |
| | | public class ImGroupMemberCreateReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "21730") |
| | | @NotNull(message = "ç¨æ·ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long userId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - 群æåé请 Request VO") |
| | | @Data |
| | | public class ImGroupMemberInviteReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "13279") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "被é请çç¨æ·ç¼å·å表", requiredMode = Schema.RequiredMode.REQUIRED, example = "[1, 2, 3]") |
| | | @NotEmpty(message = "被é请çç¨æ·ç¼å·å表ä¸è½ä¸ºç©º") |
| | | private List<Long> memberUserIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - 群æåç§»é¤ Request VO") |
| | | @Data |
| | | public class ImGroupMemberRemoveReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "被移é¤çç¨æ·ç¼å·å表", requiredMode = Schema.RequiredMode.REQUIRED, example = "[1, 2, 3]") |
| | | @NotEmpty(message = "被移é¤çç¨æ·ç¼å·å表ä¸è½ä¸ºç©º") |
| | | private List<Long> memberUserIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - 群æå Response VO") |
| | | @Data |
| | | public class ImGroupMemberRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "17071") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群ç¼å·", example = "13279") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "21730") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç»å
æ¾ç¤ºå", example = "èè¿") |
| | | private String displayUserName; |
| | | |
| | | @Schema(description = "ç¾¤å¤æ³¨", example = "æ ¸å¿ç¾¤") |
| | | private String groupRemark; |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "æåç¶æ", example = "0") |
| | | private Integer status; |
| | | |
| | | @Schema(description = "æåè§è²", example = "3") |
| | | private Integer role; // åè§ ImGroupMemberRoleEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å
¥ç¾¤æ¶é´") |
| | | private LocalDateTime joinTime; |
| | | |
| | | @Schema(description = "é群æ¶é´") |
| | | private LocalDateTime quitTime; |
| | | |
| | | @Schema(description = "ç¦è¨å°ææ¶é´") |
| | | private LocalDateTime muteEndTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | // ========== å
³è AdminUser çåæ®µ ========== |
| | | |
| | | @Schema(description = "ç¨æ·æµç§°", example = "èé") |
| | | private String nickname; |
| | | |
| | | @Schema(description = "ç¨æ·å¤´å") |
| | | private String avatar; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | @Schema(description = "管çåå° - 群æåæ´æ° Request VO") |
| | | @Data |
| | | @Accessors(chain = true) |
| | | public class ImGroupMemberUpdateReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "群å
æµç§°", example = "è头") |
| | | private String displayUserName; |
| | | |
| | | @Schema(description = "ç¾¤å¤æ³¨", example = "å
¬å¸ç¾¤") |
| | | private String groupRemark; |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°") |
| | | private Boolean silent; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.request; |
| | | |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupAddSourceEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM å 群ç³è¯·åèµ· Request VO") |
| | | @Data |
| | | public class ImGroupRequestApplyReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ¯èè¿ï¼ä¸ç§é£æï¼") |
| | | @Size(max = 255, message = "ç³è¯·çç±æå¤ 255 个å符") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "å å
¥æ¥æº", example = "1") |
| | | @InEnum(ImGroupAddSourceEnum.class) |
| | | private Integer addSource; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.group.vo.request; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM å 群ç³è¯· Response VO") |
| | | @Data |
| | | public class ImGroupRequestRespVO { |
| | | |
| | | @Schema(description = "ç³è¯·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被éè¯·äººç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "100") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "éè¯·äººç¨æ·ç¼å·ï¼NULL è¡¨ç¤ºç¨æ·ä¸»å¨ç³è¯·", example = "200") |
| | | private Long inviterUserId; |
| | | |
| | | @Schema(description = "å¤çç»æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer handleResult; // åè§ ImGroupRequestHandleResultEnum æä¸¾ |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ³å å
¥è¿ä¸ªç¾¤") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "å¤ççç±ï¼æç»æ¶å¯éå¡«ï¼", example = "æä¸éè¿") |
| | | private String handleContent; |
| | | |
| | | @Schema(description = "å¤çäººç¨æ·ç¼å·", example = "31460") |
| | | private Long handleUserId; |
| | | |
| | | @Schema(description = "å å
¥æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImGroupAddSourceEnum æä¸¾ |
| | | |
| | | @Schema(description = "å¤çæ¶é´") |
| | | private LocalDateTime handleTime; |
| | | |
| | | @Schema(description = "ç³è¯·å建æ¶é´") |
| | | private LocalDateTime createTime; |
| | | |
| | | @Schema(description = "ç³è¯·æ´æ°æ¶é´ï¼å¢éæå游æ ") |
| | | private LocalDateTime updateTime; |
| | | |
| | | // ========== ä¸é¢æ¯èååæ®µï¼æ¹ä¾¿å端æ¾ç¤º ========== |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被é请人æµç§°ï¼å®æ¶èåèª AdminUserï¼", example = "èé") |
| | | private String userNickname; |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被é请人头åï¼å®æ¶èåèª AdminUserï¼") |
| | | private String userAvatar; |
| | | |
| | | @Schema(description = "é请人æµç§°ï¼å®æ¶èåèª AdminUserï¼", example = "èå¼ ") |
| | | private String inviterNickname; |
| | | |
| | | @Schema(description = "é请人头åï¼å®æ¶èåèª AdminUserï¼") |
| | | private String inviterAvatar; |
| | | |
| | | @Schema(description = "群åç§°ï¼å®æ¶èåèª ImGroupï¼", example = "èéææ¯äº¤æµç¾¤") |
| | | private String groupName; |
| | | |
| | | @Schema(description = "群头åï¼å®æ¶èåèª ImGroupï¼") |
| | | private String groupAvatar; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel.ImChannelPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel.ImChannelRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel.ImChannelSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelDO; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | @Tag(name = "管çåå° - IM é¢é") |
| | | @RestController |
| | | @RequestMapping("/im/manager/channel") |
| | | @Validated |
| | | public class ImChannelManagerController { |
| | | |
| | | @Resource |
| | | private ImChannelService channelService; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ°å¢é¢é") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel:create')") |
| | | public CommonResult<Long> createChannel(@Valid @RequestBody ImChannelSaveReqVO reqVO) { |
| | | return success(channelService.createChannel(reqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "ä¿®æ¹é¢é") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel:update')") |
| | | public CommonResult<Boolean> updateChannel(@Valid @RequestBody ImChannelSaveReqVO reqVO) { |
| | | channelService.updateChannel(reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤é¢é") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel:delete')") |
| | | public CommonResult<Boolean> deleteChannel(@RequestParam("id") Long id) { |
| | | channelService.deleteChannel(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾é¢éå页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel:query')") |
| | | public CommonResult<PageResult<ImChannelRespVO>> getChannelPage(@Valid ImChannelPageReqVO pageReqVO) { |
| | | PageResult<ImChannelDO> pageResult = channelService.getChannelPage(pageReqVO); |
| | | return success(BeanUtils.toBean(pageResult, ImChannelRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾é¢é详æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel:query')") |
| | | public CommonResult<ImChannelRespVO> getChannel(@RequestParam("id") Long id) { |
| | | ImChannelDO channel = channelService.getChannel(id); |
| | | return success(BeanUtils.toBean(channel, ImChannelRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/simple-list") |
| | | @Operation(summary = "è·å¾å¯ç¨çé¢éç²¾ç®å表ï¼å端表åéæ©é¢éæ¶è°ç¨") |
| | | public CommonResult<List<ImChannelRespVO>> getSimpleChannelList() { |
| | | List<ImChannelDO> list = channelService.getChannelListByStatus(CommonStatusEnum.ENABLE.getStatus()); |
| | | return success(BeanUtils.toBean(list, ImChannelRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material.ImChannelMaterialPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material.ImChannelMaterialRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material.ImChannelMaterialSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelMaterialDO; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelMaterialService; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertMap; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | |
| | | @Tag(name = "管çåå° - IM é¢éç´ æ") |
| | | @RestController |
| | | @RequestMapping("/im/manager/channel-material") |
| | | @Validated |
| | | public class ImChannelMaterialManagerController { |
| | | |
| | | @Resource |
| | | private ImChannelMaterialService channelMaterialService; |
| | | @Resource |
| | | private ImChannelService channelService; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ°å¢ç´ æ") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-material:create')") |
| | | public CommonResult<Long> createMaterial(@Valid @RequestBody ImChannelMaterialSaveReqVO reqVO) { |
| | | return success(channelMaterialService.createMaterial(reqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "ä¿®æ¹ç´ æ") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-material:update')") |
| | | public CommonResult<Boolean> updateMaterial(@Valid @RequestBody ImChannelMaterialSaveReqVO reqVO) { |
| | | channelMaterialService.updateMaterial(reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤ç´ æ") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-material:delete')") |
| | | public CommonResult<Boolean> deleteMaterial(@RequestParam("id") Long id) { |
| | | channelMaterialService.deleteMaterial(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ç´ æå页ï¼å«é¢éååå¡«") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-material:query')") |
| | | public CommonResult<PageResult<ImChannelMaterialRespVO>> getMaterialPage(@Valid ImChannelMaterialPageReqVO pageReqVO) { |
| | | PageResult<ImChannelMaterialDO> pageResult = channelMaterialService.getMaterialPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // åå¡«é¢éå |
| | | List<ImChannelDO> channels = channelService.getChannelList( |
| | | convertSet(pageResult.getList(), ImChannelMaterialDO::getChannelId)); |
| | | Map<Long, ImChannelDO> channelMap = convertMap(channels, ImChannelDO::getId); |
| | | return success(BeanUtils.toBean(pageResult, ImChannelMaterialRespVO.class, vo -> |
| | | MapUtils.findAndThen(channelMap, vo.getChannelId(), c -> vo.setChannelName(c.getName())))); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç´ æè¯¦æ
ï¼å«å¯ææ¬æ£æï¼") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-material:query')") |
| | | public CommonResult<ImChannelMaterialRespVO> getMaterial(@RequestParam("id") Long id) { |
| | | ImChannelMaterialDO material = channelMaterialService.getMaterial(id); |
| | | return success(BeanUtils.toBean(material, ImChannelMaterialRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/simple-list") |
| | | @Operation(summary = "è·å¾æå®é¢éä¸çç´ æç²¾ç®å表ï¼ç¨äºæ¨éå¼¹çªçç´ æä¸æ") |
| | | @Parameter(name = "channelId", description = "é¢éç¼å·", required = true, example = "1") |
| | | public CommonResult<List<ImChannelMaterialRespVO>> getSimpleMaterialList(@RequestParam("channelId") Long channelId) { |
| | | List<ImChannelMaterialDO> list = channelMaterialService.getMaterialListByChannelId(channelId); |
| | | return success(BeanUtils.toBean(list, ImChannelMaterialRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éå页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImChannelPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "é¢éä¸å¡ç ", example = "system_notice") |
| | | private String code; |
| | | |
| | | @Schema(description = "é¢éåç§°", example = "ç³»ç»") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¶æ", example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢é Response VO") |
| | | @Data |
| | | public class ImChannelRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éä¸å¡ç ", requiredMode = Schema.RequiredMode.REQUIRED, example = "system_notice") |
| | | private String code; |
| | | |
| | | @Schema(description = "é¢éåç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ç³»ç»å
Œ") |
| | | private String name; |
| | | |
| | | @Schema(description = "é¢é头å") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.channel; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Pattern; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éæ°å¢ / ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImChannelSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·ï¼ä¿®æ¹æ¶å¿
å¡«ï¼", example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éä¸å¡ç ï¼å¯ä¸", requiredMode = Schema.RequiredMode.REQUIRED, example = "system_notice") |
| | | @NotBlank(message = "é¢éç¼ç ä¸è½ä¸ºç©º") |
| | | @Size(max = 64, message = "é¢éç¼ç é¿åº¦ä¸è½è¶
è¿ 64") |
| | | @Pattern(regexp = "^[a-z][a-z0-9_]*$", message = "é¢éç¼ç åªè½ç±å°å忝 / æ°å / ä¸åçº¿ç»æï¼ä¸å¿
须以忝å¼å¤´") |
| | | private String code; |
| | | |
| | | @Schema(description = "é¢éåç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ç³»ç»å
Œ") |
| | | @NotBlank(message = "é¢éåç§°ä¸è½ä¸ºç©º") |
| | | @Size(max = 64, message = "é¢éåç§°é¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "é¢é头å", example = "https://cdn.example.com/channel/system_notice.png") |
| | | @Size(max = 512, message = "头åé¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "æåºä¸è½ä¸ºç©º") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "ç¶æä¸è½ä¸ºç©º") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 å¯ç¨ / 1 ç¦ç¨ï¼ |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éç´ æå页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImChannelMaterialPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "é¢éç¼å·", example = "1") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "å
容类å", example = "1") |
| | | private Integer type; // åè§ ImChannelMaterialTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ é¢", example = "æ´»å¨") |
| | | private String title; |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éç´ æ Response VO") |
| | | @Data |
| | | public class ImChannelMaterialRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "é¢éåç§°ï¼å
³èæ¥è¯¢å¡«å
ï¼") |
| | | private String channelName; |
| | | |
| | | @Schema(description = "å
容类å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer type; // åè§ ImChannelMaterialTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ é¢", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private String title; |
| | | |
| | | @Schema(description = "å°é¢å¾") |
| | | private String coverUrl; |
| | | |
| | | @Schema(description = "æè¦") |
| | | private String summary; |
| | | |
| | | @Schema(description = "æ£æï¼å¯ææ¬ HTML") |
| | | private String content; |
| | | |
| | | @Schema(description = "è·³è½¬é¾æ¥") |
| | | private String url; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.channel.vo.material; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éç´ ææ°å¢ / ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImChannelMaterialSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·ï¼ä¿®æ¹æ¶å¿
å¡«ï¼", example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | @NotNull(message = "é¢éç¼å·ä¸è½ä¸ºç©º") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "å
容类å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | @NotNull(message = "å
容类åä¸è½ä¸ºç©º") |
| | | private Integer type; // åè§ ImChannelMaterialTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ é¢", requiredMode = Schema.RequiredMode.REQUIRED, example = "åå䏿´»å¨æ¥å¦") |
| | | @NotBlank(message = "æ é¢ä¸è½ä¸ºç©º") |
| | | @Size(max = 128, message = "æ é¢é¿åº¦ä¸è½è¶
è¿ 128") |
| | | private String title; |
| | | |
| | | @Schema(description = "å°é¢å¾", example = "https://cdn.example.com/cover.png") |
| | | @Size(max = 512, message = "å°é¢å¾é¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String coverUrl; |
| | | |
| | | @Schema(description = "æè¦", example = "å
¨åºäºæï¼æ³è¯¦æ
çç©æ³") |
| | | @Size(max = 255, message = "æè¦é¿åº¦ä¸è½è¶
è¿ 255") |
| | | private String summary; |
| | | |
| | | @Schema(description = "æ£æï¼å¯ææ¬ HTML") |
| | | private String content; |
| | | |
| | | @Schema(description = "è·³è½¬é¾æ¥ï¼ä¸ºç©ºè¡¨ç¤ºèµ°å®¢æ·ç«¯å
置详æ
页", example = "https://example.com/activity/123") |
| | | @Size(max = 512, message = "è·³è½¬é¾æ¥é¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String url; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item.ImFacePackItemPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item.ImFacePackItemRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item.ImFacePackItemSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFacePackItemDO; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFacePackItemService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Size; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | @Tag(name = "管çåå° - IM 表æ
å
项") |
| | | @RestController |
| | | @RequestMapping("/im/manager/face-pack-item") |
| | | @Validated |
| | | public class ImFacePackItemManagerController { |
| | | |
| | | @Resource |
| | | private ImFacePackItemService facePackItemService; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ°å¢è¡¨æ
") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:create')") |
| | | public CommonResult<Long> createFacePackItem(@Valid @RequestBody ImFacePackItemSaveReqVO reqVO) { |
| | | return success(facePackItemService.createFacePackItem(reqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "ä¿®æ¹è¡¨æ
") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:update')") |
| | | public CommonResult<Boolean> updateFacePackItem(@Valid @RequestBody ImFacePackItemSaveReqVO reqVO) { |
| | | facePackItemService.updateFacePackItem(reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤è¡¨æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "2048") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:delete')") |
| | | public CommonResult<Boolean> deleteFacePackItem(@RequestParam("id") Long id) { |
| | | facePackItemService.deleteFacePackItem(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete-list") |
| | | @Operation(summary = "æ¹éå é¤è¡¨æ
") |
| | | @Parameter(name = "ids", description = "ç¼å·å表", required = true) |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:delete')") |
| | | public CommonResult<Boolean> deleteFacePackItemList( |
| | | @RequestParam("ids") @Size(max = 100, message = "æ¹éå é¤æå¤ 100 æ¡") List<Long> ids) { |
| | | facePackItemService.deleteFacePackItemList(ids); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾è¡¨æ
å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:query')") |
| | | public CommonResult<PageResult<ImFacePackItemRespVO>> getFacePackItemPage(@Valid ImFacePackItemPageReqVO pageReqVO) { |
| | | PageResult<ImFacePackItemDO> pageResult = facePackItemService.getFacePackItemPage(pageReqVO); |
| | | return success(BeanUtils.toBean(pageResult, ImFacePackItemRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾è¡¨æ
详æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "2048") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack-item:query')") |
| | | public CommonResult<ImFacePackItemRespVO> getFacePackItem(@RequestParam("id") Long id) { |
| | | ImFacePackItemDO item = facePackItemService.getFacePackItem(id); |
| | | return success(BeanUtils.toBean(item, ImFacePackItemRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack.ImFacePackPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack.ImFacePackRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack.ImFacePackSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFacePackDO; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFacePackService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Size; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | @Tag(name = "管çåå° - IM 表æ
å
") |
| | | @RestController |
| | | @RequestMapping("/im/manager/face-pack") |
| | | @Validated |
| | | public class ImFacePackManagerController { |
| | | |
| | | @Resource |
| | | private ImFacePackService facePackService; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ°å¢è¡¨æ
å
") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:create')") |
| | | public CommonResult<Long> createFacePack(@Valid @RequestBody ImFacePackSaveReqVO reqVO) { |
| | | return success(facePackService.createFacePack(reqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "ä¿®æ¹è¡¨æ
å
") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:update')") |
| | | public CommonResult<Boolean> updateFacePack(@Valid @RequestBody ImFacePackSaveReqVO reqVO) { |
| | | facePackService.updateFacePack(reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤è¡¨æ
å
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:delete')") |
| | | public CommonResult<Boolean> deleteFacePack(@RequestParam("id") Long id) { |
| | | facePackService.deleteFacePack(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete-list") |
| | | @Operation(summary = "æ¹éå é¤è¡¨æ
å
") |
| | | @Parameter(name = "ids", description = "ç¼å·å表", required = true) |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:delete')") |
| | | public CommonResult<Boolean> deleteFacePackList(@RequestParam("ids") |
| | | @Size(max = 100, message = "æ¹éå é¤æå¤ 100 æ¡") List<Long> ids) { |
| | | facePackService.deleteFacePackList(ids); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾è¡¨æ
å
å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:query')") |
| | | public CommonResult<PageResult<ImFacePackRespVO>> getFacePackPage(@Valid ImFacePackPageReqVO pageReqVO) { |
| | | PageResult<ImFacePackDO> pageResult = facePackService.getFacePackPage(pageReqVO); |
| | | return success(BeanUtils.toBean(pageResult, ImFacePackRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾è¡¨æ
å
详æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-pack:query')") |
| | | public CommonResult<ImFacePackRespVO> getFacePack(@RequestParam("id") Long id) { |
| | | ImFacePackDO pack = facePackService.getFacePack(id); |
| | | return success(BeanUtils.toBean(pack, ImFacePackRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.useritem.ImFaceUserItemManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.useritem.ImFaceUserItemManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.face.ImFaceUserItemDO; |
| | | import cn.iocoder.yudao.module.im.service.face.ImFaceUserItemService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | @Tag(name = "管çåå° - IM ç¨æ·è¡¨æ
") |
| | | @RestController |
| | | @RequestMapping("/im/manager/face-user-item") |
| | | @Validated |
| | | public class ImFaceUserItemManagerController { |
| | | |
| | | @Resource |
| | | private ImFaceUserItemService faceUserItemService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ç¨æ·è¡¨æ
å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-user-item:query')") |
| | | public CommonResult<PageResult<ImFaceUserItemManagerRespVO>> getFaceUserItemPage( |
| | | @Valid ImFaceUserItemManagerPageReqVO pageReqVO) { |
| | | PageResult<ImFaceUserItemDO> pageResult = faceUserItemService.getFaceUserItemPage(pageReqVO); |
| | | // å
³èåå¡«ç¨æ·æµç§° |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | CollectionUtils.convertSet(pageResult.getList(), ImFaceUserItemDO::getUserId)); |
| | | List<ImFaceUserItemManagerRespVO> voList = CollectionUtils.convertList(pageResult.getList(), item -> { |
| | | ImFaceUserItemManagerRespVO vo = BeanUtils.toBean(item, ImFaceUserItemManagerRespVO.class); |
| | | AdminUserRespDTO user = userMap.get(item.getUserId()); |
| | | if (user != null) { |
| | | vo.setUserNickname(user.getNickname()); |
| | | } |
| | | return vo; |
| | | }); |
| | | return success(new PageResult<>(voList, pageResult.getTotal())); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤ç¨æ·è¡¨æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "4096") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:face-user-item:delete')") |
| | | public CommonResult<Boolean> deleteFaceUserItem(@RequestParam("id") Long id) { |
| | | faceUserItemService.deleteFaceUserItem(id); |
| | | return success(true); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
项å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImFacePackItemPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "æå±è¡¨æ
å
ç¼å·", example = "1024") |
| | | private Long packId; |
| | | |
| | | @Schema(description = "表æ
åï¼æ¨¡ç³å¹é
", example = "ç") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¶æ", example = "0") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
项 Response VO") |
| | | @Data |
| | | public class ImFacePackItemRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æå±è¡¨æ
å
ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long packId; |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/pack/cat-001.png") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | private Integer height; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.item; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
项æ°å¢ / ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImFacePackItemSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·ï¼ä¿®æ¹æ¶å¿
å¡«ï¼", example = "2048") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æå±è¡¨æ
å
ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "表æ
å
ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long packId; |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/pack/cat-001.png") |
| | | @NotBlank(message = "表æ
å¾ URL ä¸è½ä¸ºç©º") |
| | | @Size(max = 512, message = "表æ
å¾ URL é¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | @Size(max = 64, message = "表æ
åé¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | @NotNull(message = "渲æå®½åº¦ä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "渲æå®½åº¦ä¸è½å°äº 1 åç´ ") |
| | | @Max(value = 2048, message = "渲æå®½åº¦ä¸è½å¤§äº 2048 åç´ ") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "200") |
| | | @NotNull(message = "渲æé«åº¦ä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "渲æé«åº¦ä¸è½å°äº 1 åç´ ") |
| | | @Max(value = 2048, message = "渲æé«åº¦ä¸è½å¤§äº 2048 åç´ ") |
| | | private Integer height; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "æåºä¸è½ä¸ºç©º") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "ç¶æä¸è½ä¸ºç©º") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 å¯ç¨ / 1 ç¦ç¨ï¼ |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImFacePackPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "表æ
å
åç§°ï¼æ¨¡ç³å¹é
", example = "ç«") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¶æ", example = "0") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
Response VO") |
| | | @Data |
| | | public class ImFacePackRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "表æ
å
åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ç«ä¸»å") |
| | | private String name; |
| | | |
| | | @Schema(description = "表æ
å
徿 ", example = "https://cdn.example.com/face/pack/cat.png") |
| | | private String icon; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.pack; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM 表æ
å
æ°å¢ / ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImFacePackSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·ï¼ä¿®æ¹æ¶å¿
å¡«ï¼", example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "表æ
å
åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ç«ä¸»å") |
| | | @NotBlank(message = "表æ
å
åç§°ä¸è½ä¸ºç©º") |
| | | @Size(max = 64, message = "表æ
å
åç§°é¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String name; |
| | | |
| | | @Schema(description = "表æ
å
徿 ", example = "https://cdn.example.com/face/pack/cat.png") |
| | | @Size(max = 512, message = "徿 é¿åº¦ä¸è½è¶
è¿ 512") |
| | | private String icon; |
| | | |
| | | @Schema(description = "æåº", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "æåºä¸è½ä¸ºç©º") |
| | | private Integer sort; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "ç¶æä¸è½ä¸ºç©º") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 å¯ç¨ / 1 ç¦ç¨ï¼ |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.useritem; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM ç¨æ·è¡¨æ
å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImFaceUserItemManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "æå±ç¨æ·ç¼å·", example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "表æ
åï¼æ¨¡ç³å¹é
", example = "ç") |
| | | private String name; |
| | | |
| | | @Schema(description = "æ·»å æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.face.vo.useritem; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM ç¨æ·è¡¨æ
Response VO") |
| | | @Data |
| | | public class ImFaceUserItemManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "4096") |
| | | private Long id; |
| | | |
| | | @Schema(description = "æå±ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "æå±ç¨æ·æµç§°", example = "å¼ ä¸") |
| | | private String userNickname; |
| | | |
| | | @Schema(description = "表æ
å¾ URL", requiredMode = Schema.RequiredMode.REQUIRED, |
| | | example = "https://cdn.example.com/face/user/abc.gif") |
| | | private String url; |
| | | |
| | | @Schema(description = "表æ
å", example = "ç头") |
| | | private String name; |
| | | |
| | | @Schema(description = "渲æå®½åº¦ï¼åç´ ï¼", example = "200") |
| | | private Integer width; |
| | | |
| | | @Schema(description = "渲æé«åº¦ï¼åç´ ï¼", example = "200") |
| | | private Integer height; |
| | | |
| | | @Schema(description = "æ·»å æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo.ImFriendManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo.ImFriendManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.friend.ImFriendDO; |
| | | import cn.iocoder.yudao.module.im.service.friend.ImFriendService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | |
| | | @Tag(name = "管çåå° - IM 好å管ç") |
| | | @RestController |
| | | @RequestMapping("/im/manager/friend") |
| | | @Validated |
| | | public class ImFriendManagerController { |
| | | |
| | | @Resource |
| | | private ImFriendService friendService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾å¥½åå
³ç³»å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:friend:query')") |
| | | public CommonResult<PageResult<ImFriendManagerRespVO>> getFriendPage( |
| | | @Valid ImFriendManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImFriendDO> pageResult = friendService.getFriendPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // 2.1 䏿¬¡æ§æ¹éæ¥è¯¢ç¨æ· + 好åçæµç§° |
| | | Set<Long> userIds = convertSetByFlatMap(pageResult.getList(), |
| | | f -> Stream.of(f.getUserId(), f.getFriendUserId())); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
æµç§° |
| | | return success(BeanUtils.toBean(pageResult, ImFriendManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getUserId(), |
| | | user -> vo.setUserNickname(user.getNickname())); |
| | | MapUtils.findAndThen(userMap, vo.getFriendUserId(), |
| | | user -> vo.setFriendNickname(user.getNickname())); |
| | | })); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo.ImFriendRequestManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo.ImFriendRequestManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.friend.ImFriendRequestDO; |
| | | import cn.iocoder.yudao.module.im.service.friend.ImFriendRequestService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | |
| | | @Tag(name = "管çåå° - IM 好åç³è¯·ç®¡ç") |
| | | @RestController |
| | | @RequestMapping("/im/manager/friend-request") |
| | | @Validated |
| | | public class ImFriendRequestManagerController { |
| | | |
| | | @Resource |
| | | private ImFriendRequestService friendRequestService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾å¥½åç³è¯·å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:friend-request:query')") |
| | | public CommonResult<PageResult<ImFriendRequestManagerRespVO>> getFriendRequestPage( |
| | | @Valid ImFriendRequestManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImFriendRequestDO> pageResult = friendRequestService.getFriendRequestPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | |
| | | // 2.1 䏿¬¡æ§æ¹éæ¥è¯¢åèµ·æ¹ + æ¥æ¶æ¹çæµç§° |
| | | Set<Long> userIds = convertSetByFlatMap(pageResult.getList(), |
| | | request -> Stream.of(request.getFromUserId(), request.getToUserId())); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
æµç§° |
| | | return success(BeanUtils.toBean(pageResult, ImFriendRequestManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getFromUserId(), |
| | | user -> vo.setFromNickname(user.getNickname())); |
| | | MapUtils.findAndThen(userMap, vo.getToUserId(), |
| | | user -> vo.setToNickname(user.getNickname())); |
| | | })); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM 好åå
³ç³»å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImFriendManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "好åç¨æ·ç¼å·", example = "2048") |
| | | private Long friendUserId; |
| | | |
| | | @Schema(description = "好åç¶æ", example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°", example = "false") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "æ·»å 好忶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] addTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 好åå
³ç³» Response VO") |
| | | @Data |
| | | public class ImFriendManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç¨æ·æµç§°", example = "å¼ ä¸") |
| | | private String userNickname; |
| | | |
| | | @Schema(description = "好åç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long friendUserId; |
| | | |
| | | @Schema(description = "å¥½åæµç§°", example = "æå") |
| | | private String friendNickname; |
| | | |
| | | @Schema(description = "好åå±ç¤ºå¤æ³¨") |
| | | private String displayName; |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImFriendAddSourceEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "false") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "æ¯å¦ç½®é¡¶è系人", requiredMode = Schema.RequiredMode.REQUIRED, example = "false") |
| | | private Boolean pinned; |
| | | |
| | | @Schema(description = "æ¯å¦æé»", requiredMode = Schema.RequiredMode.REQUIRED, example = "false") |
| | | private Boolean blocked; |
| | | |
| | | @Schema(description = "好åç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ·»å 好忶é´") |
| | | private LocalDateTime addTime; |
| | | |
| | | @Schema(description = "å é¤å¥½åæ¶é´") |
| | | private LocalDateTime deleteTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM 好åç³è¯·å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImFriendRequestManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "åèµ·æ¹ç¨æ·ç¼å·", example = "1024") |
| | | private Long fromUserId; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹ç¨æ·ç¼å·", example = "2048") |
| | | private Long toUserId; |
| | | |
| | | @Schema(description = "å¤çç»æ", example = "0") |
| | | private Integer handleResult; // åè§ ImFriendRequestHandleResultEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImFriendAddSourceEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.friend.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 好åç³è¯· Response VO") |
| | | @Data |
| | | public class ImFriendRequestManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "åèµ·æ¹ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long fromUserId; |
| | | |
| | | @Schema(description = "åèµ·æ¹æµç§°", example = "å¼ ä¸") |
| | | private String fromNickname; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long toUserId; |
| | | |
| | | @Schema(description = "æ¥æ¶æ¹æµç§°", example = "æå") |
| | | private String toNickname; |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ¯èè¿") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "åèµ·æ¹å¯¹æ¥æ¶æ¹ç夿³¨") |
| | | private String displayName; |
| | | |
| | | @Schema(description = "æ·»å æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImFriendAddSourceEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å¤çç»æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer handleResult; // åè§ ImFriendRequestHandleResultEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å¤ççç±", example = "æä¸éè¿") |
| | | private String handleContent; |
| | | |
| | | @Schema(description = "å¤çæ¶é´") |
| | | private LocalDateTime handleTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.ImGroupManagerBanReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.ImGroupManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.ImGroupManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupMemberService; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM 群è管ç") |
| | | @RestController |
| | | @RequestMapping("/im/manager/group") |
| | | @Validated |
| | | public class ImGroupManagerController { |
| | | |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | @Resource |
| | | private ImGroupMemberService groupMemberService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ç¾¤å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:query')") |
| | | public CommonResult<PageResult<ImGroupManagerRespVO>> getGroupPage(@Valid ImGroupManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ç¾¤ |
| | | PageResult<ImGroupDO> pageResult = groupService.getGroupPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // 2.1 æ¹éæ¥è¯¢ç¸å
³æ°æ® |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertSet(pageResult.getList(), ImGroupDO::getOwnerUserId)); |
| | | Map<Long, Long> memberCountMap = groupMemberService.getActiveMemberCountMap( |
| | | convertSet(pageResult.getList(), ImGroupDO::getId)); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
群主æµç§°ã群æåæ°é |
| | | return success(BeanUtils.toBean(pageResult, ImGroupManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getOwnerUserId(), |
| | | user -> vo.setOwnerNickname(user.getNickname())); |
| | | vo.setMemberCount(memberCountMap.getOrDefault(vo.getId(), 0L).intValue()); |
| | | })); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç¾¤è¯¦æ
") |
| | | @Parameter(name = "id", description = "群ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:query')") |
| | | public CommonResult<ImGroupManagerRespVO> getGroup(@RequestParam("id") Long id) { |
| | | ImGroupDO group = groupService.getGroup(id); |
| | | return success(BeanUtils.toBean(group, ImGroupManagerRespVO.class)); |
| | | } |
| | | |
| | | @PutMapping("/ban") |
| | | @Operation(summary = "å°ç¦ç¾¤") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:ban')") |
| | | public CommonResult<Boolean> banGroup(@Valid @RequestBody ImGroupManagerBanReqVO reqVO) { |
| | | groupService.banGroup(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/unban") |
| | | @Operation(summary = "è§£å°ç¾¤") |
| | | @Parameter(name = "id", description = "群ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:ban')") |
| | | public CommonResult<Boolean> unbanGroup(@RequestParam("id") Long id) { |
| | | groupService.unbanGroup(getLoginUserId(), id); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/dissolve") |
| | | @Operation(summary = "è§£æ£ç¾¤") |
| | | @Parameter(name = "id", description = "群ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:dissolve')") |
| | | public CommonResult<Boolean> dissolveGroup(@RequestParam("id") Long id) { |
| | | groupService.dissolveGroupByManager(getLoginUserId(), id); |
| | | return success(true); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.member.ImGroupMemberManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupMemberDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupMemberService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | |
| | | @Tag(name = "管çåå° - IM 群æå管ç") |
| | | @RestController |
| | | @RequestMapping("/im/manager/group/member") |
| | | @Validated |
| | | public class ImGroupMemberManagerController { |
| | | |
| | | @Resource |
| | | private ImGroupMemberService groupMemberService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "è·å¾ç¾¤æåå表ï¼å«å·²é群æåï¼ç±å端æéè¿æ»¤ï¼") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group:query')") |
| | | public CommonResult<List<ImGroupMemberManagerRespVO>> getGroupMemberList(@RequestParam("groupId") Long groupId) { |
| | | // 1. æ¥è¯¢ç¾¤å
¨é¨æåï¼å«å·²éç¾¤ï¼ |
| | | List<ImGroupMemberDO> members = groupMemberService.getGroupMemberListByGroupId(groupId); |
| | | if (CollUtil.isEmpty(members)) { |
| | | return success(Collections.emptyList()); |
| | | } |
| | | // 2.1 æ¹éæ¥è¯¢ç¨æ·ä¿¡æ¯ |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertSet(members, ImGroupMemberDO::getUserId)); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
æµç§°ã头å |
| | | return success(BeanUtils.toBean(members, ImGroupMemberManagerRespVO.class, vo -> |
| | | MapUtils.findAndThen(userMap, vo.getUserId(), user -> |
| | | vo.setNickname(user.getNickname()).setAvatar(user.getAvatar())))); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.ImGroupRequestManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.ImGroupRequestManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupRequestDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupRequestService; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Map; |
| | | import java.util.Objects; |
| | | import java.util.Set; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | |
| | | @Tag(name = "管çåå° - IM å 群ç³è¯·ç®¡ç") |
| | | @RestController |
| | | @RequestMapping("/im/manager/group-request") |
| | | @Validated |
| | | public class ImGroupRequestManagerController { |
| | | |
| | | @Resource |
| | | private ImGroupRequestService groupRequestService; |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾å 群ç³è¯·å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:group-request:query')") |
| | | public CommonResult<PageResult<ImGroupRequestManagerRespVO>> getGroupRequestPage( |
| | | @Valid ImGroupRequestManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImGroupRequestDO> pageResult = groupRequestService.getGroupRequestPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | |
| | | // 2.1 æ¹éèå user / inviter / handler ç¨æ·æµç§° |
| | | Set<Long> userIds = convertSetByFlatMap(pageResult.getList(), |
| | | request -> Stream.of(request.getUserId(), request.getInviterUserId(), request.getHandleUserId()) |
| | | .filter(Objects::nonNull)); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | // 2.2 æ¹éèå群信æ¯ï¼å群åï¼ |
| | | Set<Long> groupIds = convertSet(pageResult.getList(), ImGroupRequestDO::getGroupId); |
| | | Map<Long, ImGroupDO> groupMap = groupService.getGroupMap(groupIds); |
| | | return success(BeanUtils.toBean(pageResult, ImGroupRequestManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getUserId(), user -> vo.setUserNickname(user.getNickname())); |
| | | MapUtils.findAndThen(userMap, vo.getInviterUserId(), user -> vo.setInviterNickname(user.getNickname())); |
| | | MapUtils.findAndThen(userMap, vo.getHandleUserId(), user -> vo.setHandleNickname(user.getNickname())); |
| | | MapUtils.findAndThen(groupMap, vo.getGroupId(), group -> vo.setGroupName(group.getName())); |
| | | })); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM 群èå°ç¦ Request VO") |
| | | @Data |
| | | public class ImGroupManagerBanReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long id; |
| | | |
| | | @Schema(description = "å°ç¦åå ", requiredMode = Schema.RequiredMode.REQUIRED, example = "è¿è§å
容") |
| | | @NotBlank(message = "å°ç¦åå ä¸è½ä¸ºç©º") |
| | | @Size(max = 200, message = "å°ç¦åå é¿åº¦ä¸è½è¶
è¿ 200") |
| | | private String reason; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM 群èå页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImGroupManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "群åç§°ï¼æ¨¡ç³å¹é
", example = "ææ¯äº¤æµç¾¤") |
| | | private String name; |
| | | |
| | | @Schema(description = "ç¾¤ä¸»ç¨æ·ç¼å·", example = "1024") |
| | | private Long ownerUserId; |
| | | |
| | | @Schema(description = "ç¾¤ç¶æ", example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 æ£å¸¸ / 1 已解æ£ï¼ |
| | | |
| | | @Schema(description = "æ¯å¦å°ç¦", example = "false") |
| | | private Boolean banned; |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 群è Response VO") |
| | | @Data |
| | | public class ImGroupManagerRespVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "ææ¯äº¤æµç¾¤") |
| | | private String name; |
| | | |
| | | @Schema(description = "群头å") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "群å
Œ") |
| | | private String notice; |
| | | |
| | | @Schema(description = "ç¾¤ä¸»ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long ownerUserId; |
| | | |
| | | @Schema(description = "群主æµç§°", example = "å¼ ä¸") |
| | | private String ownerNickname; |
| | | |
| | | @Schema(description = "群æåæ°é", requiredMode = Schema.RequiredMode.REQUIRED, example = "12") |
| | | private Integer memberCount; |
| | | |
| | | @Schema(description = "ç¾¤ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "è§£æ£æ¶é´") |
| | | private LocalDateTime dissolvedTime; |
| | | |
| | | @Schema(description = "æ¯å¦å°ç¦", requiredMode = Schema.RequiredMode.REQUIRED, example = "false") |
| | | private Boolean banned; |
| | | |
| | | @Schema(description = "æ¯å¦å
¨ç¾¤ç¦è¨") |
| | | private Boolean mutedAll; |
| | | |
| | | @Schema(description = "å°ç¦åå ") |
| | | private String bannedReason; |
| | | |
| | | @Schema(description = "å°ç¦æ¶é´") |
| | | private LocalDateTime bannedTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM å 群ç³è¯·å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImGroupRequestManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "群ç¼å·", example = "1024") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被éè¯·äººç¨æ·ç¼å·", example = "2048") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "éè¯·äººç¨æ·ç¼å·", example = "31460") |
| | | private Long inviterUserId; |
| | | |
| | | @Schema(description = "å¤çç»æ", example = "0") |
| | | private Integer handleResult; // åè§ ImGroupRequestHandleResultEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å å
¥æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImGroupAddSourceEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM å 群ç³è¯· Response VO") |
| | | @Data |
| | | public class ImGroupRequestManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "群åç§°", example = "èéææ¯äº¤æµç¾¤") |
| | | private String groupName; |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被éè¯·äººç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "100") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç³è¯·äºº / 被é请人æµç§°", example = "å¼ ä¸") |
| | | private String userNickname; |
| | | |
| | | @Schema(description = "éè¯·äººç¨æ·ç¼å·ï¼NULL è¡¨ç¤ºç¨æ·ä¸»å¨ç³è¯·", example = "200") |
| | | private Long inviterUserId; |
| | | |
| | | @Schema(description = "é请人æµç§°", example = "èå¼ ") |
| | | private String inviterNickname; |
| | | |
| | | @Schema(description = "ç³è¯·çç±", example = "ææ³å å
¥è¿ä¸ªç¾¤") |
| | | private String applyContent; |
| | | |
| | | @Schema(description = "å å
¥æ¥æº", example = "1") |
| | | private Integer addSource; // åè§ ImGroupAddSourceEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å¤çç»æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer handleResult; // åè§ ImGroupRequestHandleResultEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å¤çäººç¨æ·ç¼å·", example = "31460") |
| | | private Long handleUserId; |
| | | |
| | | @Schema(description = "å¤ç人æµç§°", example = "管çå") |
| | | private String handleNickname; |
| | | |
| | | @Schema(description = "å¤ççç±", example = "æä¸éè¿") |
| | | private String handleContent; |
| | | |
| | | @Schema(description = "å¤çæ¶é´") |
| | | private LocalDateTime handleTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.group.vo.member; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM 群æå Response VO") |
| | | @Data |
| | | public class ImGroupMemberManagerRespVO { |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç¨æ·æµç§°", example = "å¼ ä¸") |
| | | private String nickname; |
| | | |
| | | @Schema(description = "ç¨æ·å¤´å") |
| | | private String avatar; |
| | | |
| | | @Schema(description = "ç»å
æ¾ç¤ºå", example = "ä¸å¥") |
| | | private String displayUserName; |
| | | |
| | | @Schema(description = "ç¾¤å¤æ³¨", example = "ææ¯äº¤æµç¾¤") |
| | | private String groupRemark; |
| | | |
| | | @Schema(description = "æ¯å¦å
ææ°", example = "false") |
| | | private Boolean silent; |
| | | |
| | | @Schema(description = "æåç¶æ", example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æåè§è²ï¼1=群主 2=管çå 3=æ®éæå", example = "3") |
| | | private Integer role; // åè§ ImGroupMemberRoleEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å
¥ç¾¤æ¶é´") |
| | | private LocalDateTime joinTime; |
| | | |
| | | @Schema(description = "é群æ¶é´") |
| | | private LocalDateTime quitTime; |
| | | |
| | | @Schema(description = "ç¦è¨å°ææ¶é´") |
| | | private LocalDateTime muteEndTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel.ImChannelMessagePageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel.ImChannelMessageRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel.ImChannelMessageSendReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelMaterialDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImChannelMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelMaterialService; |
| | | import cn.iocoder.yudao.module.im.service.message.ImChannelMessageService; |
| | | import cn.iocoder.yudao.module.im.service.channel.ImChannelService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | |
| | | @Tag(name = "管çåå° - IM é¢éæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/manager/channel-message") |
| | | @Validated |
| | | public class ImChannelMessageManagerController { |
| | | |
| | | @Resource |
| | | private ImChannelMessageService channelMessageService; |
| | | @Resource |
| | | private ImChannelService channelService; |
| | | @Resource |
| | | private ImChannelMaterialService channelMaterialService; |
| | | |
| | | @PostMapping("/send") |
| | | @Operation(summary = "ç«å³æ¨éé¢éæ¶æ¯") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-message:send')") |
| | | public CommonResult<Long> sendMessage(@Valid @RequestBody ImChannelMessageSendReqVO reqVO) { |
| | | return success(channelMessageService.sendMessage(reqVO)); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å é¤é¢éæ¶æ¯") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-message:delete')") |
| | | public CommonResult<Boolean> deleteMessage(@RequestParam("id") Long id) { |
| | | channelMessageService.deleteMessage(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾é¢éæ¶æ¯å页ï¼åå¡«é¢éå / ç´ ææ é¢") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:channel-message:query')") |
| | | public CommonResult<PageResult<ImChannelMessageRespVO>> getMessagePage(@Valid ImChannelMessagePageReqVO pageReqVO) { |
| | | PageResult<ImChannelMessageDO> pageResult = channelMessageService.getMessagePage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // æ¹éæ¥è¯¢é¢éåç´ æï¼å¹¶åå¡«é¢éå / ç´ ææ é¢ |
| | | Map<Long, ImChannelDO> channelMap = channelService.getChannelMap( |
| | | convertSet(pageResult.getList(), ImChannelMessageDO::getChannelId)); |
| | | Map<Long, ImChannelMaterialDO> materialMap = channelMaterialService.getMaterialMap( |
| | | convertSet(pageResult.getList(), ImChannelMessageDO::getMaterialId)); |
| | | return success(BeanUtils.toBean(pageResult, ImChannelMessageRespVO.class, vo -> { |
| | | MapUtils.findAndThen(channelMap, vo.getChannelId(), c -> vo.setChannelName(c.getName())); |
| | | MapUtils.findAndThen(materialMap, vo.getMaterialId(), |
| | | material -> vo.setMaterialTitle(material.getTitle()).setMaterialCoverUrl(material.getCoverUrl())); |
| | | })); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.group.ImGroupMessageManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.group.ImGroupMessageManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImGroupMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.im.service.message.ImGroupMessageService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Map; |
| | | import java.util.Objects; |
| | | import java.util.Set; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | import static cn.iocoder.yudao.module.im.enums.ImCommonConstants.AT_USER_ID_ALL; |
| | | |
| | | @Tag(name = "管çåå° - IM ç¾¤èæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/manager/message/group") |
| | | @Validated |
| | | public class ImGroupMessageManagerController { |
| | | |
| | | @Resource |
| | | private ImGroupMessageService groupMessageService; |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ç¾¤èæ¶æ¯å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:message:query')") |
| | | public CommonResult<PageResult<ImGroupMessageManagerRespVO>> getGroupMessagePage( |
| | | @Valid ImGroupMessageManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImGroupMessageDO> pageResult = groupMessageService.getGroupMessagePage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // 2.1 æ¹éæ¥è¯¢ç¾¤åç§°ãåé人æµç§°ã@ ç¨æ·æµç§°ï¼-1 表示 @ææäººï¼è·³è¿æ¥è¯¢ï¼ç±åç«¯å¤ææ¸²æï¼ |
| | | Map<Long, ImGroupDO> groupMap = groupService.getGroupMap( |
| | | convertSet(pageResult.getList(), ImGroupMessageDO::getGroupId)); |
| | | Set<Long> userIds = convertSetByFlatMap(pageResult.getList(), m -> Stream.concat( |
| | | Stream.of(m.getSenderId()), |
| | | CollUtil.emptyIfNull(m.getAtUserIds()).stream() |
| | | .filter(id -> !Objects.equals(id, AT_USER_ID_ALL)))); |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(userIds); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
群å / åé人æµç§° / @ ç¨æ·æµç§°ï¼-1 ä½ç½®ç nullï¼ç±å端å±ç¤ºã@ææäººãï¼ |
| | | return success(BeanUtils.toBean(pageResult, ImGroupMessageManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(groupMap, vo.getGroupId(), group -> vo.setGroupName(group.getName())); |
| | | MapUtils.findAndThen(userMap, vo.getSenderId(), user -> vo.setSenderNickname(user.getNickname())); |
| | | if (CollUtil.isNotEmpty(vo.getAtUserIds())) { |
| | | vo.setAtUserNicknames(convertList(vo.getAtUserIds(), id -> { |
| | | AdminUserRespDTO user = userMap.get(id); |
| | | return user != null ? user.getNickname() : null; |
| | | })); |
| | | } |
| | | })); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç¾¤èæ¶æ¯è¯¦æ
") |
| | | @Parameter(name = "id", description = "æ¶æ¯ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:message:query')") |
| | | public CommonResult<ImGroupMessageManagerRespVO> getGroupMessage(@RequestParam("id") Long id) { |
| | | ImGroupMessageDO message = groupMessageService.getGroupMessage(id); |
| | | return success(BeanUtils.toBean(message, ImGroupMessageManagerRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.privates.ImPrivateMessageManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.privates.ImPrivateMessageManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImPrivateMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.message.ImPrivateMessageService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Map; |
| | | import java.util.stream.Stream; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSetByFlatMap; |
| | | |
| | | @Tag(name = "管çåå° - IM ç§èæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/manager/message/private") |
| | | @Validated |
| | | public class ImPrivateMessageManagerController { |
| | | |
| | | @Resource |
| | | private ImPrivateMessageService privateMessageService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ç§èæ¶æ¯å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:message:query')") |
| | | public CommonResult<PageResult<ImPrivateMessageManagerRespVO>> getPrivateMessagePage( |
| | | @Valid ImPrivateMessageManagerPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImPrivateMessageDO> pageResult = privateMessageService.getPrivateMessagePage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // 2.1 䏿¬¡æ§æ¹éæ¥è¯¢åé人 + æ¥æ¶äººæµç§° |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(convertSetByFlatMap(pageResult.getList(), |
| | | m -> Stream.of(m.getSenderId(), m.getReceiverId()))); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
æµç§° |
| | | return success(BeanUtils.toBean(pageResult, ImPrivateMessageManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getSenderId(), user -> vo.setSenderNickname(user.getNickname())); |
| | | MapUtils.findAndThen(userMap, vo.getReceiverId(), user -> vo.setReceiverNickname(user.getNickname())); |
| | | })); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ç§èæ¶æ¯è¯¦æ
") |
| | | @Parameter(name = "id", description = "æ¶æ¯ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:message:query')") |
| | | public CommonResult<ImPrivateMessageManagerRespVO> getPrivateMessage(@RequestParam("id") Long id) { |
| | | ImPrivateMessageDO message = privateMessageService.getPrivateMessage(id); |
| | | return success(BeanUtils.toBean(message, ImPrivateMessageManagerRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éæ¶æ¯å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImChannelMessagePageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "é¢éç¼å·", example = "1") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "ç´ æç¼å·", example = "1024") |
| | | private Long materialId; |
| | | |
| | | @Schema(description = "åéæ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éæ¶æ¯ Response VO") |
| | | @Data |
| | | public class ImChannelMessageRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "é¢éåç§°ï¼å
³èæ¥è¯¢å¡«å
ï¼") |
| | | private String channelName; |
| | | |
| | | @Schema(description = "ç´ æç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long materialId; |
| | | |
| | | @Schema(description = "ç´ ææ é¢ï¼å
³èæ¥è¯¢å¡«å
ï¼") |
| | | private String materialTitle; |
| | | |
| | | @Schema(description = "ç´ æå°é¢ URLï¼å
³èæ¥è¯¢å¡«å
ï¼") |
| | | private String materialCoverUrl; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "125") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼payload JSON å¿«ç
§") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·å表ï¼ä¸ºç©ºè¡¨ç¤ºå
¨å") |
| | | private List<Long> receiverUserIds; |
| | | |
| | | @Schema(description = "åéæ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.channel; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - IM é¢éæ¶æ¯æ¨é Request VO") |
| | | @Data |
| | | public class ImChannelMessageSendReqVO { |
| | | |
| | | @Schema(description = "ç´ æç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | @NotNull(message = "ç´ æç¼å·ä¸è½ä¸ºç©º") |
| | | private Long materialId; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·å表ï¼ä¸ºç©ºè¡¨ç¤ºå
¨å", example = "[1024, 2048]") |
| | | private List<Long> receiverUserIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.group; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM ç¾¤èæ¶æ¯å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImGroupMessageManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "群ç¼å·", example = "1024") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "åé人ç¼å·", example = "1024") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", example = "1") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯å
容", example = "ä½ å¥½") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", example = "0") |
| | | private Integer status; // åè§ ImMessageStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.group; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | @Schema(description = "管çåå° - IM ç¾¤èæ¶æ¯ Response VO") |
| | | @Data |
| | | public class ImGroupMessageManagerRespVO { |
| | | |
| | | @Schema(description = "æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", example = "c-uuid-xxx") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "群åç§°", example = "ææ¯äº¤æµç¾¤") |
| | | private String groupName; |
| | | |
| | | @Schema(description = "åé人ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "åé人æµç§°", example = "å¼ ä¸") |
| | | private String senderNickname; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼JSON æ ¼å¼ï¼", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ ImMessageStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "@ ç®æ ç¨æ·ç¼å·å表ï¼-1 表示 @ææäººï¼") |
| | | private List<Long> atUserIds; |
| | | @Schema(description = "@ ç®æ ç¨æ·æµç§°å表ï¼-1 ä½ç½®ä¸º nullï¼åç«¯æ ¹æ® atUserIds èªè¡å±ç¤ºã@ææäººãï¼") |
| | | private List<String> atUserNicknames; |
| | | |
| | | @Schema(description = "åæ§ç¶æ", example = "0") |
| | | private Integer receiptStatus; // åè§ ImMessageReceiptStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime sendTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.privates; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM ç§èæ¶æ¯å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImPrivateMessageManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "åé人ç¼å·", example = "1024") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·", example = "2048") |
| | | private Long receiverId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", example = "1") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯å
容", example = "ä½ å¥½") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", example = "0") |
| | | private Integer status; // åè§ ImMessageStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.message.vo.privates; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM ç§èæ¶æ¯ Response VO") |
| | | @Data |
| | | public class ImPrivateMessageManagerRespVO { |
| | | |
| | | @Schema(description = "æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", example = "c-uuid-xxx") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "åé人ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "åé人æµç§°", example = "å¼ ä¸") |
| | | private String senderNickname; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long receiverId; |
| | | |
| | | @Schema(description = "æ¥æ¶äººæµç§°", example = "æå") |
| | | private String receiverNickname; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼JSON æ ¼å¼ï¼", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ ImMessageStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åæ§ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer receiptStatus; // åè§ ImMessageReceiptStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime sendTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.rtc; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo.ImRtcCallManagerPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo.ImRtcCallManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo.ImRtcParticipantManagerRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.rtc.ImRtcCallDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.rtc.ImRtcParticipantDO; |
| | | import cn.iocoder.yudao.module.im.service.group.ImGroupService; |
| | | import cn.iocoder.yudao.module.im.service.rtc.ImRtcCallService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | |
| | | @Tag(name = "管çåå° - IM éè¯è®°å½") |
| | | @RestController |
| | | @RequestMapping("/im/manager/rtc") |
| | | @Validated |
| | | public class ImRtcCallManagerController { |
| | | |
| | | @Resource |
| | | private ImRtcCallService rtcCallService; |
| | | @Resource |
| | | private ImGroupService groupService; |
| | | |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾éè¯è®°å½å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:rtc:query')") |
| | | public CommonResult<PageResult<ImRtcCallManagerRespVO>> getCallPage(@Valid ImRtcCallManagerPageReqVO pageReqVO) { |
| | | PageResult<ImRtcCallDO> pageResult = rtcCallService.getCallPage(pageReqVO); |
| | | return success(buildCallRespVOPage(pageResult)); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾éè¯è®°å½è¯¦æ
") |
| | | @Parameter(name = "id", description = "éè¯ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:rtc:query')") |
| | | public CommonResult<ImRtcCallManagerRespVO> getCall(@RequestParam("id") Long id) { |
| | | ImRtcCallDO call = rtcCallService.getCall(id); |
| | | if (call == null) { |
| | | return success(null); |
| | | } |
| | | return success(CollUtil.getFirst(buildCallRespVOList(Collections.singletonList(call)))); |
| | | } |
| | | |
| | | @GetMapping("/participant-list") |
| | | @Operation(summary = "è·å¾éè¯åä¸è
å表") |
| | | @Parameter(name = "id", description = "éè¯ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:rtc:query')") |
| | | public CommonResult<List<ImRtcParticipantManagerRespVO>> getCallParticipantList(@RequestParam("id") Long id) { |
| | | List<ImRtcParticipantDO> participants = rtcCallService.getCallParticipantListByCallId(id); |
| | | if (CollUtil.isEmpty(participants)) { |
| | | return success(Collections.emptyList()); |
| | | } |
| | | // æ¥è¯¢ç¨æ·ä¿¡æ¯ |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertSet(participants, ImRtcParticipantDO::getUserId)); |
| | | // ç»è£
è¿å |
| | | return success(BeanUtils.toBean(participants, ImRtcParticipantManagerRespVO.class, vo -> |
| | | MapUtils.findAndThen(userMap, vo.getUserId(), |
| | | user -> vo.setUserNickname(user.getNickname())))); |
| | | } |
| | | |
| | | // ========== ç§ææ¹æ³ï¼VO ç»è£
========== |
| | | |
| | | private PageResult<ImRtcCallManagerRespVO> buildCallRespVOPage(PageResult<ImRtcCallDO> pageResult) { |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return PageResult.empty(pageResult.getTotal()); |
| | | } |
| | | return new PageResult<>(buildCallRespVOList(pageResult.getList()), pageResult.getTotal()); |
| | | } |
| | | |
| | | private List<ImRtcCallManagerRespVO> buildCallRespVOList(List<ImRtcCallDO> calls) { |
| | | // æ¥è¯¢ç¨æ·ä¿¡æ¯ |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap( |
| | | convertSet(calls, ImRtcCallDO::getInviterUserId)); |
| | | Map<Long, ImGroupDO> groupMap = groupService.getGroupMap( |
| | | convertSet(calls, ImRtcCallDO::getGroupId)); |
| | | // ç»è£
è¿å |
| | | return BeanUtils.toBean(calls, ImRtcCallManagerRespVO.class, vo -> { |
| | | MapUtils.findAndThen(userMap, vo.getInviterUserId(), |
| | | user -> vo.setInviterNickname(user.getNickname())); |
| | | MapUtils.findAndThen(groupMap, vo.getGroupId(), |
| | | group -> vo.setGroupName(group.getName())); |
| | | }); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM éè¯è®°å½å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImRtcCallManagerPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "åèµ·äººç¨æ·ç¼å·", example = "1024") |
| | | private Long inviterUserId; |
| | | |
| | | @Schema(description = "ä¼è¯ç±»å", example = "1") |
| | | private Integer conversationType; // åè§ ImConversationTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åªä½ç±»å", example = "1") |
| | | private Integer mediaType; // åè§ ImRtcCallMediaTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "éè¯ç¶æ", example = "10") |
| | | private Integer status; // åè§ ImRtcCallStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "ç»æåå ", example = "1") |
| | | private Integer endReason; // åè§ ImRtcCallEndReasonEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åèµ·æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] startTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM éè¯è®°å½ Response VO") |
| | | @Data |
| | | public class ImRtcCallManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ä¸å¡éè¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "uuid-xxx") |
| | | private String room; |
| | | |
| | | @Schema(description = "ä¼è¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer conversationType; // åè§ ImConversationTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åªä½ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer mediaType; // åè§ ImRtcCallMediaTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åèµ·äººç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long inviterUserId; |
| | | |
| | | @Schema(description = "å起人æµç§°", example = "å¼ ä¸") |
| | | private String inviterNickname; |
| | | |
| | | @Schema(description = "群ç¼å·ï¼ç§è为空", example = "999") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "群åç§°ï¼ç§è为空", example = "æµè¯ç¾¤") |
| | | private String groupName; |
| | | |
| | | @Schema(description = "éè¯ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "10") |
| | | private Integer status; // åè§ ImRtcCallStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "ç»æåå ", example = "1") |
| | | private Integer endReason; // åè§ ImRtcCallEndReasonEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åèµ·æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime startTime; |
| | | |
| | | @Schema(description = "æ¥éæ¶é´ï¼æªæ¥é为空") |
| | | private LocalDateTime acceptTime; |
| | | |
| | | @Schema(description = "ç»ææ¶é´ï¼æªç»æä¸ºç©º") |
| | | private LocalDateTime endTime; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.rtc.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM éè¯åä¸è
Response VO") |
| | | @Data |
| | | public class ImRtcParticipantManagerRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "éè¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2048") |
| | | private Long callId; |
| | | |
| | | @Schema(description = "åä¸è
ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "åä¸è
æµç§°", example = "å¼ ä¸") |
| | | private String userNickname; |
| | | |
| | | @Schema(description = "åä¸è§è²", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Integer role; // åè§ ImRtcParticipantRoleEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åä¸ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "20") |
| | | private Integer status; // åè§ ImRtcParticipantStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "被é请æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime inviteTime; |
| | | |
| | | @Schema(description = "æ¥å¬æ¶é´ï¼æªæ¥å¬ä¸ºç©º") |
| | | private LocalDateTime acceptTime; |
| | | |
| | | @Schema(description = "ç¦»å¼æ¶é´ï¼æªå å
¥ä¸ºç©º") |
| | | private LocalDateTime leaveTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.number.NumberUtils; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo.ImSensitiveWordPageReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo.ImSensitiveWordRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo.ImSensitiveWordSaveReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.sensitiveword.ImSensitiveWordDO; |
| | | import cn.iocoder.yudao.module.im.service.sensitiveword.ImSensitiveWordService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Size; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | |
| | | @Tag(name = "管çåå° - IM ææè¯") |
| | | @RestController |
| | | @RequestMapping("/im/manager/sensitive-word") |
| | | @Validated |
| | | public class ImSensitiveWordManagerController { |
| | | |
| | | @Resource |
| | | private ImSensitiveWordService sensitiveWordService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "æ°å¢ææè¯") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:create')") |
| | | public CommonResult<Long> createSensitiveWord(@Valid @RequestBody ImSensitiveWordSaveReqVO reqVO) { |
| | | return success(sensitiveWordService.createSensitiveWord(reqVO)); |
| | | } |
| | | |
| | | @PutMapping("/update") |
| | | @Operation(summary = "ä¿®æ¹ææè¯") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:update')") |
| | | public CommonResult<Boolean> updateSensitiveWord(@Valid @RequestBody ImSensitiveWordSaveReqVO reqVO) { |
| | | sensitiveWordService.updateSensitiveWord(reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "å 餿æè¯") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:delete')") |
| | | public CommonResult<Boolean> deleteSensitiveWord(@RequestParam("id") Long id) { |
| | | sensitiveWordService.deleteSensitiveWord(id); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete-list") |
| | | @Operation(summary = "æ¹éå 餿æè¯") |
| | | @Parameter(name = "ids", description = "ç¼å·å表", required = true) |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:delete')") |
| | | public CommonResult<Boolean> deleteSensitiveWordList( |
| | | @RequestParam("ids") |
| | | @Size(max = 100, message = "æ¹éå é¤æå¤ 100 æ¡") List<Long> ids) { |
| | | sensitiveWordService.deleteSensitiveWordList(ids); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/page") |
| | | @Operation(summary = "è·å¾ææè¯å页") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:query')") |
| | | public CommonResult<PageResult<ImSensitiveWordRespVO>> getSensitiveWordPage( |
| | | @Valid ImSensitiveWordPageReqVO pageReqVO) { |
| | | // 1. å页æ¥è¯¢ |
| | | PageResult<ImSensitiveWordDO> pageResult = sensitiveWordService.getSensitiveWordPage(pageReqVO); |
| | | if (CollUtil.isEmpty(pageResult.getList())) { |
| | | return success(PageResult.empty(pageResult.getTotal())); |
| | | } |
| | | // 2.1 æ¹éæ¥è¯¢å建人æµç§° |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(convertSet(pageResult.getList(), |
| | | word -> NumberUtils.parseLong(word.getCreator()))); |
| | | // 2.2 转æ¢ä¸º VOï¼å¡«å
å建人æµç§° |
| | | return success(BeanUtils.toBean(pageResult, ImSensitiveWordRespVO.class, vo -> |
| | | MapUtils.findAndThen(userMap, NumberUtils.parseLong(vo.getCreator()), |
| | | user -> vo.setCreatorName(user.getNickname())))); |
| | | } |
| | | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "è·å¾ææè¯è¯¦æ
") |
| | | @Parameter(name = "id", description = "ç¼å·", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:sensitive-word:query')") |
| | | public CommonResult<ImSensitiveWordRespVO> getSensitiveWord(@RequestParam("id") Long id) { |
| | | ImSensitiveWordDO word = sensitiveWordService.getSensitiveWord(id); |
| | | return success(BeanUtils.toBean(word, ImSensitiveWordRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND; |
| | | |
| | | @Schema(description = "管çåå° - IM ææè¯å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ImSensitiveWordPageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "ææè¯ï¼æ¨¡ç³å¹é
", example = "ææ") |
| | | private String word; |
| | | |
| | | @Schema(description = "ç¶æ", example = "0") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 å¯ç¨ / 1 ç¦ç¨ï¼ |
| | | |
| | | @Schema(description = "å建æ¶é´", example = "[2026-04-01 00:00:00, 2026-04-30 23:59:59]") |
| | | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| | | private LocalDateTime[] createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "管çåå° - IM ææè¯ Response VO") |
| | | @Data |
| | | public class ImSensitiveWordRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ææè¯", requiredMode = Schema.RequiredMode.REQUIRED, example = "ææè¯å
容") |
| | | private String word; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å建人") |
| | | private String creator; |
| | | @Schema(description = "å建人æµç§°", example = "å¼ ä¸") |
| | | private String creatorName; |
| | | |
| | | @Schema(description = "å建æ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime createTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.sensitiveword.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import jakarta.validation.constraints.Size; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM ææè¯æ°å¢ / ä¿®æ¹ Request VO") |
| | | @Data |
| | | public class ImSensitiveWordSaveReqVO { |
| | | |
| | | @Schema(description = "ç¼å·ï¼ä¿®æ¹æ¶å¿
å¡«ï¼", example = "1024") |
| | | private Long id; |
| | | |
| | | @Schema(description = "ææè¯", requiredMode = Schema.RequiredMode.REQUIRED, example = "ææè¯å
容") |
| | | @NotBlank(message = "ææè¯ä¸è½ä¸ºç©º") |
| | | @Size(max = 64, message = "ææè¯é¿åº¦ä¸è½è¶
è¿ 64") |
| | | private String word; |
| | | |
| | | @Schema(description = "ç¶æ", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "ç¶æä¸è½ä¸ºç©º") |
| | | @InEnum(value = CommonStatusEnum.class, message = "ç¶æå¿
é¡»æ¯ {value}") |
| | | private Integer status; // åè§ CommonStatusEnum æä¸¾ç±»ï¼0 å¯ç¨ / 1 ç¦ç¨ï¼ |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.MapUtils; |
| | | import cn.iocoder.yudao.framework.common.util.date.LocalDateTimeUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo.*; |
| | | import cn.iocoder.yudao.module.im.service.statistics.ImStatisticsManagerService; |
| | | import cn.iocoder.yudao.module.system.api.user.AdminUserApi; |
| | | import cn.iocoder.yudao.module.system.api.user.dto.AdminUserRespDTO; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import org.springframework.security.access.prepost.PreAuthorize; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.util.*; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| | | |
| | | @Tag(name = "管çåå° - IM æ°æ®çæ¿") |
| | | @RestController |
| | | @RequestMapping("/im/manager/statistics") |
| | | @Validated |
| | | public class ImStatisticsManagerController { |
| | | |
| | | /** |
| | | * ç¾¤è§æ¨¡åæ¡¶åç§°çå±ç¤ºé¡ºåº |
| | | */ |
| | | private static final List<String> GROUP_SIZE_BUCKETS = Arrays.asList("1-9 人", "10-49 人", "50-199 人", "200+ 人"); |
| | | /** |
| | | * çæ¿åå¸é»è®¤æ¶é´çªå£ï¼å¤©ï¼ |
| | | */ |
| | | private static final int DISTRIBUTION_WINDOW_DAYS = 30; |
| | | /** |
| | | * TOP åéè
æ°é |
| | | */ |
| | | private static final int TOP_SENDER_LIMIT = 10; |
| | | |
| | | @Resource |
| | | private ImStatisticsManagerService statisticsService; |
| | | @Resource |
| | | private AdminUserApi adminUserApi; |
| | | |
| | | @GetMapping("/overview") |
| | | @Operation(summary = "è·å¾æ°æ®æ¦è§") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<ImStatisticsManagerOverviewRespVO> getOverview() { |
| | | LocalDateTime todayBegin = LocalDate.now().atStartOfDay(); |
| | | LocalDateTime tomorrowBegin = todayBegin.plusDays(1); |
| | | LocalDateTime yesterdayBegin = todayBegin.minusDays(1); |
| | | // 卿´»/ææ´»å®ä¹ä¸º N 天æ»å¨çªå£ï¼å«ä»å¤©ï¼ |
| | | LocalDateTime weekBegin = todayBegin.minusDays(6); |
| | | LocalDateTime monthBegin = todayBegin.minusDays(29); |
| | | return success(new ImStatisticsManagerOverviewRespVO() |
| | | .setTotalUser(statisticsService.getTotalUserCount()) |
| | | .setNewUserToday(statisticsService.getNewUserCount(todayBegin, tomorrowBegin)) |
| | | .setTotalGroup(statisticsService.getTotalGroupCount()) |
| | | .setNewGroupToday(statisticsService.getNewGroupCount(todayBegin, tomorrowBegin)) |
| | | .setActiveUserDaily(statisticsService.getActiveUserCount(todayBegin, tomorrowBegin)) |
| | | .setActiveUserWeekly(statisticsService.getActiveUserCount(weekBegin, tomorrowBegin)) |
| | | .setActiveUserMonthly(statisticsService.getActiveUserCount(monthBegin, tomorrowBegin)) |
| | | .setPrivateMessageToday(statisticsService.getPrivateMessageCount(todayBegin, tomorrowBegin)) |
| | | .setGroupMessageToday(statisticsService.getGroupMessageCount(todayBegin, tomorrowBegin)) |
| | | .setPrivateMessageYesterday(statisticsService.getPrivateMessageCount(yesterdayBegin, todayBegin)) |
| | | .setGroupMessageYesterday(statisticsService.getGroupMessageCount(yesterdayBegin, todayBegin))); |
| | | } |
| | | |
| | | @GetMapping("/message-trend") |
| | | @Operation(summary = "è·å¾æ¶æ¯è¶å¿ï¼ç§è / 群èå线ï¼") |
| | | @Parameter(name = "days", description = "åç天æ°ï¼å«ä»æ¥ï¼", example = "7") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<ImStatisticsManagerTrendRespVO> getMessageTrend( |
| | | @RequestParam(value = "days", defaultValue = "7") @Min(1) @Max(90) int days) { |
| | | List<LocalDateTime> dates = LocalDateTimeUtils.getLatestDays(days); |
| | | LocalDateTime beginTime = dates.get(0); |
| | | LocalDateTime endTime = dates.get(days - 1).plusDays(1); |
| | | Map<LocalDateTime, Long> privateMap = statisticsService.getPrivateMessageDailyCountMap(beginTime, endTime); |
| | | Map<LocalDateTime, Long> groupMap = statisticsService.getGroupMessageDailyCountMap(beginTime, endTime); |
| | | // è½¬æ¢æ ¼å¼ |
| | | Map<String, List<Long>> series = new LinkedHashMap<>(); |
| | | series.put("private", alignSeries(dates, privateMap)); |
| | | series.put("group", alignSeries(dates, groupMap)); |
| | | return success(new ImStatisticsManagerTrendRespVO().setDates(dates).setSeries(series)); |
| | | } |
| | | |
| | | @GetMapping("/user-trend") |
| | | @Operation(summary = "è·å¾ç¨æ·è¶å¿ï¼æ°å¢æ³¨å / æ¥æ´»å线ï¼") |
| | | @Parameter(name = "days", description = "åç天æ°ï¼å«ä»æ¥ï¼", example = "7") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<ImStatisticsManagerTrendRespVO> getUserTrend( |
| | | @RequestParam(value = "days", defaultValue = "7") @Min(1) @Max(90) int days) { |
| | | List<LocalDateTime> dates = LocalDateTimeUtils.getLatestDays(days); |
| | | LocalDateTime beginTime = dates.get(0); |
| | | LocalDateTime endTime = dates.get(days - 1).plusDays(1); |
| | | Map<LocalDateTime, Long> registerMap = statisticsService.getNewUserDailyCountMap(beginTime, endTime); |
| | | Map<LocalDateTime, Long> activeMap = statisticsService.getActiveUserDailyCountMap(beginTime, endTime); |
| | | // è½¬æ¢æ ¼å¼ |
| | | Map<String, List<Long>> series = new LinkedHashMap<>(); |
| | | series.put("register", alignSeries(dates, registerMap)); |
| | | series.put("active", alignSeries(dates, activeMap)); |
| | | return success(new ImStatisticsManagerTrendRespVO().setDates(dates).setSeries(series)); |
| | | } |
| | | |
| | | @GetMapping("/message-type-distribution") |
| | | @Operation(summary = "è·å¾å
容类ååå¸ï¼æè¿ 30 天ï¼") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<List<ImStatisticsManagerMessageTypeRespVO>> getMessageTypeDistribution() { |
| | | LocalDateTime endTime = LocalDate.now().plusDays(1).atStartOfDay(); |
| | | LocalDateTime beginTime = endTime.minusDays(DISTRIBUTION_WINDOW_DAYS); |
| | | Map<Integer, Long> typeCountMap = statisticsService.getMessageTypeCountMap(beginTime, endTime); |
| | | // è½¬æ¢æ ¼å¼ |
| | | return success(convertList(typeCountMap.entrySet(), entry -> new ImStatisticsManagerMessageTypeRespVO() |
| | | .setType(entry.getKey()).setValue(entry.getValue()))); |
| | | } |
| | | |
| | | @GetMapping("/group-size-distribution") |
| | | @Operation(summary = "è·å¾ç¾¤è§æ¨¡åå¸") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<List<ImStatisticsManagerGroupSizeRespVO>> getGroupSizeDistribution() { |
| | | Map<String, Long> groupSizeMap = statisticsService.getGroupSizeCountMap(); |
| | | // è½¬æ¢æ ¼å¼ |
| | | return success(convertList(GROUP_SIZE_BUCKETS, bucket -> new ImStatisticsManagerGroupSizeRespVO() |
| | | .setRange(bucket).setCount(groupSizeMap.getOrDefault(bucket, 0L)))); |
| | | } |
| | | |
| | | @GetMapping("/top-senders") |
| | | @Operation(summary = "è·å¾æ¶æ¯ TOP åéè
ï¼æè¿ 30 天ï¼") |
| | | @PreAuthorize("@ss.hasPermission('im:manager:statistics:query')") |
| | | public CommonResult<List<ImStatisticsManagerTopSenderRespVO>> getTopSenders() { |
| | | LocalDateTime endTime = LocalDate.now().plusDays(1).atStartOfDay(); |
| | | LocalDateTime beginTime = endTime.minusDays(DISTRIBUTION_WINDOW_DAYS); |
| | | Map<Long, Long> topSenderMap = statisticsService.getTopSenderCountMap(beginTime, endTime, TOP_SENDER_LIMIT); |
| | | // TOP åéè
ï¼æ¹éåå¡«æµç§° |
| | | Map<Long, AdminUserRespDTO> userMap = adminUserApi.getUserMap(topSenderMap.keySet()); |
| | | return success(convertList(topSenderMap.entrySet(), entry -> { |
| | | ImStatisticsManagerTopSenderRespVO item = new ImStatisticsManagerTopSenderRespVO() |
| | | .setUserId(entry.getKey()).setMessageCount(entry.getValue()); |
| | | MapUtils.findAndThen(userMap, entry.getKey(), user -> item.setNickname(user.getNickname())); |
| | | return item; |
| | | })); |
| | | } |
| | | |
| | | /** |
| | | * ææ¯æ¥èå Map 对é½å° dates åºåï¼ç¼ºå¤±å¤©è¡¥ 0 |
| | | */ |
| | | private static List<Long> alignSeries(List<LocalDateTime> dates, Map<LocalDateTime, Long> dailyMap) { |
| | | return convertList(dates, date -> dailyMap.getOrDefault(date, 0L)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM æ°æ®çæ¿ç¾¤è§æ¨¡åå¸é¡¹ Response VO") |
| | | @Data |
| | | public class ImStatisticsManagerGroupSizeRespVO { |
| | | |
| | | @Schema(description = "åºé´åç§°", requiredMode = Schema.RequiredMode.REQUIRED, example = "1-9 人") |
| | | private String range; |
| | | |
| | | @Schema(description = "群æ°é", requiredMode = Schema.RequiredMode.REQUIRED, example = "320") |
| | | private Long count; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM æ°æ®çæ¿å
容类ååå¸é¡¹ Response VO") |
| | | @Data |
| | | public class ImStatisticsManagerMessageTypeRespVO { |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | private Integer type; // åè§ ImContentTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "æ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "8000") |
| | | private Long value; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM æ°æ®çæ¿æ¦è§ Response VO") |
| | | @Data |
| | | public class ImStatisticsManagerOverviewRespVO { |
| | | |
| | | @Schema(description = "ç¨æ·æ»æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "12345") |
| | | private Long totalUser; |
| | | |
| | | @Schema(description = "仿¥æ°å¢ç¨æ·æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "23") |
| | | private Long newUserToday; |
| | | |
| | | @Schema(description = "ç¾¤æ»æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "678") |
| | | private Long totalGroup; |
| | | |
| | | @Schema(description = "仿¥æ°å»ºç¾¤æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "4") |
| | | private Long newGroupToday; |
| | | |
| | | @Schema(description = "æ¥æ´»ç¨æ·ï¼ä»æ¥åè¿æ¶æ¯çå»éç¨æ·æ°ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "1023") |
| | | private Long activeUserDaily; |
| | | |
| | | @Schema(description = "卿´»ç¨æ·ï¼æè¿ 7 天åè¿æ¶æ¯çå»éç¨æ·æ°ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "4567") |
| | | private Long activeUserWeekly; |
| | | |
| | | @Schema(description = "ææ´»ç¨æ·ï¼æè¿ 30 天åè¿æ¶æ¯çå»éç¨æ·æ°ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "8901") |
| | | private Long activeUserMonthly; |
| | | |
| | | @Schema(description = "仿¥ç§èæ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "8765") |
| | | private Long privateMessageToday; |
| | | |
| | | @Schema(description = "仿¥ç¾¤èæ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "3210") |
| | | private Long groupMessageToday; |
| | | |
| | | @Schema(description = "æ¨æ¥ç§èæ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "7890") |
| | | private Long privateMessageYesterday; |
| | | |
| | | @Schema(description = "æ¨æ¥ç¾¤èæ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "3000") |
| | | private Long groupMessageYesterday; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - IM æ°æ®çæ¿ TOP åéè
项 Response VO") |
| | | @Data |
| | | public class ImStatisticsManagerTopSenderRespVO { |
| | | |
| | | @Schema(description = "ç¨æ·ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long userId; |
| | | |
| | | @Schema(description = "ç¨æ·æµç§°", example = "å¼ ä¸") |
| | | private String nickname; |
| | | |
| | | @Schema(description = "æ¶æ¯æ°", requiredMode = Schema.RequiredMode.REQUIRED, example = "1500") |
| | | private Long messageCount; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.manager.statistics.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | @Schema(description = "管çåå° - IM æ°æ®çæ¿è¶å¿ Response VO") |
| | | @Data |
| | | public class ImStatisticsManagerTrendRespVO { |
| | | |
| | | @Schema(description = "æ¨ªè½´æ¥æåºåï¼æ¯å¤© 00:00:00ï¼ç±å端æé忥æé¨åï¼", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private List<LocalDateTime> dates; |
| | | |
| | | @Schema(description = "æ°æ®ç³»åï¼key 为系ååï¼å¦ private/group æ register/activeï¼ï¼value ä¸ºä¸ dates çé¿çè®¡æ°æ°ç»", |
| | | requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private Map<String, List<Long>> series; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message; |
| | | |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.channel.ImChannelMessagePullRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImChannelMessageDO; |
| | | import cn.iocoder.yudao.module.im.enums.message.ImMessageReceiptStatusEnum; |
| | | import cn.iocoder.yudao.module.im.service.message.ImChannelMessageService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.PositiveOrZero; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PutMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.Collections; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertSet; |
| | | import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "ç¨æ· APP - IM é¢éæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/channel/message") |
| | | @Validated |
| | | public class ImChannelMessageController { |
| | | |
| | | @Resource |
| | | private ImChannelMessageService channelMessageService; |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "æåé¢éæ¶æ¯ï¼ç¦»çº¿å¢éï¼ï¼æ minId 游æ å页") |
| | | public CommonResult<List<ImChannelMessagePullRespVO>> pullChannelMessageList( |
| | | @RequestParam(value = "minId", defaultValue = "0") @PositiveOrZero(message = "minId ä¸è½å°äº 0") Long minId, |
| | | @RequestParam(value = "size", defaultValue = "100") |
| | | @Min(value = 1, message = "size å¿
é¡»å¤§äº 0") |
| | | @Max(value = 200, message = "size 䏿¬¡æå¤ 200 æ¡") Integer size) { |
| | | // 1. æåæ¶æ¯å表 |
| | | Long userId = getLoginUserId(); |
| | | List<ImChannelMessageDO> list = channelMessageService.pullChannelMessageList(userId, minId, size); |
| | | if (CollUtil.isEmpty(list)) { |
| | | return success(Collections.emptyList()); |
| | | } |
| | | // 2. æå·²è¯»æ¸¸æ è¡¥ receiptStatusï¼å·²è¯» DONE / æªè¯» PENDINGï¼ |
| | | Map<Long, Long> readMaxByChannel = channelMessageService.getChannelReadMaxMessageIdMap( |
| | | userId, convertSet(list, ImChannelMessageDO::getChannelId)); |
| | | return success(BeanUtils.toBean(list, ImChannelMessagePullRespVO.class, vo -> { |
| | | Long readMax = readMaxByChannel.get(vo.getChannelId()); |
| | | vo.setReceiptStatus(readMax != null && readMax >= vo.getId() |
| | | ? ImMessageReceiptStatusEnum.DONE.getStatus() |
| | | : ImMessageReceiptStatusEnum.PENDING.getStatus()); |
| | | })); |
| | | } |
| | | |
| | | @PutMapping("/read") |
| | | @Operation(summary = "æ è®°é¢éæ¶æ¯å·²è¯»") |
| | | @Parameter(name = "channelId", description = "é¢éç¼å·", required = true, example = "1") |
| | | @Parameter(name = "messageId", description = "已读å°çæ¶æ¯ç¼å·", required = true, example = "100") |
| | | public CommonResult<Boolean> readChannelMessages(@RequestParam("channelId") Long channelId, |
| | | @RequestParam("messageId") Long messageId) { |
| | | channelMessageService.readChannelMessages(getLoginUserId(), channelId, messageId); |
| | | return success(true); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.group.ImGroupMessageListReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.group.ImGroupMessageRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.group.ImGroupMessageSendReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImGroupMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.message.ImGroupMessageService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Min; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM ç¾¤èæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/message/group") |
| | | @Validated |
| | | public class ImGroupMessageController { |
| | | |
| | | @Resource |
| | | private ImGroupMessageService groupMessageService; |
| | | |
| | | @PostMapping("/send") |
| | | @Operation(summary = "åéç¾¤èæ¶æ¯") |
| | | public CommonResult<ImGroupMessageRespVO> sendGroupMessage(@Valid @RequestBody ImGroupMessageSendReqVO reqVO) { |
| | | ImGroupMessageDO message = groupMessageService.sendGroupMessage(getLoginUserId(), reqVO); |
| | | return success(BeanUtils.toBean(message, ImGroupMessageRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "æåç¾¤èæ¶æ¯ï¼å¢éï¼") |
| | | @Parameter(name = "minId", description = "æå°æ¶æ¯ id", required = true, example = "0") |
| | | @Parameter(name = "size", description = "æåæ°é", required = true, example = "100") |
| | | public CommonResult<List<ImGroupMessageRespVO>> pullGroupMessageList( |
| | | @RequestParam("minId") Long minId, |
| | | @RequestParam("size") @Min(value = 1, message = "æåæ°éæå°å¼ä¸º 1") Integer size) { |
| | | List<ImGroupMessageDO> messages = groupMessageService.pullGroupMessageList(getLoginUserId(), minId, size); |
| | | return success(BeanUtils.toBean(messages, ImGroupMessageRespVO.class)); |
| | | } |
| | | |
| | | @PutMapping("/read") |
| | | @Operation(summary = "æ è®°ç¾¤èæ¶æ¯å·²è¯»") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "1") |
| | | @Parameter(name = "messageId", description = "已读å°çæ¶æ¯ç¼å·", required = true, example = "100") |
| | | public CommonResult<Boolean> readGroupMessages(@RequestParam("groupId") Long groupId, |
| | | @RequestParam("messageId") Long messageId) { |
| | | groupMessageService.readGroupMessages(getLoginUserId(), groupId, messageId); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/recall") |
| | | @Operation(summary = "æ¤åç¾¤èæ¶æ¯") |
| | | @Parameter(name = "id", description = "æ¶æ¯ç¼å·", required = true, example = "1") |
| | | public CommonResult<ImGroupMessageRespVO> recallGroupMessage(@RequestParam("id") Long id) { |
| | | ImGroupMessageDO message = groupMessageService.recallGroupMessage(getLoginUserId(), id); |
| | | return success(BeanUtils.toBean(message, ImGroupMessageRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/get-read-user-ids") |
| | | @Operation(summary = "è·åç¾¤æ¶æ¯å·²è¯»ç¨æ·å表") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "1") |
| | | @Parameter(name = "messageId", description = "æ¶æ¯ç¼å·", required = true, example = "1") |
| | | public CommonResult<List<Long>> getGroupReadUserIds(@RequestParam("groupId") Long groupId, |
| | | @RequestParam("messageId") Long messageId) { |
| | | return success(groupMessageService.getGroupReadUserIds(getLoginUserId(), groupId, messageId)); |
| | | } |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "æ¥è¯¢ç¾¤èå岿¶æ¯") |
| | | public CommonResult<List<ImGroupMessageRespVO>> getGroupMessageList(@Valid ImGroupMessageListReqVO reqVO) { |
| | | List<ImGroupMessageDO> messages = groupMessageService.getGroupMessageList(getLoginUserId(), reqVO); |
| | | return success(BeanUtils.toBean(messages, ImGroupMessageRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | ### è¯·æ± /send æ¥å£ => æå |
| | | POST {{baseUrl}}/im/message/send |
| | | Authorization: Bearer {{token}} |
| | | Content-Type: application/json |
| | | tenant-id: {{adminTenentId}} |
| | | |
| | | { |
| | | "clientMessageId": "123", |
| | | "receiverId": 1, |
| | | "conversationType": 1, |
| | | "contentType": 101, |
| | | "content": "ä½ å¥½1" |
| | | } |
| | | |
| | | ### è¯·æ± /pull æ¥å£ => æå |
| | | GET {{baseUrl}}/im/message/pull?sequence=0&size=2 |
| | | Authorization: Bearer {{token}} |
| | | tenant-id: {{adminTenentId}} |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.object.BeanUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.privates.ImPrivateMessageListReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.privates.ImPrivateMessageRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.message.vo.privates.ImPrivateMessageSendReqVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImPrivateMessageDO; |
| | | import cn.iocoder.yudao.module.im.service.message.ImPrivateMessageService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import jakarta.validation.constraints.Min; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM ç§èæ¶æ¯") |
| | | @RestController |
| | | @RequestMapping("/im/message/private") |
| | | @Validated |
| | | public class ImPrivateMessageController { |
| | | |
| | | @Resource |
| | | private ImPrivateMessageService privateMessageService; |
| | | |
| | | @PostMapping("/send") |
| | | @Operation(summary = "åéç§èæ¶æ¯") |
| | | public CommonResult<ImPrivateMessageRespVO> sendPrivateMessage( |
| | | @Valid @RequestBody ImPrivateMessageSendReqVO reqVO) { |
| | | ImPrivateMessageDO message = privateMessageService.sendPrivateMessage(getLoginUserId(), reqVO); |
| | | return success(BeanUtils.toBean(message, ImPrivateMessageRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/pull") |
| | | @Operation(summary = "æåç§èæ¶æ¯ï¼å¢éï¼") |
| | | @Parameter(name = "minId", description = "æå°æ¶æ¯ id", required = true, example = "0") |
| | | @Parameter(name = "size", description = "æåæ°é", required = true, example = "100") |
| | | public CommonResult<List<ImPrivateMessageRespVO>> pullPrivateMessageList( |
| | | @RequestParam("minId") Long minId, |
| | | @RequestParam("size") @Min(value = 1, message = "æåæ°éæå°å¼ä¸º 1") Integer size) { |
| | | List<ImPrivateMessageDO> messages = privateMessageService.pullPrivateMessageList(getLoginUserId(), minId, size); |
| | | return success(BeanUtils.toBean(messages, ImPrivateMessageRespVO.class)); |
| | | } |
| | | |
| | | @PutMapping("/read") |
| | | @Operation(summary = "æ è®°ç§èæ¶æ¯å·²è¯»") |
| | | @Parameter(name = "receiverId", description = "æ¥æ¶æ¹ç¨æ·ç¼å·ï¼å¯¹æ¹ï¼", required = true, example = "2") |
| | | @Parameter(name = "messageId", description = "已读ä½ç½®ï¼å«ï¼ï¼é常æ¯ä¼è¯å
æå¤§æ¶æ¯ç¼å·", required = true, example = "100") |
| | | public CommonResult<Boolean> readPrivateMessages(@RequestParam("receiverId") Long receiverId, |
| | | @RequestParam("messageId") Long messageId) { |
| | | privateMessageService.readPrivateMessages(getLoginUserId(), receiverId, messageId); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/max-read-message-id") |
| | | @Operation(summary = "æ¥è¯¢å¯¹æ¹å·²è¯»å°æåçæå¤§æ¶æ¯ id", |
| | | description = "ç¨äºå¤ç«¯ / ç¦»çº¿åºæ¯ä¸ç已读ä½ç½®è¡¥é½ï¼è¿å
¥ä¼è¯ææçº¿éè¿åè°ç¨ï¼æ®æ¤ææ¬å°èªåæ¶æ¯æ´æ°ä¸ºå·²è¯»") |
| | | @Parameter(name = "peerId", description = "对æ¹ç¨æ·ç¼å·", required = true, example = "2") |
| | | public CommonResult<Long> getMaxReadMessageId(@RequestParam("peerId") Long peerId) { |
| | | return success(privateMessageService.getMaxReadMessageId(getLoginUserId(), peerId)); |
| | | } |
| | | |
| | | @DeleteMapping("/recall") |
| | | @Operation(summary = "æ¤åç§èæ¶æ¯") |
| | | @Parameter(name = "id", description = "æ¶æ¯ç¼å·", required = true, example = "1") |
| | | public CommonResult<ImPrivateMessageRespVO> recallPrivateMessage(@RequestParam("id") Long id) { |
| | | ImPrivateMessageDO message = privateMessageService.recallPrivateMessage(getLoginUserId(), id); |
| | | return success(BeanUtils.toBean(message, ImPrivateMessageRespVO.class)); |
| | | } |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "æ¥è¯¢ç§èå岿¶æ¯") |
| | | public CommonResult<List<ImPrivateMessageRespVO>> getPrivateMessageList(@Valid ImPrivateMessageListReqVO reqVO) { |
| | | List<ImPrivateMessageDO> messages = privateMessageService.getPrivateMessageList(getLoginUserId(), reqVO); |
| | | return success(BeanUtils.toBean(messages, ImPrivateMessageRespVO.class)); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.channel; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | @Schema(description = "ç¨æ· APP - IM é¢éæ¶æ¯æå Response VO") |
| | | @Data |
| | | public class ImChannelMessagePullRespVO { |
| | | |
| | | @Schema(description = "ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "9001") |
| | | private Long id; |
| | | |
| | | @Schema(description = "é¢éç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | private Long channelId; |
| | | |
| | | @Schema(description = "ç´ æç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") |
| | | private Long materialId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "125") |
| | | private Integer type; |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼payload JSON å¿«ç
§", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private String content; |
| | | |
| | | @Schema(description = "å½åç¨æ·åæ§ / 已读æï¼æ Redis 读ä½ç½®è®¡ç®ï¼å·²è¯» DONEï¼æªè¯» PENDINGï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") |
| | | private Integer receiptStatus; // åè§ ImMessageReceiptStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | private LocalDateTime sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.group; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | @Schema(description = "管çåå° - 群èå岿¶æ¯å表 Request VO") |
| | | @Data |
| | | public class ImGroupMessageListReqVO { |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "10") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "èµ·å§æ¶æ¯ç¼å·ï¼ä»è¯¥ id å¾åæåï¼ä¸å«ï¼ã为空åä»ææ°æ¶æ¯å¼å§", example = "1024") |
| | | private Long maxId; |
| | | |
| | | @Schema(description = "æåæ°é", requiredMode = Schema.RequiredMode.REQUIRED, example = "20") |
| | | @NotNull(message = "æåæ°éä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "æåæ°éæå°å¼ä¸º 1") |
| | | @Max(value = 200, message = "æåæ°éæå¤§å¼ä¸º 200") |
| | | private Integer limit; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.group; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * ç¾¤èæ¶æ¯ Response VO |
| | | */ |
| | | @Schema(description = "管çåå° - ç¾¤èæ¶æ¯ Response VO") |
| | | @Data |
| | | public class ImGroupMessageRespVO { |
| | | |
| | | @Schema(description = "æ¶æ¯ç¼å·", example = "1") |
| | | private Long id; |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", example = "uuid-xxx") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "åé人ç¼å·", example = "1") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "群ç¼å·", example = "1") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", example = "0") |
| | | private Integer type; |
| | | |
| | | @Schema(description = "æ¶æ¯å
容", example = "{\"content\":\"ä½ å¥½\"}") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", example = "0") |
| | | private Integer status; |
| | | |
| | | @Schema(description = "åéæ¶é´") |
| | | private LocalDateTime sendTime; |
| | | |
| | | @Schema(description = "@ç®æ ç¨æ·ç¼å·å表", example = "[1,2,3]") |
| | | private List<Long> atUserIds; |
| | | |
| | | @Schema(description = "å®åæ¥æ¶ç¨æ·ç¼å·å表", example = "[1,2]") |
| | | private List<Long> receiverUserIds; |
| | | |
| | | @Schema(description = "åæ§ç¶æ", example = "0") |
| | | private Integer receiptStatus; |
| | | |
| | | @Schema(description = "已读人æ°ï¼åæ§æ¶æ¯ãä¸åé人为å½åç¨æ·æ¶æå¼ï¼", example = "3") |
| | | private Integer readCount; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.group; |
| | | |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | import com.fasterxml.jackson.annotation.JsonIgnore; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.AssertTrue; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * ç¾¤èæ¶æ¯åé Request VO |
| | | */ |
| | | @Schema(description = "管çåå° - ç¾¤èæ¶æ¯åé Request VO") |
| | | @Data |
| | | public class ImGroupMessageSendReqVO { |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "uuid-xxx") |
| | | @NotEmpty(message = "客æ·ç«¯æ¶æ¯ç¼å·ä¸è½ä¸ºç©º") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "群ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | @NotNull(message = "群ç¼å·ä¸è½ä¸ºç©º") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "æ¶æ¯ç±»åä¸è½ä¸ºç©º") |
| | | @InEnum(ImContentTypeEnum.class) |
| | | private Integer type; |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼JSON æ ¼å¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "{\"content\":\"ä½ å¥½\"}") |
| | | @NotEmpty(message = "æ¶æ¯å
容ä¸è½ä¸ºç©º") |
| | | private String content; |
| | | |
| | | @Schema(description = "@ç®æ ç¨æ·ç¼å·å表", example = "[1,2,3]") |
| | | private List<Long> atUserIds; |
| | | |
| | | @Schema(description = "æ¯å¦éè¦åæ§", example = "false") |
| | | private Boolean receipt; |
| | | |
| | | /** |
| | | * ä»
å
è®¸ç¨æ·æ¶æ¯ï¼normalï¼ç±»å |
| | | */ |
| | | @AssertTrue(message = "æ¶æ¯ç±»åä¸å
许") |
| | | @JsonIgnore |
| | | public boolean isTypeNormal() { |
| | | return type == null || ImContentTypeEnum.validate(type).isNormal(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.privates; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import jakarta.validation.constraints.Max; |
| | | import jakarta.validation.constraints.Min; |
| | | import jakarta.validation.constraints.NotNull; |
| | | |
| | | @Schema(description = "管çåå° - ç§èå岿¶æ¯å表 Request VO") |
| | | @Data |
| | | public class ImPrivateMessageListReqVO { |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·ï¼å¯¹æ¹ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") |
| | | @NotNull(message = "æ¥æ¶äººç¼å·ä¸è½ä¸ºç©º") |
| | | private Long receiverId; |
| | | |
| | | @Schema(description = "èµ·å§æ¶æ¯ç¼å·ï¼ä»è¯¥ id å¾åæåï¼ä¸å«ï¼ã为空åä»ææ°æ¶æ¯å¼å§", example = "1024") |
| | | private Long maxId; |
| | | |
| | | @Schema(description = "æåæ°é", requiredMode = Schema.RequiredMode.REQUIRED, example = "20") |
| | | @NotNull(message = "æåæ°éä¸è½ä¸ºç©º") |
| | | @Min(value = 1, message = "æåæ°éæå°å¼ä¸º 1") |
| | | @Max(value = 200, message = "æåæ°éæå¤§å¼ä¸º 200") |
| | | private Integer limit; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.privates; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.ToString; |
| | | |
| | | import jakarta.validation.constraints.NotNull; |
| | | |
| | | @Schema(description = "管çåå° - ç§èæ¶æ¯å页 Request VO") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | public class ImPrivateMessagePageReqVO extends PageParam { |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·ï¼å¯¹æ¹ï¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") |
| | | @NotNull(message = "æ¥æ¶äººç¼å·ä¸è½ä¸ºç©º") |
| | | private Long receiverId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.privates; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * ç§èæ¶æ¯ Response VO |
| | | */ |
| | | @Schema(description = "管çåå° - ç§èæ¶æ¯ Response VO") |
| | | @Data |
| | | public class ImPrivateMessageRespVO { |
| | | |
| | | @Schema(description = "æ¶æ¯ç¼å·", example = "1") |
| | | private Long id; |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", example = "uuid-xxx") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "åé人ç¼å·", example = "1") |
| | | private Long senderId; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·", example = "2") |
| | | private Long receiverId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", example = "0") |
| | | private Integer type; |
| | | |
| | | @Schema(description = "æ¶æ¯å
容", example = "{\"content\":\"ä½ å¥½\"}") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¶æ¯ç¶æ", example = "0") |
| | | private Integer status; // åè§ ImMessageStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åæ§ç¶æ", example = "0") |
| | | private Integer receiptStatus; // åè§ ImMessageReceiptStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åéæ¶é´") |
| | | private LocalDateTime sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.message.vo.privates; |
| | | |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | import com.fasterxml.jackson.annotation.JsonIgnore; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.AssertTrue; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * ç§èæ¶æ¯åé Request VO |
| | | */ |
| | | @Schema(description = "管çåå° - ç§èæ¶æ¯åé Request VO") |
| | | @Data |
| | | public class ImPrivateMessageSendReqVO { |
| | | |
| | | @Schema(description = "客æ·ç«¯æ¶æ¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "uuid-xxx") |
| | | @NotEmpty(message = "客æ·ç«¯æ¶æ¯ç¼å·ä¸è½ä¸ºç©º") |
| | | private String clientMessageId; |
| | | |
| | | @Schema(description = "æ¥æ¶äººç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") |
| | | @NotNull(message = "æ¥æ¶äººç¼å·ä¸è½ä¸ºç©º") |
| | | private Long receiverId; |
| | | |
| | | @Schema(description = "æ¶æ¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "0") |
| | | @NotNull(message = "æ¶æ¯ç±»åä¸è½ä¸ºç©º") |
| | | @InEnum(ImContentTypeEnum.class) |
| | | private Integer type; |
| | | |
| | | @Schema(description = "æ¶æ¯å
容ï¼JSON æ ¼å¼", requiredMode = Schema.RequiredMode.REQUIRED, example = "{\"content\":\"ä½ å¥½\"}") |
| | | @NotEmpty(message = "æ¶æ¯å
容ä¸è½ä¸ºç©º") |
| | | private String content; |
| | | |
| | | @Schema(description = "æ¯å¦éè¦åæ§", example = "false") |
| | | private Boolean receipt; |
| | | |
| | | /** |
| | | * ä»
å
è®¸ç¨æ·æ¶æ¯ï¼normalï¼ç±»å |
| | | */ |
| | | @AssertTrue(message = "æ¶æ¯ç±»åä¸å
许") |
| | | @JsonIgnore |
| | | public boolean isTypeNormal() { |
| | | return type == null || ImContentTypeEnum.validate(type).isNormal(); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc; |
| | | |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils; |
| | | import cn.iocoder.yudao.module.im.controller.admin.rtc.vo.ImRtcCallCreateReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.rtc.vo.ImRtcCallInviteReqVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.rtc.vo.ImRtcCallRespVO; |
| | | import cn.iocoder.yudao.module.im.controller.admin.rtc.vo.ImRtcGroupCallRespVO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.rtc.ImRtcCallDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.rtc.ImRtcParticipantDO; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcCallStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcParticipantStatusEnum; |
| | | import cn.iocoder.yudao.module.im.framework.config.ImProperties; |
| | | import cn.iocoder.yudao.module.im.service.rtc.ImRtcCallService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.Parameter; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.validation.Valid; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.List; |
| | | import java.util.Objects; |
| | | import java.util.Set; |
| | | |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管çåå° - IM 宿¶éè¯") |
| | | @RestController |
| | | @RequestMapping("/im/rtc") |
| | | @Validated |
| | | public class ImRtcCallController { |
| | | |
| | | @Resource |
| | | private ImRtcCallService rtcCallService; |
| | | @Resource |
| | | private ImProperties imProperties; |
| | | |
| | | @PostMapping("/create") |
| | | @Operation(summary = "å建æ°éè¯ï¼æ conversationType åºåç§è / 群è") |
| | | public CommonResult<ImRtcCallRespVO> createCall(@Valid @RequestBody ImRtcCallCreateReqVO reqVO) { |
| | | Long userId = getLoginUserId(); |
| | | ImRtcCallDO call = rtcCallService.createCall(userId, reqVO); |
| | | return success(buildCallRespVO(call, userId)); |
| | | } |
| | | |
| | | @PostMapping("/invite") |
| | | @Operation(summary = "éè¯ä¸è¿½å é请ï¼ä»
群éè¯å¯ç¨") |
| | | public CommonResult<Boolean> inviteCall(@Valid @RequestBody ImRtcCallInviteReqVO reqVO) { |
| | | rtcCallService.inviteCall(getLoginUserId(), reqVO); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/join") |
| | | @Operation(summary = "å å
¥å·²æç¾¤éè¯ï¼ç¨äºè¶åæ¡ãå å
¥ãæé®") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<ImRtcCallRespVO> joinCall(@RequestParam("room") String room) { |
| | | Long userId = getLoginUserId(); |
| | | return success(buildCallRespVO(rtcCallService.joinCall(userId, room), userId)); |
| | | } |
| | | |
| | | @PostMapping("/accept") |
| | | @Operation(summary = "æ¥å¬éè¯") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<ImRtcCallRespVO> accept(@RequestParam("room") String room) { |
| | | Long userId = getLoginUserId(); |
| | | return success(buildCallRespVO(rtcCallService.acceptCall(userId, room), userId)); |
| | | } |
| | | |
| | | @PostMapping("/reject") |
| | | @Operation(summary = "æç»éè¯") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<Boolean> reject(@RequestParam("room") String room) { |
| | | rtcCallService.rejectCall(getLoginUserId(), room); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/cancel") |
| | | @Operation(summary = "åæ¶é请ï¼ä¸»å«æ¥éåè°ç¨") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<Boolean> cancel(@RequestParam("room") String room) { |
| | | rtcCallService.cancelCall(getLoginUserId(), room); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/leave") |
| | | @Operation(summary = "离å¼éè¯ï¼æ¥éåè°ç¨") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<Boolean> leave(@RequestParam("room") String room) { |
| | | rtcCallService.leaveCall(getLoginUserId(), room); |
| | | return success(true); |
| | | } |
| | | |
| | | @PostMapping("/no-answer-call-check") |
| | | @Operation(summary = "å端 RUNNING 端 timer å
åºï¼è§¦åå端ç«å³æ«æè¯¥ room çæ¯éè¶
æ¶ï¼æ¥å£éé»ï¼") |
| | | @Parameter(name = "room", description = "ä¸å¡éè¯ç¼å·", required = true, example = "f47ac10b58cc4372a567") |
| | | public CommonResult<Boolean> noAnswerCallCheck(@RequestParam("room") String room) { |
| | | rtcCallService.noAnswerCallCheck(getLoginUserId(), room); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/get-active-call") |
| | | @Operation(summary = "æ¥è¯¢å½åè¿è¡ä¸çéè¯ï¼ç¨äºç¾¤èé¡¶é¨ãN 人æ£å¨éè¯ãè¶åæ¡") |
| | | @Parameter(name = "groupId", description = "群ç¼å·", required = true, example = "2048") |
| | | public CommonResult<ImRtcGroupCallRespVO> getActiveCall(@RequestParam("groupId") Long groupId) { |
| | | ImRtcCallDO call = rtcCallService.getActiveCall(getLoginUserId(), groupId); |
| | | return success(buildGroupActiveRespVO(call)); |
| | | } |
| | | |
| | | // ========== VO æ¼è£
========== |
| | | |
| | | /** |
| | | * æ¼è£
invite / join / accept / refresh-token çååº VOï¼å« token + åä¸è
åæ¡¶ |
| | | * |
| | | * @param call éè¯ä¸»è¡¨ |
| | | * @param userId å½åç¨æ·ç¼å·ï¼token æè¯¥ç¨æ·ç¾å |
| | | * @return ååº VOï¼call 为空è¿å null |
| | | */ |
| | | private ImRtcCallRespVO buildCallRespVO(ImRtcCallDO call, Long userId) { |
| | | if (call == null) { |
| | | return null; |
| | | } |
| | | List<ImRtcParticipantDO> participants = rtcCallService.getCallParticipantList(call.getRoom()); |
| | | boolean ended = ImRtcCallStatusEnum.isEnded(call.getStatus()); |
| | | return new ImRtcCallRespVO() |
| | | .setRoom(call.getRoom()) |
| | | .setLivekitUrl(imProperties.getRtc().getLivekitUrl()) |
| | | // ä»
é ENDED åºæ¯æç¾ tokenï¼ENDED åºæ¯ä¸ç¾ï¼åç«¯æ ¹æ® token æ¯å¦åå¨ï¼æ¥å¤ææ¯å¦å±ç¤ºãéè¯å·²ç»æãçæç¤º |
| | | .setToken(ended ? null : rtcCallService.signCallToken(userId, call.getRoom())) |
| | | .setConversationType(call.getConversationType()).setMediaType(call.getMediaType()) |
| | | .setStatus(call.getStatus()).setEndReason(call.getEndReason()) |
| | | .setInviterId(call.getInviterUserId()).setGroupId(call.getGroupId()) |
| | | .setInviteeIds(filterUserIds(participants, ImRtcParticipantStatusEnum.INVITING)) |
| | | .setJoinedUserIds(filterUserIds(participants, ImRtcParticipantStatusEnum.JOINED)); |
| | | } |
| | | |
| | | /** |
| | | * æ¼è£
get-active-call çååº VO |
| | | * |
| | | * @param call éè¯ä¸»è¡¨ |
| | | * @return ååº VOï¼åªç¨äºç¾¤èè¶åæ¡ï¼ä¸å« token |
| | | */ |
| | | private ImRtcGroupCallRespVO buildGroupActiveRespVO(ImRtcCallDO call) { |
| | | if (call == null) { |
| | | return null; |
| | | } |
| | | List<ImRtcParticipantDO> participants = rtcCallService.getCallParticipantList(call.getRoom()); |
| | | return new ImRtcGroupCallRespVO().setRoom(call.getRoom()).setMediaType(call.getMediaType()) |
| | | .setGroupId(call.getGroupId()).setInviterId(call.getInviterUserId()) |
| | | .setJoinedUserIds(filterUserIds(participants, ImRtcParticipantStatusEnum.JOINED)) |
| | | .setInviteeIds(filterUserIds(participants, ImRtcParticipantStatusEnum.INVITING)); |
| | | } |
| | | |
| | | /** |
| | | * æç¶æè¿æ»¤åä¸è
userIdï¼ç¨ LinkedHashSet ä¿çå端å±ç¤ºé¡ºåº |
| | | * |
| | | * @param participants åä¸è
å表 |
| | | * @param status ç®æ ç¶æ |
| | | * @return userId éå |
| | | */ |
| | | private static Set<Long> filterUserIds(List<ImRtcParticipantDO> participants, |
| | | ImRtcParticipantStatusEnum status) { |
| | | return CollectionUtils.convertLinkedSet(participants, ImRtcParticipantDO::getUserId, |
| | | participant -> Objects.equals(participant.getStatus(), status.getStatus())); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc; |
| | | |
| | | import cn.hutool.core.util.StrUtil; |
| | | import cn.iocoder.yudao.framework.common.pojo.CommonResult; |
| | | import cn.iocoder.yudao.framework.common.util.json.JsonUtils; |
| | | import cn.iocoder.yudao.framework.tenant.core.aop.TenantIgnore; |
| | | import cn.iocoder.yudao.module.im.framework.rtc.core.LiveKitClient; |
| | | import cn.iocoder.yudao.module.im.framework.rtc.core.LiveKitWebhookEventDTO; |
| | | import cn.iocoder.yudao.module.im.service.rtc.ImRtcCallService; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import jakarta.annotation.Resource; |
| | | import jakarta.annotation.security.PermitAll; |
| | | import jakarta.servlet.http.HttpServletRequest; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | 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 static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | |
| | | /** |
| | | * LiveKit åå对æ¥å
¥å£ï¼Webhook åè°ï¼ |
| | | * <p> |
| | | * å®å
¨ç±è¯·æ±ç¾åï¼JWT + body sha256ï¼ä¿è¯ï¼ä¸èµ°ç»å½é´æï¼ä¼ªé 请æ±ä¼è¢«ç¾åæ ¡éªç´æ¥æç» |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @Tag(name = "LiveKit Webhook åè°") |
| | | @RestController |
| | | @RequestMapping("/im/livekit") |
| | | @Slf4j |
| | | public class ImRtcLiveKitController { |
| | | |
| | | @Resource |
| | | private LiveKitClient liveKitClient; |
| | | @Resource |
| | | private ImRtcCallService rtcCallService; |
| | | |
| | | /** |
| | | * LiveKit Webhook åè°å
¥å£ |
| | | * |
| | | * @param request HTTP 请æ±ï¼ç¨äºå Authorization 头åç¾åæ ¡éª |
| | | * @param rawBody åå§ JSON bodyï¼ç¾åæ ¡éªéè¦åå§åè |
| | | * @return æ¯å¦å¤çæåï¼ä¼ªé / éæ³äºä»¶è¿å false |
| | | */ |
| | | @PostMapping("/webhook") |
| | | @Operation(summary = "LiveKit Webhook åè°ï¼æ¥æ¶æåç¦»å¼ / æ¿é´ç»æçäºä»¶åä¸å¡æå
åºæ¸
ç") |
| | | @PermitAll |
| | | @TenantIgnore |
| | | public CommonResult<Boolean> webhook(HttpServletRequest request, @RequestBody String rawBody) { |
| | | // 1.1 æ ¡éªç¾åï¼ä¼ªé 请æ±ç´æ¥ 200 ä½å¿½ç¥ï¼é¿å
ç»æ»å»è
åé¦ |
| | | if (!liveKitClient.verifyWebhookSignature(request.getHeader("Authorization"), rawBody)) { |
| | | log.warn("[webhook][ç¾åæ ¡éªå¤±è´¥ ip={} bodyLength={}]", |
| | | request.getRemoteAddr(), rawBody == null ? 0 : rawBody.length()); |
| | | return success(false); |
| | | } |
| | | // 1.2 è§£æäºä»¶è½½è·ï¼éæ³ / 空 event ç´æ¥å¿½ç¥ |
| | | LiveKitWebhookEventDTO event = JsonUtils.parseObject(rawBody, LiveKitWebhookEventDTO.class); |
| | | if (event == null || StrUtil.isBlank(event.getEvent())) { |
| | | return success(false); |
| | | } |
| | | |
| | | // 2. äº¤ç» service å¤çï¼å¹çç± service èªå·±ä¿è¯ |
| | | log.info("[webhook][äºä»¶å¤ç event={} room={}]", event.getEvent(), |
| | | event.getRoom() == null ? null : event.getRoom().getName()); |
| | | try { |
| | | rtcCallService.handleLiveKitEvent(event); |
| | | } catch (Exception e) { |
| | | log.error("[webhook][äºä»¶å¤ç失败 event={} body={}]", event.getEvent(), rawBody, e); |
| | | } |
| | | return success(true); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc.vo; |
| | | |
| | | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| | | import cn.iocoder.yudao.module.im.enums.ImConversationTypeEnum; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcCallMediaTypeEnum; |
| | | import com.fasterxml.jackson.annotation.JsonIgnore; |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.AssertTrue; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Set; |
| | | |
| | | @Schema(description = "管çåå° - å建éè¯ Request VO") |
| | | @Data |
| | | public class ImRtcCallCreateReqVO { |
| | | |
| | | @Schema(description = "ä¼è¯ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "1") |
| | | @NotNull(message = "ä¼è¯ç±»åä¸è½ä¸ºç©º") |
| | | @InEnum(ImConversationTypeEnum.class) |
| | | private Integer conversationType; |
| | | |
| | | @Schema(description = "åªä½ç±»å", requiredMode = Schema.RequiredMode.REQUIRED, example = "2") |
| | | @NotNull(message = "åªä½ç±»åä¸è½ä¸ºç©º") |
| | | @InEnum(ImRtcCallMediaTypeEnum.class) |
| | | private Integer mediaType; |
| | | |
| | | @Schema(description = "群ç¼å·ï¼ç¾¤èåºæ¯å¿
å¡«", example = "2048") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "被é请çç¨æ·ç¼å·éåï¼ç§èå¿
ä¼ 1 个对端ï¼ç¾¤èå¿
ä¼ è³å° 1 人") |
| | | private Set<@NotNull(message = "被éè¯·ç¨æ·ç¼å·ä¸è½ä¸ºç©º") Long> inviteeIds; |
| | | |
| | | /** |
| | | * éè¯ä»
æ¯æç§èå群è |
| | | */ |
| | | @AssertTrue(message = "ä¼è¯ç±»å䏿¯æ") |
| | | @JsonIgnore |
| | | public boolean isConversationTypeSupported() { |
| | | return conversationType == null || ImConversationTypeEnum.isPrivate(conversationType) |
| | | || ImConversationTypeEnum.isGroup(conversationType); |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import jakarta.validation.constraints.NotBlank; |
| | | import jakarta.validation.constraints.NotEmpty; |
| | | import jakarta.validation.constraints.NotNull; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Set; |
| | | |
| | | @Schema(description = "管çåå° - éè¯ä¸è¿½å é请 Request VOï¼ä»
群éè¯å¯ç¨") |
| | | @Data |
| | | public class ImRtcCallInviteReqVO { |
| | | |
| | | @Schema(description = "ä¸å¡éè¯ç¼å·", requiredMode = Schema.RequiredMode.REQUIRED, example = "f47ac10b58cc4372a567") |
| | | @NotBlank(message = "éè¯ç¼å·ä¸è½ä¸ºç©º") |
| | | private String room; |
| | | |
| | | @Schema(description = "æ°é请çç¨æ·ç¼å·éå", requiredMode = Schema.RequiredMode.REQUIRED) |
| | | @NotEmpty(message = "请è³å°éæ©ä¸ä½æå") |
| | | private Set<@NotNull(message = "被éè¯·ç¨æ·ç¼å·ä¸è½ä¸ºç©º") Long> inviteeIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Set; |
| | | |
| | | @Schema(description = "管çåå° - éè¯ä¼è¯ Response VOï¼invite / accept / refreshToken å
±ç¨") |
| | | @Data |
| | | public class ImRtcCallRespVO { |
| | | |
| | | @Schema(description = "ä¸å¡éè¯ç¼å·") |
| | | private String room; |
| | | |
| | | @Schema(description = "LiveKit Server WebSocket å°åï¼å端 connect ç¨") |
| | | private String livekitUrl; |
| | | |
| | | @Schema(description = "LiveKit æ¥å
¥ Tokenï¼éè¦æ¶è° refreshToken éæ°ç¾å") |
| | | private String token; |
| | | |
| | | @Schema(description = "ä¼è¯ç±»å") |
| | | private Integer conversationType; // åè§ ImConversationTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "åªä½ç±»å") |
| | | private Integer mediaType; // åè§ ImCallMediaTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "ç¶æ") |
| | | private Integer status; // åè§ ImCallStatusEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "ç»æåå ï¼ä»
status=ENDED æ¶æå¼") |
| | | private Integer endReason; // åè§ ImRtcCallEndReasonEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å起人ç¼å·") |
| | | private Long inviterId; |
| | | |
| | | @Schema(description = "群ç¼å·ï¼ç¾¤éè¯ææ") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "被é请人ç¼å·éå") |
| | | private Set<Long> inviteeIds; |
| | | |
| | | @Schema(description = "å·²å å
¥æ¿é´çæåç¼å·éå") |
| | | private Set<Long> joinedUserIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.controller.admin.rtc.vo; |
| | | |
| | | import io.swagger.v3.oas.annotations.media.Schema; |
| | | import lombok.Data; |
| | | |
| | | import java.util.Set; |
| | | |
| | | @Schema(description = "管çåå° - 群活è·éè¯ Response VOï¼ä¸å« tokenï¼è¶åæ¡ä»
å±ç¤ºç¨") |
| | | @Data |
| | | public class ImRtcGroupCallRespVO { |
| | | |
| | | @Schema(description = "ä¸å¡éè¯ç¼å·") |
| | | private String room; |
| | | |
| | | @Schema(description = "群ç¼å·") |
| | | private Long groupId; |
| | | |
| | | @Schema(description = "åªä½ç±»å") |
| | | private Integer mediaType; // åè§ ImCallMediaTypeEnum æä¸¾ç±» |
| | | |
| | | @Schema(description = "å起人ç¼å·") |
| | | private Long inviterId; |
| | | |
| | | @Schema(description = "å·²å å
¥æ¿é´çç¨æ·ç¼å·éå") |
| | | private Set<Long> joinedUserIds; |
| | | |
| | | @Schema(description = "被éè¯·æ± ï¼ç¨äºè¶åæ¡å±å¼æ¶æ¾ç¤ºå¾
å å
¥å¤´å") |
| | | private Set<Long> inviteeIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | /** |
| | | * å ä½ |
| | | */ |
| | | package cn.iocoder.yudao.module.im.controller.app; |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | /** |
| | | * æä¾ RESTful API ç»åç«¯ï¼ |
| | | * 1. admin å
ï¼æä¾ç»ç®¡çåå° yudao-ui-admin åç«¯é¡¹ç® |
| | | * 2. app å
ï¼æä¾ç»ç¨æ· APP yudao-ui-app å端项ç®ï¼å®ç Controller å VO é½è¦æ·»å App åç¼ï¼ç¨äºå管çåå°è¿è¡åºå |
| | | */ |
| | | package cn.iocoder.yudao.module.im.controller; |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | /** |
| | | * IM é¢é DO |
| | | * <p> |
| | | * ä¸å¡è¯ä¹ï¼ |
| | | * - é¢éæ¯è¿è¥å忍éç主ä½ï¼C ç«¯ç¨æ·ä¸è½åé¢éåæ¶æ¯ |
| | | * - {@link #code} æ¯ä¸å¡ç ï¼API / åå
¸å¤é²ï¼ï¼id æ¯æ°å主é®ç»å端ä¼è¯ targetId ç¨ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_channel") |
| | | @KeySequence("im_channel_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImChannelDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * é¢éä¸å¡ç |
| | | */ |
| | | private String code; |
| | | /** |
| | | * é¢éåç§° |
| | | */ |
| | | private String name; |
| | | /** |
| | | * é¢é头å |
| | | */ |
| | | private String avatar; |
| | | /** |
| | | * æåº |
| | | */ |
| | | private Integer sort; |
| | | /** |
| | | * ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.channel; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImChannelMessageDO; |
| | | import cn.iocoder.yudao.module.im.enums.channel.ImChannelMaterialTypeEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | /** |
| | | * IM é¢éç´ æ DO |
| | | * <p> |
| | | * ä¸å¡è¯ä¹ï¼ |
| | | * - è¿è¥ç´ æåºï¼å¯è¢«å夿¨é |
| | | * - 䏿¡ç´ æ 1:N å
³è夿¡ {@link ImChannelMessageDO} |
| | | * - {@link #content} 坿æ¬ä»
å¨ç´ æè¯¦æ
æ¥å£æéè¿åï¼æ¨é payload ä¸å¸¦ï¼é¿å
åç WebSocket éé |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_channel_material") |
| | | @KeySequence("im_channel_material_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImChannelMaterialDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * é¢éç¼å· |
| | | * <p> |
| | | * å
³è {@link ImChannelDO#getId()} |
| | | */ |
| | | private Long channelId; |
| | | /** |
| | | * ç´ æå
容类å |
| | | * <p> |
| | | * æä¸¾ {@link ImChannelMaterialTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * æ é¢ |
| | | */ |
| | | private String title; |
| | | /** |
| | | * å°é¢å¾ |
| | | */ |
| | | private String coverUrl; |
| | | /** |
| | | * æè¦ |
| | | */ |
| | | private String summary; |
| | | /** |
| | | * å¯ææ¬ HTMLï¼å¨ {@link ImChannelMaterialTypeEnum#CONTENT} ä½¿ç¨ |
| | | */ |
| | | private String content; |
| | | /** |
| | | * è·³è½¬é¾æ¥ï¼å¨ {@link ImChannelMaterialTypeEnum#LINK} ä½¿ç¨ |
| | | */ |
| | | private String url; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.conversation; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImChannelMessageDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImGroupMessageDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.message.ImPrivateMessageDO; |
| | | import cn.iocoder.yudao.module.im.enums.ImConversationTypeEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM ä¼è¯è¯»ä½ç½® DO |
| | | * <p> |
| | | * åªè¡¨è¾¾ãç¨æ·å¨æä¸ªä¼è¯çæå¤§å·²è¯»ä½ç½®ãï¼ç§è / 群è / é¢éç»ä¸è½è¿å¼ è¡¨ï¼æ¯è¯»ä½ç½®çå¯ä¸æå¨ã |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_conversation_read") |
| | | @KeySequence("im_conversation_read_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImConversationReadDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * ç¨æ·ç¼å· |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * ä¼è¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImConversationTypeEnum} |
| | | */ |
| | | private Integer conversationType; |
| | | /** |
| | | * ç®æ ç¼å· |
| | | * <p> |
| | | * ç§èå
³è AdminUserDO ç idï¼ç¾¤èå
³è {@link ImGroupDO#getId()}ï¼é¢éå
³è {@link ImChannelDO#getId()} |
| | | */ |
| | | private Long targetId; |
| | | /** |
| | | * æå¤§å·²è¯»æ¶æ¯ç¼å· |
| | | * <p> |
| | | * å
³è {@link ImPrivateMessageDO#getId()}ã{@link ImGroupMessageDO#getId()}ã{@link ImChannelMessageDO#getId()} |
| | | */ |
| | | private Long messageId; |
| | | /** |
| | | * æè¿å·²è¯»æ¶é´ |
| | | */ |
| | | private LocalDateTime readTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | /** |
| | | * IM 表æ
å
DOï¼è¿è¥é
ç½®çç³»ç»è¡¨æ
å
å
æ°æ®ï¼ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_face_pack") |
| | | @KeySequence("im_face_pack_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImFacePackDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 表æ
å
åç§° |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 表æ
å
徿 |
| | | * <p> |
| | | * 颿¿åºé¨ tab æ æ¾ç¤º |
| | | */ |
| | | private String icon; |
| | | /** |
| | | * æåº |
| | | */ |
| | | private Integer sort; |
| | | /** |
| | | * ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.face; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | /** |
| | | * IM 表æ
å
项 DOï¼ç³»ç»è¡¨æ
å
å
çåå¼ è¡¨æ
å¾ï¼ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_face_pack_item") |
| | | @KeySequence("im_face_pack_item_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImFacePackItemDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * æå±è¡¨æ
å
ç¼å· |
| | | */ |
| | | private Long packId; |
| | | /** |
| | | * 表æ
å¾ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * 表æ
åï¼å¯éï¼å¦ãç头ããæè¸ãï¼ |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 渲æå®½åº¦ï¼åç´ ï¼ |
| | | */ |
| | | private Integer width; |
| | | /** |
| | | * 渲æé«åº¦ï¼åç´ ï¼ |
| | | */ |
| | | private Integer height; |
| | | /** |
| | | * æåº |
| | | */ |
| | | private Integer sort; |
| | | /** |
| | | * ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.face; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | /** |
| | | * IM ç¨æ·ç§æè¡¨æ
DOï¼ä¸ªäººè¡¨æ
å
ï¼å¯¹ç
§å¾®ä¿¡ãæç表æ
ãï¼ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_face_user_item") |
| | | @KeySequence("im_face_user_item_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImFaceUserItemDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * æå±ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id ç¼å· |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * 表æ
å¾ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * 表æ
åï¼å¯éï¼ |
| | | * <p> |
| | | * ç¨æ·ç§æè¡¨æ
é常ä¸å¸¦ååï¼çåæ®µä»¥å¤å°æ¥ãéå½åãäº¤äº |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 渲æå®½åº¦ï¼åç´ ï¼ |
| | | */ |
| | | private Integer width; |
| | | /** |
| | | * 渲æé«åº¦ï¼åç´ ï¼ |
| | | */ |
| | | private Integer height; |
| | | /** |
| | | * æåº |
| | | */ |
| | | private Integer sort; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.friend; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM 好åå
³ç³» DO |
| | | * <p> |
| | | * ä¸å¡è¯ä¹ï¼ |
| | | * - ååå
³ç³»ï¼A-B äºä¸ºå¥½åä¼å 2 æ¡è®°å½ï¼userId=A, friendUserId=B å userId=B, friendUserId=Aï¼ |
| | | * - ç¶æç®¡çï¼{@link #status} ä½¿ç¨ {@link CommonStatusEnum}ï¼ENABLE=æ£å¸¸ï¼DISABLE=å·²å é¤ |
| | | * - å
ææ°ï¼{@link #silent} æ§å¶æ¯å¦å±è½æ¥èªè¯¥å¥½åçéç¥ |
| | | * - è系人置顶ï¼{@link #pinned} åè¾¹ï¼å½±åè系人 / ä¼è¯æåº |
| | | * - é»ååï¼{@link #blocked} å¼±å
³è friendï¼åè¾¹å±è½å¯¹æ¹æ¶æ¯ï¼å¿
é¡»å
æ¯å¥½åï¼ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_friend") |
| | | @KeySequence("im_friend_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImFriendDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * 好åç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long friendUserId; |
| | | /** |
| | | * æ¯å¦å
ææ° |
| | | */ |
| | | private Boolean silent; |
| | | /** |
| | | * 好åå±ç¤ºå¤æ³¨ |
| | | */ |
| | | private String displayName; |
| | | /** |
| | | * æ·»å æ¥æº |
| | | * <p> |
| | | * æä¸¾ {@link cn.iocoder.yudao.module.im.enums.friend.ImFriendAddSourceEnum} |
| | | */ |
| | | private Integer addSource; |
| | | /** |
| | | * æ¯å¦ç½®é¡¶è系人 |
| | | */ |
| | | private Boolean pinned; |
| | | /** |
| | | * æ¯å¦æé»ï¼å¼±å
³è friendï¼åè¾¹å±è½å¯¹æ¹ç§èæ¶æ¯ï¼ |
| | | */ |
| | | private Boolean blocked; |
| | | /** |
| | | * 好åç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * æ·»å å¥½åæ¶é´ |
| | | */ |
| | | private LocalDateTime addTime; |
| | | /** |
| | | * å é¤å¥½åæ¶é´ |
| | | * <p> |
| | | * ä¸ä¸º null æ¶è¡¨ç¤ºå·²å é¤ |
| | | */ |
| | | private LocalDateTime deleteTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.friend; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.enums.friend.ImFriendAddSourceEnum; |
| | | import cn.iocoder.yudao.module.im.enums.friend.ImFriendRequestHandleResultEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM 好åç³è¯·è®°å½ DO |
| | | * <p> |
| | | * é
åãç³è¯· - 审æ¹ãæµç¨ï¼ |
| | | * - åèµ·æ¹è° apply æ¥å£è½åºï¼handleResult=UNHANDLEDï¼ |
| | | * - æ¥æ¶æ¹è° agree / refuse å¤çï¼æ´æ° handleResult / handleTime / handleContentï¼ |
| | | * - ç³è¯·éè¿åï¼displayName / addSource 忥åå
¥ {@link ImFriendDO} |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_friend_request") |
| | | @KeySequence("im_friend_request_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImFriendRequestDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * åèµ·æ¹ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long fromUserId; |
| | | /** |
| | | * æ¥æ¶æ¹ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long toUserId; |
| | | |
| | | // ========== ç³è¯·åèµ·é¶æ®µï¼åèµ·æ¹å¡«åï¼ ========== |
| | | /** |
| | | * ç³è¯·çç± |
| | | */ |
| | | private String applyContent; |
| | | /** |
| | | * åèµ·æ¹å¯¹æ¥æ¶æ¹ç夿³¨ |
| | | * <p> |
| | | * åæååå
¥ A ä¾§ {@link ImFriendDO#getDisplayName()}ï¼B ä¾§ä¸å¨ |
| | | */ |
| | | private String displayName; |
| | | /** |
| | | * æ·»å æ¥æº |
| | | * <p> |
| | | * æä¸¾ {@link ImFriendAddSourceEnum} |
| | | */ |
| | | private Integer addSource; |
| | | |
| | | // ========== ç³è¯·å¤çé¶æ®µï¼æ¥æ¶æ¹å¡«åï¼ ========== |
| | | /** |
| | | * å¤çç»æ |
| | | * <p> |
| | | * æä¸¾ {@link ImFriendRequestHandleResultEnum} |
| | | */ |
| | | private Integer handleResult; |
| | | /** |
| | | * å¤ççç±ï¼æ¥æ¶æ¹æç»æ¶å¯éå¡«ï¼ |
| | | */ |
| | | private String handleContent; |
| | | /** |
| | | * å¤çæ¶é´ |
| | | */ |
| | | private LocalDateTime handleTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.group; |
| | | |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.framework.mybatis.core.type.LongListTypeHandler; |
| | | 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 lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * IM ç¾¤ä¿¡æ¯ DO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName(value = "im_group",autoResultMap = true) |
| | | @KeySequence("im_group_seq") // ç¨äº OracleãPostgreSQLãKingbaseãDB2ãH2 æ°æ®åºç主é®èªå¢ãå¦ææ¯ MySQL çæ°æ®åºï¼å¯ä¸åã |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImGroupDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 群åç§° |
| | | */ |
| | | private String name; |
| | | /** |
| | | * ç¾¤ä¸»ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long ownerUserId; |
| | | /** |
| | | * 群头å |
| | | */ |
| | | private String avatar; |
| | | /** |
| | | * 群å
Œ |
| | | */ |
| | | private String notice; |
| | | /** |
| | | * è¿ç¾¤æ¯å¦é群主 / 管çåå®¡æ¹ |
| | | * <p> |
| | | * false èªç±è¿ç¾¤ï¼é»è®¤ï¼ï¼true é审æ¹ï¼ææãç³è¯·ããé请ãè·¯å¾é½é群主 / 管çååæ |
| | | */ |
| | | private Boolean joinApproval; |
| | | /** |
| | | * æ¯å¦å°ç¦ |
| | | */ |
| | | private Boolean banned; |
| | | /** |
| | | * å°ç¦åå |
| | | */ |
| | | private String bannedReason; |
| | | /** |
| | | * å°ç¦æ¶é´ |
| | | */ |
| | | private LocalDateTime bannedTime; |
| | | /** |
| | | * ç¾¤ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | * ENABLE = æ£å¸¸ï¼DISABLE = å·²è§£æ£ |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * è§£æ£æ¶é´ |
| | | */ |
| | | private LocalDateTime dissolvedTime; |
| | | /** |
| | | * æ¯å¦å
¨ç¾¤ç¦è¨ |
| | | */ |
| | | private Boolean mutedAll; |
| | | /** |
| | | * ç¾¤ç½®é¡¶æ¶æ¯ç¼å·å表 |
| | | * <p> |
| | | * ä»
å messageIdï¼æä½äºº / 置顶æ¶é´ä»å¯¹åº PIN äºä»¶çæ¶æ¯è®°å½é忥 |
| | | */ |
| | | @TableField(typeHandler = LongListTypeHandler.class) |
| | | private List<Long> pinnedMessageIds; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.group; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupAddSourceEnum; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupMemberRoleEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM 群æå DO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_group_member") |
| | | @KeySequence("im_group_member_seq") // ç¨äº OracleãPostgreSQLãKingbaseãDB2ãH2 æ°æ®åºç主é®èªå¢ãå¦ææ¯ MySQL çæ°æ®åºï¼å¯ä¸åã |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImGroupMemberDO extends BaseDO { |
| | | |
| | | /** |
| | | * æ°¸ä¹
ç¦è¨å°ææ¶é´ |
| | | */ |
| | | public static final LocalDateTime PERMANENT_MUTE_END_TIME = LocalDateTime.of(9999, 12, 31, 23, 59, 59); |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 群ç¼å· |
| | | * <p> |
| | | * å
³è {@link ImGroupDO#getId()} |
| | | */ |
| | | private Long groupId; |
| | | /** |
| | | * ç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * ç»å
æ¾ç¤ºå |
| | | */ |
| | | private String displayUserName; |
| | | /** |
| | | * ç¾¤å¤æ³¨ |
| | | */ |
| | | private String groupRemark; |
| | | /** |
| | | * æ¯å¦å
ææ° |
| | | */ |
| | | private Boolean silent; |
| | | /** |
| | | * æåç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link CommonStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * æåè§è² |
| | | * <p> |
| | | * æä¸¾ {@link ImGroupMemberRoleEnum} |
| | | */ |
| | | private Integer role; |
| | | /** |
| | | * å
¥ç¾¤æ¶é´ |
| | | */ |
| | | private LocalDateTime joinTime; |
| | | /** |
| | | * å å
¥æ¥æº |
| | | * <p> |
| | | * æä¸¾ {@link ImGroupAddSourceEnum} |
| | | */ |
| | | private Integer addSource; |
| | | /** |
| | | * éè¯·äººç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µï¼ç¨æ·ä¸»å¨ç³è¯·è¿ç¾¤æ¶ä¸º NULL |
| | | */ |
| | | private Long inviterUserId; |
| | | /** |
| | | * é群æ¶é´ |
| | | */ |
| | | private LocalDateTime quitTime; |
| | | /** |
| | | * ç¦è¨å°ææ¶é´ |
| | | * <p> |
| | | * null 表示æªç¦è¨ï¼é null ä¸å¨æªæ¥è¡¨ç¤ºç¦è¨ä¸ï¼ |
| | | */ |
| | | private LocalDateTime muteEndTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.group; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupAddSourceEnum; |
| | | import cn.iocoder.yudao.module.im.enums.group.ImGroupRequestHandleResultEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM å 群ç³è¯·è®°å½ DO |
| | | * <p> |
| | | * é
åãç³è¯· - 审æ¹ãæµç¨ï¼ |
| | | * <ul> |
| | | * <li>ç¨æ·ä¸»å¨ç³è¯·ï¼è° apply æ¥å£è½åºï¼inviterUserId=nullï¼handleResult=UNHANDLEDï¼ï¼ç¾¤ä¸» / 管çå审æ¹</li> |
| | | * <li>æ®éæåé请ï¼ç¾¤ joinType=APPLY_AND_NORMAL_INVITE æ¶è½åºï¼inviterUserId=æä½äººï¼ï¼ç¾¤ä¸» / 管çå审æ¹</li> |
| | | * <li>å¤çï¼ç¾¤ä¸» / 管çåè° agree / refuse æ¨è¿ç¶ææºï¼åææ¶æ addSource / inviterUserId 忥åå
¥ {@link ImGroupMemberDO}</li> |
| | | * </ul> |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_group_request") |
| | | @KeySequence("im_group_request_seq") // ç¨äº OracleãPostgreSQLãKingbaseãDB2ãH2 æ°æ®åºç主é®èªå¢ï¼MySQL çå¯ä¸å |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImGroupRequestDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 群ç¼å· |
| | | * <p> |
| | | * å
³è {@link ImGroupDO#getId()} |
| | | */ |
| | | private Long groupId; |
| | | /** |
| | | * ç³è¯·äºº / 被éè¯·äººç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long userId; |
| | | /** |
| | | * éè¯·äººç¨æ·ç¼å· |
| | | * <p> |
| | | * NULL è¡¨ç¤ºç¨æ·ä¸»å¨ç³è¯·è¿ç¾¤ï¼é NULL 表示ç±ç¾¤æåé请ãå¾
群主 / 管çåå®¡æ¹ |
| | | */ |
| | | private Long inviterUserId; |
| | | |
| | | // ========== ç³è¯·åèµ·é¶æ®µ ========== |
| | | /** |
| | | * ç³è¯·çç± |
| | | */ |
| | | private String applyContent; |
| | | /** |
| | | * å å
¥æ¥æº |
| | | * <p> |
| | | * æä¸¾ {@link ImGroupAddSourceEnum}ï¼åææ¶åæ¥åå
¥ {@link ImGroupMemberDO#getAddSource()} |
| | | */ |
| | | private Integer addSource; |
| | | |
| | | // ========== ç³è¯·å¤çé¶æ®µ ========== |
| | | /** |
| | | * å¤çç»æ |
| | | * <p> |
| | | * æä¸¾ {@link ImGroupRequestHandleResultEnum} |
| | | */ |
| | | private Integer handleResult; |
| | | /** |
| | | * å¤çäººç¨æ·ç¼å·ï¼ç¾¤ä¸»æç®¡çåï¼ |
| | | */ |
| | | private Long handleUserId; |
| | | /** |
| | | * å¤ççç±ï¼æç»æ¶å¯éå¡«ï¼ |
| | | */ |
| | | private String handleContent; |
| | | /** |
| | | * å¤çæ¶é´ |
| | | */ |
| | | private LocalDateTime handleTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.framework.mybatis.core.type.LongListTypeHandler; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.channel.ImChannelMaterialDO; |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | 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 lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * IM é¢éæ¶æ¯ DO |
| | | * <p> |
| | | * ä¸å¡è¯ä¹ï¼ |
| | | * - 䏿¬¡æ¨é 1 è¡ï¼{@link #receiverUserIds} 为空表示å
¨å |
| | | * - {@link #channelId} åä½ {@link ImChannelMaterialDO#getChannelId()} ä¾¿äºæé¢éæ£ç´¢ |
| | | * - {@link #content} 忍鿶 payload ç JSON å¿«ç
§ï¼title / coverUrl / summary / urlï¼ï¼ä¸å«å¯ææ¬æ£æ |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName(value = "im_channel_message", autoResultMap = true) |
| | | @KeySequence("im_channel_message_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImChannelMessageDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * é¢éç¼å· |
| | | * <p> |
| | | * å
³è {@link ImChannelDO#getId()}ï¼åä½ä¾¿äºæé¢éæ£ç´¢ |
| | | */ |
| | | private Long channelId; |
| | | /** |
| | | * å
³èç´ æç¼å· |
| | | * <p> |
| | | * å
³è {@link ImChannelMaterialDO#getId()} |
| | | */ |
| | | private Long materialId; |
| | | /** |
| | | * æ¶æ¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImContentTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * æ¶æ¯å
å®¹ï¼æ¨éæ¶ payload ç JSON å¿«ç
§ |
| | | */ |
| | | private String content; |
| | | /** |
| | | * æ¥æ¶äººç¼å·å表ï¼ä¸ºç©ºè¡¨ç¤ºå
¨å |
| | | */ |
| | | @TableField(typeHandler = LongListTypeHandler.class) |
| | | private List<Long> receiverUserIds; |
| | | /** |
| | | * åéæ¶é´ |
| | | */ |
| | | private LocalDateTime sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.framework.mybatis.core.type.LongListTypeHandler; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.enums.message.ImMessageReceiptStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.message.ImMessageStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | 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 lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * IM ç¾¤èæ¶æ¯ DO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName(value = "im_group_message", autoResultMap = true) |
| | | @KeySequence("im_group_message_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImGroupMessageDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 客æ·ç«¯æ¶æ¯ç¼å·ï¼ç¨äºåéå¹ç |
| | | */ |
| | | private String clientMessageId; |
| | | /** |
| | | * åé人ç¼å· |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long senderId; |
| | | /** |
| | | * 群ç¼å· |
| | | * |
| | | * å
³è {@link ImGroupDO#getId()} |
| | | */ |
| | | private Long groupId; |
| | | /** |
| | | * æ¶æ¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImContentTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * æ¶æ¯å
容ï¼JSON æ ¼å¼ |
| | | * |
| | | * åè content å
ä¸ç TextMessageãImageMessage çç»æåæ¨¡å |
| | | */ |
| | | private String content; |
| | | /** |
| | | * æ¶æ¯ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link ImMessageStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * åéæ¶é´ |
| | | */ |
| | | private LocalDateTime sendTime; |
| | | /** |
| | | * å®åæ¥æ¶ç¨æ·ç¼å·å表ï¼ä»¥éå·åé |
| | | * <p> |
| | | * 为空表示å
¨åå¯è§ |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | @TableField(typeHandler = LongListTypeHandler.class) |
| | | private List<Long> receiverUserIds; |
| | | /** |
| | | * @ ç®æ ç¨æ·ç¼å·å表ï¼ä»¥éå·åé |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | @TableField(typeHandler = LongListTypeHandler.class) |
| | | private List<Long> atUserIds; |
| | | /** |
| | | * åæ§ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link ImMessageReceiptStatusEnum} |
| | | */ |
| | | private Integer receiptStatus; |
| | | |
| | | // ========== éè¡¨åæ®µ ========== |
| | | |
| | | /** |
| | | * 离线æåçåºæ¯ä¸åç®çå·²è¯»äººæ° |
| | | */ |
| | | @TableField(exist = false) |
| | | private Integer readCount; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.enums.message.ImMessageReceiptStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.message.ImMessageStatusEnum; |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM ç§èæ¶æ¯ DO |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_private_message") |
| | | @KeySequence("im_private_message_seq") |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImPrivateMessageDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * 客æ·ç«¯æ¶æ¯ç¼å·ï¼ç¨äºåéå¹ç |
| | | */ |
| | | private String clientMessageId; |
| | | /** |
| | | * åé人ç¼å· |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long senderId; |
| | | /** |
| | | * æ¥æ¶äººç¼å· |
| | | * |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long receiverId; |
| | | /** |
| | | * æ¶æ¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImContentTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * æ¶æ¯å
容ï¼JSON æ ¼å¼ |
| | | * |
| | | * åè content å
ä¸ç TextMessageãImageMessage çç»æåæ¨¡å |
| | | */ |
| | | private String content; |
| | | /** |
| | | * æ¶æ¯ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link ImMessageStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * åæ§ç¶æ |
| | | * <p> |
| | | * æä¸¾ {@link ImMessageReceiptStatusEnum} |
| | | */ |
| | | private Integer receiptStatus; |
| | | /** |
| | | * åéæ¶é´ |
| | | */ |
| | | private LocalDateTime sendTime; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * è¯é³æ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class AudioMessage { |
| | | |
| | | /** |
| | | * è¯é³æä»¶ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * è¯é³æ¶é¿ï¼ç§ï¼ |
| | | */ |
| | | private Integer duration; |
| | | /** |
| | | * æä»¶å¤§å°ï¼åèï¼ |
| | | */ |
| | | private Long size; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import cn.iocoder.yudao.module.im.enums.ImConversationTypeEnum; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * åçæ¶æ¯å
容 |
| | | * <p> |
| | | * æ¯æä¸¤ç±»åçï¼æ targetType åºåï¼ |
| | | * 1. ç¨æ·åçï¼targetType = PRIVATEï¼ï¼targetId = ç¨æ·ç¼å·ï¼name = ç¨æ·æµç§° |
| | | * 2. 群åçï¼targetType = GROUPï¼ï¼targetId = 群ç¼å·ï¼name = 群åï¼å¯å¸¦ memberCount |
| | | */ |
| | | @Data |
| | | public class CardMessage { |
| | | |
| | | /** |
| | | * åç对象类å |
| | | * <p> |
| | | * æä¸¾ {@link ImConversationTypeEnum} |
| | | */ |
| | | private Integer targetType; |
| | | /** |
| | | * ç®æ 对象ç¼å·ï¼PRIVATE æ¶ = ç¨æ·ç¼å·ï¼GROUP æ¶ = 群ç¼å· |
| | | */ |
| | | private Long targetId; |
| | | /** |
| | | * æ¾ç¤ºåå¿«ç
§ï¼PRIVATE æ¶ = ç¨æ·æµç§°ï¼GROUP æ¶ = 群å |
| | | */ |
| | | private String name; |
| | | /** |
| | | * 头åï¼å¿«ç
§ï¼ |
| | | */ |
| | | private String avatar; |
| | | /** |
| | | * 群æåæ°ï¼ä»
targetType = GROUPï¼æ¥æ¶ç«¯å±ç¤ºãN 人群èãï¼ |
| | | */ |
| | | private Integer memberCount; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * 表æ
æ¶æ¯å
容 |
| | | * <p> |
| | | * æ¿è½½ãè´´å¾ / èªå®ä¹è¡¨æ
å
ãç±»æ¶æ¯ï¼Unicode emojiï¼ððï¼ä»èµ° TEXT |
| | | */ |
| | | @Data |
| | | public class FaceMessage { |
| | | |
| | | /** |
| | | * 表æ
å¾ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * 渲æå®½åº¦ï¼åç´ ï¼å¯éï¼ |
| | | * <p> |
| | | * 客æ·ç«¯æ¸²ææ¶ææ¤å°ºå¯¸å ä½ï¼é¿å
å¾çå è½½å®æåçå¸å±æå¨ï¼ç¼ºå¤±æ¶ç±å®¢æ·ç«¯ CSS max-width å
åº |
| | | */ |
| | | private Integer width; |
| | | /** |
| | | * 渲æé«åº¦ï¼åç´ ï¼å¯éï¼ |
| | | */ |
| | | private Integer height; |
| | | /** |
| | | * 表æ
åï¼å¯éï¼ |
| | | * <p> |
| | | * ç³»ç»è¡¨æ
å
é常带ååï¼å¦ãç头ããæè¸ãï¼ï¼ç¨æ·ç§æè¡¨æ
å
é常为空 |
| | | */ |
| | | private String name; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * æä»¶æ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class FileMessage { |
| | | |
| | | /** |
| | | * æä»¶ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * æä»¶å |
| | | */ |
| | | private String name; |
| | | /** |
| | | * æä»¶å¤§å°ï¼åèï¼ |
| | | */ |
| | | private Long size; |
| | | /** |
| | | * æä»¶ç±»åï¼æ©å±åï¼ |
| | | */ |
| | | private String type; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * å¾çæ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class ImageMessage { |
| | | |
| | | /** |
| | | * å¾ç URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * 缩ç¥å¾ URL |
| | | */ |
| | | private String thumbnailUrl; |
| | | /** |
| | | * å¾ç宽度 |
| | | */ |
| | | private Integer width; |
| | | /** |
| | | * å¾çé«åº¦ |
| | | */ |
| | | private Integer height; |
| | | /** |
| | | * å¾ç大å°ï¼åèï¼ |
| | | */ |
| | | private Long size; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * ä½ç½®æ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class LocationMessage { |
| | | |
| | | /** |
| | | * ä½ç½®æè¿° |
| | | */ |
| | | private String description; |
| | | /** |
| | | * ç»åº¦ |
| | | */ |
| | | private Double longitude; |
| | | /** |
| | | * 纬度 |
| | | */ |
| | | private Double latitude; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * é¢éç´ ææ¶æ¯ payload |
| | | * <p> |
| | | * å¯¹åº {@link cn.iocoder.yudao.module.im.enums.ImContentTypeEnum#MATERIAL}ï¼type=125ï¼ã |
| | | * 客æ·ç«¯ææ¬åæ®µéæ¸²æå¾æå¡çï¼ |
| | | * å¯ææ¬æ£æä¸å¨æ¬ payload ä¸ä¼ éï¼ç¹å»è¯¦æ
æ¶å¦è° /im/channel/material/get-content?id= æéæåã |
| | | */ |
| | | @Data |
| | | @Accessors(chain = true) |
| | | public class MaterialMessage { |
| | | |
| | | /** |
| | | * ç´ æç¼å· |
| | | */ |
| | | private Long materialId; |
| | | /** |
| | | * é¢éç¼å· |
| | | * <p> |
| | | * åä½å° payload å
ï¼è½¬åå°ç§è / 群èå客æ·ç«¯ç¨æ¬å段å®ä½é¢éï¼æ¸²æå¡çåºé¨çé¢é头å + åç§° |
| | | */ |
| | | private Long channelId; |
| | | /** |
| | | * ç´ æå
容类å |
| | | * <p> |
| | | * æä¸¾ {@link cn.iocoder.yudao.module.im.enums.channel.ImChannelMaterialTypeEnum} |
| | | * 客æ·ç«¯ææ¬å段å¤å®ç¹å»è¡ä¸ºï¼CONTENT èµ°ç«å
详æ
页æå¯ææ¬ï¼LINK è·³ url |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * æ é¢ |
| | | */ |
| | | private String title; |
| | | /** |
| | | * å°é¢å¾ |
| | | */ |
| | | private String coverUrl; |
| | | /** |
| | | * æè¦ |
| | | */ |
| | | private String summary; |
| | | /** |
| | | * è·³è½¬é¾æ¥ |
| | | */ |
| | | private String url; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * åå¹¶è½¬åæ¶æ¯å
容 |
| | | * <p> |
| | | * payload å
åµå®æ´å¿«ç
§ï¼åæ¶æ¯æ¤å / å é¤ä¸å½±å已转åçåå¹¶æ¶æ¯ |
| | | */ |
| | | @Data |
| | | public class MergeMessage { |
| | | |
| | | /** |
| | | * åå¹¶æ é¢ |
| | | */ |
| | | private String title; |
| | | /** |
| | | * å
åµç宿´æ¶æ¯å¿«ç
§ |
| | | */ |
| | | private List<Item> messages; |
| | | |
| | | /** |
| | | * åæ¡å
嵿¶æ¯å¿«ç
§ |
| | | */ |
| | | @Data |
| | | public static class Item { |
| | | |
| | | /** |
| | | * åæ¶æ¯ç¼å· |
| | | */ |
| | | private Long messageId; |
| | | /** |
| | | * åé人ç¼å· |
| | | */ |
| | | private Long senderId; |
| | | /** |
| | | * åé人æµç§°å¿«ç
§ï¼æ¥æ¶æ¹å¯è½ä¸å¨åä¼è¯éï¼æ æ³å®æ¶æ¥å° |
| | | */ |
| | | private String senderNickname; |
| | | /** |
| | | * åé人头åå¿«ç
§ |
| | | */ |
| | | private String senderAvatar; |
| | | /** |
| | | * æ¶æ¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImContentTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * åæ¶æ¯ contentï¼JSONï¼ |
| | | */ |
| | | private String content; |
| | | /** |
| | | * åéæ¶é´æ³ï¼æ¯«ç§ï¼ |
| | | */ |
| | | private Long sendTime; |
| | | |
| | | } |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import cn.iocoder.yudao.module.im.enums.ImContentTypeEnum; |
| | | import lombok.Data; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯å
容 |
| | | * <p> |
| | | * 客æ·ç«¯å¨ content.quote éåå
¥ messageId 表达"å¼ç¨äºåªæ¡æ¶æ¯"ï¼æå¡ç«¯åæ¥åæ¶æ¯åéç® QuoteMessage è¦ç客æ·ç«¯åå
¥ï¼ |
| | | * é¿å
伪é åé人 / ç±»å / æè¦ |
| | | * |
| | | * @see TextMessage ççæ¶æ¯å
容é quote åæ®µ |
| | | */ |
| | | @Data |
| | | @Accessors(chain = true) |
| | | public class QuoteMessage { |
| | | |
| | | /** |
| | | * content JSON é quote åæ®µå |
| | | */ |
| | | public static final String FIELD_NAME = "quote"; |
| | | |
| | | /** |
| | | * QuoteMessage é messageId åæ®µå |
| | | */ |
| | | public static final String FIELD_MESSAGE_ID = "messageId"; |
| | | |
| | | /** |
| | | * 被å¼ç¨æ¶æ¯ç¼å· |
| | | */ |
| | | private Long messageId; |
| | | /** |
| | | * 被å¼ç¨æ¶æ¯åé人ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long senderId; |
| | | /** |
| | | * 被å¼ç¨æ¶æ¯ç±»å |
| | | * <p> |
| | | * æä¸¾ {@link ImContentTypeEnum} |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * åæ¶æ¯å®æ´ content(JSON);æå¡ç«¯å¤å¶æ¶ä¼ removeQuote é²åµå¥ |
| | | */ |
| | | private String content; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * æ¤åæç¤ºæ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | @Accessors(chain = true) |
| | | public class RecallMessage { |
| | | |
| | | /** |
| | | * 被æ¤åçåæ¶æ¯ç¼å· |
| | | */ |
| | | private Long messageId; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * ææ¬æ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class TextMessage { |
| | | |
| | | /** |
| | | * ææ¬å
容 |
| | | */ |
| | | private String content; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.message.content; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * è§é¢æ¶æ¯å
容 |
| | | */ |
| | | @Data |
| | | public class VideoMessage { |
| | | |
| | | /** |
| | | * è§é¢æä»¶ URL |
| | | */ |
| | | private String url; |
| | | /** |
| | | * è§é¢å°é¢ URL |
| | | */ |
| | | private String coverUrl; |
| | | /** |
| | | * è§é¢æ¶é¿ï¼ç§ï¼ |
| | | */ |
| | | private Integer duration; |
| | | /** |
| | | * è§é¢å®½åº¦ |
| | | */ |
| | | private Integer width; |
| | | /** |
| | | * è§é¢é«åº¦ |
| | | */ |
| | | private Integer height; |
| | | /** |
| | | * æä»¶å¤§å°ï¼åèï¼ |
| | | */ |
| | | private Long size; |
| | | |
| | | /** |
| | | * å¼ç¨æ¶æ¯ï¼å¯éï¼ |
| | | */ |
| | | private QuoteMessage quote; |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package cn.iocoder.yudao.module.im.dal.dataobject.rtc; |
| | | |
| | | import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO; |
| | | import cn.iocoder.yudao.module.im.dal.dataobject.group.ImGroupDO; |
| | | import cn.iocoder.yudao.module.im.enums.ImConversationTypeEnum; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcCallEndReasonEnum; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcCallMediaTypeEnum; |
| | | import cn.iocoder.yudao.module.im.enums.rtc.ImRtcCallStatusEnum; |
| | | import com.baomidou.mybatisplus.annotation.KeySequence; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import lombok.*; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * IM éè¯è®°å½ DOï¼æ¿é´çº§ / ä¸»è¡¨ï¼ |
| | | * <p> |
| | | * ä¸ééè¯ä¸è¡ï¼ç¶ææº CREATED â RUNNING â ENDEDï¼åæç»è¡¨ {@link ImRtcParticipantDO} éè¿ {@link #room} å
³è |
| | | * |
| | | * @author èéæºç |
| | | */ |
| | | @TableName("im_rtc_call") |
| | | @KeySequence("im_rtc_call_seq") // ç¨äº OracleãPostgreSQLãKingbaseãDB2ãH2 æ°æ®åºç主é®èªå¢ï¼MySQL çæ°æ®åºå¯ä¸å |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ToString(callSuper = true) |
| | | @Builder |
| | | @NoArgsConstructor |
| | | @AllArgsConstructor |
| | | public class ImRtcCallDO extends BaseDO { |
| | | |
| | | /** |
| | | * ç¼å· |
| | | */ |
| | | @TableId |
| | | private Long id; |
| | | /** |
| | | * ä¸å¡éè¯ç¼å·ï¼UUIDï¼åæ¶ä½ä¸º LiveKit æ¿é´åï¼ï¼å¯ä¸ |
| | | */ |
| | | private String room; |
| | | /** |
| | | * ä¼è¯ç±»å |
| | | * |
| | | * æä¸¾ {@link ImConversationTypeEnum} |
| | | */ |
| | | private Integer conversationType; |
| | | /** |
| | | * åªä½ç±»å |
| | | * |
| | | * æä¸¾ {@link ImRtcCallMediaTypeEnum} |
| | | */ |
| | | private Integer mediaType; |
| | | /** |
| | | * åèµ·äººç¨æ·ç¼å· |
| | | * <p> |
| | | * å
³è AdminUserDO ç id åæ®µ |
| | | */ |
| | | private Long inviterUserId; |
| | | /** |
| | | * 群ç¼å·ï¼ç§è为 NULL |
| | | * <p> |
| | | * å
³è {@link ImGroupDO#getId()} |
| | | */ |
| | | private Long groupId; |
| | | /** |
| | | * éè¯ç¶æ |
| | | * |
| | | * æä¸¾ {@link ImRtcCallStatusEnum} |
| | | */ |
| | | private Integer status; |
| | | /** |
| | | * ç»æåå ï¼éè¯æªç»ææ¶ä¸º NULL |
| | | * |
| | | * æä¸¾ {@link ImRtcCallEndReasonEnum} |
| | | */ |
| | | private Integer endReason; |
| | | /** |
| | | * åèµ·æ¶é´ |
| | | */ |
| | | private LocalDateTime startTime; |
| | | /** |
| | | * æ¥éæ¶é´ |
| | | * |
| | | * é¦ä¸ªéå起人å å
¥æ¶åå
¥ï¼æªæ¥éä¿æ NULL |
| | | */ |
| | | private LocalDateTime acceptTime; |
| | | /** |
| | | * éè¯ç»ææ¶é´ |
| | | */ |
| | | private LocalDateTime endTime; |
| | | |
| | | } |
| yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/dataobject/rtc/ImRtcParticipantDO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/dataobject/sensitiveword/ImSensitiveWordDO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/channel/ImChannelMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/channel/ImChannelMaterialMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/conversation/ImConversationReadMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/face/ImFacePackItemMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/face/ImFacePackMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/face/ImFaceUserItemMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/friend/ImFriendMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/friend/ImFriendRequestMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/group/ImGroupMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/group/ImGroupMemberMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/group/ImGroupRequestMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/message/ImChannelMessageMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/message/ImGroupMessageMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/message/ImPrivateMessageMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/rtc/ImRtcCallMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/rtc/ImRtcParticipantMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/sensitiveword/ImSensitiveWordMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/mysql/statistics/ImStatisticsManagerMapper.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/redis/RedisKeyConstants.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/dal/redis/rtc/ImRtcCallLockRedisDAO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/ErrorCodeConstants.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/ImCommonConstants.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/ImContentTypeEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/ImConversationTypeEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/channel/ImChannelMaterialTypeEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/friend/ImFriendAddSourceEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/friend/ImFriendRequestHandleResultEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/friend/ImFriendStateEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/group/ImGroupAddSourceEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/group/ImGroupMemberRoleEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/group/ImGroupRequestHandleResultEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/message/ImMessageReceiptStatusEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/message/ImMessageStatusEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/rtc/ImRtcCallEndReasonEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/rtc/ImRtcCallMediaTypeEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/rtc/ImRtcCallStatusEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/rtc/ImRtcParticipantRoleEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/enums/rtc/ImRtcParticipantStatusEnum.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/config/ImProperties.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/package-info.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/rtc/config/ImRtcConfiguration.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/rtc/core/LiveKitClient.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/rtc/core/LiveKitWebhookEventDTO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/web/config/ImWebConfiguration.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/framework/web/package-info.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/job/rtc/ImRtcCallCleanupJob.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/job/rtc/ImRtcParticipantTimeoutJob.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/mq/consumer/friend/AdminUserProfileUpdateConsumer.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/package-info.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/channel/ImChannelMaterialService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/channel/ImChannelMaterialServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/channel/ImChannelService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/channel/ImChannelServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/conversation/ImConversationReadService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/conversation/ImConversationReadServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFacePackItemService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFacePackItemServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFacePackService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFacePackServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFaceUserItemService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/face/ImFaceUserItemServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/friend/ImFriendRequestService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/friend/ImFriendRequestServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/friend/ImFriendService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/friend/ImFriendServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupMemberService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupMemberServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupRequestService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupRequestServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/group/ImGroupServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImChannelMessageService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImChannelMessageServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImGroupMessageService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImGroupMessageServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImPrivateMessageService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/ImPrivateMessageServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/dto/ImGroupMessageSendDTO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/message/dto/ImPrivateMessageSendDTO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/rtc/ImRtcCallService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/rtc/ImRtcCallServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/sensitiveword/ImSensitiveWordService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/sensitiveword/ImSensitiveWordServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/statistics/ImStatisticsManagerService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/statistics/ImStatisticsManagerServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/ImWebSocketService.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/ImWebSocketServiceImpl.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/ImNotificationWebSocketDTO.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/BaseFriendNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendAddNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendBlockNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendDeleteNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendInfoUpdatedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendRequestApprovedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendRequestNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendRequestRejectedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendUnblockNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/friend/FriendUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/BaseGroupNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupAdminAddNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupAdminRemoveNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupBannedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupCancelMutedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupCreateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupDissolveNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupInfoUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberCancelMutedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberEnterNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberInviteNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberKickNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberListNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberMutedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberNicknameUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberQuitNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMemberSettingUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMessagePinNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMessageUnpinNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupMutedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupNameUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupNoticeUpdateNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupOwnerTransferNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupRequestApprovedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupRequestReceivedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/group/GroupRequestRejectedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/message/ImChannelMessageNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/message/ImGroupMessageNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/message/ImMessageReadNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/message/ImMessageReceiptNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/message/ImPrivateMessageNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/package-info.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/rtc/ImRtcCallEndNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/rtc/ImRtcCallNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/rtc/ImRtcCallStartNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/rtc/ImRtcParticipantConnectedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/service/websocket/notification/rtc/ImRtcParticipantDisconnectedNotification.java
yudao-module-im/src/main/java/cn/iocoder/yudao/module/im/util/ImMessageUtils.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/dal/mysql/conversation/ImConversationReadMapperTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/dal/mysql/friend/ImFriendRequestMapperTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/dal/mysql/message/ImGroupMessageMapperTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/dal/mysql/message/ImPrivateMessageMapperTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/dal/mysql/statistics/ImStatisticsManagerMapperTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/face/ImFacePackItemServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/face/ImFacePackServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/face/ImFaceUserItemServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/friend/ImFriendRequestServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/friend/ImFriendServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/group/ImGroupMemberServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/group/ImGroupRequestServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/group/ImGroupServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/message/ImChannelMessageServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/message/ImGroupMessageServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/message/ImPrivateMessageServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/rtc/ImRtcCallServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/sensitiveword/ImSensitiveWordServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/statistics/ImStatisticsManagerServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/service/websocket/ImWebSocketServiceImplTest.java
yudao-module-im/src/test/java/cn/iocoder/yudao/module/im/util/ImMessageUtilsTest.java
yudao-module-im/src/test/resources/application-unit-test.yaml
yudao-module-im/src/test/resources/sql/clean.sql
yudao-module-im/src/test/resources/sql/create_tables.sql
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/FileController.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/file/FileUploadReqVO.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/controller/app/file/AppFileController.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/dal/mysql/file/FileMapper.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/enums/ErrorCodeConstants.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/enums/codegen/CodegenFrontTypeEnum.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/AbstractFileClient.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/local/LocalFileClient.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/client/s3/S3FileClient.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/utils/FilePathUtils.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/framework/file/core/utils/FileTypeUtils.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/service/codegen/inner/CodegenEngine.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/service/file/FileService.java
yudao-module-infra/src/main/java/cn/iocoder/yudao/module/infra/service/file/FileServiceImpl.java
yudao-module-infra/src/main/resources/codegen/java/service/serviceImpl.vm
yudao-module-infra/src/main/resources/codegen/vue3_admin_uniapp/components/search-form.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_admin_uniapp/views/detail/index.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_admin_uniapp/views/form/index.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_admin_uniapp/views/index.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/api/api.ts.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/form.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/import.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/index.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/modules/form_sub_erp.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/modules/form_sub_inner.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/modules/form_sub_normal.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/modules/list_sub_erp.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/general/views/modules/list_sub_inner.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/api/api.ts.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/data.ts.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/form.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/import.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/index.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/modules/form_sub_erp.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/modules/form_sub_inner.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/modules/form_sub_normal.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/modules/list_sub_erp.vue.vm
yudao-module-infra/src/main/resources/codegen/vue3_vben5_antdv_next/schema/views/modules/list_sub_inner.vue.vm
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/framework/file/core/local/LocalFileClientTest.java
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/framework/file/core/s3/S3FileClientTest.java
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/framework/file/core/utils/FileTypeUtilsTest.java
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/service/codegen/inner/CodegenEngineAbstractTest.java
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/service/codegen/inner/CodegenEngineUniappTest.java
yudao-module-infra/src/test/java/cn/iocoder/yudao/module/infra/service/file/FileServiceImplTest.java
yudao-module-infra/src/test/resources/codegen/vben5_antd_general_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_antd_general_master_normal/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_antd_schema_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_antd_schema_master_normal/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_ele_general_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_ele_general_master_normal/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_ele_schema_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vben5_ele_schema_master_normal/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vue2_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vue2_master_normal/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/assert.json
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/ErrorCodeConstants_手动操作
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentController
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentDO
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentMapper
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentPageReqVO
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentRespVO
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentSaveReqVO
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentService
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/java/InfraStudentServiceImplTest
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/sql/h2
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/sql/sql
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/ts/index
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/vue/detail/index
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/vue/form/index
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/vue/index
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/vue/search-form
yudao-module-infra/src/test/resources/codegen/vue3_admin_uniapp_one/xml/InfraStudentMapper
yudao-module-infra/src/test/resources/codegen/vue3_master_inner/java/InfraStudentServiceImpl
yudao-module-infra/src/test/resources/codegen/vue3_master_normal/java/InfraStudentServiceImpl
yudao-module-iot/yudao-module-iot-biz/pom.xml
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/api/device/IoTDeviceApiImpl.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/controller/admin/alert/vo/config/IotAlertConfigRespVO.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/controller/admin/alert/vo/config/IotAlertConfigSaveReqVO.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/controller/admin/rule/vo/scene/IotSceneRuleRespVO.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/dal/dataobject/alert/IotAlertConfigDO.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/dal/mysql/alert/IotAlertConfigMapper.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/dal/mysql/device/IotDeviceMapper.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/dal/mysql/rule/IotDataRuleMapper.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/enums/ErrorCodeConstants.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/framework/tdengine/core/TDengineTableField.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/alert/IotAlertConfigServiceImpl.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/device/property/IotDevicePropertyServiceImpl.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/IotSceneRuleTimeHelper.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/action/IotAlertTriggerSceneRuleAction.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/IotSceneRuleMatcherHelper.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/condition/IotCurrentTimeConditionMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/condition/IotDevicePropertyConditionMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/condition/IotDeviceStateConditionMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/trigger/IotDeviceEventPostTriggerMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/trigger/IotDevicePropertyPostTriggerMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/trigger/IotDeviceServiceInvokeTriggerMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/rule/scene/matcher/trigger/IotDeviceStateUpdateTriggerMatcher.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/thingmodel/IotThingModelService.java
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/service/thingmodel/IotThingModelServiceImpl.java
yudao-module-iot/yudao-module-iot-biz/src/main/resources/mapper/device/IotDevicePropertyMapper.xml
yudao-module-iot/yudao-module-iot-biz/src/test/java/cn/iocoder/yudao/module/iot/framework/tdengine/core/TDengineTableFieldTest.java
yudao-module-iot/yudao-module-iot-biz/src/test/java/cn/iocoder/yudao/module/iot/service/device/property/IotDevicePropertyServiceImplTest.java
yudao-module-iot/yudao-module-iot-biz/src/test/java/cn/iocoder/yudao/module/iot/service/rule/scene/IotSceneRuleTimerConditionIntegrationTest.java
yudao-module-iot/yudao-module-iot-biz/src/test/java/cn/iocoder/yudao/module/iot/service/rule/scene/action/IotAlertTriggerSceneRuleActionTest.java
yudao-module-iot/yudao-module-iot-biz/src/test/java/cn/iocoder/yudao/module/iot/service/thingmodel/IotThingModelServiceImplTest.java
yudao-module-iot/yudao-module-iot-core/pom.xml
yudao-module-iot/yudao-module-iot-core/src/main/java/cn/iocoder/yudao/module/iot/core/messagebus/config/IotMessageBusAutoConfiguration.java
yudao-module-iot/yudao-module-iot-core/src/main/java/cn/iocoder/yudao/module/iot/core/messagebus/config/IotMessageBusProperties.java
yudao-module-iot/yudao-module-iot-core/src/main/java/cn/iocoder/yudao/module/iot/core/messagebus/core/kafka/IotKafkaMessageBus.java
yudao-module-iot/yudao-module-iot-core/src/main/java/cn/iocoder/yudao/module/iot/core/messagebus/core/rabbitmq/IotRabbitMQMessageBus.java
yudao-module-iot/yudao-module-iot-gateway/pom.xml
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/common/manager/AbstractIotModbusPollScheduler.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/common/utils/IotModbusTcpClientUtils.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/tcpclient/manager/IotModbusTcpClientPollScheduler.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/tcpserver/IotModbusTcpServerProtocol.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/tcpserver/manager/IotModbusTcpServerConfigCacheService.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/tcpserver/manager/IotModbusTcpServerConnectionManager.java
yudao-module-iot/yudao-module-iot-gateway/src/main/java/cn/iocoder/yudao/module/iot/gateway/service/device/remote/IotDeviceApiImpl.java
yudao-module-iot/yudao-module-iot-gateway/src/main/resources/application.yaml
yudao-module-iot/yudao-module-iot-gateway/src/test/java/cn/iocoder/yudao/module/iot/gateway/protocol/modbus/tcpclient/manager/IotModbusTcpClientPollSchedulerTest.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/controller/admin/comment/ProductCommentController.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/controller/admin/spu/ProductSpuController.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/dal/mysql/spu/ProductSpuMapper.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/service/comment/ProductCommentService.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/service/comment/ProductCommentServiceImpl.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/service/spu/ProductSpuService.java
yudao-module-mall/yudao-module-product/src/main/java/cn/iocoder/yudao/module/product/service/spu/ProductSpuServiceImpl.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/CouponController.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/coupon/CouponTemplateMapper.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/reward/RewardActivityMapper.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/seckill/seckillactivity/SeckillActivityMapper.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationRecordServiceImpl.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/service/coupon/CouponService.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/service/coupon/CouponServiceImpl.java
yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/service/coupon/CouponTemplateServiceImpl.java
yudao-module-mall/yudao-module-promotion/src/test/java/cn/iocoder/yudao/module/promotion/service/combination/CombinationRecordServiceImplTest.java
yudao-module-mall/yudao-module-promotion/src/test/java/cn/iocoder/yudao/module/promotion/service/coupon/CouponTemplateServiceImplTest.java
yudao-module-mall/yudao-module-promotion/src/test/resources/sql/clean.sql
yudao-module-mall/yudao-module-promotion/src/test/resources/sql/create_tables.sql
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/controller/admin/delivery/DeliveryPickUpStoreController.java
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/controller/admin/delivery/vo/pickup/DeliveryPickUpStoreRespVO.java
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/controller/app/aftersale/AppAfterSaleController.java
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/convert/delivery/DeliveryPickUpStoreConvert.java
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/convert/order/TradeOrderConvert.java
yudao-module-mall/yudao-module-trade/src/main/java/cn/iocoder/yudao/module/trade/service/brokerage/BrokerageRecordServiceImpl.java
yudao-module-mall/yudao-module-trade/src/main/resources/mapper/brokerage/BrokerageUserMapper.xml
yudao-module-mall/yudao-module-trade/src/test/java/cn/iocoder/yudao/module/trade/service/brokerage/BrokerageRecordServiceImplTest.java
yudao-module-mall/yudao-module-trade/src/test/resources/sql/create_tables.sql
yudao-module-mdm-api/pom.xml (已删除)
yudao-module-mdm/pom.xml (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/brand/MdmBrandApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/brand/MdmBrandApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/brand/dto/MdmBrandRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/category/MdmItemCategoryApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/category/MdmItemCategoryApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/category/dto/MdmItemCategoryRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/MdmItemApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/MdmItemApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/MdmItemSkuApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/MdmItemSkuApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/dto/MdmItemCreateReqDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/dto/MdmItemRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/dto/MdmItemSkuRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/item/dto/MdmItemUpdateReqDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/unit/MdmUnitMeasureApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/unit/MdmUnitMeasureApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/unit/dto/MdmUnitMeasureRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/warehouse/MdmWarehouseApi.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/warehouse/MdmWarehouseApiImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/api/warehouse/dto/MdmWarehouseRespDTO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/brand/MdmBrandController.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/brand/vo/MdmBrandPageReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/brand/vo/MdmBrandSaveReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/category/MdmItemCategoryController.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/category/vo/MdmItemCategoryPageReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/category/vo/MdmItemCategoryRespVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/category/vo/MdmItemCategorySaveReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/item/MdmItemController.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/item/vo/MdmItemPageReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/item/vo/MdmItemRespVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/item/vo/MdmItemSaveReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/unit/MdmUnitMeasureController.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/unit/vo/MdmUnitMeasurePageReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/unit/vo/MdmUnitMeasureSaveReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/warehouse/MdmWarehouseController.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/warehouse/vo/MdmWarehousePageReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/warehouse/vo/MdmWarehouseRespVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/controller/admin/warehouse/vo/MdmWarehouseSaveReqVO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/brand/MdmBrandDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/category/MdmItemCategoryDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/item/MdmItemBatchConfigDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/item/MdmItemDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/item/MdmItemSkuDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/unit/MdmUnitMeasureDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/dataobject/warehouse/MdmWarehouseDO.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/brand/MdmBrandMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/category/MdmItemCategoryMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/item/MdmItemBatchConfigMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/item/MdmItemMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/item/MdmItemSkuMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/unit/MdmUnitMeasureMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/dal/mysql/warehouse/MdmWarehouseMapper.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/enums/ErrorCodeConstants.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/enums/MdmItemTypeEnum.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/brand/MdmBrandService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/brand/MdmBrandServiceImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/category/MdmItemCategoryService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/category/MdmItemCategoryServiceImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/item/MdmItemService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/item/MdmItemServiceImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/item/MdmItemSkuService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/item/MdmItemSkuServiceImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/unit/MdmUnitMeasureService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/unit/MdmUnitMeasureServiceImpl.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/warehouse/MdmWarehouseService.java (已删除)
yudao-module-mdm/src/main/java/cn/iocoder/yudao/module/mdm/service/warehouse/MdmWarehouseServiceImpl.java (已删除)
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/api/user/dto/MemberUserRespDTO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/controller/admin/address/vo/AddressRespVO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/controller/admin/user/vo/MemberUserBaseVO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/controller/admin/user/vo/MemberUserPageReqVO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/controller/app/user/vo/AppMemberUserInfoRespVO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/controller/app/user/vo/AppMemberUserUpdateReqVO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/convert/address/AddressConvert.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/dal/dataobject/user/MemberUserDO.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/dal/mysql/user/MemberUserMapper.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/enums/ErrorCodeConstants.java
yudao-module-member/src/main/java/cn/iocoder/yudao/module/member/service/user/MemberUserServiceImpl.java
yudao-module-member/src/test/resources/sql/create_tables.sql
yudao-module-mes/pom.xml
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/pro/andon/MesProAndonConfigController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/pro/andon/vo/config/MesProAndonConfigRespVO.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/pro/workorder/MesProWorkOrderController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/qc/defectrecord/MesQcDefectRecordController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/miscreceipt/MesWmMiscReceiptController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/miscreceipt/MesWmMiscReceiptLineController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/outsourceissue/MesWmOutsourceIssueController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/outsourceissue/MesWmOutsourceIssueDetailController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/outsourceissue/MesWmOutsourceIssueLineController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/packages/MesWmPackageController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/packages/MesWmPackageLineController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/returnsales/MesWmReturnSalesController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/returnsales/MesWmReturnSalesDetailController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/returnsales/MesWmReturnSalesLineController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/controller/admin/wm/sn/MesWmSnController.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/dal/dataobject/pro/workorder/MesProWorkOrderDO.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/dal/mysql/qc/template/MesQcTemplateMapper.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/dal/mysql/wm/barcode/MesWmBarcodeMapper.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/enums/ErrorCodeConstants.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/enums/MesBizTypeConstants.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/enums/pro/MesProWorkOrderStatusEnum.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/enums/wm/BarcodeBizTypeEnum.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/md/autocode/MesMdAutoCodeRecordServiceImpl.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/md/item/MesMdItemServiceImpl.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pro/workorder/MesProWorkOrderService.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pro/workorder/MesProWorkOrderServiceImpl.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/pro/workorder/listener/MesProWorkOrderStatusListener.java (已删除)
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/defectrecord/MesQcDefectRecordService.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/qc/defectrecord/MesQcDefectRecordServiceImpl.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/wm/barcode/MesWmBarcodeService.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/wm/barcode/MesWmBarcodeServiceImpl.java
yudao-module-mes/src/main/java/cn/iocoder/yudao/module/mes/service/wm/sn/MesWmSnServiceImpl.java
yudao-module-mes/src/test/java/cn/iocoder/yudao/module/mes/service/md/autocode/MesMdAutoCodeRecordServiceImplTest.java
yudao-module-mp/src/main/java/cn/iocoder/yudao/module/mp/service/handler/user/SubscribeHandler.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/controller/admin/channel/PayChannelController.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/controller/app/wallet/AppPayWalletController.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/convert/channel/PayChannelConvert.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/dal/mysql/channel/PayChannelMapper.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/dal/mysql/transfer/PayTransferMapper.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/framework/pay/core/client/impl/weixin/AbstractWxPayClient.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/service/channel/PayChannelService.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/service/channel/PayChannelServiceImpl.java
yudao-module-pay/src/main/java/cn/iocoder/yudao/module/pay/service/transfer/PayTransferServiceImpl.java
yudao-module-pay/src/test/java/cn/iocoder/yudao/module/pay/service/transfer/PayTransferServiceTest.java
yudao-module-pay/src/test/resources/sql/create_tables.sql
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/message/user/AdminUserProfileUpdateMessage.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/permission/RoleApi.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/permission/RoleApiImpl.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/permission/dto/RoleRespDTO.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/user/AdminUserApi.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/api/user/AdminUserApiImpl.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/mail/MailTemplateController.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/mail/vo/template/MailTemplateSimpleRespVO.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/notify/NotifyTemplateController.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/notify/vo/template/NotifyTemplateSimpleRespVO.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/permission/PermissionController.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sms/SmsTemplateController.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/sms/vo/template/SmsTemplateSimpleRespVO.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/user/UserController.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/controller/admin/user/vo/user/UserSimpleRespVO.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/mail/MailLogMapper.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/mail/MailTemplateMapper.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/notify/NotifyTemplateMapper.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/sms/SmsTemplateMapper.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/dal/mysql/tenant/TenantMapper.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/framework/sms/core/client/impl/QiniuSmsClient.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/framework/social/config/YudaoWxClientConfiguration.java (已删除)
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/framework/weixin/config/YudaoWxClientConfiguration.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/framework/weixin/package-info.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/mq/producer/user/AdminUserProducer.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/mail/MailTemplateService.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/mail/MailTemplateServiceImpl.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/notify/NotifyTemplateService.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/notify/NotifyTemplateServiceImpl.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/sms/SmsTemplateService.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/sms/SmsTemplateServiceImpl.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/user/AdminUserService.java
yudao-module-system/src/main/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImpl.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/mail/MailLogServiceImplTest.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/mail/MailTemplateServiceImplTest.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/notify/NotifyTemplateServiceImplTest.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/sms/SmsTemplateServiceImplTest.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/tenant/TenantServiceImplTest.java
yudao-module-system/src/test/java/cn/iocoder/yudao/module/system/service/user/AdminUserServiceImplTest.java
yudao-module-wms/pom.xml
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/WmsInventoryApi.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/WmsInventoryApiImpl.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsInventoryQueryReqDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsInventoryRespDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsReceiptReqDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsReceiptResultDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsReserveReqDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsShipmentReqDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsShipmentResultDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/inventory/dto/WmsUseReserveReqDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/stock/WmsStockApi.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/api/stock/dto/StockRecordCreateDTO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/inventory/WmsInventoryReserveController.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/inventory/vo/WmsInventoryReservePageReqVO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/inventory/vo/WmsInventoryReserveRespVO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/md/item/vo/item/WmsItemListReqVO.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/md/item/vo/item/WmsItemPageReqVO.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/controller/admin/md/item/vo/item/WmsItemSaveReqVO.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/dataobject/inventory/WmsInventoryReserveDO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/dataobject/inventory/WmsInventoryTransactionDO.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/dataobject/md/item/WmsItemSkuDO.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/mysql/inventory/WmsInventoryMapper.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/mysql/inventory/WmsInventoryReserveMapper.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/dal/mysql/inventory/WmsInventoryTransactionMapper.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/DictTypeConstants.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/ErrorCodeConstants.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/inventory/WmsInventoryBizTypeEnum.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/inventory/WmsReserveBizTypeEnum.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/inventory/WmsReserveStatusEnum.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/inventory/WmsTransactionTypeEnum.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/enums/stock/StockBizTypeEnum.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryReserveService.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryReserveServiceImpl.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryService.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryServiceImpl.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryTransactionService.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryTransactionServiceImpl.java (已删除)
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/md/item/WmsItemServiceImpl.java
yudao-module-wms/src/main/java/cn/iocoder/yudao/module/wms/service/md/item/WmsItemSkuServiceImpl.java
yudao-module-wms/src/test/java/cn/iocoder/yudao/module/wms/service/inventory/WmsInventoryServiceImplTest.java
yudao-server/pom.xml
yudao-server/src/main/resources/application-dev.yaml
yudao-server/src/main/resources/application-local.yaml
yudao-server/src/main/resources/application-test.yaml (已删除)
yudao-server/src/main/resources/application.yaml |