大件运输联网系统前端代码
guoshilong
2022-12-16 1e376296b2d8abbcdd051b1e75d860353c8bb19d
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
<template>
  <el-dialog
    :title="title"
    :modal-append-to-body="false"
    :append-to-body="true"
    :close-on-click-modal="false"
    width="60%"
    :visible.sync="visible"
  >
    <avue-form ref="form" v-model="form" :option="option" @submit="submit">
    </avue-form>
  </el-dialog>
</template>
 
<script>
import {add} from '@/api/reject/reject'
export default {
  name: "reject",
  data() {
    return {
      title:"不予受理",
      form: {},
      visible: false,
      option: {
        emptyBtn: false,
        submitText: "保存",
        gutter: 30,
        column: [
          {
            label: "理由",
            prop: "rejectReason",
            type: "select",
            dicUrl: "/api/blade-system/dict-biz/dictionary?code=reject_reason",
            props:{
              label:"dictValue",
              value:"dictKey"
            },
            hide: true,
            rules: [{
              required: true,
              message: "请选择理由",
              trigger: "blur"
            }]
          },
          {
            label: "备注",
            prop: "remark",
            type: "textarea",
            span: 24
          }
        ]
      }
    }
  },
  methods: {
    init(data) {
      this.form.no = data.no
      this.visible = true
    },
    // 表单提交
    submit(row,done) {
      add(row).then(res=>{
        if (res.data.code ==200){
          this.$refs.form.resetFields()
          this.$emit("refreshLoad")
          this.visible = false
          this.$message.success("处理成功")
          done();
        }else {
          this.$message.error("处理失败")
          done();
        }
      })
    }
  }
}
</script>
 
<style scoped>
 
</style>