Bläddra i källkod

Merge branch 'dev' of http://git.xayunmei.com/SH-Arbitrate/Arbitrate-Backend into hjb

hejinbo 2 år sedan
förälder
incheckning
7cfc39190a

+ 7
- 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysLoginController.java Visa fil

3
 import java.util.List;
3
 import java.util.List;
4
 import java.util.Set;
4
 import java.util.Set;
5
 
5
 
6
+import com.ruoyi.system.service.ISysUserService;
6
 import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
7
 import com.ruoyi.wisdomarbitrate.domain.IdentityAuthentication;
7
 import com.ruoyi.wisdomarbitrate.service.IdentityAuthenticationService;
8
 import com.ruoyi.wisdomarbitrate.service.IdentityAuthenticationService;
8
 import org.springframework.beans.factory.annotation.Autowired;
9
 import org.springframework.beans.factory.annotation.Autowired;
37
     private SysPermissionService permissionService;
38
     private SysPermissionService permissionService;
38
     @Autowired
39
     @Autowired
39
     IdentityAuthenticationService identityAuthenticationService;
40
     IdentityAuthenticationService identityAuthenticationService;
41
+    @Autowired
42
+    private ISysUserService sysUserService;
40
 
43
 
41
     /**
44
     /**
42
      * 登录方法
45
      * 登录方法
57
         String status = identityAuthenticationService.checkIsAuthentication(identityAuthentication);
60
         String status = identityAuthenticationService.checkIsAuthentication(identityAuthentication);
58
 
61
 
59
         ajax.put("certificationStatus", status);
62
         ajax.put("certificationStatus", status);
60
-        ajax.put("userId", SecurityUtils.getUserId());
61
-        ajax.put("userName", SecurityUtils.getUsername());
63
+        // 获取用户信息
64
+        SysUser sysUser = sysUserService.selectUserByUserName(loginBody.getUsername());
65
+        ajax.put("userId", sysUser!=null?sysUser.getUserId():"");
66
+        ajax.put("userName", sysUser!=null?sysUser.getUserName():"");
62
         return ajax;
67
         return ajax;
63
     }
68
     }
64
 
69
 

+ 14
- 8
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysUserController.java Visa fil

3
 import java.util.List;
3
 import java.util.List;
4
 import java.util.stream.Collectors;
4
 import java.util.stream.Collectors;
5
 import javax.servlet.http.HttpServletResponse;
5
 import javax.servlet.http.HttpServletResponse;
6
+
7
+import cn.hutool.core.util.StrUtil;
8
+import com.ruoyi.common.annotation.Anonymous;
6
 import org.apache.commons.lang3.ArrayUtils;
9
 import org.apache.commons.lang3.ArrayUtils;
7
 import org.springframework.beans.factory.annotation.Autowired;
10
 import org.springframework.beans.factory.annotation.Autowired;
8
 import org.springframework.security.access.prepost.PreAuthorize;
11
 import org.springframework.security.access.prepost.PreAuthorize;
9
 import org.springframework.validation.annotation.Validated;
12
 import org.springframework.validation.annotation.Validated;
10
-import org.springframework.web.bind.annotation.DeleteMapping;
11
-import org.springframework.web.bind.annotation.GetMapping;
12
-import org.springframework.web.bind.annotation.PathVariable;
13
-import org.springframework.web.bind.annotation.PostMapping;
14
-import org.springframework.web.bind.annotation.PutMapping;
15
-import org.springframework.web.bind.annotation.RequestBody;
16
-import org.springframework.web.bind.annotation.RequestMapping;
17
-import org.springframework.web.bind.annotation.RestController;
13
+import org.springframework.web.bind.annotation.*;
18
 import org.springframework.web.multipart.MultipartFile;
14
 import org.springframework.web.multipart.MultipartFile;
19
 import com.ruoyi.common.annotation.Log;
15
 import com.ruoyi.common.annotation.Log;
20
 import com.ruoyi.common.core.controller.BaseController;
16
 import com.ruoyi.common.core.controller.BaseController;
248
     {
244
     {
249
         return success(deptService.selectDeptTreeList(dept));
245
         return success(deptService.selectDeptTreeList(dept));
250
     }
246
     }
247
+    /**
248
+     * 根据userId获取用户信息
249
+     * @param userId
250
+     * @return
251
+     */
252
+    @Anonymous
253
+    @GetMapping("/generateUserSign")
254
+    public AjaxResult generateUserSign(@RequestParam(required = true) Long userId){
255
+        return AjaxResult.success(userService.selectUserById(userId));
256
+    }
251
 }
257
 }

+ 13
- 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/wisdomarbitrate/CaseApplicationController.java Visa fil

23
 import com.ruoyi.common.utils.poi.ExcelUtil;
23
 import com.ruoyi.common.utils.poi.ExcelUtil;
24
 import org.springframework.web.multipart.MultipartFile;
24
 import org.springframework.web.multipart.MultipartFile;
25
 
25
 
26
+import javax.servlet.http.HttpServletRequest;
26
 import javax.servlet.http.HttpServletResponse;
27
 import javax.servlet.http.HttpServletResponse;
27
 import java.util.List;
28
 import java.util.List;
28
 
29
 
375
         return caseApplicationService.reservedConference(reservedConferenceVO);
376
         return caseApplicationService.reservedConference(reservedConferenceVO);
376
     }
377
     }
377
 
378
 
379
+    /**
380
+     * 腾讯云销毁房间回调
381
+     * @param body
382
+     * @param request
383
+     * @return
384
+     */
385
+    @Anonymous
386
+    @PostMapping("/destroyRoomBack")
387
+    public AjaxResult destroyRoomBack(  @RequestBody String body, HttpServletRequest request) {
388
+        caseApplicationService.destroyRoomBack(body,request);
389
+        return success();
390
+    }
378
 }
391
 }

+ 9
- 0
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/domain/CaseAffiliate.java Visa fil

135
 
135
 
136
     /** 送达电子邮件 */
136
     /** 送达电子邮件 */
137
     private String sendEmail;
137
     private String sendEmail;
138
+    private String userId;
138
     private String applicantAgentUserId;
139
     private String applicantAgentUserId;
139
 
140
 
141
+    public String getUserId() {
142
+        return userId;
143
+    }
144
+
145
+    public void setUserId(String userId) {
146
+        this.userId = userId;
147
+    }
148
+
140
     public String getApplicantAgentUserId() {
149
     public String getApplicantAgentUserId() {
141
         return applicantAgentUserId;
150
         return applicantAgentUserId;
142
     }
151
     }

+ 40
- 0
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/domain/ReservedConference.java Visa fil

1
+package com.ruoyi.wisdomarbitrate.domain;
2
+
3
+import lombok.Data;
4
+
5
+/**
6
+ * @author wangqiong
7
+ * @description 预定会议
8
+ * @Version 1.0
9
+ * @date 2023-11-09 16:51
10
+ */
11
+@Data
12
+public class ReservedConference {
13
+    /**
14
+     * id
15
+     */
16
+    private String id;
17
+    /**
18
+     * 案件id
19
+     */
20
+    private Long caseId;
21
+    /**
22
+     * 房间号
23
+     */
24
+    private String roomId;
25
+    /**
26
+     * 预定会议开始时间
27
+     */
28
+    private String scheduleStartTime;
29
+    /**
30
+     * 预定会议结束时间
31
+     */
32
+    private String scheduleEndTime;
33
+
34
+    public ReservedConference( Long caseId, String roomId, String scheduleStartTime, String scheduleEndTime) {
35
+        this.caseId = caseId;
36
+        this.roomId = roomId;
37
+        this.scheduleStartTime = scheduleStartTime;
38
+        this.scheduleEndTime = scheduleEndTime;
39
+    }
40
+}

+ 37
- 0
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/mapper/ReservedConferenceMapper.java Visa fil

1
+package com.ruoyi.wisdomarbitrate.mapper;
2
+
3
+import com.ruoyi.wisdomarbitrate.domain.ReservedConference;
4
+import org.springframework.data.repository.query.Param;
5
+import org.springframework.stereotype.Repository;
6
+
7
+
8
+import java.util.List;
9
+
10
+
11
+/**
12
+ * @author wangqiong
13
+ * @description 预约会议Mapper接口
14
+ * @Version 1.0
15
+ * @date 2023-11-09 16:51
16
+ */
17
+@Repository
18
+public interface ReservedConferenceMapper {
19
+    /**
20
+     * 根据案件id查询预约会议列表
21
+     * @param caseId
22
+     * @return
23
+     */
24
+    List<ReservedConference> selectListByCaseId(@Param("caseId")Long caseId);
25
+
26
+    /**
27
+     * 新增
28
+     * @param reservedConference
29
+     */
30
+    void insert(ReservedConference reservedConference);
31
+
32
+    /**
33
+     * 根据房间号删除
34
+     * @param roomId
35
+     */
36
+    void deleteByRoomId(@Param("roomId")String roomId);
37
+}

+ 9
- 0
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/ICaseApplicationService.java Visa fil

8
 import com.ruoyi.wisdomarbitrate.domain.vo.ToDoCount;
8
 import com.ruoyi.wisdomarbitrate.domain.vo.ToDoCount;
9
 import org.springframework.web.multipart.MultipartFile;
9
 import org.springframework.web.multipart.MultipartFile;
10
 
10
 
11
+import javax.servlet.http.HttpServletRequest;
11
 import java.util.List;
12
 import java.util.List;
12
 
13
 
13
 public interface ICaseApplicationService {
14
 public interface ICaseApplicationService {
94
      * @throws Exception
95
      * @throws Exception
95
      */
96
      */
96
      AjaxResult reservedConference(ReservedConferenceVO reservedConferenceVO) throws Exception;
97
      AjaxResult reservedConference(ReservedConferenceVO reservedConferenceVO) throws Exception;
98
+
99
+    /**
100
+     * 腾讯云销毁房间回调
101
+     * @param body
102
+     * @param request
103
+     * @return
104
+     */
105
+    void destroyRoomBack(String body, HttpServletRequest request);
97
 }
106
 }

+ 66
- 23
ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/impl/CaseApplicationServiceImpl.java Visa fil

3
 
3
 
4
 import cn.hutool.core.collection.CollectionUtil;
4
 import cn.hutool.core.collection.CollectionUtil;
5
 import cn.hutool.core.util.StrUtil;
5
 import cn.hutool.core.util.StrUtil;
6
+import com.alibaba.fastjson.JSON;
6
 import com.alibaba.fastjson.JSONArray;
7
 import com.alibaba.fastjson.JSONArray;
7
 import com.alibaba.fastjson.JSONObject;
8
 import com.alibaba.fastjson.JSONObject;
8
 import com.google.gson.Gson;
9
 import com.google.gson.Gson;
45
 import org.springframework.stereotype.Service;
46
 import org.springframework.stereotype.Service;
46
 import org.springframework.transaction.annotation.Transactional;
47
 import org.springframework.transaction.annotation.Transactional;
47
 import org.springframework.web.multipart.MultipartFile;
48
 import org.springframework.web.multipart.MultipartFile;
49
+
50
+import javax.servlet.http.HttpServletRequest;
48
 import java.io.*;
51
 import java.io.*;
49
 import java.math.BigDecimal;
52
 import java.math.BigDecimal;
50
 import java.math.RoundingMode;
53
 import java.math.RoundingMode;
55
 import java.time.LocalDate;
58
 import java.time.LocalDate;
56
 import java.time.ZoneId;
59
 import java.time.ZoneId;
57
 import java.util.*;
60
 import java.util.*;
58
-import java.util.concurrent.ThreadLocalRandom;
59
 import java.util.regex.Pattern;
61
 import java.util.regex.Pattern;
60
 import java.util.stream.Collectors;
62
 import java.util.stream.Collectors;
61
 
63
 
102
     private SmsRecordMapper smsRecordMapper;
104
     private SmsRecordMapper smsRecordMapper;
103
     @Autowired
105
     @Autowired
104
     private DeptIdentifyMapper deptIdentifyMapper;
106
     private DeptIdentifyMapper deptIdentifyMapper;
107
+    @Autowired
108
+    private ReservedConferenceMapper reservedConferenceMapper;
105
     // 手机号正则
109
     // 手机号正则
106
     private static final Pattern TELEPHONE_REGX = Pattern.compile("^1(3\\d|4[5-9]|5[0-35-9]|6[2567]|7[0-8]|8\\d|9[0-35-9])\\d{8}$");
110
     private static final Pattern TELEPHONE_REGX = Pattern.compile("^1(3\\d|4[5-9]|5[0-35-9]|6[2567]|7[0-8]|8\\d|9[0-35-9])\\d{8}$");
107
 
111
 
1872
         caseApplication.setId(messageVO.getId());
1876
         caseApplication.setId(messageVO.getId());
1873
         CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
1877
         CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
1874
         String returnResult = "短信发送成功";
1878
         String returnResult = "短信发送成功";
1875
-        //发送短信通知
1879
+        //todo 需要申请模板,申请人,被申请人发送短信通知
1876
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
1880
         SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
1877
         request.setTemplateId("1952136");
1881
         request.setTemplateId("1952136");
1878
         for (CaseAffiliate caseAffiliate : caseAffiliates) {
1882
         for (CaseAffiliate caseAffiliate : caseAffiliates) {
1879
             request.setPhone(caseAffiliate.getContactTelphone());
1883
             request.setPhone(caseAffiliate.getContactTelphone());
1880
-            request.setTemplateParamSet(new String[]{caseAffiliate.getName(), caseApplicationselect.getCaseNum(), messageVO.getRoomNo()});
1881
-            // 1948332 普通短信 尊敬的{1}用户,您的{2}仲裁案件,开庭审理房间号为{3},请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。
1884
+            request.setTemplateParamSet(new String[]{caseAffiliate.getName(), caseApplicationselect.getCaseNum(), messageVO.getRoomNo()+caseAffiliate.getUserId()});
1885
+            // 1952136 普通短信 尊敬的{1}用户,您的{2}仲裁案件,开庭审理房间号为{3},请在浏览器打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。
1882
             Boolean aBoolean = SmsUtils.sendSms(request);
1886
             Boolean aBoolean = SmsUtils.sendSms(request);
1883
             //保存短信发送记录
1887
             //保存短信发送记录
1884
             SmsSendRecord smsSendRecord = new SmsSendRecord();
1888
             SmsSendRecord smsSendRecord = new SmsSendRecord();
1886
             smsSendRecord.setCaseNum(caseApplicationselect.getCaseNum());
1890
             smsSendRecord.setCaseNum(caseApplicationselect.getCaseNum());
1887
             smsSendRecord.setPhone(request.getPhone());
1891
             smsSendRecord.setPhone(request.getPhone());
1888
             smsSendRecord.setSendTime(new Date());
1892
             smsSendRecord.setSendTime(new Date());
1889
-            String content = "尊敬的" + caseAffiliate.getName() + "用户,您的" + caseApplicationselect.getCaseNum() + "仲裁案件,开庭审理房间号为" + messageVO.getRoomNo() + ",请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。";
1893
+            String content = "尊敬的" + caseAffiliate.getName() + "用户,您的" + caseApplicationselect.getCaseNum() + "仲裁案件,开庭审理房间号为" + messageVO.getRoomNo()+caseAffiliate.getUserId() + ",请在微信内打开https://miniapp-3gpama6l759911ef-1321289474.tcloudbaseapp.com/jump-mp.html 请知晓,如非本人操作,请忽略本短信。";
1890
             smsSendRecord.setSendContent(content);
1894
             smsSendRecord.setSendContent(content);
1891
 
1895
 
1892
             String userName;
1896
             String userName;
1905
         }
1909
         }
1906
         return returnResult;
1910
         return returnResult;
1907
     }
1911
     }
1908
-
1909
     @Override
1912
     @Override
1910
     public SealSignRecord selectSignUrl(CaseApplication caseApplication) throws EsignDemoException {
1913
     public SealSignRecord selectSignUrl(CaseApplication caseApplication) throws EsignDemoException {
1911
         SealSignRecord sealSignRecord = new SealSignRecord();
1914
         SealSignRecord sealSignRecord = new SealSignRecord();
2467
     @Transactional
2470
     @Transactional
2468
     @Override
2471
     @Override
2469
     public AjaxResult reservedConference(ReservedConferenceVO reservedConferenceVO) throws Exception {
2472
     public AjaxResult reservedConference(ReservedConferenceVO reservedConferenceVO) throws Exception {
2470
-        // 生成administrator的userSig
2473
+        // 创建房间必须拿administrator生成usersig,否则调用腾讯云接口报7004,生成administrator的userSig
2471
         String administrator = "administrator";
2474
         String administrator = "administrator";
2472
         String userSign = generateUserSign(administrator);
2475
         String userSign = generateUserSign(administrator);
2473
         if (StrUtil.isEmpty(userSign)) {
2476
         if (StrUtil.isEmpty(userSign)) {
2474
             return AjaxResult.error("生成userSign失败");
2477
             return AjaxResult.error("生成userSign失败");
2475
         }
2478
         }
2476
-        int random = ThreadLocalRandom.current().nextInt(0, 214748364);
2479
+        Integer scheduleStartTime = reservedConferenceVO.getScheduleStartTime();
2480
+        Integer scheduleEndTime = reservedConferenceVO.getScheduleEndTime();
2481
+        Random rand = new Random();
2482
+        int random = rand.nextInt(214748365);
2477
         String url="https://roomkit.trtc.tencent-cloud.com/room_api/v1/roomctl/create?usersig=" + userSign + "&identifier=" + administrator + "&sdkappid=" + sdkAppId + "&random=" +random + "&contenttype=json";
2483
         String url="https://roomkit.trtc.tencent-cloud.com/room_api/v1/roomctl/create?usersig=" + userSign + "&identifier=" + administrator + "&sdkappid=" + sdkAppId + "&random=" +random + "&contenttype=json";
2478
         HttpPost post = new HttpPost(url);
2484
         HttpPost post = new HttpPost(url);
2479
         String result = "";
2485
         String result = "";
2480
-
2481
-
2482
         //添加参数
2486
         //添加参数
2483
         JSONObject bodyParams = new JSONObject();
2487
         JSONObject bodyParams = new JSONObject();
2488
+        JSONObject roomParams = new JSONObject();
2484
         bodyParams.put("ownerId", reservedConferenceVO.getOwnerId());
2489
         bodyParams.put("ownerId", reservedConferenceVO.getOwnerId());
2485
         bodyParams.put("roomId", reservedConferenceVO.getRoomId());
2490
         bodyParams.put("roomId", reservedConferenceVO.getRoomId());
2486
-        bodyParams.put("scheduleStartTime", reservedConferenceVO.getScheduleStartTime());
2487
-        bodyParams.put("scheduleEndTime", reservedConferenceVO.getScheduleEndTime());
2491
+        bodyParams.put("scheduleStartTime", scheduleStartTime);
2492
+        bodyParams.put("scheduleEndTime",scheduleEndTime);
2493
+        roomParams.put("roomType", 1);
2494
+        bodyParams.put("roomInfo", roomParams);
2488
         StringEntity postingString = new StringEntity(bodyParams.toString());
2495
         StringEntity postingString = new StringEntity(bodyParams.toString());
2489
         post.setEntity(postingString);
2496
         post.setEntity(postingString);
2490
         CloseableHttpClient client = HttpClients.createDefault();
2497
         CloseableHttpClient client = HttpClients.createDefault();
2496
         result = EntityUtils.toString(entity, "UTF-8");
2503
         result = EntityUtils.toString(entity, "UTF-8");
2497
         if (StrUtil.isNotEmpty(result)) {
2504
         if (StrUtil.isNotEmpty(result)) {
2498
             JSONObject resJson = JSONObject.parseObject(result);
2505
             JSONObject resJson = JSONObject.parseObject(result);
2499
-            if ((int) resJson.get("errorCode") == 0 ) {
2500
-                // 绑定房间号和案件id
2501
-                caseApplicationMapper.bindCaseId(reservedConferenceVO.getCaseId(),reservedConferenceVO.getRoomId());
2502
-                return AjaxResult.success("预约会议成功");
2503
-            } else if((int) resJson.get("errorCode") == 42003){
2504
-                return AjaxResult.error("请求频繁");
2505
-            }else if((int) resJson.get("errorCode") == 84005){
2506
-                return AjaxResult.error("房间号已被占用");
2507
-            }else {
2508
-                return AjaxResult.error("预约会议失败");
2506
+            switch ((int) resJson.get("errorCode")) {
2507
+                case 0:
2508
+                    // todo  不需要绑定,以后删        绑定房间号和案件id
2509
+                    caseApplicationMapper.bindCaseId(reservedConferenceVO.getCaseId(), reservedConferenceVO.getRoomId());
2510
+                    String format = "yyyy-MM-dd HH:mm:ss"; // 目标格式
2511
+                    Date startDate = new Date(scheduleStartTime);
2512
+                    Date endDate = new Date(scheduleEndTime);
2513
+                    SimpleDateFormat sdf = new SimpleDateFormat(format);
2514
+                    String startFormat = sdf.format(startDate);
2515
+                    String endFormat = sdf.format(endDate);
2516
+                    // 新增预约会议表
2517
+                    ReservedConference conference = new ReservedConference(reservedConferenceVO.getCaseId(), reservedConferenceVO.getRoomId(),
2518
+                            startFormat, endFormat);
2519
+                    reservedConferenceMapper.insert(conference);
2520
+                    return AjaxResult.success("预约会议成功");
2521
+
2522
+                case 42002:
2523
+                    return AjaxResult.error("预定会议无效");
2524
+                case 42003:
2525
+                    return AjaxResult.error("预定会议必须是会议场景");
2526
+                case 84005:
2527
+                    return AjaxResult.error("房间号已被占用");
2528
+                default:
2529
+                    return AjaxResult.error("预约会议失败");
2509
             }
2530
             }
2510
 
2531
 
2511
-        }else {
2532
+        } else {
2512
             return AjaxResult.error("预约会议失败");
2533
             return AjaxResult.error("预约会议失败");
2513
         }
2534
         }
2514
     }
2535
     }
2515
 
2536
 
2537
+    /**
2538
+     * 销毁房间回调
2539
+     * @param body
2540
+     * @param request
2541
+     */
2542
+    @Override
2543
+    public void destroyRoomBack(String body, HttpServletRequest request) {
2544
+        JSONObject jsonObject = (JSONObject) JSON.parse(body);
2545
+        // 事件类型
2546
+        Integer eventType = jsonObject.getInteger("EventType");
2547
+        // 事件信息
2548
+        String eventInfo = jsonObject.getString("EventInfo");
2549
+        JSONObject eventInfoJson = (JSONObject) JSON.parse(eventInfo);
2550
+        // 104 退出房间事件
2551
+        if (eventType == 104) {
2552
+            // 删除预定会议表
2553
+            reservedConferenceMapper.deleteByRoomId(eventInfoJson.getString("RoomId"));
2554
+        }
2555
+
2556
+    }
2557
+
2516
 
2558
 
2517
 }
2559
 }
2518
 
2560
 
2519
 
2561
 
2562
+

+ 3
- 1
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/CaseAffiliateMapper.xml Visa fil

29
 
29
 
30
         <result property="residenAffili"    column="residen_affili"   />
30
         <result property="residenAffili"    column="residen_affili"   />
31
         <result property="appliAgentTitle"    column="appli_agent_title"   />
31
         <result property="appliAgentTitle"    column="appli_agent_title"   />
32
+        <result property="userId"    column="user_id"   />
32
 
33
 
33
     </resultMap>
34
     </resultMap>
34
 
35
 
37
         c.work_address ,c.work_telphone ,c.name_agent, c.identity_num_agent ,c.contact_telphone_agent ,c.contact_address_agent,
38
         c.work_address ,c.work_telphone ,c.name_agent, c.identity_num_agent ,c.contact_telphone_agent ,c.contact_address_agent,
38
         c.comp_legal_person,c.comp_legalper_post,c.respon_sex,c.respon_birth,
39
         c.comp_legal_person,c.comp_legalper_post,c.respon_sex,c.respon_birth,
39
         c.residen_affili,c.appli_agent_title,
40
         c.residen_affili,c.appli_agent_title,
40
-        c.track_num,c.application_organ_id,c.application_organ_name
41
+        c.track_num,c.application_organ_id,c.application_organ_name,s.user_id
41
         from case_affiliate c
42
         from case_affiliate c
43
+        left join sys_user s on c.identity_num=s.id_card
42
         <where>
44
         <where>
43
             <if test="caseAppliId != null ">
45
             <if test="caseAppliId != null ">
44
                 AND c.case_appli_id = #{caseAppliId}
46
                 AND c.case_appli_id = #{caseAppliId}

+ 35
- 0
ruoyi-system/src/main/resources/mapper/wisdomarbitrate/ReservedConferenceMapper.xml Visa fil

1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper
3
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5
+<mapper namespace="com.ruoyi.wisdomarbitrate.mapper.ReservedConferenceMapper">
6
+    <resultMap type="com.ruoyi.wisdomarbitrate.domain.ReservedConference" id="BaseResult">
7
+        <id     property="id"       column="id"      />
8
+        <result property="caseId"     column="case_id"    />
9
+        <result property="roomId"     column="room_id"    />
10
+        <result property="scheduleStartTime"        column="schedule_start_time"        />
11
+        <result property="scheduleEndTime"  column="schedule_end_time"  />
12
+
13
+    </resultMap>
14
+    <insert id="insert">
15
+        insert into reserved_conference(
16
+        case_id,
17
+        room_id,
18
+        schedule_start_time,
19
+        schedule_end_time
20
+        )values(
21
+                #{caseId},
22
+                #{roomId},
23
+                #{scheduleStartTime},
24
+                #{scheduleEndTime}
25
+        )
26
+    </insert>
27
+    <delete id="deleteByRoomId">
28
+        delete from reserved_conference where room_id=#{roomId}
29
+    </delete>
30
+    <select id="selectListByCaseId" resultMap="BaseResult">
31
+        select * from reserved_conference where case_id=#{caseId}
32
+    </select>
33
+
34
+
35
+</mapper>