branch.vue
4.17 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
<template>
<div>
<a-card>
<h3 style="font-weight: bold;">基本信息</h3>
<a-form-model ref="ruleForm" :model="form" :rules="rules">
<a-row>
<a-col :span="8">
<a-form-model-item ref="staffId" label="部门编号">
<a-input :disabled="true" style="width: 250px" v-model="form.staffId" />
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item ref="staffId" label="创建时间">
<a-date-picker
v-model="form.startValue"
show-time
format="YYYY-MM-DD HH:mm:ss"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="创建时间"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="状态" prop="staffId">
<a-select v-model="form.staffId" style="width: 250px;" placeholder="请选择">
<a-select-option v-for="(item,i) in provinceData" :key="item.id">
{{ item.name }}
</a-select-option>
</a-select>
</a-form-model-item>
</a-col>
</a-row>
<a-row>
<a-col :span="8">
<a-form-model-item ref="staffId" label="部门名称" prop="staffId">
<a-input style="width: 250px;" v-model="form.staffId" />
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item ref="staffId" label="部门代码" prop="staffId">
<a-input style="width: 250px;" v-model="form.staffId" />
</a-form-model-item>
</a-col>
</a-row>
</a-form-model>
</a-card>
<div style="float: right; margin:20px;">
<a-button @click="$router.back(-1)">
返回
</a-button>
<a-button type="primary" style="margin-left: 10px;" @click="onSubmit">
保存
</a-button>
</div>
</div>
</template>
<script>
import '@/assets/less/TableExpand.less'
// import { JeecgListMixin } from '@/mixins/JeecgListMixin'
export default {
name: "",
// mixins: [JeecgListMixin],
components: {
},
created() {
},
data() {
return {
form: {
staffId: '123',
startValue:"",
},
provinceData: [
{ id: 0, name: "启用" },
{ id: 1, name: "禁用" }
],
rules: {
staffId: [
{ required: true, message: '请输入姓名', trigger: 'blur' },
],
},
url: {
list: "/veri/veriDetail/list",
delete: "/veri/veriDetail/delete",
deleteBatch: "/veri/veriDetail/deleteBatch",
exportXlsUrl: "veri/veriDetail/exportXls",
importExcelUrl: "veri/veriDetail/importExcel",
},
}
},
computed: {
},
methods: {
onSubmit() {
this.$refs.ruleForm.validate(valid => {
if (valid) {
console.log(this.form)
} else {
console.log('error submit!!');
return false;
}
});
}
}
}
</script>
<style scoped>
@import '~@assets/less/common.less';
</style>