|
@@ -6,8 +6,14 @@
|
|
|
<el-dialog title="详情" width="100%" :modal="false" :visible.sync="formBool" :before-close="handleClose">
|
|
|
<zj-page-container v-if="formBool">
|
|
|
<zj-page-fill class="neibuview" v-if="formBool">
|
|
|
- <zj-form-container v-if="formBool" :formAttributes="{ 'label-position': 'top' }">
|
|
|
- <zj-form-module v-if="formBool" title="" :form-data="formData" :form-items="formItems">
|
|
|
+ <zj-form-container ref="formRef" v-if="formBool" :formAttributes="{ 'label-position': 'top' }">
|
|
|
+ <zj-form-module v-if="formBool" title="费用信息" :form-data="formData" :form-items="formItems">
|
|
|
+ </zj-form-module>
|
|
|
+ <zj-form-module v-if="formBool && formData.payType !== 'WECHAT'" title="审批信息" :form-data="formData"
|
|
|
+ :form-items="spFormItems">
|
|
|
+ <div v-if="openType === 1" style="text-align:right">
|
|
|
+ <el-button size="mini" type="danger" plain @click="WAITfun">确定</el-button>
|
|
|
+ </div>
|
|
|
</zj-form-module>
|
|
|
</zj-form-container>
|
|
|
</zj-page-fill>
|
|
@@ -21,7 +27,8 @@
|
|
|
import TemplatePage from '@/components/template/template-page-1.vue'
|
|
|
import import_mixin from '@/components/template/import_mixin.js'
|
|
|
import operation_mixin from '@/components/template/operation_mixin.js'
|
|
|
-import { enginMaterialList, enginMaterialListExport, enginMaterialDetail } from "@/api/applicationWithoutFee.js"
|
|
|
+import { enginMaterialList, enginMaterialListExport, enginMaterialDetail, enginMaterialExamine } from "@/api/applicationWithoutFee.js"
|
|
|
+import { required } from '@/components/template/rules_verify.js'
|
|
|
import feel from "../mixins/feel.js"
|
|
|
export default {
|
|
|
components: {
|
|
@@ -40,7 +47,11 @@ export default {
|
|
|
tableEvents: {
|
|
|
'selection-change': this.selectionChange
|
|
|
},
|
|
|
- formData: {}
|
|
|
+ formData: {
|
|
|
+ examineStatus: "",
|
|
|
+ examineRemark: "",
|
|
|
+ },
|
|
|
+ openType: 0
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
@@ -62,6 +73,20 @@ export default {
|
|
|
}
|
|
|
]
|
|
|
},
|
|
|
+ spFormItems() {
|
|
|
+ return [{
|
|
|
+ name: 'el-radio',
|
|
|
+ md: 24,
|
|
|
+ options: [{ value: "OK", label: "审批" }, { value: "FAIL", label: "驳回" }],
|
|
|
+ attributes: { disabled: this.openType == 0 },
|
|
|
+ formItemAttributes: { label: '审批状态', prop: 'examineStatus', rules: [...required] },
|
|
|
+ }, {
|
|
|
+ name: 'el-input',
|
|
|
+ md: 24,
|
|
|
+ attributes: { disabled: this.openType == 0, type: "textarea", placeholder: '' },
|
|
|
+ formItemAttributes: { label: '审批备注', prop: 'examineRemark' },
|
|
|
+ }]
|
|
|
+ }
|
|
|
},
|
|
|
methods: {
|
|
|
// 列表请求函数
|
|
@@ -96,24 +121,56 @@ export default {
|
|
|
return this.operationBtn({
|
|
|
detail: {
|
|
|
click: ({ row, index, column }) => {
|
|
|
- console.log(row)
|
|
|
enginMaterialDetail({
|
|
|
id: row.orderId
|
|
|
}).then(res => {
|
|
|
+ this.openType = 0
|
|
|
this.formData = res.data
|
|
|
this.$nextTick(() => {
|
|
|
this.formBool = true
|
|
|
})
|
|
|
})
|
|
|
}
|
|
|
- }
|
|
|
+ },
|
|
|
+ examine: {
|
|
|
+ conditions: ({ row, index, column }) => {
|
|
|
+ return res.data.examineStatus == "WAIT"
|
|
|
+ },
|
|
|
+ click: ({ row, index, column }) => {
|
|
|
+ enginMaterialDetail({
|
|
|
+ id: row.orderId
|
|
|
+ }).then(res => {
|
|
|
+ this.openType = 1
|
|
|
+ this.formData = res.data
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.formBool = true
|
|
|
+ })
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
})
|
|
|
},
|
|
|
|
|
|
handleClose() {
|
|
|
+ this.$refs.formRef.$refs.inlineForm.clearValidate()
|
|
|
+ this.formData = {}
|
|
|
this.formBool = false
|
|
|
},
|
|
|
|
|
|
+ WAITfun() {
|
|
|
+ this.$refs.formRef.validate((valid, invalidFields, errLabels) => {
|
|
|
+ if (valid) {
|
|
|
+ enginMaterialExamine({
|
|
|
+ id: this.formData.orderId,
|
|
|
+ examineStatus: this.formData.examineStatus,
|
|
|
+ examineRemark: this.formData.examineRemark
|
|
|
+ }).then(res => {
|
|
|
+ this.$refs.pageRef.refreshList()
|
|
|
+ this.handleClose()
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
</script>
|