|
|
@@ -34,102 +34,107 @@
|
|
|
@click="handleDelFace">人脸删除
|
|
|
</el-button>
|
|
|
</template>
|
|
|
- <!-- <template slot="buildingId" slot-scope="scope">-->
|
|
|
- <!-- <span v-if="scope.row.buildingId!==-1">-->
|
|
|
- <!-- {{scope.row.buildingName}}-->
|
|
|
- <!-- </span>-->
|
|
|
- <!-- </template>-->
|
|
|
- <!-- <template slot="floorId" slot-scope="scope">-->
|
|
|
- <!-- <span v-if="scope.row.floorId!==-1">-->
|
|
|
- <!-- {{scope.row.floorName}}-->
|
|
|
- <!-- </span>-->
|
|
|
- <!-- </template>-->
|
|
|
- <!-- <template slot="unitId" slot-scope="scope">-->
|
|
|
- <!-- <span v-if="scope.row.unitId!==-1">-->
|
|
|
- <!-- {{scope.row.unitName}}-->
|
|
|
- <!-- </span>-->
|
|
|
- <!-- </template>-->
|
|
|
- <!-- <template slot="roomId" slot-scope="scope">-->
|
|
|
- <!-- <span v-if="scope.row.roomId!==-1">-->
|
|
|
- <!-- {{scope.row.roomName}}-->
|
|
|
- <!-- </span>-->
|
|
|
- <!-- </template>-->
|
|
|
+ <template slot="residentialIdForm" slot-scope="scope">
|
|
|
+ <select-dialog-residential :name="form.residentialName" :id="form.residentialId" :disabled="residentialDisabled" :callback="selectCallback"></select-dialog-residential>
|
|
|
+ </template>
|
|
|
+ <!-- <template slot="buildingId" slot-scope="scope">
|
|
|
+ <span v-if="scope.row.buildingId!==-1">
|
|
|
+ {{scope.row.buildingName}}
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
+ <template slot="floorId" slot-scope="scope">
|
|
|
+ <span v-if="scope.row.floorId!==-1">
|
|
|
+ {{scope.row.floorName}}
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
+ <template slot="unitId" slot-scope="scope">
|
|
|
+ <span v-if="scope.row.unitId!==-1">
|
|
|
+ {{scope.row.unitName}}
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
+ <template slot="roomId" slot-scope="scope">
|
|
|
+ <span v-if="scope.row.roomId!==-1">
|
|
|
+ {{scope.row.roomName}}
|
|
|
+ </span>
|
|
|
+ </template>
|
|
|
|
|
|
- <!-- <template slot="menu" slot-scope="scope">-->
|
|
|
- <!-- <el-button icon="el-icon-setting" size="mini" type="text">-->
|
|
|
- <!-- <el-dropdown>-->
|
|
|
- <!-- <span class="el-dropdown-link" style="font-size: xx-small; color: #4babfe">设置标签<i class="el-icon-arrow-down el-icon--right"></i></span>-->
|
|
|
- <!-- <el-dropdown-menu slot="dropdown">-->
|
|
|
- <!-- <el-dropdown-item type="text" @click.native="tagsFormOpen('elder', scope.row)">高龄老人</el-dropdown-item>-->
|
|
|
- <!-- <el-dropdown-item type="text" @click.native="tagsFormOpen('keyPerson', scope.row)">重点人员</el-dropdown-item>-->
|
|
|
- <!-- <el-dropdown-item type="text" @click.native="tagsFormOpen('disabler', scope.row)">残障人士</el-dropdown-item>-->
|
|
|
- <!-- <!– <el-dropdown-item type="text" @click.native="tagsFormOpen('household', scope.row)">常住人员</el-dropdown-item>–>-->
|
|
|
- <!-- <!– <el-dropdown-item type="text" @click.native="tagsFormOpen('enterpriseStaff', scope.row)">企业员工</el-dropdown-item>–>-->
|
|
|
- <!-- </el-dropdown-menu>-->
|
|
|
- <!-- </el-dropdown>-->
|
|
|
- <!-- </el-button>-->
|
|
|
- <!-- </template>-->
|
|
|
- <!-- 标签点击事件-->
|
|
|
- <!-- <template slot="tags" slot-scope="scope" style="display: flex">-->
|
|
|
- <!-- <div v-if="scope.row.tags!== null">-->
|
|
|
- <!-- <el-button style="margin: auto" class="el-icon-collection-tag" v-for="item in scope.row.tags.split(',')" @click.native="tagsDetail(item,scope.row)" size="mini" type="text">-->
|
|
|
- <!-- {{item}}-->
|
|
|
- <!-- </el-button>-->
|
|
|
- <!-- </div>-->
|
|
|
- <!-- </template>-->
|
|
|
+ <template slot="menu" slot-scope="scope">
|
|
|
+ <el-button icon="el-icon-setting" size="mini" type="text">
|
|
|
+ <el-dropdown>
|
|
|
+ <span class="el-dropdown-link" style="font-size: xx-small; color: #4babfe">设置标签<i class="el-icon-arrow-down el-icon--right"></i></span>
|
|
|
+ <el-dropdown-menu slot="dropdown">
|
|
|
+ <el-dropdown-item type="text" @click.native="tagsFormOpen('elder', scope.row)">高龄老人</el-dropdown-item>
|
|
|
+ <el-dropdown-item type="text" @click.native="tagsFormOpen('keyPerson', scope.row)">重点人员</el-dropdown-item>
|
|
|
+ <el-dropdown-item type="text" @click.native="tagsFormOpen('disabler', scope.row)">残障人士</el-dropdown-item>
|
|
|
+ <!– <el-dropdown-item type="text" @click.native="tagsFormOpen('household', scope.row)">常住人员</el-dropdown-item>–>
|
|
|
+ <!– <el-dropdown-item type="text" @click.native="tagsFormOpen('enterpriseStaff', scope.row)">企业员工</el-dropdown-item>–>
|
|
|
+ </el-dropdown-menu>
|
|
|
+ </el-dropdown>
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
+ 标签点击事件
|
|
|
+ <template slot="tags" slot-scope="scope" style="display: flex">
|
|
|
+ <div v-if="scope.row.tags!== null">
|
|
|
+ <el-button style="margin: auto" class="el-icon-collection-tag" v-for="item in scope.row.tags.split(',')" @click.native="tagsDetail(item,scope.row)" size="mini" type="text">
|
|
|
+ {{item}}
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
+ </template>-->
|
|
|
</avue-crud>
|
|
|
- <!-- 显示标签详情组件-->
|
|
|
- <!-- <el-dialog title="残障人士【标签详情】" :visible.sync="disablerTagsdetail" :modal-append-to-body="false">-->
|
|
|
- <!-- <DisablerTagsDetail v-if="disablerTagsdetail" :basic-data="basicData"></DisablerTagsDetail>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="高龄老人【标签详情】" :visible.sync="elderTagsdetail" :modal-append-to-body="false">-->
|
|
|
- <!-- <ElderTagsDetail v-if="elderTagsdetail" :basic-data="basicData"></ElderTagsDetail>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="重点人员【标签详情】" :visible.sync="keyPersonTagsdetail" :modal-append-to-body="false">-->
|
|
|
- <!-- <KeypeopleTagsDetail v-if="keyPersonTagsdetail" :basic-data="basicData"></KeypeopleTagsDetail>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="常住人员【标签详情】" :visible.sync="householdTagsdetail" :modal-append-to-body="false">-->
|
|
|
- <!-- <HouseholdTagsDetail v-if="householdTagsdetail" :basic-data="basicData"></HouseholdTagsDetail>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="企业员工【标签详情】" :visible.sync="enterpriseStaffTagsdetail" :modal-append-to-body="false">-->
|
|
|
- <!-- <EnterpriseStaffTagsDetail v-if="enterpriseStaffTagsdetail" :basic-data="basicData"></EnterpriseStaffTagsDetail>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- 标签添加信息组件-->
|
|
|
- <!-- <el-dialog title="高龄老人【添加标签信息】" :visible.sync="elderTags" :modal-append-to-body="false">-->
|
|
|
- <!-- <ElderTagsForm v-if="elderTags" :basic-data="basicData" :close-fn="() => {elderTags = false}"></ElderTagsForm>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="残障人士【添加标签信息】" :visible.sync="disablerTags" :modal-append-to-body="false">-->
|
|
|
- <!-- <DisablerTagsForm v-if="disablerTags" :basic-data="basicData" :close-fn="() => {disablerTags = false}"></DisablerTagsForm>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="重点人员【添加标签信息】" :visible.sync="keyPersonTags" :modal-append-to-body="false">-->
|
|
|
- <!-- <KeyPersonTagsForm v-if="keyPersonTags" :basic-data="basicData" :close-fn="() => {keyPersonTags = false}"></KeyPersonTagsForm>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="常住人员【添加标签信息】" :visible.sync="householdTags" :modal-append-to-body="false">-->
|
|
|
- <!-- <HouseholdTagsForm v-if="householdTags" :basic-data="basicData" :close-fn="() => {householdTags = false}"></HouseholdTagsForm>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
- <!-- <el-dialog title="企业人员【添加标签信息】" :visible.sync="enterpriseStaffTags" :modal-append-to-body="false">-->
|
|
|
- <!-- <EnterpriseStaffTagsForm v-if="enterpriseStaffTags" :basic-data="basicData" :close-fn="() => {enterpriseStaffTags = false}"></EnterpriseStaffTagsForm>-->
|
|
|
- <!-- </el-dialog>-->
|
|
|
+ <!-- 显示标签详情组件
|
|
|
+ <el-dialog title="残障人士【标签详情】" :visible.sync="disablerTagsdetail" :modal-append-to-body="false">
|
|
|
+ <DisablerTagsDetail v-if="disablerTagsdetail" :basic-data="basicData"></DisablerTagsDetail>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="高龄老人【标签详情】" :visible.sync="elderTagsdetail" :modal-append-to-body="false">
|
|
|
+ <ElderTagsDetail v-if="elderTagsdetail" :basic-data="basicData"></ElderTagsDetail>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="重点人员【标签详情】" :visible.sync="keyPersonTagsdetail" :modal-append-to-body="false">
|
|
|
+ <KeypeopleTagsDetail v-if="keyPersonTagsdetail" :basic-data="basicData"></KeypeopleTagsDetail>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="常住人员【标签详情】" :visible.sync="householdTagsdetail" :modal-append-to-body="false">
|
|
|
+ <HouseholdTagsDetail v-if="householdTagsdetail" :basic-data="basicData"></HouseholdTagsDetail>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="企业员工【标签详情】" :visible.sync="enterpriseStaffTagsdetail" :modal-append-to-body="false">
|
|
|
+ <EnterpriseStaffTagsDetail v-if="enterpriseStaffTagsdetail" :basic-data="basicData"></EnterpriseStaffTagsDetail>
|
|
|
+ </el-dialog>
|
|
|
+ 标签添加信息组件
|
|
|
+ <el-dialog title="高龄老人【添加标签信息】" :visible.sync="elderTags" :modal-append-to-body="false">
|
|
|
+ <ElderTagsForm v-if="elderTags" :basic-data="basicData" :close-fn="() => {elderTags = false}"></ElderTagsForm>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="残障人士【添加标签信息】" :visible.sync="disablerTags" :modal-append-to-body="false">
|
|
|
+ <DisablerTagsForm v-if="disablerTags" :basic-data="basicData" :close-fn="() => {disablerTags = false}"></DisablerTagsForm>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="重点人员【添加标签信息】" :visible.sync="keyPersonTags" :modal-append-to-body="false">
|
|
|
+ <KeyPersonTagsForm v-if="keyPersonTags" :basic-data="basicData" :close-fn="() => {keyPersonTags = false}"></KeyPersonTagsForm>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="常住人员【添加标签信息】" :visible.sync="householdTags" :modal-append-to-body="false">
|
|
|
+ <HouseholdTagsForm v-if="householdTags" :basic-data="basicData" :close-fn="() => {householdTags = false}"></HouseholdTagsForm>
|
|
|
+ </el-dialog>
|
|
|
+ <el-dialog title="企业人员【添加标签信息】" :visible.sync="enterpriseStaffTags" :modal-append-to-body="false">
|
|
|
+ <EnterpriseStaffTagsForm v-if="enterpriseStaffTags" :basic-data="basicData" :close-fn="() => {enterpriseStaffTags = false}"></EnterpriseStaffTagsForm>
|
|
|
+ </el-dialog>-->
|
|
|
</basic-container>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import {getList, getDetail, add, update, remove} from "@/api/person/basicinfo";
|
|
|
import {mapGetters} from "vuex";
|
|
|
- // import ElderTagsForm from "@/components/person-tags/elderTags-form";
|
|
|
- // import DisablerTagsForm from "@/components/person-tags/disablerTags-form";
|
|
|
- // import KeyPersonTagsForm from "@/components/person-tags/keyPersonTags-form";
|
|
|
- // import EnterpriseStaffTagsForm from "@/components/person-tags/enterpriseStaffTags-form";
|
|
|
- // import HouseholdTagsForm from "@/components/person-tags/householdTags-form";
|
|
|
- // import ElderTagsDetail from "@/components/person-tags/elderTags-detail";
|
|
|
- // import DisablerTagsDetail from "@/components/person-tags/disablerTags-detail";
|
|
|
- // import KeypeopleTagsDetail from "@/components/person-tags/keyPersonTags-detail";
|
|
|
- // import HouseholdTagsDetail from "@/components/person-tags/householdTags-detail";
|
|
|
- // import EnterpriseStaffTagsDetail from "@/components/person-tags/enterpriseStaffTags-detail";
|
|
|
+ /*import ElderTagsForm from "@/components/person-tags/elderTags-form";
|
|
|
+ import DisablerTagsForm from "@/components/person-tags/disablerTags-form";
|
|
|
+ import KeyPersonTagsForm from "@/components/person-tags/keyPersonTags-form";
|
|
|
+ import EnterpriseStaffTagsForm from "@/components/person-tags/enterpriseStaffTags-form";
|
|
|
+ import HouseholdTagsForm from "@/components/person-tags/householdTags-form";
|
|
|
+ import ElderTagsDetail from "@/components/person-tags/elderTags-detail";
|
|
|
+ import DisablerTagsDetail from "@/components/person-tags/disablerTags-detail";
|
|
|
+ import KeypeopleTagsDetail from "@/components/person-tags/keyPersonTags-detail";
|
|
|
+ import HouseholdTagsDetail from "@/components/person-tags/householdTags-detail";
|
|
|
+ import EnterpriseStaffTagsDetail from "@/components/person-tags/enterpriseStaffTags-detail";*/
|
|
|
import {DIC} from "@/api/util/nation"
|
|
|
import {validatePhone} from "../../util/validator";
|
|
|
+ import SelectDialogResidential from "../../components/select-dialog/select-dialog-residential";
|
|
|
|
|
|
export default {
|
|
|
+ components: {SelectDialogResidential},
|
|
|
// components: {ElderTagsForm, DisablerTagsForm,KeyPersonTagsForm,DisablerTagsDetail,ElderTagsDetail,KeypeopleTagsDetail},
|
|
|
data() {
|
|
|
return {
|
|
|
@@ -150,6 +155,7 @@
|
|
|
confirmInfo:'',
|
|
|
query: {},
|
|
|
loading: true,
|
|
|
+ residentialDisabled: false,
|
|
|
page: {
|
|
|
pageSize: 10,
|
|
|
currentPage: 1,
|
|
|
@@ -227,7 +233,7 @@
|
|
|
trigger: "blur"
|
|
|
}]
|
|
|
},
|
|
|
- {
|
|
|
+ /*{
|
|
|
label: "所属社区",
|
|
|
prop: "agencyId",
|
|
|
search: true,
|
|
|
@@ -247,20 +253,21 @@
|
|
|
message: "请选择所属社区",
|
|
|
trigger: "blur"
|
|
|
}]
|
|
|
- },
|
|
|
+ },*/
|
|
|
{
|
|
|
label: "所属小区",
|
|
|
prop: "residentialId",
|
|
|
type: "select",
|
|
|
search: true,
|
|
|
searchFilterable: true,
|
|
|
- cascaderItem: ['buildingId'],
|
|
|
- dicUrl: "/api/cyzh-community/residential/list?agencyId={{key}}",
|
|
|
+ // cascaderItem: ['buildingId'],
|
|
|
+ dicUrl: "/api/cyzh-community/residential/list",
|
|
|
dicFormatter:(res)=>{
|
|
|
return res.data.records;//返回字典的层级结构
|
|
|
},
|
|
|
// dicFlag: false,
|
|
|
filterable: true,
|
|
|
+ formslot: true,
|
|
|
props: {
|
|
|
label: "name",
|
|
|
value: "id"
|
|
|
@@ -286,7 +293,8 @@
|
|
|
// slot:true,
|
|
|
search: true,
|
|
|
cascaderItem: ['unitId'],
|
|
|
- dicUrl: "/api/cyzh-community/building/list?residentialId={{key}}&size=100",
|
|
|
+ // dicUrl: "/api/cyzh-community/building/list?residentialId={{key}}&size=100",
|
|
|
+ dicUrl: "/api/cyzh-community/building/list",
|
|
|
dicFormatter:(res)=>{
|
|
|
return res.data.records;//返回字典的层级结构
|
|
|
},
|
|
|
@@ -602,25 +610,25 @@
|
|
|
trigger: "blur"
|
|
|
}]
|
|
|
},
|
|
|
- // {
|
|
|
- // label:'创建时间',
|
|
|
- // prop:'createTime',
|
|
|
- // type:"datetime",
|
|
|
- // span:12,
|
|
|
- // search:true,
|
|
|
- // valueFormat: 'yyyy-MM-dd HH:mm:ss',
|
|
|
- // format: 'yyyy-MM-dd HH:mm:ss',
|
|
|
- // defaultTime:['2020-1-1 00:00:00','2021-6-30 23:59:59'],
|
|
|
- // // dateDefault: true,
|
|
|
- // // searchValue:['2020-1-1 00:00:00','2021-6-30 23:59:59'],
|
|
|
- // searchRange:true,
|
|
|
- // searchClearable: false,
|
|
|
- // rules: [{
|
|
|
- // required: false,
|
|
|
- // message: "请输入创建时间",
|
|
|
- // trigger: "blur"
|
|
|
- // }]
|
|
|
- // }
|
|
|
+ /*{
|
|
|
+ label:'创建时间',
|
|
|
+ prop:'createTime',
|
|
|
+ type:"datetime",
|
|
|
+ span:12,
|
|
|
+ search:true,
|
|
|
+ valueFormat: 'yyyy-MM-dd HH:mm:ss',
|
|
|
+ format: 'yyyy-MM-dd HH:mm:ss',
|
|
|
+ defaultTime:['2020-1-1 00:00:00','2021-6-30 23:59:59'],
|
|
|
+ // dateDefault: true,
|
|
|
+ // searchValue:['2020-1-1 00:00:00','2021-6-30 23:59:59'],
|
|
|
+ searchRange:true,
|
|
|
+ searchClearable: false,
|
|
|
+ rules: [{
|
|
|
+ required: false,
|
|
|
+ message: "请输入创建时间",
|
|
|
+ trigger: "blur"
|
|
|
+ }]
|
|
|
+ }*/
|
|
|
]
|
|
|
},
|
|
|
data: []
|
|
|
@@ -649,6 +657,13 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ selectCallback(row){
|
|
|
+ this.form.residentialId = row.id;
|
|
|
+ this.form.residentialName = row.name;
|
|
|
+ if (this.option.column[6].prop == 'buildingId' && this.option.column[6].dicUrl.indexOf('residentialId') == -1){
|
|
|
+ this.option.column[6].dicUrl += '?residentialId=' + this.form.residentialId + '&size=100';
|
|
|
+ }
|
|
|
+ },
|
|
|
tagsFormOpen(type,row) {
|
|
|
this.basicData = row;
|
|
|
switch (type) {
|
|
|
@@ -691,7 +706,7 @@
|
|
|
},
|
|
|
rowSave(row, done, loading) {
|
|
|
row.agencyName = row.$agencyId;
|
|
|
- row.residentialName = row.$residentialId;
|
|
|
+ // row.residentialName = row.$residentialId;
|
|
|
row.buildingName = row.$buildingId;
|
|
|
row.unitName = row.$unitId;
|
|
|
row.floorName = row.$floorId;
|
|
|
@@ -721,9 +736,8 @@
|
|
|
return true; //如果不能找到相匹配的元素,返回true
|
|
|
},
|
|
|
rowUpdate(row, index, done, loading) {
|
|
|
- console.log(row)
|
|
|
row.agencyName = row.$agencyId;
|
|
|
- row.residentialName = row.$residentialId;
|
|
|
+ // row.residentialName = row.$residentialId;
|
|
|
row.buildingName = row.$buildingId;
|
|
|
row.unitName = row.$unitId;
|
|
|
row.floorName = row.$floorId;
|
|
|
@@ -731,8 +745,6 @@
|
|
|
if (row.tags.length == 0) {
|
|
|
row.tags = '';
|
|
|
}
|
|
|
- console.log(this.oldForm.tags,"oldtags")
|
|
|
- console.log(row.tags,"updatatags")
|
|
|
if (this.oldForm.tags!=null){
|
|
|
let oldtags = this.oldForm.tags.split(",");
|
|
|
let utags = row.tags.split(",");
|
|
|
@@ -827,6 +839,7 @@
|
|
|
},
|
|
|
beforeOpen(done, type) {
|
|
|
if (["edit", "view"].includes(type)) {
|
|
|
+ this.residentialDisabled = true;
|
|
|
getDetail(this.form.id).then(res => {
|
|
|
this.form = res.data.data;
|
|
|
this.oldForm = res.data.data;
|