Commit 756b30b3 authored by 张伯涛's avatar 张伯涛

修改

parent 93591aba
This diff is collapsed.
...@@ -460,7 +460,14 @@ ...@@ -460,7 +460,14 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="楼层" prop="floor"> <el-form-item label="楼层" prop="floor">
<el-input v-model="form.floor" maxlength="4" show-word-limit placeholder="请输入单元号" /> <el-select style="width: 100%" v-model="form.floor" placeholder="请选择楼层">
<el-option
v-for="item in floorOptions"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -953,8 +960,42 @@ export default { ...@@ -953,8 +960,42 @@ export default {
}, },
// 表单参数 // 表单参数
formLoading: false, formLoading: false,
floorOptions: [
{label: '1', value: '1'},
{label: '2', value: '2'},
{label: '3', value: '3'},
{label: '4', value: '4'},
{label: '5', value: '5'},
{label: '6', value: '6'},
{label: '7', value: '7'},
{label: '8', value: '8'},
{label: '9', value: '9'},
{label: '10', value: '10'},
{label: '11', value: '11'},
{label: '12', value: '12'},
{label: '13', value: '13'},
{label: '14', value: '14'},
{label: '15', value: '15'},
{label: '16', value: '16'},
{label: '17', value: '17'},
{label: '18', value: '18'},
{label: '19', value: '19'},
{label: '20', value: '20'},
{label: '21', value: '21'},
{label: '22', value: '22'},
{label: '23', value: '23'},
{label: '24', value: '24'},
{label: '25', value: '25'},
{label: '26', value: '26'},
{label: '27', value: '27'},
{label: '28', value: '28'},
{label: '29', value: '29'},
{label: '30', value: '30'},
{label: '31', value: '31'},
{label: '32', value: '32'},
],
form: { form: {
floor: null, floor: [],
sbDate: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'), sbDate: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
cyTime: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'), cyTime: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
zyTime: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'), zyTime: moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
...@@ -1205,7 +1246,7 @@ export default { ...@@ -1205,7 +1246,7 @@ export default {
community: null, community: null,
building: null, building: null,
unit: null, unit: null,
floor: null, floor: [],
house: null, house: null,
hasAcid: null, hasAcid: null,
isHome: null, isHome: null,
...@@ -1257,6 +1298,9 @@ export default { ...@@ -1257,6 +1298,9 @@ export default {
this.juSelect(response.data.committee) this.juSelect(response.data.committee)
} }
this.form = response.data; this.form = response.data;
if(this.form.floor.length > 0) {
this.form.floor = this.form.floor.split(',')
}
this.getInfoByCard() this.getInfoByCard()
this.formLoading = false this.formLoading = false
}); });
...@@ -1275,6 +1319,9 @@ export default { ...@@ -1275,6 +1319,9 @@ export default {
this.juSelect(response.data.committee) this.juSelect(response.data.committee)
} }
this.form = response.data; this.form = response.data;
if(this.form.floor.length > 0) {
this.form.floor = this.form.floor.split(',')
}
this.getInfoByCard() this.getInfoByCard()
this.title = "修改阳性人员"; this.title = "修改阳性人员";
this.formLoading = false this.formLoading = false
...@@ -1297,6 +1344,9 @@ export default { ...@@ -1297,6 +1344,9 @@ export default {
submitForm() { submitForm() {
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
if(this.form.floor.length > 0) {
this.form.floor = this.form.floor.toString()
}
if (this.form.id != null) { if (this.form.id != null) {
updateYxry(this.form).then(response => { updateYxry(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment