|
|
@@ -44,6 +44,8 @@
|
|
|
// import CyPersonFile from "../../components/file/cy-person-file";
|
|
|
import {mapGetters} from "vuex";
|
|
|
import {validatePhone} from "../../util/validator";
|
|
|
+ import {getList as getAgencyList} from "@/api/community/agency";
|
|
|
+ import {getList as getResidentialList} from "@/api/community/residential";
|
|
|
// import CyExcelImport from "../../components/excel/cy-excel-import";
|
|
|
|
|
|
export default {
|
|
|
@@ -102,6 +104,12 @@
|
|
|
trigger: "blur"
|
|
|
}]
|
|
|
},
|
|
|
+ {
|
|
|
+ label: "所属社区",
|
|
|
+ prop: "agencyName",
|
|
|
+ editDisplay: false,
|
|
|
+ addDisplay: false,
|
|
|
+ },
|
|
|
{
|
|
|
label: "所属社区",
|
|
|
prop: "agencyId",
|
|
|
@@ -123,7 +131,15 @@
|
|
|
required: true,
|
|
|
message: "请选择所属社区",
|
|
|
trigger: "blur"
|
|
|
- }]
|
|
|
+ }],
|
|
|
+ hide: true,
|
|
|
+ viewDisplay: false,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "所属小区",
|
|
|
+ prop: "residentialName",
|
|
|
+ editDisplay: false,
|
|
|
+ addDisplay: false
|
|
|
},
|
|
|
{
|
|
|
label: "所属小区",
|
|
|
@@ -131,6 +147,7 @@
|
|
|
type: "select",
|
|
|
search: true,
|
|
|
// dataType:'string',
|
|
|
+ cascaderItem: ["parkingLotId"],
|
|
|
dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}",
|
|
|
dicFormatter:(res)=>{
|
|
|
return res.data.records;//返回字典的层级结构
|
|
|
@@ -145,15 +162,18 @@
|
|
|
required: true,
|
|
|
message: "请选择所属小区",
|
|
|
trigger: "blur"
|
|
|
- }]
|
|
|
- },{
|
|
|
+ }],
|
|
|
+ hide: true,
|
|
|
+ viewDisplay: false,
|
|
|
+ },
|
|
|
+ {
|
|
|
label: "所属车场",
|
|
|
- prop: "parkinglotId",
|
|
|
+ prop: "parkingLotId",
|
|
|
type: "select",
|
|
|
search: true,
|
|
|
overHidden: true,
|
|
|
- dicFlag: false,
|
|
|
remote: true,
|
|
|
+ dicUrl: "/api/cyzh-estate/parkinglot/list?size=500&residentialId={{key}}",
|
|
|
props: {
|
|
|
label: 'parkName',
|
|
|
value: 'id'
|
|
|
@@ -161,7 +181,7 @@
|
|
|
dicFormatter: (res) => {
|
|
|
return res.data.records;
|
|
|
},
|
|
|
- dicUrl: "/api/cyzh-estate/parkinglot/list?size=10&residentialId={{key}}",
|
|
|
+
|
|
|
rules: [{
|
|
|
require: true,
|
|
|
message: "请选择所属车场",
|
|
|
@@ -232,7 +252,7 @@
|
|
|
value: "dictKey",
|
|
|
},
|
|
|
rules: [{
|
|
|
- required: true,
|
|
|
+ required: false,
|
|
|
message: "请输入燃油类别",
|
|
|
trigger: "blur"
|
|
|
}]
|
|
|
@@ -305,6 +325,22 @@
|
|
|
return ids.join(",");
|
|
|
}
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ "form.agencyId"() {
|
|
|
+ getAgencyList(1, 10, {id: this.form.agencyId}).then(res => {
|
|
|
+ this.form.agencyName = res.data.data.records[0].name;
|
|
|
+ })
|
|
|
+ },
|
|
|
+ "form.residentialId"() {
|
|
|
+ getResidentialList(1, 10, {id: this.form.residentialId}).then(res => {
|
|
|
+ this.form.residentialName = res.data.data.records[0].name;
|
|
|
+ console.log(JSON.stringify(this.form))
|
|
|
+ })
|
|
|
+ },
|
|
|
+ "form.parkinglotId"() {
|
|
|
+ console.log(JSON.stringify(this.form))
|
|
|
+ }
|
|
|
+ },
|
|
|
mounted() {
|
|
|
let tenantType = localStorage.getItem("tenantType");
|
|
|
const agencyColumn = this.findObject(this.option.column, "agencyId");
|