From ffbe5016cb2426f16b13d58795c523931cb36f08 Mon Sep 17 00:00:00 2001
From: liyong <18434998025@163.com>
Date: 星期一, 09 二月 2026 13:34:59 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/dev_New' into dev_New

---
 src/main/java/com/ruoyi/project/system/service/SysUserClientService.java          |   19 +
 src/main/java/com/ruoyi/project/system/service/impl/SysNoticeServiceImpl.java     |   13 +
 pom.xml                                                                           |   83 ++++---
 src/main/java/com/ruoyi/project/system/controller/SysUserClientController.java    |   44 ++++
 src/main/java/com/ruoyi/project/system/domain/GetuiConfig.java                    |   46 ++++
 src/main/java/com/ruoyi/project/system/mapper/SysMenuMapper.java                  |    8 
 src/main/java/com/ruoyi/project/system/service/impl/UnipushService.java           |  198 +++++++++++++++++++
 src/main/resources/mapper/system/SysMenuMapper.xml                                |   11 
 src/main/resources/application-dev.yml                                            |   10 +
 src/main/java/com/ruoyi/project/system/service/impl/SysUserClientServiceImpl.java |   43 ++++
 src/main/resources/application-new.yml                                            |   10 +
 src/main/java/com/ruoyi/project/system/domain/SysUserClient.java                  |   47 ++++
 src/main/java/com/ruoyi/project/system/mapper/SysUserClientMapper.java            |   18 +
 13 files changed, 510 insertions(+), 40 deletions(-)

diff --git a/pom.xml b/pom.xml
index 790a3e7..25bd9fe 100644
--- a/pom.xml
+++ b/pom.xml
@@ -16,7 +16,7 @@
         <groupId>org.springframework.boot</groupId>
         <artifactId>spring-boot-starter-parent</artifactId>
         <version>2.5.15</version>
-        <relativePath />
+        <relativePath/>
     </parent>
 
     <properties>
@@ -43,6 +43,7 @@
         <spring-security.version>5.7.12</spring-security.version>
         <spring-framework.version>5.3.39</spring-framework.version>
         <mybatis-plus.version>3.5.3.1</mybatis-plus.version>
+        <getui-sdk.version>1.0.7.0</getui-sdk.version>
     </properties>
 
     <dependencies>
@@ -269,7 +270,6 @@
         </dependency>
 
 
-
         <!-- minio -->
         <dependency>
             <groupId>io.minio</groupId>
@@ -301,51 +301,58 @@
             <artifactId>easyexcel</artifactId>
             <version>4.0.3</version>
         </dependency>
-        
-         <dependency>
+
+        <dependency>
             <groupId>com.google.zxing</groupId>
             <artifactId>core</artifactId>
             <version>3.3.3</version>
         </dependency>
 
+        <dependency>
+            <groupId>com.getui.push</groupId>
+            <artifactId>restful-sdk</artifactId>
+            <version>${getui-sdk.version}</version>
+            <scope>compile</scope>
+        </dependency>
+
     </dependencies>
 
-	<build>
-	    <finalName>${project.artifactId}</finalName>
-	    <plugins>
-	        <plugin>
-	            <groupId>org.springframework.boot</groupId>
-	            <artifactId>spring-boot-maven-plugin</artifactId>
-	            <configuration>
-	                <fork>true</fork> <!-- 濡傛灉娌℃湁璇ラ厤缃紝devtools涓嶄細鐢熸晥 -->
-	            </configuration>
-	        </plugin>
+    <build>
+        <finalName>${project.artifactId}</finalName>
+        <plugins>
+            <plugin>
+                <groupId>org.springframework.boot</groupId>
+                <artifactId>spring-boot-maven-plugin</artifactId>
+                <configuration>
+                    <fork>true</fork> <!-- 濡傛灉娌℃湁璇ラ厤缃紝devtools涓嶄細鐢熸晥 -->
+                </configuration>
+            </plugin>
         </plugins>
-	</build>
+    </build>
 
-	<repositories>
-	    <repository>
-	        <id>public</id>
-	        <name>aliyun nexus</name>
-	        <url>https://maven.aliyun.com/repository/public</url>
-	        <releases>
-	            <enabled>true</enabled>
-	        </releases>
-	    </repository>
-	</repositories>
+    <repositories>
+        <repository>
+            <id>public</id>
+            <name>aliyun nexus</name>
+            <url>https://maven.aliyun.com/repository/public</url>
+            <releases>
+                <enabled>true</enabled>
+            </releases>
+        </repository>
+    </repositories>
 
-	<pluginRepositories>
-	    <pluginRepository>
-	        <id>public</id>
-	        <name>aliyun nexus</name>
-	        <url>https://maven.aliyun.com/repository/public</url>
-	        <releases>
-	            <enabled>true</enabled>
-	        </releases>
-	        <snapshots>
-	            <enabled>false</enabled>
-	        </snapshots>
-	    </pluginRepository>
-	</pluginRepositories>
+    <pluginRepositories>
+        <pluginRepository>
+            <id>public</id>
+            <name>aliyun nexus</name>
+            <url>https://maven.aliyun.com/repository/public</url>
+            <releases>
+                <enabled>true</enabled>
+            </releases>
+            <snapshots>
+                <enabled>false</enabled>
+            </snapshots>
+        </pluginRepository>
+    </pluginRepositories>
 
 </project>
diff --git a/src/main/java/com/ruoyi/project/system/controller/SysUserClientController.java b/src/main/java/com/ruoyi/project/system/controller/SysUserClientController.java
new file mode 100644
index 0000000..c05fa73
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/controller/SysUserClientController.java
@@ -0,0 +1,44 @@
+package com.ruoyi.project.system.controller;
+
+import com.ruoyi.framework.security.LoginUser;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.project.system.domain.GetuiConfig;
+import com.ruoyi.project.system.domain.SysUserClient;
+import com.ruoyi.project.system.service.SysUserClientService;
+import com.ruoyi.common.utils.SecurityUtils;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+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;
+
+/**
+ * 鐢ㄦ埛瀹夊崜璁惧绠$悊鎺у埗灞�
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+@Api(tags = "鐢ㄦ埛璁惧缁戝畾")
+@RestController
+@RequestMapping("/system/client")
+public class SysUserClientController extends BaseController {
+
+    @Autowired
+    private SysUserClientService sysUserClientService;
+
+    /**
+     * 娣诲姞/鏇存柊鐢ㄦ埛cid
+     */
+    @PostMapping("/addOrUpdateClientId")
+    @ApiOperation("娣诲姞/鏇存柊鐢ㄦ埛cid")
+    public AjaxResult addOrUpdateClientId(@RequestBody SysUserClient sysUserClient) {
+        Long userId = SecurityUtils.getUserId();
+        sysUserClient.setUserId(userId);
+        boolean result = sysUserClientService.addOrUpdateClientId(sysUserClient);
+        return result ? success() : error("璁惧缁戝畾澶辫触");
+    }
+}
\ No newline at end of file
diff --git a/src/main/java/com/ruoyi/project/system/domain/GetuiConfig.java b/src/main/java/com/ruoyi/project/system/domain/GetuiConfig.java
new file mode 100644
index 0000000..f5ba300
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/domain/GetuiConfig.java
@@ -0,0 +1,46 @@
+package com.ruoyi.project.system.domain;
+
+import lombok.Data;
+import org.springframework.boot.context.properties.ConfigurationProperties;
+import org.springframework.stereotype.Component;
+
+/**
+ * <p>
+ * 涓帹 (Unipush v2) 娑堟伅鎺ㄩ�侀厤缃被
+ * </p>
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+@Data
+@Component
+@ConfigurationProperties(prefix = "ruoyi.getui")
+public class GetuiConfig {
+
+    /**
+     * AppID
+     */
+    private String appId;
+
+    /**
+     * AppKey
+     */
+    private String appKey;
+
+    /**
+     * MasterSecret
+     */
+    private String masterSecret;
+
+    /**
+     * 涓帹 RESTful API 鍩熷悕鍦板潃
+     */
+    private String domain;
+
+    /**
+     * 绂荤嚎鎺ㄩ�� Intent 鐩爣缁勪欢鍚�
+     * 鏍煎紡: 鍖呭悕/鍏ュ彛Activity鍚�
+     */
+    private String intentComponent;
+}
\ No newline at end of file
diff --git a/src/main/java/com/ruoyi/project/system/domain/SysUserClient.java b/src/main/java/com/ruoyi/project/system/domain/SysUserClient.java
new file mode 100644
index 0000000..24dc336
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/domain/SysUserClient.java
@@ -0,0 +1,47 @@
+package com.ruoyi.project.system.domain;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.AllArgsConstructor;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * <br>
+ * 鐢ㄦ埛瀹夊崜璁惧鍏宠仈瀵硅薄 sys_user_client
+ * </br>
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+@TableName("sys_user_client")
+public class SysUserClient implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 鐢ㄦ埛ID
+     */
+    @TableId(type = IdType.INPUT)
+    private Long userId;
+
+    /**
+     * 涓帹璁惧鏍囪瘑 (CID)
+     */
+    private String cid;
+
+    /**
+     * 鏈�鍚庢椿璺冩椂闂�
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    private Date updateTime;
+}
\ No newline at end of file
diff --git a/src/main/java/com/ruoyi/project/system/mapper/SysMenuMapper.java b/src/main/java/com/ruoyi/project/system/mapper/SysMenuMapper.java
index 3a0857d..a570593 100644
--- a/src/main/java/com/ruoyi/project/system/mapper/SysMenuMapper.java
+++ b/src/main/java/com/ruoyi/project/system/mapper/SysMenuMapper.java
@@ -122,4 +122,12 @@
      * @return 缁撴灉
      */
     public SysMenu checkMenuNameUnique(@Param("menuName") String menuName, @Param("parentId") Long parentId);
+
+    /**
+     * 鏍规嵁璺敱鍦板潃鏌ヨ鑿滃崟
+     *
+     * @param lastSegment 璺敱鍦板潃
+     * @return 鑿滃崟
+     */
+    SysMenu selectMenuByPath(String lastSegment);
 }
diff --git a/src/main/java/com/ruoyi/project/system/mapper/SysUserClientMapper.java b/src/main/java/com/ruoyi/project/system/mapper/SysUserClientMapper.java
new file mode 100644
index 0000000..b48e2e7
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/mapper/SysUserClientMapper.java
@@ -0,0 +1,18 @@
+package com.ruoyi.project.system.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.ruoyi.project.system.domain.SysUserClient;
+
+/**
+ * <br>
+ * 鐢ㄦ埛瀹夊崜璁惧鍏宠仈mapper
+ * </br>
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+
+public interface SysUserClientMapper extends BaseMapper<SysUserClient> {
+
+}
diff --git a/src/main/java/com/ruoyi/project/system/service/SysUserClientService.java b/src/main/java/com/ruoyi/project/system/service/SysUserClientService.java
new file mode 100644
index 0000000..0ff0009
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/service/SysUserClientService.java
@@ -0,0 +1,19 @@
+package com.ruoyi.project.system.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.ruoyi.project.system.domain.SysUserClient;
+
+/**
+ * <br>
+ * 鐢ㄦ埛瀹夊崜璁惧鍏宠仈鎺ュ彛
+ * </br>
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+
+public interface SysUserClientService extends IService<SysUserClient> {
+
+    boolean addOrUpdateClientId(SysUserClient sysUserClient);
+}
diff --git a/src/main/java/com/ruoyi/project/system/service/impl/SysNoticeServiceImpl.java b/src/main/java/com/ruoyi/project/system/service/impl/SysNoticeServiceImpl.java
index 679514d..aa7056c 100644
--- a/src/main/java/com/ruoyi/project/system/service/impl/SysNoticeServiceImpl.java
+++ b/src/main/java/com/ruoyi/project/system/service/impl/SysNoticeServiceImpl.java
@@ -53,6 +53,9 @@
     @Lazy
     private ISysNoticeService sysNoticeService;
 
+    @Autowired
+    private UnipushService unipushService;
+
     /**
      * 鏌ヨ鍏憡淇℃伅
      *
@@ -146,6 +149,11 @@
         Long tenantId = SecurityUtils.getLoginUser().getTenantId();
         List<SysNotice> sysNotices = consigneeId.stream().map(it -> convertSysNotice(title, message, it,tenantId, jumpPath, userId)).collect(Collectors.toList());
         sysNoticeService.saveBatch(sysNotices);
+        try {
+            unipushService.sendClientMessage(sysNotices);
+        } catch (Exception e) {
+            log.error("APP鎺ㄩ�侀�氱煡澶辫触锛屽師鍥�: {}", e);
+        }
     }
 
     @Override
@@ -197,6 +205,11 @@
                 .collect(Collectors.toList());
 
         sysNoticeService.saveBatch(collect);
+        try {
+            unipushService.sendClientMessage(collect);
+        } catch (Exception e) {
+            log.error("APP鎺ㄩ�侀�氱煡澶辫触锛屽師鍥�: {}", e);
+        }
     }
 
 
diff --git a/src/main/java/com/ruoyi/project/system/service/impl/SysUserClientServiceImpl.java b/src/main/java/com/ruoyi/project/system/service/impl/SysUserClientServiceImpl.java
new file mode 100644
index 0000000..7130bf4
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/service/impl/SysUserClientServiceImpl.java
@@ -0,0 +1,43 @@
+package com.ruoyi.project.system.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.project.system.domain.SysUserClient;
+import com.ruoyi.project.system.mapper.SysUserClientMapper;
+import com.ruoyi.project.system.service.SysUserClientService;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.Date;
+
+/**
+ * 鐢ㄦ埛瀹夊崜璁惧鍏宠仈鎺ュ彛瀹炵幇绫�
+ *
+ * @author deslrey
+ * @version 1.0
+ * @since 2026/2/9
+ */
+@Service
+public class SysUserClientServiceImpl extends ServiceImpl<SysUserClientMapper, SysUserClient> implements SysUserClientService {
+
+    @Override
+    @Transactional(rollbackFor = Exception.class)
+    public boolean addOrUpdateClientId(SysUserClient sysUserClient) {
+        if (sysUserClient == null || sysUserClient.getUserId() == null || StringUtils.isEmpty(sysUserClient.getCid())) {
+            return false;
+        }
+
+        String cid = sysUserClient.getCid();
+        Long userId = sysUserClient.getUserId();
+
+        remove(new LambdaQueryWrapper<SysUserClient>().eq(SysUserClient::getCid, cid).ne(SysUserClient::getUserId, userId));
+
+        SysUserClient userClient = new SysUserClient();
+        userClient.setUserId(userId);
+        userClient.setCid(cid);
+        userClient.setUpdateTime(new Date());
+
+        return saveOrUpdate(userClient);
+    }
+}
\ No newline at end of file
diff --git a/src/main/java/com/ruoyi/project/system/service/impl/UnipushService.java b/src/main/java/com/ruoyi/project/system/service/impl/UnipushService.java
new file mode 100644
index 0000000..0a33b66
--- /dev/null
+++ b/src/main/java/com/ruoyi/project/system/service/impl/UnipushService.java
@@ -0,0 +1,198 @@
+package com.ruoyi.project.system.service.impl;
+
+import com.getui.push.v2.sdk.ApiHelper;
+import com.getui.push.v2.sdk.GtApiConfiguration;
+import com.getui.push.v2.sdk.api.PushApi;
+import com.getui.push.v2.sdk.common.ApiResult;
+import com.getui.push.v2.sdk.dto.req.Audience;
+import com.getui.push.v2.sdk.dto.req.message.PushChannel;
+import com.getui.push.v2.sdk.dto.req.message.PushDTO;
+import com.getui.push.v2.sdk.dto.req.message.PushMessage;
+import com.getui.push.v2.sdk.dto.req.message.android.AndroidDTO;
+import com.getui.push.v2.sdk.dto.req.message.android.ThirdNotification;
+import com.getui.push.v2.sdk.dto.req.message.android.Ups;
+import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.project.system.domain.GetuiConfig;
+import com.ruoyi.project.system.domain.SysMenu;
+import com.ruoyi.project.system.domain.SysNotice;
+import com.ruoyi.project.system.domain.SysUserClient;
+import com.ruoyi.project.system.mapper.SysMenuMapper;
+import com.ruoyi.project.system.service.SysUserClientService;
+import lombok.extern.slf4j.Slf4j;
+import org.jetbrains.annotations.NotNull;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.scheduling.annotation.Async;
+import org.springframework.stereotype.Component;
+
+import javax.annotation.PostConstruct;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * APP娑堟伅鎺ㄩ�佹湇鍔�
+ *
+ * @author deslrey
+ * @version 1.4
+ * @since 2026/2/9
+ */
+@Slf4j
+@Component
+public class UnipushService {
+
+    @Autowired
+    private SysMenuMapper sysMenuMapper;
+
+    @Autowired
+    private GetuiConfig getuiConfig;
+
+    @Autowired
+    private SysUserClientService userClientService;
+
+    private PushApi pushApi;
+
+    private static final String DEFAULT_APP_PAGE = "pages/index";
+
+    @PostConstruct
+    public void init() {
+        GtApiConfiguration config = new GtApiConfiguration();
+        config.setAppId(getuiConfig.getAppId());
+        config.setAppKey(getuiConfig.getAppKey());
+        config.setMasterSecret(getuiConfig.getMasterSecret());
+        config.setDomain(getuiConfig.getDomain());
+        ApiHelper apiHelper = ApiHelper.build(config);
+        this.pushApi = apiHelper.creatApi(PushApi.class);
+    }
+
+    /**
+     * 鎵归噺鍙戦�侀�氱煡鍏憡鍒扮Щ鍔ㄧ
+     */
+    @Async
+    public void sendClientMessage(List<SysNotice> sysNoticeList) {
+        if (sysNoticeList == null || sysNoticeList.isEmpty()) {
+            return;
+        }
+
+        for (SysNotice sysNotice : sysNoticeList) {
+            SysUserClient client = userClientService.getById(sysNotice.getConsigneeId());
+            if (client == null || StringUtils.isEmpty(client.getCid())) {
+                log.warn("鐢ㄦ埛 {} 鏈粦瀹氱Щ鍔ㄧ CID,璺宠繃鎺ㄩ��", sysNotice.getConsigneeId());
+                continue;
+            }
+
+            // 杞崲璺緞
+            String appPath = convertWebPathToAppPath(sysNotice.getJumpPath());
+
+            // 鎺ㄩ��
+            sendRoutingPush(
+                    client.getCid(),
+                    sysNotice.getNoticeTitle(),
+                    sysNotice.getRemark() != null ? sysNotice.getRemark() : sysNotice.getNoticeContent(),
+                    appPath
+            );
+        }
+    }
+
+    /**
+     * 灏� Web 绔垎灞傚叏璺緞杞崲涓� App 绔粍浠惰矾鐢�
+     */
+    private String convertWebPathToAppPath(String webPath) {
+        if (StringUtils.isEmpty(webPath)) {
+            return DEFAULT_APP_PAGE;
+        }
+
+        String pathOnly = webPath;
+        String queryString = "";
+        if (webPath.contains("?")) {
+            int index = webPath.indexOf("?");
+            pathOnly = webPath.substring(0, index);
+            queryString = webPath.substring(index);
+        }
+
+        String[] pathSegments = pathOnly.split("/");
+        String lastSegment = "";
+        for (int i = pathSegments.length - 1; i >= 0; i--) {
+            if (StringUtils.isNotEmpty(pathSegments[i])) {
+                lastSegment = pathSegments[i];
+                break;
+            }
+        }
+
+        if (StringUtils.isEmpty(lastSegment)) {
+            return DEFAULT_APP_PAGE;
+        }
+
+        SysMenu menu = sysMenuMapper.selectMenuByPath(lastSegment);
+
+        if (menu != null && StringUtils.isNotEmpty(menu.getAppComponent())) {
+            String appComponent = menu.getAppComponent();
+            if (appComponent.startsWith("/")) {
+                appComponent = appComponent.substring(1);
+            }
+            return appComponent + queryString;
+        }
+
+        return DEFAULT_APP_PAGE;
+    }
+
+    /**
+     * 鍙戦�佸崟浜鸿矾鐢辨帹閫�
+     */
+    private void sendRoutingPush(String cid, String title, String content, String targetPath) {
+        log.info("鍑嗗鎺ㄩ�佹秷鎭�: CID={}, Title={}, TargetPath={}", cid, title, targetPath);
+
+        PushDTO<Audience> pushDTO = new PushDTO<>();
+        pushDTO.setRequestId("REQ_" + System.currentTimeMillis());
+
+        // 鍦ㄧ嚎閫忎紶鍐呭
+        PushMessage pushMessage = new PushMessage();
+        String transmissionContent = String.format(
+                "{\"title\":\"%s\",\"content\":\"%s\",\"payload\":\"%s\"}",
+                title, content, targetPath
+        );
+        pushMessage.setTransmission(transmissionContent);
+        pushDTO.setPushMessage(pushMessage);
+
+        // 鎺ユ敹浜�
+        Audience audience = new Audience();
+        audience.addCid(cid);
+        pushDTO.setAudience(audience);
+
+        // 绂荤嚎鎺ㄩ�侀�氶亾
+        pushDTO.setPushChannel(getPushChannel(title, content, targetPath));
+
+        try {
+            ApiResult<Map<String, Map<String, String>>> result = pushApi.pushToSingleByCid(pushDTO);
+            if (result.isSuccess()) {
+                log.info("Unipush 鎺ㄩ�佹垚鍔�: CID={}", cid);
+            } else {
+                log.error("Unipush 鎺ㄩ�佸け璐�: CID={}, Code={}, Msg={}", cid, result.getCode(), result.getMsg());
+            }
+        } catch (Exception e) {
+            log.error("Unipush 鎺ㄩ�佸紓甯�: ", e);
+        }
+    }
+
+    @NotNull
+    private PushChannel getPushChannel(String title, String content, String targetPath) {
+        PushChannel pushChannel = new PushChannel();
+        AndroidDTO androidDTO = new AndroidDTO();
+        Ups ups = new Ups();
+        ThirdNotification thirdNotification = new ThirdNotification();
+        thirdNotification.setTitle(title);
+        thirdNotification.setBody(content);
+        thirdNotification.setClickType("intent");
+
+        String intent = "intent:#Intent;launchFlags=0x04000000;"
+                + "component=" + getuiConfig.getIntentComponent() + ";"
+                + "S.UP-OL-P9=true;"
+                + "S.path=" + targetPath + ";"
+                + "S.payload=" + targetPath + ";"
+                + "end";
+        thirdNotification.setIntent(intent);
+
+        ups.setNotification(thirdNotification);
+        androidDTO.setUps(ups);
+        pushChannel.setAndroid(androidDTO);
+        return pushChannel;
+    }
+}
\ No newline at end of file
diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml
index 40dc00c..ff56f9d 100644
--- a/src/main/resources/application-dev.yml
+++ b/src/main/resources/application-dev.yml
@@ -15,6 +15,16 @@
   captchaType: math
   # 鍗忓悓瀹℃壒缂栧彿鍓嶇紑(閰嶇疆鏂囦欢鍚庣紑鍛藉悕)
   approvalNumberPrefix: DEV
+
+  # 涓帹 Unipush 閰嶇疆
+  getui:
+    appId: PfjyAAE0FK64FaO1w2CMb1
+    appKey: zTMb831OEL6J4GK1uE3Ob4
+    masterSecret: K1GFtsv42v61tXGnF7SGE5
+    domain: https://restapi.getui.cn/v2/
+    # 绂荤嚎鎺ㄩ�佷娇鐢ㄧ殑鍖呭悕/缁勪欢鍚�
+    intentComponent: uni.app.UNI099A590/io.dcloud.PandoraEntry
+
 # 寮�鍙戠幆澧冮厤缃�
 server:
   # 鏈嶅姟鍣ㄧ殑HTTP绔彛锛岄粯璁や负8080
diff --git a/src/main/resources/application-new.yml b/src/main/resources/application-new.yml
index 47f7ecd..f44dfdb 100644
--- a/src/main/resources/application-new.yml
+++ b/src/main/resources/application-new.yml
@@ -15,6 +15,16 @@
   captchaType: math
   # 鍗忓悓瀹℃壒缂栧彿鍓嶇紑(閰嶇疆鏂囦欢鍚庣紑鍛藉悕)
   approvalNumberPrefix: NEW
+
+  # 涓帹 Unipush 閰嶇疆
+  getui:
+    appId: PfjyAAE0FK64FaO1w2CMb1
+    appKey: zTMb831OEL6J4GK1uE3Ob4
+    masterSecret: K1GFtsv42v61tXGnF7SGE5
+    domain: https://restapi.getui.cn/v2/
+    # 绂荤嚎鎺ㄩ�佷娇鐢ㄧ殑鍖呭悕/缁勪欢鍚�
+    intentComponent: uni.app.UNI099A590/io.dcloud.PandoraEntry
+
 # 寮�鍙戠幆澧冮厤缃�
 server:
   # 鏈嶅姟鍣ㄧ殑HTTP绔彛锛岄粯璁や负8080
diff --git a/src/main/resources/mapper/system/SysMenuMapper.xml b/src/main/resources/mapper/system/SysMenuMapper.xml
index aaf0cd4..20063e3 100644
--- a/src/main/resources/mapper/system/SysMenuMapper.xml
+++ b/src/main/resources/mapper/system/SysMenuMapper.xml
@@ -85,7 +85,7 @@
 		where u.user_id = #{userId} and m.menu_type in ('M', 'C') and m.status = 0  AND ro.status = 0
 		order by m.parent_id, m.order_num
 	</select>
-	
+
 	<select id="selectMenuListByRoleId" resultType="Long">
 		select m.menu_id
 		from sys_menu m
@@ -133,7 +133,14 @@
 		<include refid="selectMenuVo"/>
 		where menu_name=#{menuName} and parent_id = #{parentId} limit 1
 	</select>
-	
+
+	<select id="selectMenuByPath" resultType="com.ruoyi.project.system.domain.SysMenu" parameterType="java.lang.String">
+        SELECT menu_id, menu_name, parent_id, path, app_component, status
+        FROM sys_menu
+        WHERE path = #{path}
+          AND status = '0' LIMIT 1
+    </select>
+
 	<update id="updateMenu" parameterType="com.ruoyi.project.system.domain.SysMenu">
 		update sys_menu
 		<set>

--
Gitblit v1.9.3