| | |
| | | } |
| | | |
| | | /** |
| | | * 发送直接路由推送(不经过SysNotice表) |
| | | */ |
| | | public void sendDirectRoutingPushToUser(Long userId, String title, String content, String webPath) { |
| | | SysUserClient client = userClientService.getById(userId); |
| | | if (client == null || StringUtils.isEmpty(client.getCid())) { |
| | | log.warn("用户 {} 未绑定移动端 CID,跳过直接推送", userId); |
| | | return; |
| | | } |
| | | String appPath = convertWebPathToAppPath(webPath); |
| | | sendRoutingPush( |
| | | System.currentTimeMillis(), |
| | | client.getCid(), |
| | | title, |
| | | content, |
| | | appPath, |
| | | false |
| | | ); |
| | | } |
| | | |
| | | /** |
| | | * 发送单人路由推送 |
| | | */ |
| | | private void sendRoutingPush(Long noticeId, String cid, String title, String content, String targetPath) { |