物业之前,新工作台

This commit is contained in:
Zy
2026-04-16 21:03:35 +08:00
parent cf9a1f1585
commit 4184f1c55d
91 changed files with 1781 additions and 588 deletions

View File

@@ -7,15 +7,15 @@
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
<el-form-item label="住户类型" prop="type">
<el-select v-model="queryParams.type" placeholder="请输入住户类型" style="width: 240px">
<el-option v-for="item in typelist" :key="item.value" :label="item.label" :value="item.value" />
<el-option v-for="item in com_resident_relationship" :key="item.value" :label="item.label" :value="item.value" />
</el-select>
</el-form-item>
<el-form-item label="住户状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请输入住户状态" style="width: 240px">
<el-option v-for="item in statuslist" :key="item.value" :label="item.label" :value="item.value" />
<el-option v-for="item in com_review" :key="item.value" :label="item.label" :value="item.value" />
</el-select>
</el-form-item>
<el-form-item label="提交日期" prop="date">
<!-- <el-form-item label="提交日期" prop="date">
<el-date-picker
v-model="queryParams.date"
type="date"
@@ -23,7 +23,7 @@
:disabled-date="disabledDate"
:shortcuts="shortcuts"
/>
</el-form-item>
</el-form-item> -->
<el-form-item>
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
@@ -36,7 +36,7 @@
<el-card style="flex: 1" shadow="never">
<div class="residentBody h-full">
<div class="treebox h-full">
<div class="treeTitlebox">北境碧桂园小区</div>
<div class="treeTitlebox">{{ currentVilageInfo.villageName ?? '12' }}</div>
<div class="treeboxbody">
<!-- 树状+ -->
<el-tree :highlight-current="true" style="max-width: 600px" :data="treedata" :props="defaultProps" @node-click="handleNodeClick" />
@@ -114,7 +114,8 @@ import { getHousePathById } from '@/utils/house';
import { useHouseStore } from '@/store/modules/house';
const houseStore = useHouseStore();
const { treedata } = storeToRefs(houseStore);
const { currentVilageInfo } = storeToRefs(houseStore);
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
const { com_resident_relationship } = toRefs<any>(proxy?.useDict('com_resident_relationship'));
const { com_review } = toRefs<any>(proxy?.useDict('com_review'));
@@ -129,16 +130,6 @@ const multiple = ref(true);
const total = ref(0);
const queryFormRef = ref<ElFormInstance>();
// 住户类型
const typelist = [
{ label: '业主', value: 0 },
{ label: '租户', value: 1 }
];
// 住户状态
const statuslist = [
{ label: '审核中', value: 0 },
{ label: '已认证', value: 1 }
];
const initFormData: ResidentForm = {
id: undefined,
@@ -162,12 +153,12 @@ const data = reactive<PageData<ResidentForm, ResidentQuery>>({
queryParams: {
pageNum: 1,
pageSize: 10,
villageId: Number(localStorage.getItem('villageid')),
date: '',
type: null,
status: null,
houseId: null,
villageId: null,
buildingId: null,
unitNo: null
}
@@ -256,16 +247,22 @@ const defaultProps = {
label: 'label'
};
// ! 树形------------------------------------------------------------------------
const treedata = ref([]);
function gettree() {
houseStore.getCurrentVilageTreeHouse().then((res) => {
treedata.value = res;
});
}
gettree();
/** 查询住户管理列表 */
const getList = async () => {
loading.value = true;
const res = await listResident(queryParams.value);
residentList.value = res.rows;
console.log(residentList.value);
residentList.value.forEach((item) => {
const arr = getHousePathById(treedata.value, item.houseId, 'label');
console.log(arr);
item.houseAddress = arr.join(' ');
});
total.value = res.total;