瀏覽代碼

Merge branch 'dev' of http://git.xayunmei.com/SH-Arbitrate/Mediation-Frontend into hhl

hhl123456789 2 年之前
父節點
當前提交
6470f23e30
共有 2 個檔案被更改,包括 59 行新增40 行删除
  1. 8
    0
      src/api/caseManagement/caseManagement.js
  2. 51
    40
      src/views/caseManagement/components/mediation.vue

+ 8
- 0
src/api/caseManagement/caseManagement.js 查看文件

@@ -231,3 +231,11 @@ export function confirmMeetingResult(data) {
231 231
     data: data
232 232
   })
233 233
 }
234
+// 根据用户id查询是否为调解员
235
+export function secretaryRoleByUserId(query) {
236
+  return request({
237
+    url: '/video/secretaryRoleByUserId',
238
+    method: 'get',
239
+    params: query
240
+  })
241
+}

+ 51
- 40
src/views/caseManagement/components/mediation.vue 查看文件

@@ -39,19 +39,19 @@
39 39
         <el-col :span="24">
40 40
           <el-form-item label="申请人案件证据:">
41 41
             <div v-if="applicateArr.length == 0">申请人暂未提供证据!</div>
42
-            <div  v-for="(item, index) in applicateArr" :key="index" v-if="item.annexType == 2">
42
+            <div v-for="(item, index) in applicateArr" :key="index" v-if="item.annexType == 2">
43 43
               <a href="#" @click="toFile(item, index)" style="color: blue">{{ item.annexName }}</a>
44 44
             </div>
45 45
           </el-form-item>
46 46
         </el-col>
47 47
         <el-col :span="24" v-if="mediationType">
48 48
           <el-form-item label="调解结果:">
49
-             <el-radio-group v-model="mediaResult" @change="resultsMediation">
50
-                <el-radio :label="1">达成调解</el-radio>
51
-                <el-radio :label="2">未达成调解</el-radio>
52
-                <el-radio :label="3">未达成调解但不在争议</el-radio>
53
-                <el-radio :label="4">未达成调解但同意引入仲裁</el-radio>
54
-                <el-radio :label="5">达成和解</el-radio>
49
+            <el-radio-group v-model="mediaResult" :disabled="!isSecretaryRole" @change="resultsMediation">
50
+              <el-radio :label="1">达成调解</el-radio>
51
+              <el-radio :label="2">未达成调解</el-radio>
52
+              <el-radio :label="3">未达成调解但不在争议</el-radio>
53
+              <el-radio :label="4">未达成调解但同意引入仲裁</el-radio>
54
+              <el-radio :label="5">达成和解</el-radio>
55 55
             </el-radio-group>
56 56
           </el-form-item>
57 57
         </el-col>
@@ -98,10 +98,10 @@
98 98
         <!-- v-if="!mediationType" -->
99 99
         <el-col :span="24">
100 100
           <el-form-item label="上传调解书">
101
-            <el-upload class="upload-demo" accept=".png,.jpg,.doc,.docx,.txt,.pdf" ref="upload" :action="UploadUrl()" :headers="headers" :data="filedata"
102
-              :on-preview="handlePreview" :on-remove="handleRemove" :limit="1" :on-change="beforeUpload" :on-success="handlSuccess"
103
-              :file-list="fileList">
104
-              <el-button slot="trigger" size="small" type="primary">选取文件</el-button>
101
+            <el-upload class="upload-demo" accept=".png,.jpg,.doc,.docx,.txt,.pdf" ref="upload" :action="UploadUrl()"
102
+              :headers="headers" :data="filedata" :on-preview="handlePreview" :on-remove="handleRemove" :limit="1"
103
+              :on-change="beforeUpload" :on-success="handlSuccess" :file-list="fileList">
104
+              <el-button slot="trigger" size="small" :disabled="!isSecretaryRole" type="primary">选取文件</el-button>
105 105
               <!-- <el-button style="margin-left: 10px;" size="small" type="success" @click="submitUpload">上传到服务器</el-button> -->
106 106
               <div slot="tip" class="el-upload__tip">只能上传.jpg,png,.doc,docx,.txt,.pdf文件</div>
107 107
             </el-upload>
@@ -109,16 +109,16 @@
109 109
         </el-col>
110 110
         <!-- </el-form> -->
111 111
       </el-form>
112
-      <el-button @click="openmeeting" type="primary" v-if="mediationType">发起会议</el-button>
112
+      <el-button @click="openmeeting" type="primary" v-if="mediationType">{{ isSecretaryRole ? '发起会议' :
113
+        '进入会议' }}</el-button>
113 114
       <!-- v-if="this.recordArr.length <= 0 && mediationData.mediationMethod == '1'" -->
114 115
       <el-button @click="openArbitrationresults" type="primary"
115
-     v-if="this.recordArr.length <= 0 && mediationData.mediationMethod == '1'"
116
-        >确认会议结果</el-button>
116
+        v-if="this.recordArr.length <= 0 && mediationData.mediationMethod == '1'">确认会议结果</el-button>
117 117
       <div slot="footer" class="dialog-footer">
118 118
         <el-button @click="cancel" class="endbutton1" round>
119 119
           <span>取 消</span>
120 120
         </el-button>
121
-        <el-button @click="submitMediation" :disabled="this.recordArr.length <= 0 && mediationData.mediationMethod == '1'"
121
+        <el-button v-if="isSecretaryRole" @click="submitMediation" :disabled="this.recordArr.length <= 0 && mediationData.mediationMethod == '1'"
122 122
           class="endbutton1" type="primary" round>
123 123
           <span>提 交</span>
124 124
         </el-button>
@@ -131,7 +131,8 @@
131 131
 import {
132 132
   caseApplicationSelectById,
133 133
   mediation,
134
-  confirmMeetingResult
134
+  confirmMeetingResult,
135
+  secretaryRoleByUserId
135 136
 } from "@/api/caseManagement/caseManagement.js";
136 137
 import { getUserProfile } from "@/api/system/user";
137 138
 import { reserveConferenceList } from "@/api/metting/metting.js";
@@ -141,15 +142,15 @@ export default {
141 142
   data() {
142 143
     return {
143 144
       loanStartDate: "",
144
-      codes:null,
145
+      codes: null,
145 146
       title: "线上调解",
146 147
       applicateArr: [],
147 148
       quiltArr: [],
148 149
       recordArr: [],
149
-      recordArrMediate:[],
150
+      recordArrMediate: [],
150 151
       roomId: null,
151 152
       startTime: null,
152
-      mediaResult:1,
153
+      mediaResult: 1,
153 154
       // isReconci:0,
154 155
       formData: {
155 156
         affiliate: {}
@@ -164,8 +165,9 @@ export default {
164 165
       filedata: {
165 166
         annexType: 7,
166 167
       },
167
-      fileList:[],
168
-      attachList:[],
168
+      fileList: [],
169
+      attachList: [],
170
+      isSecretaryRole: true,
169 171
     };
170 172
   },
171 173
   watch: {
@@ -189,6 +191,14 @@ export default {
189 191
   },
190 192
   created() { },
191 193
   methods: {
194
+    // 根据用户id查询是否为调解员
195
+    secretaryRoleByUserIdFn() {
196
+      secretaryRoleByUserId({
197
+        userId: this.userId
198
+      }).then(res => {
199
+        this.isSecretaryRole = res.data.isSecretaryRole;
200
+      })
201
+    },
192 202
     /**上传地址*/
193 203
     UploadUrl() {
194 204
       return window.location.origin + "/API/common/upload";
@@ -196,14 +206,14 @@ export default {
196 206
     handlePreview(file) {
197 207
     },
198 208
     handleRemove(file, fileList) {
199
-     
209
+
200 210
     },
201 211
     beforeUpload(flie, fileList) {
202 212
       this.fileList = fileList;
203 213
     },
204 214
     handlSuccess(res, file) {
205 215
       this.codes = res.code
206
-      this.attachList = [{annexId:res.annexId}];
216
+      this.attachList = [{ annexId: res.annexId }];
207 217
       // this.$set(this.mediationData, "attachList", {annexId:res.annexId});
208 218
     },
209 219
     /** 获取案件详情信息 */
@@ -214,7 +224,7 @@ export default {
214 224
         res.data.caseAttachList.forEach(item => {
215 225
           if (item.annexType == 6) {
216 226
             this.recordArr.push(item);
217
-          }else if(item.annexType == 7){
227
+          } else if (item.annexType == 7) {
218 228
             this.recordArrMediate.push(item);
219 229
           }
220 230
         });
@@ -225,6 +235,7 @@ export default {
225 235
       getUserProfile().then(response => {
226 236
         this.user = response.data.userName;
227 237
         this.userId = response.data.userId;
238
+        this.secretaryRoleByUserIdFn();
228 239
       });
229 240
     },
230 241
     /** 发起会议 */
@@ -250,10 +261,10 @@ export default {
250 261
         id: this.mediationData.id,
251 262
         caseFlowId: this.mediationData.caseFlowId,
252 263
         batchNumber: "",
253
-        mediaResult:this.mediaResult,
254
-      }).then(res =>{
264
+        mediaResult: this.mediaResult,
265
+      }).then(res => {
255 266
         caseApplicationSelectById({
256
-        id: this.mediationData.id
267
+          id: this.mediationData.id
257 268
         }).then(res => {
258 269
           res.data.caseAttachList.forEach(item => {
259 270
             if (item.annexType == 7) {
@@ -286,26 +297,26 @@ export default {
286 297
         this.$modal.msgError("请上传调解书");
287 298
         return
288 299
       }
289
-      let mediationVal ={}
290
-      if (this.codes == 200){
300
+      let mediationVal = {}
301
+      if (this.codes == 200) {
291 302
         mediationVal = {
292
-        id: this.mediationData.id,
293
-        caseFlowId: this.mediationData.caseFlowId,
294
-        attachList: this.attachList,
295
-        // isReconci:this.isReconci,
296
-        mediaResult:this.mediaResult,
303
+          id: this.mediationData.id,
304
+          caseFlowId: this.mediationData.caseFlowId,
305
+          attachList: this.attachList,
306
+          // isReconci:this.isReconci,
307
+          mediaResult: this.mediaResult,
297 308
         }
298
-      }else{
309
+      } else {
299 310
         mediationVal = {
300
-        id: this.mediationData.id,
301
-        caseFlowId: this.mediationData.caseFlowId,
302
-        mediaResult:this.mediaResult,
311
+          id: this.mediationData.id,
312
+          caseFlowId: this.mediationData.caseFlowId,
313
+          mediaResult: this.mediaResult,
303 314
         }
304 315
       }
305 316
       this.mediationFn(mediationVal);
306 317
     },
307
-    resultsMediation(){
308
-      
318
+    resultsMediation() {
319
+
309 320
     }
310 321
   }
311 322
 };