auditsDialog.vue
5.31 KB
1
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
52
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
85
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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
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
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
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
<!-- 运营审核 -->
<template>
<el-dialog
id="baseDialog"
top="15vh"
:close-on-click-modal="false"
:close-on-press-escape="true"
:title="dialogConfig.title"
:width="dialogConfig.width"
:visible.sync="visible"
:show-close="true"
class="noborder"
>
<div class="reject-dialog">
<div class="dialog-title-box">
<div class="dialog-name">{{ info.staffName }}</div>
<div class="dialog-title1">
<div class="flex">
<span class="title-text">手机号:</span>
<span class="title-text1 flex-1">{{ info.staffPhone }}</span>
</div>
<div class="flex">
<span class="title-text">所属门店:</span>
<span class="title-text1">{{ info.merchantName }}</span>
</div>
</div>
<div class="dialog-title1">
<div class="flex">
<span class="title-text">客户姓名:</span>
<span class="title-text1">{{ info.customerName }}</span>
</div>
<div class="flex-1 flex">
<span class="title-text">缺失原因:</span>
<span class="title-text1 flex-1">{{ info.reason }}</span>
</div>
</div>
</div>
<glsx-combi-form
class="edit-form-container"
ref="formRef"
label-width="150px"
default-width="350px"
:form-ref="rejectRef"
:form-obj="infoForm"
:form-data="editFormData"
:form-rules="formRules"
></glsx-combi-form>
<!-- <span :style="{ 'margin-left': '150px' }"
>审核通过后,转账业务单据自动流转至财务确认。</span
> -->
</div>
<div slot="footer">
<el-button
v-preventReClick
@click="visible = false"
type="info"
size="small"
>
取消
</el-button>
<el-button v-preventReClick @click="confirmBtn(2)" size="small">
驳回
</el-button>
<el-button
size="small"
type="primary"
@click="confirmBtn(1)"
:loading="$store.state.d2admin.loading.value || btnLoding"
>
通过
</el-button>
</div>
</el-dialog>
</template>
<script>
import { reportApproval } from "@/api/earlyWarningManager"
export default {
name: "ExamineDialog",
data() {
return {
userInfo: this.$store.state.d2admin.user.info,
// txtObj: {
// procurementReview: '说明:订单审核后会自动流转至商务进行复审',
// procurementBusiness: '说明:订单审核后会自动流转至供应商进行确认并发货'
// },
infoForm: {
remark: ""
},
rejectRef: "rejectRef",
dialogConfig: {
title: "审核",
width: "600px"
},
examineRef: "examineRef",
formRules: {},
editFormData: [
{
label: "审核意见",
name: "remark",
type: "input",
maxlength: 50,
inputType: "textarea",
showLimit: true,
rows: 4
}
],
baseData: {
// shippingEntityList: []
}
}
},
props: {
// fromPage: {
// type: String,
// default: 'procurementReview'
// },
auditsVisible: {
type: Boolean,
default: false
},
// paramsObj: {
// type: Object,
// default: {}
// }
info: {
type: Object,
default: () => {}
}
},
computed: {
visible: {
get() {
return this.auditsVisible
},
set(newVal) {
this.$emit("dialogClose", { flag: newVal, attrName: "auditsVisible" })
}
}
},
mounted() {},
methods: {
confirmBtn(type) {
this.$refs.formRef.$refs[this.rejectRef].validate((valid) => {
if (valid) {
var params = {}
if (type === 2 && !this.infoForm.remark) {
this.$message.warning("请填写审核意见")
return
}
params.auditOpinion = this.infoForm.remark
params.id = this.info.id
params.auditStatus = type
console.log(params)
reportApproval(params).then((res) => {
this.notice.okTips("操作成功")
this.visible = true
})
}
})
}
}
}
</script>
<style lang="scss" scoped>
.reject-dialog {
.dialog-title-box {
width: 100%;
background: #fafafa;
padding: 10px 20px;
color: #333333;
font-size: 16px;
font-weight: 400;
box-sizing: border-box;
margin-bottom: 20px;
.dialog-name {
font-weight: 600;
margin-bottom: 12px;
}
.dialog-title1 {
display: flex;
color: #333333;
font-size: 14px;
font-weight: 400;
margin-bottom: 8px;
}
}
.title-text {
width: 80px;
}
.title-text1 {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
width: 100px;
display: block;
}
.flex {
display: flex;
}
.flex-1 {
flex: 1;
}
.reject-input {
::v-deep .el-textarea__inner {
height: 70px;
}
}
.el-textarea .el-input__count {
right: 90px;
bottom: -10px;
font-size: 12px;
color: #999999;
}
.tips {
color: #999999;
}
}
::v-deep .el-dialog__footer {
border-top: 1px solid #e5e5e5;
.el-button {
width: 80px;
}
}
::v-deep .el-dialog__header {
border-bottom: 1px solid #e5e5e5;
}
</style>