6ec243d6
wuxw
v1.9 点击提交后,成功提示没有...
|
1
|
<template>
|
9c311762
wuxw
工作办理测试中
|
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
<div class="animated fadeInRight ecommerce padding">
<el-row v-if="contractChangeAuditOrdersInfo.audit === '1'">
<el-col :span="24">
<el-card>
<div slot="header" class="flex justify-between">
<div>{{ $t('contractChangeAuditOrders.title') }}</div>
</div>
<div class="">
<el-table :data="contractChangeAuditOrdersInfo.contractChangeAuditOrders" border style="width: 100%">
<el-table-column prop="contractCode" :label="$t('contractChangeAuditOrders.contractCode')"
align="center" />
<el-table-column prop="contractName" :label="$t('contractChangeAuditOrders.contractName')"
align="center" />
<el-table-column prop="contractTypeName" :label="$t('contractChangeAuditOrders.contractType')"
align="center" />
<el-table-column prop="stateName" :label="$t('contractChangeAuditOrders.contractStatus')"
align="center" />
<el-table-column prop="createTime" :label="$t('contractChangeAuditOrders.createTime')" align="center" />
<el-table-column :label="$t('contractChangeAuditOrders.operation')" align="center">
<template slot-scope="scope">
<el-button-group>
<el-button size="mini" @click="_viewChangeDetail(scope.row)">
{{ $t('contractChangeAuditOrders.view') }}
</el-button>
<el-button v-if="scope.row.hasAudit && !scope.row.hasEnd" size="mini" type="primary"
@click="_openAuditOrderModel(scope.row)">
{{ $t('contractChangeAuditOrders.audit') }}
</el-button>
<el-button v-if="scope.row.hasEnd" size="mini" type="warning" @click="_finishAuditOrder(scope.row)">
{{ $t('contractChangeAuditOrders.finish') }}
</el-button>
</el-button-group>
</template>
</el-table-column>
</el-table>
<el-pagination :current-page.sync="page.current" :page-sizes="[10, 20, 30, 50]" :page-size="page.size"
:total="page.total" layout="total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange"
@current-change="handleCurrentChange" />
</div>
</el-card>
</el-col>
</el-row>
<flow-audit v-else ref="flowAudit" :call-back-listener="'contractChangeAuditOrders'"
:call-back-function="'notifyAudit'" />
</div>
</template>
<script>
import { queryContractChangeTask, needAuditContractPlan } from '@/api/resource/contractChangeAuditOrdersApi'
import FlowAudit from '@/components/contract/flowAudit'
|
19bafb73
wuxw
v1.9 优化采购相关bug
|
52
|
import { getUserId } from '@/api/user/userApi'
|
9c311762
wuxw
工作办理测试中
|
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
|
export default {
name: 'ContractChangeAuditOrdersList',
components: {
FlowAudit
},
data() {
return {
contractChangeAuditOrdersInfo: {
contractChangeAuditOrders: [],
total: 0,
records: 1,
moreCondition: false,
userName: '',
currentUserId: '',
conditions: {
planId: '',
userName: '',
auditLink: ''
},
orderInfo: '',
procure: false,
audit: '1'
},
page: {
current: 1,
size: 10,
total: 0
}
}
},
created() {
|
19bafb73
wuxw
v1.9 优化采购相关bug
|
85
|
this.contractChangeAuditOrdersInfo.currentUserId = getUserId()
|
9c311762
wuxw
工作办理测试中
|
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
this._listAuditOrders(this.page.current, this.page.size)
},
methods: {
async _listAuditOrders(page, rows) {
this.contractChangeAuditOrdersInfo.audit = '1'
this.contractChangeAuditOrdersInfo.conditions.page = page
this.contractChangeAuditOrdersInfo.conditions.row = rows
try {
const { data, total } = await queryContractChangeTask(this.contractChangeAuditOrdersInfo.conditions)
this.contractChangeAuditOrdersInfo.contractChangeAuditOrders = data
this.contractChangeAuditOrdersInfo.total = total
this.page.total = total
} catch (error) {
console.error('请求失败:', error)
}
},
_openAuditOrderModel(auditOrder) {
this.contractChangeAuditOrdersInfo.orderInfo = auditOrder
this.contractChangeAuditOrdersInfo.audit = '2'
auditOrder.startUserId = auditOrder.changePerson
this.$refs.flowAudit.open(auditOrder)
},
async _auditOrderInfo(auditInfo) {
auditInfo.taskId = this.contractChangeAuditOrdersInfo.orderInfo.taskId
auditInfo.planId = this.contractChangeAuditOrdersInfo.orderInfo.planId
auditInfo.contractId = this.contractChangeAuditOrdersInfo.orderInfo.contractId
try {
await needAuditContractPlan(auditInfo)
|
6ec243d6
wuxw
v1.9 点击提交后,成功提示没有...
|
116
|
this.$message.success(this.$t('common.operationSuccess'))
|
9c311762
wuxw
工作办理测试中
|
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
this._listAuditOrders(this.page.current, this.page.size)
} catch (error) {
this.$message.error(this.$t('common.handleFailed') + error.message)
}
},
async _finishAuditOrder(auditOrder) {
const auditInfo = {
taskId: auditOrder.taskId,
planId: auditOrder.planId,
state: '1200',
remark: this.$t('contractChangeAuditOrders.processEnd'),
contractId: auditOrder.contractId
}
try {
await needAuditContractPlan(auditInfo)
|
6ec243d6
wuxw
v1.9 点击提交后,成功提示没有...
|
133
|
this.$message.success(this.$t('common.operationSuccess'))
|
9c311762
wuxw
工作办理测试中
|
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
|
this._listAuditOrders(this.page.current, this.page.size)
} catch (error) {
this.$message.error(this.$t('common.handleFailed') + error.message)
}
},
_viewChangeDetail(plan) {
this.$router.push({
path: '/views/contract/contractChangeDetails',
query: { planId: plan.planId }
})
},
handleSizeChange(val) {
this.page.size = val
this._listAuditOrders(this.page.current, val)
},
handleCurrentChange(val) {
this.page.current = val
this._listAuditOrders(val, this.page.size)
}
}
}
</script>
<style scoped>
.ibox-content {
padding: 15px 20px 20px 20px;
}
.el-pagination {
margin-top: 15px;
}
</style>
|