新增数据,开始安全巡检模块
This commit is contained in:
@@ -361,6 +361,7 @@ const cancelForm = () => {
|
||||
height: 50px;
|
||||
line-height: 50px;
|
||||
background-color: #1a75ff;
|
||||
background-color: #dfedff;
|
||||
& > div {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
@@ -109,6 +109,7 @@ function handleclick(item: communitylist_rows_type) {
|
||||
height: 50px;
|
||||
line-height: 50px;
|
||||
background-color: #1a75ff;
|
||||
background-color: #dfedff;
|
||||
& > div {
|
||||
flex: 1;
|
||||
}
|
||||
@@ -116,6 +117,7 @@ function handleclick(item: communitylist_rows_type) {
|
||||
padding-left: 20px;
|
||||
font-size: 20px;
|
||||
color: white;
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
<el-form ref="formRef" :model="form" :rules="rules" label-width="120px">
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="活动标题" prop="titile">
|
||||
<el-input v-model.trim="form.titile" placeholder="请输入活动标题" />
|
||||
<el-form-item label="活动标题" prop="title">
|
||||
<el-input v-model.trim="form.title" placeholder="请输入活动标题" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
@@ -52,14 +52,13 @@ const router = useRouter();
|
||||
const formRef = ref();
|
||||
const form = ref({
|
||||
'id': null,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
'titile': '',
|
||||
'title': '',
|
||||
'author': '',
|
||||
'content': '',
|
||||
'status': '0'
|
||||
});
|
||||
const rules = {
|
||||
titile: [{ required: true, message: '请输入活动标题', trigger: 'blur' }],
|
||||
title: [{ required: true, message: '请输入活动标题', trigger: 'blur' }],
|
||||
author: [{ required: true, message: '请输入作者', trigger: 'blur' }],
|
||||
content: [{ required: true, message: '请输入内容', trigger: 'blur' }]
|
||||
};
|
||||
@@ -85,7 +84,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateActivity(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -115,7 +115,6 @@ const initFormData: ActivityForm = {
|
||||
const data = reactive<PageData<ActivityForm, ActivityQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
titile: undefined,
|
||||
|
||||
@@ -138,7 +138,6 @@ const formRef = ref();
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateComplaint(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -87,7 +87,6 @@ const initFormData: ComplaintForm = {
|
||||
const data = reactive<PageData<ComplaintForm, ComplaintQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
typeId: undefined,
|
||||
|
||||
@@ -67,7 +67,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateComplaintType(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
@@ -86,7 +85,7 @@ const submitForm = () => {
|
||||
// 返回
|
||||
function handleBack() {
|
||||
router.push({
|
||||
path: '/repair/complaintType'
|
||||
path: '/system/complaintType'
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -99,7 +99,6 @@ const data = reactive<PageData<ComplaintTypeForm, ComplaintTypeQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
name: undefined,
|
||||
status: undefined,
|
||||
createNam: undefined,
|
||||
@@ -145,14 +144,14 @@ const router = useRouter();
|
||||
/** 新增按钮操作 */
|
||||
const handleAdd = () => {
|
||||
router.push({
|
||||
path: '/repair/addComplantType'
|
||||
path: '/system/addComplantType'
|
||||
});
|
||||
};
|
||||
|
||||
/** 修改按钮操作 */
|
||||
const handleUpdate = async (row?: ComplaintTypeVO) => {
|
||||
router.push({
|
||||
path: '/repair/addComplantType',
|
||||
path: '/system/addComplantType',
|
||||
query: {
|
||||
id: row.id
|
||||
}
|
||||
|
||||
@@ -58,10 +58,10 @@ import PageHeader from '@/components/Pageheader/index.vue';
|
||||
import { addDecoration, getDecoration, updateDecoration } from '@/api/system/Decoration';
|
||||
import { useHouseStore } from '@/store/modules/house';
|
||||
import { CascaderValue } from 'element-plus';
|
||||
import { getHousePathById } from '@/utils/house';
|
||||
|
||||
const houseStore = useHouseStore();
|
||||
const { treedata } = storeToRefs(houseStore);
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const treedata = ref([]);
|
||||
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
@@ -69,7 +69,6 @@ const formRef = ref();
|
||||
const form = ref({
|
||||
'id': null,
|
||||
'houseId': null,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
'applyName': '',
|
||||
'decorationCompany': '',
|
||||
'decorationContent': '',
|
||||
@@ -83,21 +82,6 @@ const rules = {
|
||||
};
|
||||
const userid = ref();
|
||||
|
||||
// ! 投诉 ====================================================================================================
|
||||
function init() {
|
||||
getDecoration(userid.value).then((res) => {
|
||||
form.value = {
|
||||
...form.value,
|
||||
...res.data
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
if (route.query.id) {
|
||||
userid.value = route.query.id;
|
||||
init();
|
||||
}
|
||||
|
||||
// 获取房屋
|
||||
const userHousepath = ref([]);
|
||||
function handleChange(val: (string | number)[]) {
|
||||
@@ -107,11 +91,34 @@ function handleChange(val: (string | number)[]) {
|
||||
form.value.houseId = null;
|
||||
}
|
||||
}
|
||||
|
||||
// ! 投诉 ====================================================================================================
|
||||
function getTree() {
|
||||
houseStore.getCurrentVilageTreeHouse().then((res) => {
|
||||
treedata.value = res;
|
||||
if (route.query.id) {
|
||||
userid.value = route.query.id;
|
||||
init();
|
||||
}
|
||||
});
|
||||
}
|
||||
getTree();
|
||||
function init() {
|
||||
getDecoration(userid.value).then((res) => {
|
||||
form.value = {
|
||||
...form.value,
|
||||
...res.data
|
||||
};
|
||||
const arr = getHousePathById(treedata.value, form.value.houseId);
|
||||
console.log(arr);
|
||||
userHousepath.value = arr;
|
||||
});
|
||||
}
|
||||
|
||||
// 提交
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateDecoration(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<div class="flex flex-col h-full p-2">
|
||||
<Pageheader title="装修管理"></Pageheader>
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
@@ -22,7 +22,7 @@
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<el-card class="flex-1" shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
@@ -146,7 +146,6 @@ const data = reactive<PageData<DecorationForm, DecorationQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageSize: 10,
|
||||
houseId: undefined,
|
||||
applyName: undefined,
|
||||
@@ -260,3 +259,9 @@ onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-table {
|
||||
height: calc(100% - 80px);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -112,7 +112,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateHandleLog(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -94,7 +94,6 @@ const initFormData: HandleLogForm = {
|
||||
const data = reactive<PageData<HandleLogForm, HandleLogQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
content: undefined,
|
||||
|
||||
205
src/views/system/InspectionPlan/addInspectionPlan.vue
Normal file
205
src/views/system/InspectionPlan/addInspectionPlan.vue
Normal file
@@ -0,0 +1,205 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<PageHeader title="新建巡检计划"></PageHeader>
|
||||
<div class="EditBody">
|
||||
<div class="title">
|
||||
<div>基本信息</div>
|
||||
</div>
|
||||
<div class="bodybox">
|
||||
<el-form label-width="100px" label-position="right">
|
||||
<el-form-item label="巡检计划名称">
|
||||
<el-input placeholder="请输入"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="巡检人员">
|
||||
<el-input placeholder="请输入"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="执行周期">
|
||||
<el-date-picker
|
||||
@update:model-value="handleTime"
|
||||
v-model="taskDate"
|
||||
type="daterange"
|
||||
range-separator="到"
|
||||
format="YYYY-MM-DD"
|
||||
value-format="YYYY-MM-DD"
|
||||
start-placeholder="开启日期"
|
||||
end-placeholder="结束日期"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务时间">
|
||||
<el-select v-model="form.taskTime" placeholder="Select" style="width: 100%">
|
||||
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
<div flex flex-wrap>
|
||||
<div
|
||||
class="week-items"
|
||||
@click="checkoutWeekFun(item)"
|
||||
:class="{
|
||||
active: checkoutWeek.includes(item)
|
||||
}"
|
||||
v-for="(item, index) in 7"
|
||||
:key="index"
|
||||
>
|
||||
<div class="iconbox">
|
||||
<el-icon v-show="checkoutWeek.includes(item)"><Check /></el-icon>
|
||||
</div>
|
||||
<span class="ml-5px">{{ numToWeek(item) }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="提醒时间">
|
||||
<el-select v-model="form.remindTime" placeholder="Select" style="width: 100%">
|
||||
<el-option v-for="item in remindTimeoptions" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="巡检设置">
|
||||
<el-radio-group v-model="form.inspectSetting">
|
||||
<el-radio label="必须拍照" value="1" />
|
||||
<el-radio label="允许跳检" value="0" />
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="计划路线">
|
||||
<el-select v-model="form.routeIds" placeholder="Select" style="width: 100%">
|
||||
<el-option v-for="item in routeIdsoptions" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
<div class="mapbox">123</div>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary">提交</el-button>
|
||||
<el-button @click="routeback">返回</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import PageHeader from '@/components/Pageheader/index.vue';
|
||||
import { numToWeek } from '@/utils/time';
|
||||
import { ref } from 'vue';
|
||||
const route = useRoute();
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
const form = ref({
|
||||
taskTime: 0,
|
||||
remindTime: '',
|
||||
startTime: '',
|
||||
endTime: '',
|
||||
inspectSetting: '',
|
||||
routeIds: ''
|
||||
});
|
||||
|
||||
// 执行周期
|
||||
const taskDate = ref([]);
|
||||
function handleTime(val) {
|
||||
console.log(val);
|
||||
taskDate.value = val;
|
||||
form.value.startTime = val[0];
|
||||
form.value.endTime = val[1];
|
||||
}
|
||||
const checkoutWeek = ref([]);
|
||||
function checkoutWeekFun(val: number) {
|
||||
if (!checkoutWeek.value.includes(val)) {
|
||||
checkoutWeek.value.push(val);
|
||||
} else {
|
||||
checkoutWeek.value = checkoutWeek.value.filter((item) => item !== val);
|
||||
}
|
||||
console.log(val);
|
||||
}
|
||||
|
||||
// 任务时间
|
||||
const options = ref([
|
||||
{
|
||||
value: '09:00-11:00; 13:00-15:00',
|
||||
label: '09:00-11:00; 13:00-15:00'
|
||||
}
|
||||
]);
|
||||
// 提醒时间
|
||||
const remindTimeoptions = ref([
|
||||
{
|
||||
value: 0,
|
||||
label: '任务开始前10分钟'
|
||||
},
|
||||
{
|
||||
value: 1,
|
||||
label: '任务开始前15分钟'
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
label: '任务开始前30分钟'
|
||||
}
|
||||
]);
|
||||
|
||||
// 计划路线
|
||||
const routeIdsoptions = ref([
|
||||
{
|
||||
value: 0,
|
||||
label: '常规巡更计划1'
|
||||
},
|
||||
{
|
||||
value: 1,
|
||||
label: '常规巡更计划2'
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
label: '常规巡更计划3'
|
||||
}
|
||||
]);
|
||||
// 巡检计划id
|
||||
const editid = ref(null);
|
||||
function init() {
|
||||
if (route.query.id) {
|
||||
editid.value = route.query.id;
|
||||
}
|
||||
}
|
||||
|
||||
init();
|
||||
|
||||
function routeback() {
|
||||
router.back();
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.EditBody {
|
||||
margin-top: 20px;
|
||||
padding: 30px;
|
||||
background-color: white;
|
||||
.bodybox {
|
||||
width: 600px;
|
||||
margin: 0 auto;
|
||||
margin-top: 20px;
|
||||
}
|
||||
.week-items {
|
||||
width: 90px;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
border-radius: 5px;
|
||||
cursor: pointer;
|
||||
margin: 10px 5px;
|
||||
background-color: #ccc;
|
||||
color: #000;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.iconbox {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
margin-left: 5px;
|
||||
text-align: center;
|
||||
line-height: 30px;
|
||||
}
|
||||
&.active {
|
||||
color: rgba(26, 117, 255, 1);
|
||||
background-color: rgba(26, 117, 255, 0.15);
|
||||
}
|
||||
}
|
||||
|
||||
.mapbox {
|
||||
margin-top: 20px;
|
||||
width: 100%;
|
||||
height: 400px;
|
||||
border: 1px solid #ccc;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
222
src/views/system/InspectionPlan/index.vue
Normal file
222
src/views/system/InspectionPlan/index.vue
Normal file
@@ -0,0 +1,222 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
<el-form ref="queryFormRef" label-width="100px" :model="queryParams" :inline="true">
|
||||
<el-form-item label="巡检计划名称" prop="planName">
|
||||
<el-input v-model="queryParams.planName" placeholder="请输入巡检计划名称" clearable @keyup.enter="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-card>
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['system:plan:add']">新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="success" plain icon="Edit" :disabled="single" @click="handleUpdate()" v-hasPermi="['system:plan:edit']">修改</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="danger" plain icon="Delete" :disabled="multiple" @click="handleDelete()" v-hasPermi="['system:plan:remove']"
|
||||
>删除</el-button
|
||||
>
|
||||
</el-col>
|
||||
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
</template>
|
||||
|
||||
<el-table v-loading="loading" border :data="planList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="巡检计划名称" align="center" prop="planName" />
|
||||
<el-table-column label="巡检人员" align="center" prop="inspectorIds" />
|
||||
<el-table-column label="执行周期" align="center" prop="executeCycle" />
|
||||
<el-table-column label="任务时间" align="center" prop="taskTime" />
|
||||
<el-table-column label="巡检设置:0-必须拍照,1-可以跳检" align="center" prop="inspectSetting" />
|
||||
<el-table-column label="计划路线" align="center" prop="routeIds" />
|
||||
<el-table-column label="状态:0-关闭,1-开启" align="center" prop="status" />
|
||||
<el-table-column label="备注" align="center" prop="remark" />
|
||||
<el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width">
|
||||
<template #default="scope">
|
||||
<el-tooltip content="修改" placement="top">
|
||||
<el-button link type="primary" icon="Edit" @click="handleUpdate(scope.row)" v-hasPermi="['system:plan:edit']"></el-button>
|
||||
</el-tooltip>
|
||||
<el-tooltip content="删除" placement="top">
|
||||
<el-button link type="primary" icon="Delete" @click="handleDelete(scope.row)" v-hasPermi="['system:plan:remove']"></el-button>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup name="Plan" lang="ts">
|
||||
import { listPlan, getPlan, delPlan, addPlan, updatePlan } from '@/api/system/InspectionPlan/index';
|
||||
import { PlanVO, PlanQuery, PlanForm } from '@/api/system/InspectionPlan/type';
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
|
||||
const planList = ref<PlanVO[]>([]);
|
||||
const buttonLoading = ref(false);
|
||||
const loading = ref(true);
|
||||
const showSearch = ref(true);
|
||||
const ids = ref<Array<string | number>>([]);
|
||||
const single = ref(true);
|
||||
const multiple = ref(true);
|
||||
const total = ref(0);
|
||||
|
||||
const queryFormRef = ref<ElFormInstance>();
|
||||
const planFormRef = ref<ElFormInstance>();
|
||||
|
||||
const dialog = reactive<DialogOption>({
|
||||
visible: false,
|
||||
title: ''
|
||||
});
|
||||
|
||||
const initFormData: PlanForm = {
|
||||
id: undefined,
|
||||
planName: undefined,
|
||||
inspectorIds: undefined,
|
||||
executeCycle: undefined,
|
||||
taskTime: undefined,
|
||||
remindTime: undefined,
|
||||
inspectSetting: undefined,
|
||||
routeIds: undefined,
|
||||
status: undefined,
|
||||
remark: undefined,
|
||||
executeDay: undefined
|
||||
};
|
||||
const data = reactive<PageData<PlanForm, PlanQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
planName: undefined,
|
||||
inspectorIds: undefined,
|
||||
executeCycle: undefined,
|
||||
taskTime: undefined,
|
||||
remindTime: undefined,
|
||||
inspectSetting: undefined,
|
||||
routeIds: undefined,
|
||||
status: undefined,
|
||||
executeDay: undefined,
|
||||
params: {}
|
||||
},
|
||||
rules: {
|
||||
id: [{ required: true, message: '主键ID不能为空', trigger: 'blur' }],
|
||||
planName: [{ required: true, message: '巡检计划名称不能为空', trigger: 'blur' }]
|
||||
}
|
||||
});
|
||||
|
||||
const { queryParams, form, rules } = toRefs(data);
|
||||
|
||||
/** 查询巡检计划列表 */
|
||||
const getList = async () => {
|
||||
loading.value = true;
|
||||
const res = await listPlan(queryParams.value);
|
||||
planList.value = res.rows;
|
||||
total.value = res.total;
|
||||
loading.value = false;
|
||||
};
|
||||
|
||||
/** 取消按钮 */
|
||||
const cancel = () => {
|
||||
reset();
|
||||
dialog.visible = false;
|
||||
};
|
||||
|
||||
/** 表单重置 */
|
||||
const reset = () => {
|
||||
form.value = { ...initFormData };
|
||||
planFormRef.value?.resetFields();
|
||||
};
|
||||
|
||||
/** 搜索按钮操作 */
|
||||
const handleQuery = () => {
|
||||
queryParams.value.pageNum = 1;
|
||||
getList();
|
||||
};
|
||||
|
||||
/** 重置按钮操作 */
|
||||
const resetQuery = () => {
|
||||
queryFormRef.value?.resetFields();
|
||||
handleQuery();
|
||||
};
|
||||
|
||||
/** 多选框选中数据 */
|
||||
const handleSelectionChange = (selection: PlanVO[]) => {
|
||||
ids.value = selection.map((item) => item.id);
|
||||
single.value = selection.length != 1;
|
||||
multiple.value = !selection.length;
|
||||
};
|
||||
|
||||
const router = useRouter();
|
||||
/** 新增按钮操作 */
|
||||
const handleAdd = () => {
|
||||
router.push({
|
||||
path: '/Inspection/addInspectionPlan'
|
||||
});
|
||||
};
|
||||
|
||||
/** 修改按钮操作 */
|
||||
const handleUpdate = async (row?: PlanVO) => {
|
||||
router.push({
|
||||
path: '/Inspection/addInspectionPlan',
|
||||
query: {
|
||||
id: row.id
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/** 提交按钮 */
|
||||
const submitForm = () => {
|
||||
planFormRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
buttonLoading.value = true;
|
||||
if (form.value.id) {
|
||||
await updatePlan(form.value).finally(() => (buttonLoading.value = false));
|
||||
} else {
|
||||
await addPlan(form.value).finally(() => (buttonLoading.value = false));
|
||||
}
|
||||
proxy?.$modal.msgSuccess('操作成功');
|
||||
dialog.visible = false;
|
||||
await getList();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/** 删除按钮操作 */
|
||||
const handleDelete = async (row?: PlanVO) => {
|
||||
const _ids = row?.id || ids.value;
|
||||
await proxy?.$modal.confirm('是否确认删除巡检计划编号为"' + _ids + '"的数据项?').finally(() => (loading.value = false));
|
||||
await delPlan(_ids);
|
||||
proxy?.$modal.msgSuccess('删除成功');
|
||||
await getList();
|
||||
};
|
||||
|
||||
/** 导出按钮操作 */
|
||||
const handleExport = () => {
|
||||
proxy?.download(
|
||||
'system/plan/export',
|
||||
{
|
||||
...queryParams.value
|
||||
},
|
||||
`plan_${new Date().getTime()}.xlsx`
|
||||
);
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
161
src/views/system/InspectionRecord/InspectionRecordMain.vue
Normal file
161
src/views/system/InspectionRecord/InspectionRecordMain.vue
Normal file
@@ -0,0 +1,161 @@
|
||||
<template>
|
||||
<div class="AddBuildingBox">
|
||||
<PageHeader title="记录详情"></PageHeader>
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">基本信息</div>
|
||||
<div class="addBuildingFormBody">
|
||||
<div class="infobox">
|
||||
<div class="label">任务名称 :</div>
|
||||
<div class="value">{{ form.taskName }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">巡更人员 :</div>
|
||||
<div class="value">{{ form.inspectorName }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">关联计划 :</div>
|
||||
<div class="value">{{ form.planName }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">开始时间 :</div>
|
||||
<div class="value">{{ form.actualStartTime }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">结束时间 :</div>
|
||||
<div class="value">{{ form.actualEndTime }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">执行状态 :</div>
|
||||
<div class="value">{{ form.statusLabel }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">创建人 :</div>
|
||||
<div class="value">{{ form.createByName }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">创建时间 :</div>
|
||||
<div class="value">{{ form.createTime }}</div>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="label">更新时间 :</div>
|
||||
<div class="value">{{ form.updateTime }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">巡检记录</div>
|
||||
<div class="">
|
||||
<el-table :data="form.details" style="width: 100%">
|
||||
<el-table-column type="index" align="center" label="序号" width="85" />
|
||||
<el-table-column prop="pointName" align="center" label="巡检点" />
|
||||
<el-table-column prop="checkTime" align="center" label=" 巡检时间" />
|
||||
<el-table-column prop="location" align="center" label="巡检地址" />
|
||||
<el-table-column prop="checkResult" align="center" label="巡检结果" />
|
||||
<el-table-column prop="photos" align="center" label="图片" />
|
||||
</el-table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import PageHeader from '@/components/Pageheader/index.vue';
|
||||
import { addMonthCard, getMonthCard, updateMonthCard } from '@/api/system/MonthCard';
|
||||
import { getRecord } from '@/api/system/InspectionRecord';
|
||||
import { RecordVO } from '@/api/system/InspectionRecord/type';
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_pay_method } = toRefs<any>(proxy?.useDict('com_pay_method'));
|
||||
|
||||
const router = useRouter();
|
||||
const route = useRoute();
|
||||
|
||||
const formRef = ref();
|
||||
const form = ref<RecordVO>();
|
||||
const userid = ref(null);
|
||||
if (route.query.id) {
|
||||
userid.value = route.query.id;
|
||||
getRecord(userid.value).then((res) => {
|
||||
form.value = {
|
||||
...res.data
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
// ! table
|
||||
const tableData = [
|
||||
{
|
||||
date: '2016-05-03',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-02',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-04',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-01',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
}
|
||||
];
|
||||
// ! table
|
||||
|
||||
// 推出
|
||||
const cancelForm = () => {
|
||||
router.push({
|
||||
path: '/carArea/monthCard'
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.AddBuildingBox {
|
||||
padding: 15px;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
.AddBuildingBody {
|
||||
margin-top: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
background-color: white;
|
||||
padding: 15px;
|
||||
.title {
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
padding-left: 20px;
|
||||
background-color: rgba(255, 255, 255, 1);
|
||||
color: rgba(16, 16, 16, 1);
|
||||
border-bottom: 1px solid #bbbbbb;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.addBuildingFormBody {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
|
||||
.infobox {
|
||||
font-size: 16px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 40px;
|
||||
.label {
|
||||
width: 100px;
|
||||
text-align: right;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.value {
|
||||
font-weight: 500;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
223
src/views/system/InspectionRecord/index.vue
Normal file
223
src/views/system/InspectionRecord/index.vue
Normal file
@@ -0,0 +1,223 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
<el-form ref="queryFormRef" :model="queryParams" :inline="true">
|
||||
<el-form-item label="执行状态" prop="routeId">
|
||||
<el-input v-model="queryParams.routeId" placeholder="请输入巡检路线ID" clearable @keyup.enter="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item label="巡检日期" prop="routeId">
|
||||
<el-input v-model="queryParams.routeId" placeholder="请输入巡检路线ID" clearable @keyup.enter="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务名称" prop="routeId">
|
||||
<el-input v-model="queryParams.routeId" placeholder="请输入巡检路线ID" clearable @keyup.enter="handleQuery" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-card>
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button type="primary" plain icon="Plus" @click="handleAdd" v-hasPermi="['system:record:add']">临时跳转详情页</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="danger" plain icon="Delete" :disabled="multiple" @click="handleDelete()" v-hasPermi="['system:record:remove']"
|
||||
>删除</el-button
|
||||
>
|
||||
</el-col>
|
||||
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
</template>
|
||||
|
||||
<el-table v-loading="loading" border :data="recordList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="任务名称" align="center" prop="taskName" />
|
||||
<el-table-column label="巡检人员" align="center" prop="inspectorName" />
|
||||
<el-table-column label="任务开始时间" align="center" prop="startTime" width="180">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.actualStartTime, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="任务结束时间" align="center" prop="endTime" width="180">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.actualEndTime, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="执行状态" align="center" prop="status" />
|
||||
<el-table-column label="关联计划" align="center" prop="planName" />
|
||||
<el-table-column label="操作" align="center" fixed="right" class-name="small-padding fixed-width">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" @click="handleUpdate(scope.row)">查看详情</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination v-show="total > 0" :total="total" v-model:page="queryParams.pageNum" v-model:limit="queryParams.pageSize" @pagination="getList" />
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup name="Record" lang="ts">
|
||||
import { listRecord, getRecord, delRecord, addRecord, updateRecord } from '@/api/system/InspectionRecord/index';
|
||||
import { RecordVO, RecordQuery, RecordForm } from '@/api/system/InspectionRecord/type';
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
|
||||
const recordList = ref<RecordVO[]>([]);
|
||||
const buttonLoading = ref(false);
|
||||
const loading = ref(true);
|
||||
const showSearch = ref(true);
|
||||
const ids = ref<Array<string | number>>([]);
|
||||
const single = ref(true);
|
||||
const multiple = ref(true);
|
||||
const total = ref(0);
|
||||
|
||||
const queryFormRef = ref<ElFormInstance>();
|
||||
const recordFormRef = ref<ElFormInstance>();
|
||||
|
||||
const dialog = reactive<DialogOption>({
|
||||
visible: false,
|
||||
title: ''
|
||||
});
|
||||
|
||||
const initFormData: RecordForm = {
|
||||
id: undefined,
|
||||
taskId: undefined,
|
||||
planId: undefined,
|
||||
inspectorId: undefined,
|
||||
routeId: undefined,
|
||||
startTime: undefined,
|
||||
endTime: undefined,
|
||||
execStatus: undefined,
|
||||
remark: undefined
|
||||
};
|
||||
const data = reactive<PageData<RecordForm, RecordQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
taskId: undefined,
|
||||
planId: undefined,
|
||||
inspectorId: undefined,
|
||||
routeId: undefined,
|
||||
startTime: undefined,
|
||||
endTime: undefined,
|
||||
execStatus: undefined,
|
||||
params: {}
|
||||
},
|
||||
rules: {
|
||||
id: [{ required: true, message: '主键ID不能为空', trigger: 'blur' }],
|
||||
taskId: [{ required: true, message: '关联巡检任务ID不能为空', trigger: 'blur' }],
|
||||
inspectorId: [{ required: true, message: '巡检人员ID不能为空', trigger: 'blur' }]
|
||||
}
|
||||
});
|
||||
|
||||
const { queryParams, form, rules } = toRefs(data);
|
||||
|
||||
/** 查询巡检记录主列表 */
|
||||
const getList = async () => {
|
||||
loading.value = true;
|
||||
const res = await listRecord(queryParams.value);
|
||||
recordList.value = res.rows;
|
||||
total.value = res.total;
|
||||
loading.value = false;
|
||||
};
|
||||
|
||||
/** 取消按钮 */
|
||||
const cancel = () => {
|
||||
reset();
|
||||
dialog.visible = false;
|
||||
};
|
||||
|
||||
/** 表单重置 */
|
||||
const reset = () => {
|
||||
form.value = { ...initFormData };
|
||||
recordFormRef.value?.resetFields();
|
||||
};
|
||||
|
||||
/** 搜索按钮操作 */
|
||||
const handleQuery = () => {
|
||||
queryParams.value.pageNum = 1;
|
||||
getList();
|
||||
};
|
||||
|
||||
/** 重置按钮操作 */
|
||||
const resetQuery = () => {
|
||||
queryFormRef.value?.resetFields();
|
||||
handleQuery();
|
||||
};
|
||||
|
||||
/** 多选框选中数据 */
|
||||
const handleSelectionChange = (selection: RecordVO[]) => {
|
||||
ids.value = selection.map((item) => item.id);
|
||||
single.value = selection.length != 1;
|
||||
multiple.value = !selection.length;
|
||||
};
|
||||
|
||||
const router = useRouter();
|
||||
/** 新增按钮操作 */
|
||||
const handleAdd = () => {
|
||||
router.push({
|
||||
path: '/Inspection/InspectionRecordMain'
|
||||
});
|
||||
};
|
||||
|
||||
/** 修改按钮操作 */
|
||||
const handleUpdate = async (row?: RecordVO) => {
|
||||
reset();
|
||||
const _id = row?.id || ids.value[0];
|
||||
const res = await getRecord(_id);
|
||||
Object.assign(form.value, res.data);
|
||||
dialog.visible = true;
|
||||
dialog.title = '修改巡检记录主';
|
||||
};
|
||||
|
||||
/** 提交按钮 */
|
||||
const submitForm = () => {
|
||||
recordFormRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
buttonLoading.value = true;
|
||||
if (form.value.id) {
|
||||
await updateRecord(form.value).finally(() => (buttonLoading.value = false));
|
||||
} else {
|
||||
await addRecord(form.value).finally(() => (buttonLoading.value = false));
|
||||
}
|
||||
proxy?.$modal.msgSuccess('操作成功');
|
||||
dialog.visible = false;
|
||||
await getList();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/** 删除按钮操作 */
|
||||
const handleDelete = async (row?: RecordVO) => {
|
||||
const _ids = row?.id || ids.value;
|
||||
await proxy?.$modal.confirm('是否确认删除巡检记录主编号为"' + _ids + '"的数据项?').finally(() => (loading.value = false));
|
||||
await delRecord(_ids);
|
||||
proxy?.$modal.msgSuccess('删除成功');
|
||||
await getList();
|
||||
};
|
||||
|
||||
/** 导出按钮操作 */
|
||||
const handleExport = () => {
|
||||
proxy?.download(
|
||||
'system/record/export',
|
||||
{
|
||||
...queryParams.value
|
||||
},
|
||||
`record_${new Date().getTime()}.xlsx`
|
||||
);
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
@@ -103,7 +103,6 @@ const formRef = ref();
|
||||
const form = ref({
|
||||
id: null,
|
||||
cardCode: '', // 月卡编号
|
||||
villageId: Number(localStorage.getItem('villageid')), // 月卡编号
|
||||
cardName: null, // 持卡人姓名
|
||||
phone: '', // 手机号
|
||||
carNum: null, // 绑定车牌号
|
||||
@@ -171,7 +170,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (!form.value.startTime.trim() || !form.value.endTime.trim()) {
|
||||
ElMessage.warning('请选择有效日期');
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<div class="h-full flex flex-col p-2">
|
||||
<pageheader title="月卡管理"></pageheader>
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
@@ -22,7 +22,7 @@
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<el-card class="flex-1" shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
@@ -178,7 +178,6 @@ const data = reactive<PageData<MonthCardForm, MonthCardQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
handleTime: undefined,
|
||||
cardName: undefined,
|
||||
phone: undefined,
|
||||
@@ -298,3 +297,9 @@ onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-table {
|
||||
height: calc(100% - 80px);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -116,7 +116,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateNotice(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -109,7 +109,6 @@ const initFormData: NoticeForm = {
|
||||
const data = reactive<PageData<NoticeForm, NoticeQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
noticeTitle: undefined,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="AddBuildingBox">
|
||||
<PageHeader :title="userid ? '编辑月卡' : '添加月卡'"></PageHeader>
|
||||
<PageHeader :title="userid ? '编辑停车缴费' : '添加停车缴费'"></PageHeader>
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">基本信息</div>
|
||||
<div class="addBuildingFormBody">
|
||||
@@ -108,11 +108,9 @@
|
||||
<script setup lang="ts">
|
||||
import { ref } from 'vue';
|
||||
import PageHeader from '@/components/Pageheader/index.vue';
|
||||
import { addMonthCard, getMonthCard, updateMonthCard } from '@/api/system/MonthCard';
|
||||
import { listArea } from '@/api/system/carArea';
|
||||
import { addParkingCost, getParkingCost, updateParkingCost } from '@/api/system/ParkingCost';
|
||||
import { listParking } from '@/api/system/parking';
|
||||
import { getCommunitylistAPI } from '@/api/system/community';
|
||||
import { validator } from '@/utils/Reg';
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_pay_method } = toRefs<any>(proxy?.useDict('com_pay_method'));
|
||||
@@ -125,7 +123,6 @@ const route = useRoute();
|
||||
const formRef = ref();
|
||||
const form = ref({
|
||||
id: null,
|
||||
villageId: Number(localStorage.getItem('villageid')), // 所属小区id
|
||||
areaId: null, // 区域id
|
||||
parkingId: '', // 车位id
|
||||
chargeItem: '0', // 临时停车
|
||||
@@ -215,7 +212,6 @@ function handleArea(val: string) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateParkingCost(form.value).then((res) => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -143,7 +143,6 @@ const data = reactive<PageData<ParkingCostForm, ParkingCostQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
areaId: undefined,
|
||||
parkingId: undefined,
|
||||
chargeItem: undefined,
|
||||
|
||||
@@ -173,6 +173,7 @@ async function handleEdit(id: string | number) {
|
||||
// 保存草稿
|
||||
async function handleSave(data: QuestionnaireForm) {
|
||||
try {
|
||||
console.log(data);
|
||||
// 父组件自己调用接口提交
|
||||
if (userid.value) {
|
||||
await updateQuestionnaire({
|
||||
@@ -181,8 +182,7 @@ async function handleSave(data: QuestionnaireForm) {
|
||||
status: '0', // 草稿状态
|
||||
startTime: timedata.value[0],
|
||||
endTime: timedata.value[1],
|
||||
...form.value,
|
||||
villageId: Number(localStorage.getItem('villageid'))
|
||||
...form.value
|
||||
});
|
||||
} else {
|
||||
await addQuestionnaire({
|
||||
@@ -191,8 +191,7 @@ async function handleSave(data: QuestionnaireForm) {
|
||||
status: '0', // 草稿状态
|
||||
startTime: timedata.value[0],
|
||||
endTime: timedata.value[1],
|
||||
...form.value,
|
||||
villageId: Number(localStorage.getItem('villageid'))
|
||||
...form.value
|
||||
});
|
||||
}
|
||||
ElMessage.success('保存成功');
|
||||
@@ -206,23 +205,24 @@ async function handleSave(data: QuestionnaireForm) {
|
||||
// 发布问卷
|
||||
async function handlePublish(data: QuestionnaireForm) {
|
||||
try {
|
||||
console.log(data);
|
||||
if (userid.value) {
|
||||
await updateQuestionnaire({
|
||||
...data,
|
||||
content: JSON.stringify(data.content),
|
||||
status: '1', // 发布状态
|
||||
startTime: timedata.value[0],
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
endTime: timedata.value[1]
|
||||
endTime: timedata.value[1],
|
||||
...form.value
|
||||
});
|
||||
} else {
|
||||
await addQuestionnaire({
|
||||
...data,
|
||||
content: JSON.stringify(data.content),
|
||||
status: '1', // 发布状态
|
||||
endTime: timedata.value[1],
|
||||
startTime: timedata.value[0],
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
endTime: timedata.value[1]
|
||||
...form.value
|
||||
});
|
||||
}
|
||||
ElMessage.success('发布成功');
|
||||
|
||||
@@ -155,7 +155,7 @@ function cloneComponent(component: ComponentItem): QuestionComponentItem {
|
||||
return {
|
||||
cid: Date.now(), // 生成唯一ID
|
||||
type: component.type,
|
||||
title: 'ces',
|
||||
title: '',
|
||||
required: true,
|
||||
options: component.type === 'radio' || component.type === 'checkbox' ? [{ label: '选项1' }, { label: '选项2' }] : []
|
||||
};
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<div class="flex flex-col h-full p-2">
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
<el-card shadow="hover">
|
||||
@@ -19,7 +19,7 @@
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<el-card class="flex-1" shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
@@ -129,7 +129,6 @@ const initFormData: QuestionnaireForm = {
|
||||
const data = reactive<PageData<QuestionnaireForm, QuestionnaireQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: undefined,
|
||||
@@ -249,3 +248,8 @@ onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.el-table {
|
||||
height: calc(100% - 80px);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -246,7 +246,6 @@ const submitForm = () => {
|
||||
|
||||
const sendForm = (str: string) => {
|
||||
form.value.problemImageUrl = str;
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateRepair(form.value).then((res) => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -118,7 +118,6 @@ init();
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (!userid.value) {
|
||||
addRepairProject(form.value).then(() => {
|
||||
ElMessage.success('添加成功');
|
||||
@@ -136,7 +135,7 @@ const submitForm = () => {
|
||||
// 推出
|
||||
const cancelForm = () => {
|
||||
router.push({
|
||||
path: '/repair/repairProjectList'
|
||||
path: '/system/repairProjectList'
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -127,7 +127,6 @@ const data = reactive<PageData<RepairForm, RepairQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
houseId: undefined,
|
||||
maintenanceItemId: undefined,
|
||||
problem: undefined,
|
||||
|
||||
@@ -186,7 +186,6 @@ const initFormData: RepairProjectForm = {
|
||||
const data = reactive<PageData<RepairProjectForm, RepairProjectQuery>>({
|
||||
form: { ...initFormData },
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
projectName: undefined,
|
||||
parentId: undefined,
|
||||
projectType: undefined,
|
||||
@@ -259,14 +258,14 @@ const handleSelectionChange = (selection: RepairProjectVO[]) => {
|
||||
/** 新增按钮操作 */
|
||||
const handleAdd = () => {
|
||||
router.push({
|
||||
path: '/repair/addRepairProjectList'
|
||||
path: '/system/addRepairProjectList'
|
||||
});
|
||||
};
|
||||
|
||||
/** 修改按钮操作 */
|
||||
const handleUpdate = async (row?: RepairProjectVO) => {
|
||||
router.push({
|
||||
path: '/repair/addRepairProjectList',
|
||||
path: '/system/addRepairProjectList',
|
||||
query: {
|
||||
id: row.id
|
||||
}
|
||||
|
||||
@@ -94,7 +94,6 @@ const data = reactive<PageData<VisitorForm, VisitorQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
houseId: undefined,
|
||||
visitorName: undefined,
|
||||
visitorGender: undefined,
|
||||
|
||||
@@ -61,7 +61,6 @@ const route = useRoute();
|
||||
const formRef = ref();
|
||||
const form = ref({
|
||||
id: null,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
areaName: null,
|
||||
areaCode: null,
|
||||
area: null,
|
||||
@@ -90,7 +89,6 @@ if (route.query.id) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (parkingid.value) {
|
||||
updateArea(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -97,7 +97,6 @@ const data = reactive<PageData<AreaForm, AreaQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
areaName: undefined,
|
||||
areaCode: undefined,
|
||||
area: undefined,
|
||||
|
||||
@@ -121,7 +121,6 @@ const form = ref({
|
||||
id: null,
|
||||
areaId: null, // 区域id
|
||||
residentId: null, // 车位id
|
||||
villageId: Number(localStorage.getItem('villageid')), // 小区id
|
||||
parkingId: null, // 持有人id
|
||||
carNum: '', //车牌号
|
||||
carBrand: '', //车辆品牌
|
||||
@@ -207,7 +206,6 @@ function changeArealist(val: string) {
|
||||
const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value.trim() !== '') {
|
||||
updateCar(form.value).then(() => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<div class="flex flex-col h-full p-2">
|
||||
<Pageheader title="车辆管理"></Pageheader>
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
@@ -23,7 +23,7 @@
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<el-card class="flex-1" shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
@@ -109,7 +109,6 @@ const data = reactive<PageData<CarForm, CarQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
areaId: undefined,
|
||||
parkingId: undefined,
|
||||
residentId: undefined,
|
||||
@@ -196,3 +195,8 @@ onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.el-table {
|
||||
height: calc(100% - 80px);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -50,7 +50,6 @@ import { useRouter } from 'vue-router';
|
||||
import { useHouseStore } from '@/store/modules/house';
|
||||
|
||||
const houseStore = useHouseStore();
|
||||
const { currentVilageInfo } = storeToRefs(houseStore);
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_build_use } = toRefs<any>(proxy?.useDict('com_build_use'));
|
||||
@@ -100,7 +99,6 @@ const submitForm = () => {
|
||||
if (buildingId) {
|
||||
editBuildingApi({
|
||||
...form.value,
|
||||
villageId: currentVilageInfo.value.villageId,
|
||||
id: buildingId
|
||||
})
|
||||
.then((res) => {
|
||||
@@ -113,8 +111,7 @@ const submitForm = () => {
|
||||
});
|
||||
} else {
|
||||
addBuildingApi({
|
||||
...form.value,
|
||||
villageId: currentVilageInfo.value.villageId
|
||||
...form.value
|
||||
})
|
||||
.then((res) => {
|
||||
ElMessage.success('添加成功');
|
||||
|
||||
@@ -4,19 +4,19 @@
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">基本信息</div>
|
||||
<div class="addBuildingFormBody">
|
||||
<el-form class="formBody" label-position="left" ref="formRef" :model="form" :rules="rules" label-width="100px">
|
||||
<el-form class="formBody" label-position="right" ref="formRef" :model="form" :rules="rules" label-width="100px">
|
||||
<el-form-item label="楼栋" prop="buildingId">
|
||||
<el-select @change="handlechangeBuild" v-model="form.buildingId" class="m-2" placeholder="请选择">
|
||||
<el-select @change="handlechangeBuild" v-model="form.buildingId" placeholder="请选择">
|
||||
<el-option v-for="item in houseStore.currentBuildingInfoList" :key="item.id" :label="item.buildingName" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="单元" prop="unit">
|
||||
<el-select v-model.number="form.unitNo" class="m-2" placeholder="请选择">
|
||||
<el-select v-model.number="form.unitNo" placeholder="请选择">
|
||||
<el-option v-for="item in units" :key="item.no" :label="item.name" :value="item.no" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="楼层" prop="floor">
|
||||
<el-select v-model.number="form.floorNo" class="m-2" placeholder="请选择">
|
||||
<el-select v-model.number="form.floorNo" placeholder="请选择">
|
||||
<el-option v-for="item in floors" :key="item.no" :label="item.name" :value="item.no" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
@@ -2,14 +2,13 @@
|
||||
<div class="TableBox p-5 h-full" v-if="houseStore.currentHouseInfoList !== null">
|
||||
<el-checkbox-group @change="handleChangeCheckhouses" v-model="houseStore.checkoutHouses">
|
||||
<el-table border :data="houseStore.currentFloorInfoList">
|
||||
<el-table-column align="center" fixed label="楼层\单元" min-width="85">
|
||||
<el-table-column align="center" fixed label="楼层\单元" max-width="100">
|
||||
<template #default="{ row }">
|
||||
<span>{{ row }}楼</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
min-width="160"
|
||||
class="column"
|
||||
align="center"
|
||||
:label="`${unit.unitNo}单元`"
|
||||
v-for="(unit, index) in houseStore.currentHouseInfoList?.units ?? []"
|
||||
@@ -74,11 +73,8 @@ function contextMenuFun(val: { type: string; value: string }) {
|
||||
|
||||
<style scoped lang="scss">
|
||||
.TableBox {
|
||||
overflow: hidden;
|
||||
flex: 1;
|
||||
.column {
|
||||
width: 200px;
|
||||
background-color: red;
|
||||
.el-table {
|
||||
height: calc(100% - 500px);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -77,6 +77,8 @@ $primary_color: #1978fe;
|
||||
}
|
||||
.UnitBody {
|
||||
flex: 1;
|
||||
overflow-x: hidden;
|
||||
overflow-y: auto;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">基本信息</div>
|
||||
<div class="addBuildingFormBody">
|
||||
<el-form class="formBody" label-position="left" ref="formRef" :model="form" :rules="rules" label-width="130px">
|
||||
<el-form class="formBody" label-position="right" ref="formRef" :model="form" :rules="rules" label-width="130px">
|
||||
<el-row>
|
||||
<el-col :span="11">
|
||||
<el-form-item label="房屋" prop="houseId">
|
||||
@@ -22,7 +22,7 @@
|
||||
<el-row>
|
||||
<el-col :span="11">
|
||||
<el-form-item label="租赁状态" prop="rentalStatus">
|
||||
<el-select v-model.number="form.rentalStatus" class="m-2" placeholder="请选择">
|
||||
<el-select v-model.number="form.rentalStatus" placeholder="请选择">
|
||||
<el-option v-for="(item, index) in com_rental_status" :key="index" :label="item.label" :value="Number(item.value)" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -30,7 +30,7 @@
|
||||
<el-col :span="2"></el-col>
|
||||
<el-col :span="11">
|
||||
<el-form-item label="房屋用途" prop="houseUse">
|
||||
<el-select v-model.number="form.houseUse" class="m-2" placeholder="请选择">
|
||||
<el-select v-model.number="form.houseUse" placeholder="请选择">
|
||||
<el-option v-for="(item, index) in com_house_use" :key="index" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -57,7 +57,7 @@
|
||||
<el-row>
|
||||
<el-col :span="11">
|
||||
<el-form-item label="房屋朝向" prop="type">
|
||||
<el-select v-model.number="form.houseFace" class="m-2" placeholder="请选择">
|
||||
<el-select v-model.number="form.houseFace" placeholder="请选择">
|
||||
<el-option v-for="(item, index) in houseformat" :key="index" :label="item" :value="item" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -202,7 +202,7 @@ const route = useRoute();
|
||||
|
||||
const formRef = ref();
|
||||
const houseformat = ['东', '西', '南', '北'];
|
||||
const form = ref<HouseRentalVO>({
|
||||
const form = ref({
|
||||
id: null,
|
||||
houseId: null,
|
||||
rentalName: '', // 租户姓名
|
||||
@@ -251,6 +251,8 @@ async function gettreedata() {
|
||||
...form.value,
|
||||
...res.data
|
||||
};
|
||||
console.log(form.value);
|
||||
housedeviceslist.value = form.value.facilities.split(',').filter((item) => item);
|
||||
const imgurllist = splitStringUrl(form.value.houseImageUrl);
|
||||
fileList.value = imgurllist;
|
||||
const arr = getHousePathById(treedata.value, form.value.houseId);
|
||||
@@ -354,7 +356,6 @@ const submitForm = () => {
|
||||
};
|
||||
const sendForm = (val: string) => {
|
||||
form.value.houseImageUrl = val;
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
// edit or add
|
||||
if (userid.value) {
|
||||
updateHouseRental(form.value).then(() => {
|
||||
@@ -363,8 +364,7 @@ const sendForm = (val: string) => {
|
||||
});
|
||||
} else {
|
||||
addHouseRental({
|
||||
...form.value,
|
||||
villageid: Number(localStorage.getItem('villageid'))
|
||||
...form.value
|
||||
}).then(() => {
|
||||
ElMessage.success('添加成功');
|
||||
cancelForm();
|
||||
|
||||
@@ -2,9 +2,12 @@
|
||||
<div class="AddBuildingBox">
|
||||
<PageHeader title="房屋租赁管理"></PageHeader>
|
||||
<div class="AddBuildingBody">
|
||||
<div class="title">
|
||||
<span>基础资料 </span>
|
||||
<span class="ml-20px color-blue cursor-pointer" @click="hanlededit">编辑</span>
|
||||
<div class="title flex flex-items-center flex-justify-between">
|
||||
<div>
|
||||
<span>基础资料 </span>
|
||||
<span class="ml-20px color-blue cursor-pointer" @click="hanlededit">编辑</span>
|
||||
</div>
|
||||
<el-button @click="handlBack" class="mr-10px">返回</el-button>
|
||||
</div>
|
||||
<div class="addBuildingFormBody">
|
||||
<div class="descriptionsbox">
|
||||
@@ -46,6 +49,7 @@
|
||||
<div class="label">房屋设施:</div>
|
||||
<div class="value">
|
||||
<DictTag :options="com_house_rental_facilities" :value="HouseInfo.facilities"></DictTag>
|
||||
<span v-for="item in HouseInfo.facilitieslist" :key="item">{{ handlefacilities(item.name) }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<el-row>
|
||||
@@ -86,6 +90,7 @@ import PageHeader from '@/components/Pageheader/index.vue';
|
||||
import { getHouseRental } from '@/api/system/houseRental';
|
||||
import { useHouseStore } from '@/store/modules/house';
|
||||
import { getHousePathById } from '@/utils/house';
|
||||
import { listHouseFacilities } from '@/api/system/HouseFacilities';
|
||||
|
||||
const houseStore = useHouseStore();
|
||||
const { treedata } = storeToRefs(houseStore);
|
||||
@@ -97,8 +102,7 @@ const route = useRoute();
|
||||
const router = useRouter();
|
||||
const houseRentalid = ref(null);
|
||||
const HouseInfo = ref({
|
||||
'id': '',
|
||||
house: '',
|
||||
'house': '',
|
||||
'name': null,
|
||||
'rentalStatus': null,
|
||||
'rentalName': '',
|
||||
@@ -118,14 +122,21 @@ const HouseInfo = ref({
|
||||
'houseUse': '',
|
||||
'pubBy': null,
|
||||
'pubTime': '',
|
||||
houseImageUrls: []
|
||||
'facilitieslist': [],
|
||||
'houseImageUrls': []
|
||||
});
|
||||
function init() {
|
||||
|
||||
const housefacilities = ref([]);
|
||||
async function init() {
|
||||
if (route.query.id) {
|
||||
houseRentalid.value = route.query.id;
|
||||
}
|
||||
const reslist = await listHouseFacilities();
|
||||
housefacilities.value = reslist.rows;
|
||||
|
||||
getHouseRental(houseRentalid.value).then((res) => {
|
||||
HouseInfo.value = res.data;
|
||||
HouseInfo.value.facilitieslist = res.data.facilities.split(',').filter((item) => item);
|
||||
HouseInfo.value.houseImageUrls = HouseInfo.value.houseImageUrl.split(',').filter((item) => item);
|
||||
const arr = getHousePathById(treedata.value, HouseInfo.value.houseId, 'label');
|
||||
HouseInfo.value.house = arr.join(' - ');
|
||||
@@ -133,6 +144,10 @@ function init() {
|
||||
}
|
||||
init();
|
||||
|
||||
function handlefacilities(id: string) {
|
||||
const find = housefacilities.value.find((item) => item.id === id);
|
||||
}
|
||||
|
||||
function hanlededit() {
|
||||
router.push({
|
||||
path: '/house/addhouseRental',
|
||||
@@ -141,6 +156,12 @@ function hanlededit() {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function handlBack() {
|
||||
router.push({
|
||||
path: '/house/houseRental'
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
@@ -129,7 +129,6 @@ const data = reactive<PageData<HouseRentalForm, HouseRentalQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
houseUse: '',
|
||||
rentalName: undefined,
|
||||
rent: undefined,
|
||||
|
||||
@@ -100,7 +100,6 @@ const form = ref({
|
||||
residentId: null, // 住户id
|
||||
parkingStatus: '', // 车位状态
|
||||
remark: '', // 备注
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
parkingCode: '' // 车位编码
|
||||
});
|
||||
const rules = ref({
|
||||
@@ -142,7 +141,6 @@ const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
form.value.residentId = holderInfo.value;
|
||||
form.value.villageId = Number(localStorage.getItem('villageid'));
|
||||
if (userid.value) {
|
||||
updateParking(form.value).then((res) => {
|
||||
ElMessage.success('编辑成功');
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="p-2">
|
||||
<div class="h-full flex flex-col p-2">
|
||||
<Pageheader title="车位管理"></Pageheader>
|
||||
<transition :enter-active-class="proxy?.animate.searchAnimate.enter" :leave-active-class="proxy?.animate.searchAnimate.leave">
|
||||
<div v-show="showSearch" class="mb-[10px]">
|
||||
@@ -27,7 +27,7 @@
|
||||
</div>
|
||||
</transition>
|
||||
|
||||
<el-card shadow="never">
|
||||
<el-card class="flex-1" shadow="never">
|
||||
<template #header>
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
@@ -129,7 +129,6 @@ const data = reactive<PageData<ParkingForm, ParkingQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
areaId: undefined,
|
||||
parkingCode: undefined,
|
||||
parkingArea: undefined,
|
||||
@@ -138,8 +137,7 @@ const data = reactive<PageData<ParkingForm, ParkingQuery>>({
|
||||
residentId: undefined,
|
||||
addTime: undefined,
|
||||
addBy: undefined,
|
||||
checkStatus: undefined,
|
||||
params: {}
|
||||
checkStatus: undefined
|
||||
}
|
||||
});
|
||||
|
||||
@@ -217,3 +215,9 @@ onMounted(() => {
|
||||
getList();
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.el-table {
|
||||
height: calc(100% - 80px);
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
<div class="actions mt-5">
|
||||
<el-button type="primary">审核通过</el-button>
|
||||
<el-button type="danger">审核不通过</el-button>
|
||||
<el-button>返回</el-button>
|
||||
<el-button @click="handlBacK">返回</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -232,6 +232,11 @@ function handleActivestaus(rews) {
|
||||
|
||||
console.log(active.value);
|
||||
}
|
||||
|
||||
const router = useRouter();
|
||||
function handlBacK() {
|
||||
router.back();
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
@@ -28,9 +28,7 @@
|
||||
</div>
|
||||
<div class="userinfo_item">
|
||||
<div class="title_item">住户类型:</div>
|
||||
<span v-if="userInfo.type === 0"> 业主 </span>
|
||||
<span v-else-if="userInfo.type === 1"> 亲戚 </span>
|
||||
<span v-else> 租户 </span>
|
||||
<DictTag :options="com_resident_relationship" :value="userInfo.type"></DictTag>
|
||||
</div>
|
||||
<div class="userinfo_item">
|
||||
<div class="title_item">住户来源:</div>
|
||||
@@ -71,7 +69,7 @@
|
||||
<div class="userinfo_item img">
|
||||
<div class="title_item">身份证背面:</div>
|
||||
<div class="userinfo_itme_img">
|
||||
<el-image class="w-full h-full" fit="fill" :src="userInfo.cardImageFront"></el-image>
|
||||
<el-image class="w-full h-full" fit="fill" :src="`/${userInfo.cardImageFront}`"></el-image>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
@@ -149,6 +147,7 @@ import { ResidentVO } from '@/api/system/resident/type';
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_review } = toRefs<any>(proxy?.useDict('com_review'));
|
||||
const { com_sub_status } = toRefs<any>(proxy?.useDict('com_sub_status'));
|
||||
const { com_resident_relationship } = toRefs<any>(proxy?.useDict('com_resident_relationship'));
|
||||
const { com_certification_status } = toRefs<any>(proxy?.useDict('com_certification_status'));
|
||||
|
||||
const userInfo = ref<ResidentVO>({
|
||||
@@ -183,13 +182,18 @@ const reviewInfo = ref({
|
||||
const active = ref(0);
|
||||
const userid = ref(null);
|
||||
const route = useRoute();
|
||||
|
||||
if (route.query.id) {
|
||||
userid.value = route.query.id;
|
||||
// 获取住户信息
|
||||
getResident(userid.value).then((res) => {
|
||||
userInfo.value = res.data;
|
||||
// 获取 审核流程
|
||||
getresidentReviewlistAPI(userid.value).then((res) => {
|
||||
console.log(res);
|
||||
if (res.rows[0]) {
|
||||
reviewInfo.value = res.rows[0];
|
||||
console.log(reviewInfo.value);
|
||||
handleActivestaus(reviewInfo.value);
|
||||
}
|
||||
});
|
||||
@@ -228,11 +232,9 @@ const activeStop = computed(() => {
|
||||
case 0:
|
||||
break;
|
||||
case 1:
|
||||
status = 1;
|
||||
break;
|
||||
case 2:
|
||||
case 3:
|
||||
status = 2;
|
||||
status = 1;
|
||||
break;
|
||||
case 4:
|
||||
case 5:
|
||||
@@ -249,9 +251,13 @@ const activeStop = computed(() => {
|
||||
function updatePass(val: '0' | '1' | '2') {
|
||||
reviewInfo.value = {
|
||||
...reviewInfo.value,
|
||||
// 审核时间
|
||||
'propertyTime': new Date().toLocaleString().replaceAll('/', '-'),
|
||||
'propertyStatus': val
|
||||
// 审核状态
|
||||
'propertyStatus': val,
|
||||
'residentId': userid.value
|
||||
};
|
||||
console.log(reviewInfo.value);
|
||||
update();
|
||||
}
|
||||
|
||||
|
||||
@@ -234,8 +234,7 @@ const submitForm = () => {
|
||||
// return ElMessage.error('请上传身份证背面照片');
|
||||
// }
|
||||
const obj = {
|
||||
...form.value,
|
||||
villageId: Number(localStorage.getItem('villageid'))
|
||||
...form.value
|
||||
};
|
||||
if (userid.value) {
|
||||
updateResident(obj).then(() => {
|
||||
|
||||
@@ -15,15 +15,6 @@
|
||||
<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-date-picker
|
||||
v-model="queryParams.date"
|
||||
type="date"
|
||||
placeholder="开始日期~结束日期"
|
||||
:disabled-date="disabledDate"
|
||||
:shortcuts="shortcuts"
|
||||
/>
|
||||
</el-form-item> -->
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||
@@ -78,7 +69,7 @@
|
||||
<el-table-column label="操作" align="center" min-width="120" fixed="right" class-name="small-padding fixed-width">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
v-if="scope.row.status === '0'"
|
||||
v-if="scope.row.status !== '1'"
|
||||
link
|
||||
type="primary"
|
||||
icon="Edit"
|
||||
@@ -114,7 +105,32 @@ import { getHousePathById } from '@/utils/house';
|
||||
import { useHouseStore } from '@/store/modules/house';
|
||||
|
||||
const houseStore = useHouseStore();
|
||||
const { currentVilageInfo } = storeToRefs(houseStore);
|
||||
const currentVilageInfo = ref({
|
||||
'villageId': null,
|
||||
'villageName': '',
|
||||
'villageCode': '',
|
||||
'city': '',
|
||||
'address': '',
|
||||
'completDate': '',
|
||||
'houseUse': 0,
|
||||
'villageArea': null,
|
||||
'parkingSpaceCount': null,
|
||||
'villageImageUrl': '',
|
||||
'status': '0',
|
||||
'remark': '',
|
||||
'manageName': '',
|
||||
'managePhone': '',
|
||||
'manageQq': '',
|
||||
'manageVx': '',
|
||||
'manageEmail': ''
|
||||
});
|
||||
|
||||
function init() {
|
||||
houseStore.getviliageinfo(localStorage.getItem('villageid')).then((res) => {
|
||||
currentVilageInfo.value = res;
|
||||
});
|
||||
}
|
||||
init();
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_resident_relationship } = toRefs<any>(proxy?.useDict('com_resident_relationship'));
|
||||
@@ -153,7 +169,6 @@ const data = reactive<PageData<ResidentForm, ResidentQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
date: '',
|
||||
type: null,
|
||||
status: null,
|
||||
|
||||
@@ -129,8 +129,7 @@ const submitForm = () => {
|
||||
formRef.value?.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
const data = {
|
||||
...form.value,
|
||||
villageId: Number(localStorage.getItem('villageid'))
|
||||
...form.value
|
||||
};
|
||||
if (storeRoomid.value !== null) {
|
||||
updateStoreroom(data).then(() => {
|
||||
|
||||
@@ -106,7 +106,6 @@ const data = reactive<PageData<StoreroomForm, StoreroomQuery>>({
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
buildingId: undefined,
|
||||
unitNo: undefined,
|
||||
storeroomNo: undefined,
|
||||
|
||||
@@ -415,7 +415,7 @@ const resetQuery = () => {
|
||||
/** 删除按钮操作 */
|
||||
const handleDelete = async (row?: UserVO) => {
|
||||
const userIds = row?.userId || ids.value;
|
||||
const [err] = await to(proxy?.$modal.confirm('是否确认删除员工编号为"' + userIds + '"的数据项?') as any);
|
||||
const [err] = await to(proxy?.$modal.confirm('是否确认删除?') as any);
|
||||
if (!err) {
|
||||
await api.delUser(userIds);
|
||||
await getList();
|
||||
|
||||
@@ -25,10 +25,6 @@
|
||||
<svg-icon icon-class="email" />用户邮箱
|
||||
<div class="pull-right">{{ state.user.email }}</div>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<svg-icon icon-class="tree" />所属部门
|
||||
<div v-if="state.user.deptName" class="pull-right">{{ state.user.deptName }} / {{ state.postGroup }}</div>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<svg-icon icon-class="peoples" />所属角色
|
||||
<div class="pull-right">{{ state.roleGroup }}</div>
|
||||
@@ -55,9 +51,9 @@
|
||||
<el-tab-pane label="修改密码" name="resetPwd">
|
||||
<resetPwd />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="第三方应用" name="thirdParty">
|
||||
<!-- <el-tab-pane label="第三方应用" name="thirdParty">
|
||||
<thirdParty :auths="state.auths" />
|
||||
</el-tab-pane>
|
||||
</el-tab-pane> -->
|
||||
<el-tab-pane label="在线设备" name="onlineDevice">
|
||||
<onlineDevice :devices="state.devices" />
|
||||
</el-tab-pane>
|
||||
|
||||
@@ -1,183 +1,234 @@
|
||||
<template>
|
||||
<div class="w-full h-full workBenchBox">
|
||||
<el-row>
|
||||
<el-col :span="18">
|
||||
<div class="villageBox">
|
||||
<div class="title">小区概况</div>
|
||||
<div class="villageBody">
|
||||
<div class="village_items" v-for="(item, index) in list" :key="index">
|
||||
<div class="icon"></div>
|
||||
<div class="infobox">
|
||||
<div class="infoTitle">{{ item.name }}</div>
|
||||
<div class="infoNum">{{ item.value }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="echartsbox flex flex-items-center">
|
||||
<div class="echarts">
|
||||
<div class="nav flex flex-items-center justify-between">
|
||||
<div>
|
||||
<span class="ecarts_title">近一周报修量趋势</span>
|
||||
<span class="echarts_units">单位(个)</span>
|
||||
</div>
|
||||
<div class="flex flex-items-center justify-center">
|
||||
<span class="echarts_all_baoxiu">全部保修</span>
|
||||
<i class="echarts_all_arrow"></i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="echartsbody">
|
||||
<repairEcharts />
|
||||
</div>
|
||||
</div>
|
||||
<div class="echarts">
|
||||
<div class="nav flex flex-items-center justify-between">
|
||||
<div>
|
||||
<span class="ecarts_title">近一周收入支出趋势</span>
|
||||
<span class="echarts_units">单位(个)</span>
|
||||
</div>
|
||||
<div class="flex flex-items-center justify-center">
|
||||
<div
|
||||
class="actions"
|
||||
@click="changeActive_index(index)"
|
||||
:class="{ active: active_index === index }"
|
||||
v-for="(item, index) in actions"
|
||||
:key="index"
|
||||
>
|
||||
{{ item.name }}
|
||||
<!-- 外层缩放容器 -->
|
||||
<div class="scale-container">
|
||||
<div class="w-full h-full workBenchBox">
|
||||
<el-row>
|
||||
<el-col :span="18">
|
||||
<div class="villageBox">
|
||||
<div class="title">小区概况</div>
|
||||
<div class="villageBody">
|
||||
<div class="village_items" v-for="(item, index) in list" :key="index">
|
||||
<div class="icon">
|
||||
<el-image :src="item.icon"></el-image>
|
||||
</div>
|
||||
<div class="infobox">
|
||||
<div class="infoTitle">{{ item.name }}</div>
|
||||
<div class="infoNum">{{ item.value }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="echartsbody">
|
||||
<repairEcharts />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<div class="villageInfoBox">
|
||||
<div class="iconbox">
|
||||
<el-image :src="summicon"></el-image>
|
||||
</div>
|
||||
<div class="villageinfo">
|
||||
<div class="villagename">北境碧桂园小区</div>
|
||||
<div class="week">2025-08-20 星期三</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tabsbox">
|
||||
<div class="topbox">
|
||||
<div
|
||||
:class="{
|
||||
active: Sideactive === 1
|
||||
}"
|
||||
@click="handleSelect(1)"
|
||||
>
|
||||
<span>快捷入口</span>
|
||||
<i></i>
|
||||
</div>
|
||||
<div
|
||||
:class="{
|
||||
active: Sideactive === 2
|
||||
}"
|
||||
@click="handleSelect(2)"
|
||||
>
|
||||
<span>创建办事记录</span>
|
||||
<i class="righti"></i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="body">
|
||||
<div class="quicly_box" v-if="Sideactive === 1">
|
||||
<div class="quickly_item" v-for="(item, index) in quickBox" :key="index">
|
||||
<div class="quickly_item_icon"></div>
|
||||
<div class="quickly_item_content">{{ item.name }}</div>
|
||||
<div class="echartsbox flex flex-items-center">
|
||||
<div class="echarts">
|
||||
<div class="nav flex flex-items-center justify-between">
|
||||
<div>
|
||||
<span class="ecarts_title">近一周报修量趋势</span>
|
||||
<span class="echarts_units">单位(个)</span>
|
||||
</div>
|
||||
<div class="flex flex-items-center justify-center">
|
||||
<span class="echarts_all_baoxiu">全部保修</span>
|
||||
<i class="echarts_all_arrow"></i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="quickly_item add">
|
||||
<el-icon><Plus /></el-icon>
|
||||
<span>添加</span>
|
||||
<div class="echartsbody">
|
||||
<repairEcharts />
|
||||
</div>
|
||||
</div>
|
||||
<div class="echarts">
|
||||
<div class="nav flex flex-items-center justify-between">
|
||||
<div>
|
||||
<span class="ecarts_title">近一周收入支出趋势</span>
|
||||
<span class="echarts_units">单位(个)</span>
|
||||
</div>
|
||||
<div class="flex flex-items-center justify-center">
|
||||
<div
|
||||
class="actions"
|
||||
@click="changeActive_index(index)"
|
||||
:class="{ active: active_index === index }"
|
||||
v-for="(item, index) in actions"
|
||||
:key="index"
|
||||
>
|
||||
{{ item.name }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="echartsbody">
|
||||
<repairEcharts />
|
||||
</div>
|
||||
</div>
|
||||
<div v-else></div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row class="mt-20px">
|
||||
<el-col>
|
||||
<div class="userBox">
|
||||
<div class="title">住户查询</div>
|
||||
<div class="searbox">
|
||||
<div>精准查询</div>
|
||||
<el-select v-model="value" placeholder="住户姓名" style="width: 240px">
|
||||
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
<el-input placeholder="请输入">
|
||||
<template #prefix>
|
||||
<el-icon><Search /></el-icon>
|
||||
</template>
|
||||
</el-input>
|
||||
<el-button type="primary">查询 </el-button>
|
||||
<el-button>重置</el-button>
|
||||
</el-col>
|
||||
<!-- tabs -->
|
||||
<el-col :span="6">
|
||||
<div class="villageInfoBox">
|
||||
<div class="iconbox">
|
||||
<el-image :src="summicon"></el-image>
|
||||
</div>
|
||||
<div class="villageinfo">
|
||||
<div class="villagename">北境碧桂园小区</div>
|
||||
<div class="week">2025-08-20 星期三</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tablebox">
|
||||
<el-table :data="tableData" stripe style="width: 100%">
|
||||
<el-table-column type="index" :index="indexMethod" label="序号" width="60" align="center" />
|
||||
<el-table-column prop="date" align="center" label="姓名" width="180" />
|
||||
<el-table-column prop="date" align="center" label="类型" width="180" />
|
||||
<el-table-column prop="date" align="center" label="状态" width="180" />
|
||||
<el-table-column prop="date" align="center" label="证件号码" />
|
||||
<el-table-column prop="date" align="center" label="手机号" />
|
||||
<el-table-column prop="name" align="center" label="房间" />
|
||||
<el-table-column prop="address" align="center" label="操作">
|
||||
<template #default>
|
||||
<el-button type="primary" text> 审核</el-button>
|
||||
<el-button type="primary" text> 编辑</el-button>
|
||||
<el-button type="primary" text> 删除</el-button>
|
||||
<div class="tabsbox">
|
||||
<div class="topbox">
|
||||
<div
|
||||
:class="{
|
||||
active: Sideactive === 1
|
||||
}"
|
||||
@click="handleSelect(1)"
|
||||
>
|
||||
<span>快捷入口</span>
|
||||
<i></i>
|
||||
</div>
|
||||
<div
|
||||
:class="{
|
||||
active: Sideactive === 2
|
||||
}"
|
||||
@click="handleSelect(2)"
|
||||
>
|
||||
<span>创建办事记录</span>
|
||||
<i class="righti"></i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="body">
|
||||
<div class="quicly_box" v-if="Sideactive === 1">
|
||||
<div class="quickly_item" v-for="(item, index) in quickBox" :key="index" @click="handleRouter(item.url)">
|
||||
<div class="quickly_item_icon"></div>
|
||||
<div class="quickly_item_content">{{ item.name }}</div>
|
||||
</div>
|
||||
<div class="quickly_item add">
|
||||
<el-icon><Plus /></el-icon>
|
||||
<span>添加</span>
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<div class="noticeNav">
|
||||
<div>创建办事记录</div>
|
||||
<el-button type="primary">提交</el-button>
|
||||
</div>
|
||||
<div class="noticeBox">
|
||||
<el-form label-position="top">
|
||||
<el-form-item label="需求方姓名">
|
||||
<el-input placeholder="请输入姓名" v-model="noticForm.seekName"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="办事时间">
|
||||
<el-date-picker
|
||||
v-model="noticForm.handleTime"
|
||||
type="datetime"
|
||||
clearable
|
||||
placeholder="年-月-日 时:分"
|
||||
value-format="YYYY-MM-DD HH:MM"
|
||||
format="YYYY-MM-DD HH:MM"
|
||||
>
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="办事内容">
|
||||
<el-input type="textarea" v-model="noticForm.content" :rows="2" placeholder="请输入办事内容"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="附件">
|
||||
<el-upload
|
||||
v-model:file-list="fileList"
|
||||
class="upload-demo"
|
||||
action="https://run.mocky.io/v3/9d059bf9-4660-45f2-925d-ce80ad6c4d15"
|
||||
multiple
|
||||
>
|
||||
<div class="uploadBtn flex flex-items-center">
|
||||
<el-icon><Upload /></el-icon>
|
||||
<span>上传文件</span>
|
||||
</div>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!-- table -->
|
||||
<el-row class="mt-20px">
|
||||
<el-col>
|
||||
<div class="userBox">
|
||||
<div class="title">住户查询</div>
|
||||
<div class="searbox">
|
||||
<div>精准查询</div>
|
||||
<el-select v-model="seachervalue" placeholder="住户姓名" style="width: 240px">
|
||||
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value" />
|
||||
</el-select>
|
||||
<el-input v-model="searchInput" placeholder="请输入">
|
||||
<template #prefix>
|
||||
<el-icon><Search /></el-icon>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:total="total"
|
||||
v-model:page="queryParams.pageNum"
|
||||
v-model:limit="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
</el-input>
|
||||
<el-button type="primary" @click="handleSearch">查询 </el-button>
|
||||
<el-button>重置</el-button>
|
||||
</div>
|
||||
<div class="tablebox">
|
||||
<el-table :data="tableData" stripe style="width: 100%">
|
||||
<el-table-column type="index" :index="indexMethod" label="序号" width="60" align="center" />
|
||||
<el-table-column prop="name" align="center" label="姓名" width="180" />
|
||||
<el-table-column prop="type" align="center" label="类型" width="180">
|
||||
<template #default="scope">
|
||||
<DictTag :options="com_resident_type" :value="scope.row.status"></DictTag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="status" align="center" label="状态" width="180">
|
||||
<template #default="scope">
|
||||
<DictTag :options="com_review" :value="scope.row.type"></DictTag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="idCard" align="center" label="证件号码" />
|
||||
<el-table-column prop="phone" align="center" label="手机号" />
|
||||
<el-table-column prop="houseName" align="center" label="房间" />
|
||||
<el-table-column prop="address" align="center" label="操作">
|
||||
<template #default>
|
||||
<el-button type="primary" text> 审核</el-button>
|
||||
<el-button type="primary" text> 编辑</el-button>
|
||||
<el-button type="primary" text> 删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<pagination
|
||||
v-show="total > 0"
|
||||
:background="false"
|
||||
:total="total"
|
||||
v-model:page="queryParams.pageNum"
|
||||
v-model:limit="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import summicon from '@/assets/images/index/summer.png';
|
||||
import repairEcharts from './components/repairEcharts.vue';
|
||||
import { listResident } from '@/api/system/resident';
|
||||
|
||||
import icon1 from '@/assets/images/index/1.png';
|
||||
import icon2 from '@/assets/images/index/2.png';
|
||||
import icon3 from '@/assets/images/index/3.png';
|
||||
import icon5 from '@/assets/images/index/5.png';
|
||||
import icon6 from '@/assets/images/index/6.png';
|
||||
import { UploadUserFile } from 'element-plus';
|
||||
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
const { com_resident_type } = toRefs<any>(proxy?.useDict('com_resident_type'));
|
||||
const { com_review } = toRefs<any>(proxy?.useDict('com_review'));
|
||||
|
||||
const list = ref([
|
||||
{
|
||||
name: '住户总数量',
|
||||
value: 10000
|
||||
},
|
||||
{
|
||||
name: '房屋总数量',
|
||||
value: 458
|
||||
},
|
||||
{
|
||||
name: '车位总数量',
|
||||
value: 2539
|
||||
},
|
||||
{
|
||||
name: '设备总数量',
|
||||
value: 22
|
||||
},
|
||||
{
|
||||
name: '物料总数量',
|
||||
value: 458
|
||||
},
|
||||
{
|
||||
name: '投诉总数量',
|
||||
value: 458
|
||||
}
|
||||
{ name: '住户总数量', value: 10000, icon: icon1 },
|
||||
{ name: '房屋总数量', value: 458, icon: icon2 },
|
||||
{ name: '车位总数量', value: 2539, icon: icon3 },
|
||||
{ name: '设备总数量', value: 22, icon: icon5 },
|
||||
{ name: '物料总数量', value: 458, icon: icon6 },
|
||||
{ name: '投诉总数量', value: 458, icon: icon6 }
|
||||
]);
|
||||
// ! echarts 切换
|
||||
const active_index = ref(0);
|
||||
const actions = ref([
|
||||
{
|
||||
@@ -193,13 +244,13 @@ const actions = ref([
|
||||
function changeActive_index(val: number) {
|
||||
active_index.value = val;
|
||||
}
|
||||
// ! echarts 切换
|
||||
// ! 侧边栏
|
||||
const Sideactive = ref(1);
|
||||
function handleSelect(val: number) {
|
||||
Sideactive.value = val;
|
||||
console.log(Sideactive.value);
|
||||
}
|
||||
|
||||
// ! 侧边栏
|
||||
// ! 快捷入口
|
||||
const quickBox = ref([
|
||||
{
|
||||
@@ -227,21 +278,33 @@ const quickBox = ref([
|
||||
url: '/repair/visitorList'
|
||||
}
|
||||
]);
|
||||
|
||||
const router = useRouter();
|
||||
function handleRouter(val: string) {
|
||||
router.push({
|
||||
path: val
|
||||
});
|
||||
}
|
||||
// ! table
|
||||
const value = ref('');
|
||||
const loading = ref(true);
|
||||
// ! 快捷入口
|
||||
|
||||
// ! 创建办事记录
|
||||
const noticForm = ref({
|
||||
seekName: '',
|
||||
phone: '',
|
||||
handleTime: '',
|
||||
content: '',
|
||||
handlePosition: '',
|
||||
file: ''
|
||||
});
|
||||
const fileList = ref<UploadUserFile[]>([]);
|
||||
// ! 创建办事记录
|
||||
|
||||
// ! table
|
||||
const seachervalue = ref('');
|
||||
const searchInput = ref('');
|
||||
const loading = ref(true);
|
||||
const total = ref(100);
|
||||
const data = reactive({
|
||||
queryParams: {
|
||||
villageId: Number(localStorage.getItem('villageid')),
|
||||
pageNum: 1,
|
||||
pageSize: 10
|
||||
}
|
||||
@@ -253,54 +316,42 @@ const indexMethod = (index) => {
|
||||
};
|
||||
const options = [
|
||||
{
|
||||
value: 'Option1',
|
||||
value: 'name',
|
||||
label: '住户姓名'
|
||||
},
|
||||
{
|
||||
value: 'Option2',
|
||||
value: 'phone',
|
||||
label: '住户手机号'
|
||||
},
|
||||
{
|
||||
value: 'Option3',
|
||||
value: 'idCard',
|
||||
label: '住户身份证'
|
||||
}
|
||||
];
|
||||
function getList() {}
|
||||
const tableData = ref([
|
||||
{
|
||||
date: '2016-05-03',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-02',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-04',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
},
|
||||
{
|
||||
date: '2016-05-01',
|
||||
name: 'Tom',
|
||||
address: 'No. 189, Grove St, Los Angeles'
|
||||
}
|
||||
]);
|
||||
function handleSearch() {
|
||||
queryParams[seachervalue.value] = searchInput.value;
|
||||
getList();
|
||||
}
|
||||
const tableData = ref([]);
|
||||
async function getList() {
|
||||
const res = await listResident(queryParams.value);
|
||||
tableData.value = res.rows;
|
||||
}
|
||||
getList();
|
||||
// ! table
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
.workBenchBox {
|
||||
padding: 20px;
|
||||
background-color: #eaf2ff;
|
||||
// 小区概况
|
||||
.villageBox {
|
||||
height: 198px;
|
||||
background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, #ffffff 70%);
|
||||
border-radius: 16px 16px 16px 16px;
|
||||
border: 2px solid #ffffff;
|
||||
padding: 20px;
|
||||
margin-bottom: 20px;
|
||||
margin-bottom: 10px;
|
||||
.title {
|
||||
height: 25px;
|
||||
font-weight: 500;
|
||||
@@ -313,15 +364,19 @@ const tableData = ref([
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-around;
|
||||
flex-wrap: wrap; /* 自动换行 */
|
||||
gap: 16px;
|
||||
.village_items {
|
||||
margin-right: 20px;
|
||||
min-width: 185px;
|
||||
height: 109px;
|
||||
flex: 1;
|
||||
min-width: 160px; /* 小屏自动单列 */
|
||||
|
||||
margin-right: 10px;
|
||||
min-height: 109px;
|
||||
background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, #ffffff 100%);
|
||||
box-shadow: 0px 4px 8px 0px rgba(0, 104, 255, 0.06);
|
||||
border-radius: 8px 8px 8px 8px;
|
||||
border: 1px solid #ffffff;
|
||||
padding: 30px 20px;
|
||||
padding-left: 20px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.icon {
|
||||
@@ -332,11 +387,14 @@ const tableData = ref([
|
||||
border-radius: 10px 10px 10px 10px;
|
||||
border: 1px solid #ffffff;
|
||||
margin-right: 15px;
|
||||
.el-image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.infobox {
|
||||
margin-right: 20px;
|
||||
.infoTitle {
|
||||
width: 70px;
|
||||
height: 18px;
|
||||
font-weight: 400;
|
||||
font-size: 14px;
|
||||
@@ -344,7 +402,6 @@ const tableData = ref([
|
||||
line-height: 18px;
|
||||
}
|
||||
.infoNum {
|
||||
width: 87px;
|
||||
height: 35px;
|
||||
font-weight: 600;
|
||||
font-size: 28px;
|
||||
@@ -358,10 +415,11 @@ const tableData = ref([
|
||||
|
||||
// echarts
|
||||
.echartsbox {
|
||||
height: inherit;
|
||||
.echarts {
|
||||
margin-right: 20px;
|
||||
flex: 1;
|
||||
height: 425px;
|
||||
height: 450px;
|
||||
background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, #ffffff 70%);
|
||||
border: 2px solid #ffffff;
|
||||
border-radius: 12px;
|
||||
@@ -469,7 +527,6 @@ const tableData = ref([
|
||||
// tabs
|
||||
.tabsbox {
|
||||
margin-left: 20px;
|
||||
height: 497px;
|
||||
border: 2px solid;
|
||||
background: linear-gradient(180deg, #ebf4ff 0%, rgba(247, 252, 255, 0.5) 21.14%);
|
||||
border-image: linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0)) 2 2;
|
||||
@@ -478,7 +535,7 @@ const tableData = ref([
|
||||
align-items: center;
|
||||
div {
|
||||
flex: 1;
|
||||
border-bottom: 2px solid #fff;
|
||||
border-bottom: 4px solid;
|
||||
border-image: linear-gradient(to bottom, #fff, rgba(255, 255, 255, 0)) 100% 1;
|
||||
text-align: center;
|
||||
padding: 14px;
|
||||
@@ -497,7 +554,7 @@ const tableData = ref([
|
||||
position: absolute;
|
||||
right: 10px;
|
||||
top: 0;
|
||||
width: $width / 2;
|
||||
width: calc($width / 2);
|
||||
height: 100%;
|
||||
transform: skew(30deg);
|
||||
background: white;
|
||||
@@ -529,7 +586,7 @@ const tableData = ref([
|
||||
position: absolute;
|
||||
left: 10px;
|
||||
top: 0;
|
||||
width: $width / 2;
|
||||
width: calc($width / 2);
|
||||
height: 100%;
|
||||
transform: skew(-30deg);
|
||||
background: white;
|
||||
@@ -576,12 +633,17 @@ const tableData = ref([
|
||||
.body {
|
||||
font-size: 16px;
|
||||
color: #222222;
|
||||
padding: 30px;
|
||||
padding: 20px;
|
||||
.quicly_box {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: start;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
|
||||
.quickly_item {
|
||||
width: 125px;
|
||||
min-width: 30%;
|
||||
max-width: 33%;
|
||||
margin-bottom: 20px;
|
||||
height: 56px;
|
||||
background: #ffffff;
|
||||
@@ -590,6 +652,10 @@ const tableData = ref([
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
cursor: pointer;
|
||||
&:hover {
|
||||
background-color: #0084ff09;
|
||||
}
|
||||
.quickly_item_content {
|
||||
margin-left: 5px;
|
||||
width: 64px;
|
||||
@@ -610,6 +676,37 @@ const tableData = ref([
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.noticeNav {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.noticeBox {
|
||||
:deep(.el-date-editor.el-input, .el-date-editor.el-input__wrapper) {
|
||||
width: 100%;
|
||||
}
|
||||
.upload-demo,
|
||||
:deep(.el-upload.el-upload--text) {
|
||||
width: 100%;
|
||||
}
|
||||
.uploadBtn {
|
||||
height: 30px;
|
||||
line-height: 20px;
|
||||
border-radius: 5px;
|
||||
background-color: rgba(255, 255, 255, 1);
|
||||
color: rgba(16, 16, 16, 1);
|
||||
padding-left: 20px;
|
||||
font-size: 14px;
|
||||
border: 1px solid rgba(204, 204, 204, 1);
|
||||
width: 100%;
|
||||
border: 1px solid #ccc;
|
||||
span {
|
||||
margin-left: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -617,13 +714,12 @@ const tableData = ref([
|
||||
.userBox {
|
||||
border-radius: 10px;
|
||||
padding: 20px;
|
||||
height: 550px;
|
||||
background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, #ffffff 70%);
|
||||
border: 2px solid #ffffff;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
.title {
|
||||
margin-bottom: 15px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.searbox {
|
||||
height: 35px;
|
||||
@@ -631,7 +727,7 @@ const tableData = ref([
|
||||
font-size: 16px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 30px;
|
||||
margin-bottom: 20px;
|
||||
div {
|
||||
width: 70px;
|
||||
margin-right: 20px;
|
||||
|
||||
Reference in New Issue
Block a user