|
@@ -87,7 +87,7 @@ |
|
@@ -87,7 +87,7 @@ |
|
87
|
<uni-popup ref="uploadPopup" type="bottom" :mask-click="false" :safe-area="true">
|
87
|
<uni-popup ref="uploadPopup" type="bottom" :mask-click="false" :safe-area="true">
|
|
88
|
<view class="upload-dialog">
|
88
|
<view class="upload-dialog">
|
|
89
|
<view class="upload-header">
|
89
|
<view class="upload-header">
|
|
90
|
- <text class="title">上传规范性合同</text>
|
90
|
+ <text class="title">{{ uploadType === 'seal' ? '上传双方盖章合同' : '上传规范性合同' }}</text>
|
|
91
|
<uni-icons type="closeempty" style="position: absolute; right: 16px;" size="22"
|
91
|
<uni-icons type="closeempty" style="position: absolute; right: 16px;" size="22"
|
|
92
|
@click="$refs.uploadPopup.close()" />
|
92
|
@click="$refs.uploadPopup.close()" />
|
|
93
|
</view>
|
93
|
</view>
|
|
@@ -97,7 +97,7 @@ |
|
@@ -97,7 +97,7 @@ |
|
97
|
<FileUpload v-model="fileInfo" />
|
97
|
<FileUpload v-model="fileInfo" />
|
|
98
|
</view>
|
98
|
</view>
|
|
99
|
<view v-if="fileInfo && fileInfo.name" class="upload-show">{{ fileInfo.name }}</view>
|
99
|
<view v-if="fileInfo && fileInfo.name" class="upload-show">{{ fileInfo.name }}</view>
|
|
100
|
- <view class="row1" @click="openStandardizedSheet">
|
100
|
+ <view class="row1" @click="openStandardizedSheet" v-if="uploadType !== 'seal'">
|
|
101
|
<view class="label1">合同是否规范</view>
|
101
|
<view class="label1">合同是否规范</view>
|
|
102
|
<uni-icons type="right" size="18" v-if="!standardStandardizedName"></uni-icons>
|
102
|
<uni-icons type="right" size="18" v-if="!standardStandardizedName"></uni-icons>
|
|
103
|
<view class="value" v-else>{{ standardStandardizedName }}</view>
|
103
|
<view class="value" v-else>{{ standardStandardizedName }}</view>
|
|
@@ -114,7 +114,7 @@ |
|
@@ -114,7 +114,7 @@ |
|
114
|
</template>
|
114
|
</template>
|
|
115
|
|
115
|
|
|
116
|
<script>
|
116
|
<script>
|
|
117
|
-import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract } from '@/api/contract'
|
117
|
+import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, uploadSignedContractFile } from '@/api/contract'
|
|
118
|
import ProductRel from './productRel.vue'
|
118
|
import ProductRel from './productRel.vue'
|
|
119
|
import DetailButtons from '@/components/detail-buttons/index.vue'
|
119
|
import DetailButtons from '@/components/detail-buttons/index.vue'
|
|
120
|
import FileUpload from '@/components/file-upload/index.vue'
|
120
|
import FileUpload from '@/components/file-upload/index.vue'
|
|
@@ -252,6 +252,12 @@ export default { |
|
@@ -252,6 +252,12 @@ export default { |
|
252
|
variant: 'primary',
|
252
|
variant: 'primary',
|
|
253
|
event: 'auditDetail3'
|
253
|
event: 'auditDetail3'
|
|
254
|
},
|
254
|
},
|
|
|
|
255
|
+ {
|
|
|
|
256
|
+ text: '上传双方盖章合同附件',
|
|
|
|
257
|
+ visible: true,
|
|
|
|
258
|
+ variant: 'outline',
|
|
|
|
259
|
+ event: 'uploadSeal'
|
|
|
|
260
|
+ },
|
|
255
|
],
|
261
|
],
|
|
256
|
}
|
262
|
}
|
|
257
|
},
|
263
|
},
|
|
@@ -277,6 +283,7 @@ export default { |
|
@@ -277,6 +283,7 @@ export default { |
|
277
|
{ ...this.buttons[10], visible: (s === 'FORMAL' && a) }, //正式合同审核详情
|
283
|
{ ...this.buttons[10], visible: (s === 'FORMAL' && a) }, //正式合同审核详情
|
|
278
|
{ ...this.buttons[11], visible: (s === 'STANDARD' && a) }, //正式合同审核详情
|
284
|
{ ...this.buttons[11], visible: (s === 'STANDARD' && a) }, //正式合同审核详情
|
|
279
|
{ ...this.buttons[12], visible: (s === 'STANDARD' && t) }, //标准合同审核详情
|
285
|
{ ...this.buttons[12], visible: (s === 'STANDARD' && t) }, //标准合同审核详情
|
|
|
|
286
|
+ { ...this.buttons[13], visible: (s === 'STANDARD') }, //上传双方盖章合同附件
|
|
280
|
]
|
287
|
]
|
|
281
|
}
|
288
|
}
|
|
282
|
},
|
289
|
},
|
|
@@ -343,14 +350,18 @@ export default { |
|
@@ -343,14 +350,18 @@ export default { |
|
343
|
})
|
350
|
})
|
|
344
|
return
|
351
|
return
|
|
345
|
}
|
352
|
}
|
|
346
|
- if (!this.standardStandardized) {
|
353
|
+ if (!this.standardStandardized && this.uploadType !== 'seal') {
|
|
347
|
uni.showToast({
|
354
|
uni.showToast({
|
|
348
|
title: '请选择合同是否规范',
|
355
|
title: '请选择合同是否规范',
|
|
349
|
icon: 'error'
|
356
|
icon: 'error'
|
|
350
|
})
|
357
|
})
|
|
351
|
return
|
358
|
return
|
|
352
|
}
|
359
|
}
|
|
353
|
- const data = this.uploadType === 'formal' ? {
|
360
|
+ const data = this.uploadType === 'seal' ? {
|
|
|
|
361
|
+ id: this.id,
|
|
|
|
362
|
+ signedContractFileId: this.fileInfo.id,
|
|
|
|
363
|
+ signedContractFileName: this.fileInfo.name,
|
|
|
|
364
|
+ } : this.uploadType === 'formal' ? {
|
|
354
|
id: this.id,
|
365
|
id: this.id,
|
|
355
|
formalFileId: this.fileInfo.id,
|
366
|
formalFileId: this.fileInfo.id,
|
|
356
|
formalFileName: this.fileInfo.name,
|
367
|
formalFileName: this.fileInfo.name,
|
|
@@ -361,15 +372,15 @@ export default { |
|
@@ -361,15 +372,15 @@ export default { |
|
361
|
standardFileName: this.fileInfo.name,
|
372
|
standardFileName: this.fileInfo.name,
|
|
362
|
standardStandardized: this.standardStandardized
|
373
|
standardStandardized: this.standardStandardized
|
|
363
|
}
|
374
|
}
|
|
364
|
- const api = this.uploadType === 'formal' ? uploadFormalContract : uploadStandardContract
|
375
|
+ const api = this.uploadType === 'seal' ? uploadSignedContractFile : this.uploadType === 'formal' ? uploadFormalContract : uploadStandardContract
|
|
365
|
uni.showModal({
|
376
|
uni.showModal({
|
|
366
|
title: '确认提交',
|
377
|
title: '确认提交',
|
|
367
|
- content: this.uploadType === 'formal' ? '确定提交正式合同吗?' : '确定提交标准合同吗?',
|
378
|
+ content: this.uploadType === 'formal' ? '确定提交正式合同吗?' : this.uploadType === 'seal' ? '确定提交双方盖章合同吗?' : '确定提交标准合同吗?',
|
|
368
|
success: (res) => {
|
379
|
success: (res) => {
|
|
369
|
if (res.confirm) {
|
380
|
if (res.confirm) {
|
|
370
|
api({ ...this.detail, ...data }).then(() => {
|
381
|
api({ ...this.detail, ...data }).then(() => {
|
|
371
|
uni.showToast({
|
382
|
uni.showToast({
|
|
372
|
- title: this.uploadType === 'formal' ? '上传正式合同成功' : '上传标准合同成功',
|
383
|
+ title: this.uploadType === 'seal' ? '上传双方盖章合同成功' : this.uploadType === 'formal' ? '上传正式合同成功' : '上传标准合同成功',
|
|
373
|
icon: 'success'
|
384
|
icon: 'success'
|
|
374
|
})
|
385
|
})
|
|
375
|
setTimeout(() => {
|
386
|
setTimeout(() => {
|
|
@@ -415,6 +426,7 @@ export default { |
|
@@ -415,6 +426,7 @@ export default { |
|
415
|
if (e === 'auditDetail1') return this.onAuditDetail(this.detail.id || '', 'FORMAL_CONTRACT')
|
426
|
if (e === 'auditDetail1') return this.onAuditDetail(this.detail.id || '', 'FORMAL_CONTRACT')
|
|
416
|
if (e === 'auditDetail2') return this.onAuditDetail(this.detail.parentId || '', 'FORMAL_CONTRACT')
|
427
|
if (e === 'auditDetail2') return this.onAuditDetail(this.detail.parentId || '', 'FORMAL_CONTRACT')
|
|
417
|
if (e === 'auditDetail3') return this.onAuditDetail(this.detail.id || '', 'STANDARD_CONTRACT')
|
428
|
if (e === 'auditDetail3') return this.onAuditDetail(this.detail.id || '', 'STANDARD_CONTRACT')
|
|
|
|
429
|
+ if (e === 'uploadSeal') return this.uploadContract(this.detail.id || '', 'seal')
|
|
418
|
},
|
430
|
},
|
|
419
|
onAudit(id, type) {
|
431
|
onAudit(id, type) {
|
|
420
|
const CACHE_KEY = 'sourceBusinessId'
|
432
|
const CACHE_KEY = 'sourceBusinessId'
|