Browse Source

通讯录-网格列表/新增:增加排序字段

wxz_unit_doorplate
wxz 1 year ago
parent
commit
c7fbf3fcd4
  1. 69
      src/views/modules/base/organization/organization.vue

69
src/views/modules/base/organization/organization.vue

@ -100,6 +100,8 @@
label="联系人"></el-table-column>
<el-table-column prop="mobile"
label="联系人电话"></el-table-column>
<el-table-column prop="sort"
label="排序"></el-table-column>
<el-table-column label="操作"
align="center"
class-name="small-padding fixed-width">
@ -323,6 +325,8 @@
width="850"
:before-close="handleClose" destroy-on-close>
<el-form label-width="120px"
ref="addGridForm"
:model="GridForm"
:rules="rules">
<el-form-item label="网格名称"
prop="gridName">
@ -349,6 +353,10 @@
</el-select>
</el-form-item>
<el-form-item label="排序" prop="sort">
<el-input-number v-model="GridForm.sort" :min="1" :max="50" label="排序"></el-input-number>
</el-form-item>
<el-form-item label="联系人"
prop="GridContacts">
<el-input v-model.trim="GridForm.contacts"
@ -1198,6 +1206,7 @@ export default {
longitude: "", //
latitude: "", //
centerAddress: "",
sort: 1,
},
//
agencyForm: {
@ -1630,33 +1639,39 @@ export default {
},
//
async submitGrid () {
const url = "/gov/org/grid/addgrid";
let params = {
agencyId: this.GridForm.agencyId,
gridName: this.GridForm.gridName,
contacts: this.GridForm.contacts,
mobile: this.GridForm.mobile,
code: this.GridForm.code,
manageDistrict: this.GridForm.manageDistrict,
gridType: this.GridForm.gridType,
latitude: this.lat,
longitude: this.lng,
};
const { data, code, msg } = await requestPost(url, params);
if (code === 0) {
this.$message.success("添加成功");
this.dialogVisibleGrid = false;
this.GridForm = [];
this.getAgencyList();
this.getDepartmentList();
this.getGridList();
this.getAgencyStaffListData();
} else {
this.$message.error(msg);
}
debugger
this.$refs.addGridForm.validate(async (result) => {
if (result === true) {
const url = "/gov/org/grid/addgrid";
let params = {
agencyId: this.GridForm.agencyId,
gridName: this.GridForm.gridName,
contacts: this.GridForm.contacts,
mobile: this.GridForm.mobile,
code: this.GridForm.code,
sort: this.GridForm.sort,
manageDistrict: this.GridForm.manageDistrict,
gridType: this.GridForm.gridType,
latitude: this.lat,
longitude: this.lng,
};
const { data, code, msg } = await requestPost(url, params);
if (code === 0) {
this.$message.success("添加成功");
this.dialogVisibleGrid = false;
this.GridForm = [];
this.getAgencyList();
this.getDepartmentList();
this.getGridList();
this.getAgencyStaffListData();
} else {
this.$message.error(msg);
}
}
})
},
async submitPeo () {

Loading…
Cancel
Save