3f535f30
杨鑫
'初始'
|
1
2
|
<template>
<div style="background-color:#f7f7f7;padding:10px 10px;">
|
93c8bac5
李宇
1
|
3
|
<div class="zhuti" v-if="onaction == '1'">
|
3f535f30
杨鑫
'初始'
|
4
5
6
7
8
9
10
11
|
<div style="height:58px;line-height:58px;">
<div style="color:#0006"> <span>商铺租赁服务</span> <span style="padding:0 5px;">></span> <span
style="color:#000000e6">合同管理</span></div>
</div>
<!-- 线上 -->
<div>
<!-- 搜索 -->
<div class="formSearch">
|
93c8bac5
李宇
1
|
12
|
<el-form :inline="true" :model="pagequery">
|
4373acf5
wesley88
1
|
13
|
<el-form-item label="合同名称">
|
93c8bac5
李宇
1
|
14
|
<el-input v-model="pagequery.contractName" placeholder="请输入" style="width:168px;" />
|
3f535f30
杨鑫
'初始'
|
15
|
</el-form-item>
|
3f535f30
杨鑫
'初始'
|
16
|
</el-form>
|
8550d958
杨鑫
'最新'
|
17
|
|
3f535f30
杨鑫
'初始'
|
18
19
20
21
22
23
24
25
26
|
<div>
<el-button @click="onSubmit" style="background-color: #3F9B6A;color: #fff">查询
</el-button>
<el-button @click="resetting" class="buttonHover"
style="color: #606266;border: 1px solid #dddfe5;background-color: #fff;">重置
</el-button>
</div>
</div>
<div style="margin-bottom: 20px;">
|
93c8bac5
李宇
1
|
27
|
<el-button @click="removeonaction('2')" style="background-color: #3F9B6A;color: #fff;padding:8px 15px;"
|
3f535f30
杨鑫
'初始'
|
28
29
30
31
32
|
icon="el-icon-circle-plus-outline">新增</el-button>
<!-- <el-button @click="" style="background-color: #3F9B6A;color: #fff">批量导入</el-button> -->
</div>
<!-- 表格 -->
|
93c8bac5
李宇
1
|
33
|
<el-table :data="tableData"
|
3f535f30
杨鑫
'初始'
|
34
|
:header-cell-style="{fontSize: '14px',color:'#0009',fontWeight: 'normal',backgroundColor:'#F2F3F5'}">
|
900ab311
李宇
1
|
35
|
<el-table-column label="合同名称">
|
3f535f30
杨鑫
'初始'
|
36
|
<template slot-scope="scope">
|
fb82c607
李宇
1
|
37
|
{{scope.row.contractName}}
|
3f535f30
杨鑫
'初始'
|
38
39
40
|
</template>
</el-table-column>
|
900ab311
李宇
1
|
41
|
<el-table-column label="合同金额">
|
93c8bac5
李宇
1
|
42
|
<template slot-scope="scope">
|
fb82c607
李宇
1
|
43
|
{{scope.row.contractAmount}}
|
3f535f30
杨鑫
'初始'
|
44
|
|
93c8bac5
李宇
1
|
45
|
</template>
|
3f535f30
杨鑫
'初始'
|
46
|
</el-table-column>
|
900ab311
李宇
1
|
47
|
<el-table-column label="签订日期">
|
93c8bac5
李宇
1
|
48
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
49
|
{{scope.row.contractSigningDate}}
|
3f535f30
杨鑫
'初始'
|
50
|
|
93c8bac5
李宇
1
|
51
|
</template>
|
3f535f30
杨鑫
'初始'
|
52
|
</el-table-column>
|
900ab311
李宇
1
|
53
|
<el-table-column label="终止日期">
|
3f535f30
杨鑫
'初始'
|
54
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
55
|
{{scope.row.contractTerminationDate}}
|
3f535f30
杨鑫
'初始'
|
56
57
58
|
</template>
</el-table-column>
|
900ab311
李宇
1
|
59
|
<el-table-column label="姓名">
|
93c8bac5
李宇
1
|
60
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
61
|
{{scope.row.tenantName}}
|
3f535f30
杨鑫
'初始'
|
62
|
|
93c8bac5
李宇
1
|
63
|
</template>
|
3f535f30
杨鑫
'初始'
|
64
|
</el-table-column>
|
900ab311
李宇
1
|
65
|
<el-table-column label="联系电话">
|
3f535f30
杨鑫
'初始'
|
66
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
67
|
{{scope.row.tenantTelephone}}
|
3f535f30
杨鑫
'初始'
|
68
69
70
|
</template>
</el-table-column>
|
900ab311
李宇
1
|
71
|
<el-table-column label="合同类型">
|
3f535f30
杨鑫
'初始'
|
72
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
73
|
{{scope.row.contractType}}
|
3f535f30
杨鑫
'初始'
|
74
75
76
|
</template>
</el-table-column>
|
900ab311
李宇
1
|
77
|
<el-table-column prop="dataStatus" label="合同状态">
|
3f535f30
杨鑫
'初始'
|
78
|
<template slot-scope="scope">
|
900ab311
李宇
1
|
79
80
81
82
|
<span v-if='scope.row.dataStatus == 1'>使用中</span>
<span v-else-if='scope.row.dataStatus == 2'>往期合同</span>
<span v-else-if='scope.row.dataStatus == 3'>已终止</span>
<span v-else>-</span>
|
3f535f30
杨鑫
'初始'
|
83
84
85
|
</template>
</el-table-column>
|
900ab311
李宇
1
|
86
87
|
<el-table-column label="操作" min-width="150" fixed="right">
<template slot-scope="scope">
|
3f535f30
杨鑫
'初始'
|
88
|
<div @click="details(scope.row)" class="tableBtn greens">查看</div>
|
4373acf5
wesley88
1
|
89
90
91
|
<div v-if='scope.row.dataStatus == 1' @click="removeinfo(scope.row,'合同变更')" class="tableBtn greens">合同变更</div>
<div v-if='scope.row.dataStatus == 1' @click="removeinfo(scope.row,'合同续约')" class="tableBtn greens">合同续约</div>
<div v-if='scope.row.dataStatus == 1' @click="removeinfozz(scope.row,'合同终止')" class="tableBtn greens">合同终止</div>
|
900ab311
李宇
1
|
92
93
|
<!-- <div @click="handleDelete(scope.row)" class="tableBtn greens">删除</div> -->
</template>
|
3f535f30
杨鑫
'初始'
|
94
95
|
</el-table-column>
</el-table>
|
93c8bac5
李宇
1
|
96
97
|
<div style="display: flex;justify-content: space-between;" class="bom">
<div style="font-size: 14px;">共 <span style="color: #3F9B6A;">{{total}}</span> 项数据</div>
|
4373acf5
wesley88
1
|
98
99
|
<el-pagination :current-page="pagequery.pageNumber+1" :page-sizes="[10, 20, 50, 100]" :page-size="10"
background small layout="prev, pager, next" :total="total" @size-change="handleSizeChange"
|
93c8bac5
李宇
1
|
100
101
|
@current-change="handleCurrentChange">
</el-pagination>
|
3f535f30
杨鑫
'初始'
|
102
|
</div>
|
3f535f30
杨鑫
'初始'
|
103
|
|
3f535f30
杨鑫
'初始'
|
104
105
106
|
</div>
</div>
|
3f535f30
杨鑫
'初始'
|
107
|
|
3f535f30
杨鑫
'初始'
|
108
|
|
3f535f30
杨鑫
'初始'
|
109
|
|
3f535f30
杨鑫
'初始'
|
110
|
|
3f535f30
杨鑫
'初始'
|
111
|
|
93c8bac5
李宇
1
|
112
113
114
115
116
117
|
<div class="zhuti" v-if="onaction == '2'">
<div style="height:58px;line-height:58px;">
<div style="color:#0006"> <span>合同管理</span> <span style="padding:0 5px;">></span> <span
style="color:#000000e6">新增</span></div>
</div>
|
3f535f30
杨鑫
'初始'
|
118
|
|
8550d958
杨鑫
'最新'
|
119
|
<div style="padding: 20px 20px 20px 0;">
|
93c8bac5
李宇
1
|
120
|
<add :info="formInline" @removeonaction="removeonaction"></add>
|
8550d958
杨鑫
'最新'
|
121
122
|
</div>
</div>
|
900ab311
李宇
1
|
123
124
125
126
127
128
|
<div class="zhuti" v-if="onaction == '3'">
<div style="height:58px;line-height:58px;">
<div style="color:#0006"> <span>合同管理</span> <span style="padding:0 5px;">></span> <span
style="color:#000000e6">查看</span></div>
</div>
<div>
|
4373acf5
wesley88
1
|
129
|
<busCha :info="detailsinfo" @removeonaction="removeonaction"></busCha>
|
900ab311
李宇
1
|
130
|
</div>
|
4373acf5
wesley88
1
|
131
132
133
134
135
136
137
138
139
140
141
142
143
|
<!-- <div>
<el-button class="buttonHover"
style="color: #606266;border: 1px solid #dddfe5;background-color: #fff;margin-top: 20px;"
@click="removeonaction('1')">返回</el-button>
</div> -->
</div>
<div class="zhuti" v-if="onaction == '4'">
<div style="height:58px;line-height:58px;">
<div style="color:#0006"> <span>合同管理</span> <span style="padding:0 5px;">></span> <span
style="color:#000000e6">{{contractChangeReason}}</span></div>
</div>
<div style="padding: 20px 20px 20px 0;">
|
9a707dae
wesley88
1
|
144
145
146
|
<!-- <addremove :info="detailsinfo" :contractChangeReason="contractChangeReason" @removeonaction="removeonaction">
</addremove> -->
<add :info="detailsinfo" :contractChangeReason="contractChangeReason" @removeonaction="removeonaction"></add>
|
900ab311
李宇
1
|
147
148
|
</div>
</div>
|
3f535f30
杨鑫
'初始'
|
149
150
151
152
153
154
155
|
</div>
</template>
<script>
import {
|
93c8bac5
李宇
1
|
156
|
contractGetAllnew,
|
4373acf5
wesley88
1
|
157
158
159
160
161
162
163
|
} from '@/api/manage.js'
import add from '@/components/add/addht.vue'
import addremove from '@/components/add/addremoveht.vue'
import busCha from '@/components/buscha/busCha'
import {
cereContractInformation
} from '@/api/commodityLease.js'
|
ad5052c5
wesley88
1
|
164
165
166
|
import {
modifyResourceStatus
} from '@/api/newly.js'
|
3f535f30
杨鑫
'初始'
|
167
|
export default {
|
3f535f30
杨鑫
'初始'
|
168
169
|
data() {
return {
|
4373acf5
wesley88
1
|
170
171
|
contractChangeReason: '',
detailsinfo: {},
|
93c8bac5
李宇
1
|
172
|
pagequery: {
|
4373acf5
wesley88
1
|
173
|
dataStatus:'1',
|
900ab311
李宇
1
|
174
|
pageNumber: 0,
|
3f535f30
杨鑫
'初始'
|
175
|
pageSize: 10,
|
4373acf5
wesley88
1
|
176
|
contractName: ''
|
3f535f30
杨鑫
'初始'
|
177
|
},
|
93c8bac5
李宇
1
|
178
179
180
|
tableData: [],
total: 0,
onaction: '1',
|
9a707dae
wesley88
1
|
181
|
formInline: {},
|
3f535f30
杨鑫
'初始'
|
182
183
|
}
},
|
93c8bac5
李宇
1
|
184
|
components: {
|
4373acf5
wesley88
1
|
185
186
187
|
add,
busCha,
addremove
|
93c8bac5
李宇
1
|
188
|
},
|
3f535f30
杨鑫
'初始'
|
189
190
|
created() {
this.getAll()
|
3f535f30
杨鑫
'初始'
|
191
192
|
},
methods: {
|
4373acf5
wesley88
1
|
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
|
gettime() {
// 获取当前时间
let currentTime = new Date();
// 获取年份
let year = currentTime.getFullYear();
// 获取月份(注意月份是从0开始计数的,所以需要加1)
let month = currentTime.getMonth() + 1;
// 获取日期
let day = currentTime.getDate();
// 获取小时
let hours = currentTime.getHours();
// 获取分钟
let minutes = currentTime.getMinutes();
// 获取秒数
let seconds = currentTime.getSeconds();
// 获取毫秒数
let milliseconds = currentTime.getMilliseconds();
// 格式化时间为 YYYY-MM-DD
let formattedDate = `${year}-${month.toString().padStart(2, '0')}-${day.toString().padStart(2, '0')}`;
// 格式化时间为 HH:MM:SS
let formattedTime =
`${hours.toString().padStart(2, '0')}:${minutes.toString().padStart(2, '0')}:${seconds.toString().padStart(2, '0')}`;
// 格式化时间为 YYYY-MM-DD HH:MM:SS
let formattedDateTime = `${formattedDate} ${formattedTime}`;
return formattedDateTime
},
removeinfozz(row, e) {
let that = this
this.$confirm('确定要终止合同吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
cereContractInformation({
...row,
contractChangeReason: e,
dataStatus: '3',
originalContractCode: row.contractNumber,
updateDate: that.gettime(),
createDate: that.gettime(),
contractChangeTime: that.gettime(),
updateUser:localStorage.getItem('roleName')
}).then(res => {
console.error(res)
if (res.code == 200) {
this.$message({
message: '终止成功',
type: 'success'
})
|
ad5052c5
wesley88
1
|
253
254
255
256
257
258
259
|
let c1 = row.shopNumber
modifyResourceStatus({
resourcesId: c1,
status:"0"
}).then(res => {
console.error(res)
})
|
6abe0316
wesley88
1
|
260
261
|
// this.$emit('removeonaction', '1')
this.getAll()
|
4373acf5
wesley88
1
|
262
263
264
265
266
267
268
269
270
271
|
} else {
this.$message({
message: res.msg,
type: 'error'
})
}
})
})
},
|
900ab311
李宇
1
|
272
273
274
275
|
details(row) {
this.detailsinfo = row
this.onaction = '3'
},
|
4373acf5
wesley88
1
|
276
277
|
removeinfo(row, e) {
this.contractChangeReason = e
|
9a707dae
wesley88
1
|
278
|
// console.error(this.contractChangeReason)
|
4373acf5
wesley88
1
|
279
280
|
this.detailsinfo = row
this.onaction = '4'
|
900ab311
李宇
1
|
281
|
},
|
93c8bac5
李宇
1
|
282
283
|
async getAll() {
const res = await contractGetAllnew(this.pagequery)
|
3f535f30
杨鑫
'初始'
|
284
|
this.tableData = res.data.content
|
900ab311
李宇
1
|
285
|
this.total = res.data.totalElements
|
3f535f30
杨鑫
'初始'
|
286
|
},
|
93c8bac5
李宇
1
|
287
288
289
|
removeonaction(e) {
console.error(e)
this.onaction = e
|
4373acf5
wesley88
1
|
290
291
|
this.pagequery.pageNumber = 0
this.getAll()
|
3f535f30
杨鑫
'初始'
|
292
293
|
},
handleCurrentChange(val) {
|
4373acf5
wesley88
1
|
294
|
this.pagequery.pageNumber = val - 1
|
900ab311
李宇
1
|
295
|
this.getAll()
|
3f535f30
杨鑫
'初始'
|
296
|
},
|
93c8bac5
李宇
1
|
297
298
|
handleSizeChange(val) {
this.pagequery.pageSize = val
|
3f535f30
杨鑫
'初始'
|
299
|
},
|
4373acf5
wesley88
1
|
300
|
// 查询按钮
|
3f535f30
杨鑫
'初始'
|
301
|
async onSubmit() {
|
900ab311
李宇
1
|
302
|
this.pagequery.pageNumber = 0
|
93c8bac5
李宇
1
|
303
|
this.getAll()
|
3f535f30
杨鑫
'初始'
|
304
305
306
|
},
//重置按钮
resetting() {
|
93c8bac5
李宇
1
|
307
|
this.pagequery = {
|
900ab311
李宇
1
|
308
|
pageNumber: 0,
|
93c8bac5
李宇
1
|
309
|
pageSize: 10,
|
4373acf5
wesley88
1
|
310
311
|
dataStatus:'1',
contractName: ''
|
93c8bac5
李宇
1
|
312
|
},
|
3f535f30
杨鑫
'初始'
|
313
314
|
this.getAll()
},
|
3f535f30
杨鑫
'初始'
|
315
|
}
|
93c8bac5
李宇
1
|
316
|
|
3f535f30
杨鑫
'初始'
|
317
318
319
320
|
}
</script>
<style scoped>
|
93c8bac5
李宇
1
|
321
|
.el-table {
|
900ab311
李宇
1
|
322
|
/* height: calc(100vh - 330px); */
|
93c8bac5
李宇
1
|
323
|
}
|
900ab311
李宇
1
|
324
|
|
3f535f30
杨鑫
'初始'
|
325
326
327
328
329
330
331
332
333
334
335
336
337
|
.zhuti {
padding: 0 20px 20px 20px;
min-height: calc(100vh - 50px - 20px);
background-color: #Fff;
}
.chengeXia {
border-bottom: 6px solid #3F9B6A;
padding-bottom: 4px;
color: #3F9B6A;
}
|
93c8bac5
李宇
1
|
338
|
/* /deep/ .el-form-item__content {
|
3f535f30
杨鑫
'初始'
|
339
|
line-height: 0;
|
93c8bac5
李宇
1
|
340
|
} */
|
3f535f30
杨鑫
'初始'
|
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
|
.tableBtn {
display: inline-block;
margin-right: 10px;
color: #ACACAC;
}
.formSearch {
display: flex;
width: 100%;
font-size: 14px;
justify-content: space-between;
}
.greens {
color: #3F9B6A;
}
/deep/ .el-table__row {
font-size: 14px;
color: #000000e6;
height: 42px;
}
.fenye {
margin-top: 20px;
display: flex;
|
8550d958
杨鑫
'最新'
|
368
|
justify-content: space-between;
|
3f535f30
杨鑫
'初始'
|
369
370
371
372
373
374
|
}
/deep/ .el-pagination.is-background .el-pager li:not(.disabled).active {
background-color: #3F9B6A;
}
|
3f535f30
杨鑫
'初始'
|
375
|
|
3f535f30
杨鑫
'初始'
|
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
|
.el-col {
border-radius: 4px;
}
.bg-purple-dark {
background: #99a9bf;
}
.bg-purple {
background: #d3dce6;
}
.bg-purple-light {
background: #e5e9f2;
}
.grid-content {
border-radius: 4px;
min-height: 36px;
}
.row-bg {
padding: 10px 0;
background-color: #f9fafc;
}
/deep/ .bg-purple[data-v-0e3fe4ec] {
background: #fff;
height: 50px;
}
/deep/ .bg-purple[data-v-3bebae82] {
background: #fff;
height: 50px;
}
::v-deep .bg-purple {
background: #fff;
height: 50px;
}
/deep/ .el-form--label-top .el-form-item__label {
padding: 0;
}
::v-deep .el-dialog__wrapper {
.el-dialog__header {
background-color: #fff;
}
}
|
8550d958
杨鑫
'最新'
|
428
|
|
3f535f30
杨鑫
'初始'
|
429
430
431
432
433
434
435
436
|
.dialog-footer {
display: flex;
justify-content: flex-end;
border-top: solid rgba(209, 209, 209, 0.2) 2px;
padding-top: 20px;
}
|
3f535f30
杨鑫
'初始'
|
437
|
|
3f535f30
杨鑫
'初始'
|
438
|
|
3f535f30
杨鑫
'初始'
|
439
440
441
442
443
|
.el-select-dropdown__item.selected {
color: #3F9B6A;
}
|
93c8bac5
李宇
1
|
444
445
446
447
|
::v-deep .el-dialog__title {
color: #000;
}
|
3f535f30
杨鑫
'初始'
|
448
449
450
451
452
453
|
::v-deep .el-dialog__wrapper {
.dialog_css {
margin-right: 12px;
margin-top: 61px !important;
|
3f535f30
杨鑫
'初始'
|
454
455
456
457
458
459
460
461
462
|
}
.diaslog_zhong {
margin-left: 222px;
margin-top: 61px !important;
}
}
|
3f535f30
杨鑫
'初始'
|
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
|
/deep/ .el-table_1_column_8 .hetong {
color: #7DBB9A;
text-decoration: underline;
}
/deep/ .first-column-bg {
background-color: #FAFAFA !important;
}
.el-table tr {
height: 56px;
}
::v-deep .table3 {
.el-table__empty-block {
display: none;
}
}
::v-deep .textarea {
width: 85%;
.el-textarea__inner {
width: 100%;
}
}
::v-deep .el-button--mini {
padding: 7px 10px;
}
::v-deep .pass_input {
width: 100%;
.el-input__inner {
border: none;
padding: 0;
}
}
::v-deep .pass_select {
width: 100%;
.el-input__inner {
border: none;
padding: 0;
}
.el-icon-arrow-up:before {
content: ''
}
}
/deep/ .el-table--enable-row-hover .el-table__body tr:hover>td.el-table__cell {
background-color: #fff;
}
</style>
<style lang="scss" scoped>
|
93c8bac5
李宇
1
|
522
523
524
|
::v-deep .el-dialog__body {
padding: 0 0 !important;
}
|
3f535f30
杨鑫
'初始'
|
525
|
|
118fc86d
wesley88
1
|
526
|
|
3f535f30
杨鑫
'初始'
|
527
|
</style>
|