feat:搜索条件修改

This commit is contained in:
2025-12-13 16:26:30 +08:00
parent cbe9fc9ead
commit 93c9715e78

View File

@ -12,22 +12,6 @@
<!-- 搜索 --> <!-- 搜索 -->
<div ref="searchBox" v-if="search"> <div ref="searchBox" v-if="search">
<Searchs :searchArr="searchConfiger" @submit="onSearch" :key="pageData.keyCount"> <Searchs :searchArr="searchConfiger" @submit="onSearch" :key="pageData.keyCount">
<template #defaultSlot>
<el-form-item label="预警类型" prop="yjlx">
<el-select v-model="listQuery.yjlx" placeholder="请选择预警类型">
<el-option v-for="item in D_BZ_YJLX" :key="item.value" :label="item.label" :value="item.value" />
</el-select>
</el-form-item>
<!-- <el-select @change="gettbGsxtBqglSelectList" v-model="queryFrom.sfdl" placeholder="请选择身份类型"
style="width: 100%">
<el-option :label="item.label" :value="item.value" v-for="(item, index) in bqLbData.bqDl" :key="index" />
</el-select> -->
</template>
<!-- <template #nameSlot>
<el-select v-model="queryFrom.sfxl" placeholder="请选择身份类型" style="width: 100%">
<el-option :label="item.label" :value="item.value" v-for="(item, index) in bqLbData.bqXl" :key="index" />
</el-select>
</template> -->
</Searchs> </Searchs>
</div> </div>
<!-- 表格 --> <!-- 表格 -->
@ -46,6 +30,7 @@
<template #yjlb="{ row }"> <template #yjlb="{ row }">
<DictTag :value="row.yjlb" :options="D_BZ_YJLX" /> <DictTag :value="row.yjlb" :options="D_BZ_YJLX" />
</template> </template>
<!-- <template #yjjb="{ row }"> <!-- <template #yjjb="{ row }">
<DictTag :value="row.yjjb" :tag="false" :color="bqYs(row.yjjb)" :options="D_BZ_YJJB" /> <DictTag :value="row.yjjb" :tag="false" :color="bqYs(row.yjjb)" :options="D_BZ_YJJB" />
</template> --> </template> -->
@ -105,15 +90,20 @@ const searchBox = ref();
const { D_BZ_YJLX, D_BZ_HPZL, D_BZ_YJJB, D_GS_ZDQT_YJLB } = proxy.$dict("D_BZ_YJLX", "D_BZ_HPZL", "D_BZ_YJJB", "D_GS_ZDQT_YJLB") const { D_BZ_YJLX, D_BZ_HPZL, D_BZ_YJJB, D_GS_ZDQT_YJLB } = proxy.$dict("D_BZ_YJLX", "D_BZ_HPZL", "D_BZ_YJJB", "D_GS_ZDQT_YJLB")
// 搜索配置 // 搜索配置
const searchConfiger = ref([ const searchConfiger = ref([
{ label: "姓名", prop: 'ryxm', placeholder: "请输入姓名", showType: "input" }, // { label: "姓名", prop: 'ryxm', placeholder: "请输入姓名", showType: "input" },
{ label: "身份证号码", prop: 'rysfzh', placeholder: "请输入身份证号码", showType: "input" }, // { label: "身份证号码", prop: 'rysfzh', placeholder: "请输入身份证号码", showType: "input" },
{ label: "车牌号", prop: 'cph', placeholder: "请输入车牌号", showType: "input" },//yjClcph // { label: "车牌号", prop: 'cph', placeholder: "请输入车牌号", showType: "input" },//yjClcph
{ label: "预警类型", prop: 'yjlb', placeholder: "请选择预警类型", showType: "select", options: [] }, { label: "预警类型", prop: 'yjlxList', placeholder: "请选择预警类型", showType: "select", options: [],multiple:true },
{ label: "号牌类型", prop: 'hplx', placeholder: "请选择号牌类型", showType: "select", options: [] }, { label: "预警级别", prop: 'yjjbList', placeholder: "请选择预警级别", showType: "select", options: [],multiple:true },
{ label: "预警类别", prop: 'yjlbList', placeholder: "请选择预警级别", showType: "select", options: [],multiple:true },
// { label: "号牌类型", prop: 'hplx', placeholder: "请选择号牌类型", showType: "select", options: [] },
]); ]);
const queryFrom = ref({}); const queryFrom = ref({});
const bqLbData = ref({}); const bqLbData = ref({});
const listQuery = reactive({
yjlx: []
})
const pageData = reactive({ const pageData = reactive({
tableData: [], //表格数据 tableData: [], //表格数据
keyCount: 0, keyCount: 0,
@ -141,18 +131,22 @@ const pageData = reactive({
// { label: "预警地址", prop: "yjdz", showOverflowTooltip: true }, // { label: "预警地址", prop: "yjdz", showOverflowTooltip: true },
{ label: "预警标签", prop: "yjbq", showOverflowTooltip: true }, { label: "预警标签", prop: "yjbq", showOverflowTooltip: true },
{ label: "预警级别", prop: "yjjb", showSolt: true, showOverflowTooltip: true }, { label: "预警级别", prop: "yjjb", showSolt: true, showOverflowTooltip: true },
{ label: "预警类", prop: "yjlb", showSolt: true }, { label: "预警类", prop: "yjlb", showSolt: true },
{ label: "预警类型", prop: "yjlx", showSolt: true },
// { label: "身份次数", prop: "sfcs", showSlot: true }, // { label: "身份次数", prop: "sfcs", showSlot: true },
{ label: "身份分值", prop: "sffz" }, { label: "身份分值", prop: "sffz" },
{ label: "预警内容", prop: "yjnr", showOverflowTooltip: true }, { label: "预警内容", prop: "yjnr", showOverflowTooltip: true },
] ]
}); });
// yjlb // 预警类别 D_BZ_YJLX 1人像 2车辆。。
// yjjb // 预警级别 D_BZ_YJJB 01红 02绿03蓝 。。
// yjlx 预警类型 D_GS_ZDQT_YJLB 01布控 02 身份预警 .。。
onMounted(() => { onMounted(() => {
tabHeightFn(); tabHeightFn();
// 初始化搜索配置的选项 // 初始化搜索配置的选项
searchConfiger.value[3].options = D_BZ_YJLX; searchConfiger.value[0].options = D_GS_ZDQT_YJLB;
searchConfiger.value[4].options = D_BZ_HPZL; searchConfiger.value[1].options = D_BZ_YJJB;
searchConfiger.value[2].options = D_BZ_YJLX;
getList() getList()
}); });
@ -181,6 +175,9 @@ const getList = (val) => {
pageCurrent: pageData.pageConfiger.pageCurrent, pageCurrent: pageData.pageConfiger.pageCurrent,
pageSize: pageData.pageConfiger.pageSize pageSize: pageData.pageConfiger.pageSize
} }
if(listQuery.yjlxList?.length) promes.yjlxList = listQuery.yjlxList;
if(listQuery.yjjbList?.length) promes.yjjbList = listQuery.yjjbList;
if(listQuery.yjlbList?.length) promes.yjlbList = listQuery.yjlbList;
qcckPost(promes, '/mosty-gsxt/tbYjxx/selectYjxxFzPage').then((res) => { qcckPost(promes, '/mosty-gsxt/tbYjxx/selectYjxxFzPage').then((res) => {
pageData.tableData = res.records || []; pageData.tableData = res.records || [];
pageData.total = res.total; pageData.total = res.total;
@ -193,10 +190,10 @@ const getList = (val) => {
// 处理签收 // 处理签收
const handleToImportantMan = (val, type) => { const handleToImportantMan = (val, type) => {
proxy.$confirm("是否确定转重点人?", "警告", { type: "warning" }).then(() => { proxy.$confirm("是否确定转重点人?", "警告", { type: "warning" }).then(() => {
// qcckPost({ id: val.id }, "/mosty-gsxt/jfpm/yjqs").then(() => { qcckGet({}, `/mosty-gsxt/tbYjxx/yjToZdry/${val.id}`).then(() => {
// proxy.$message({ type: "success", message: "转重点人成功" }); proxy.$message({ type: "success", message: "转重点人成功" });
// getList() getList()
// }); });
}) })
} }
@ -221,7 +218,7 @@ const openAddFrom = (row) => {
} }
const handleClick = (row) => { const handleClick = (row) => {
console.log('点击了身份:', row);
} }
// 根据身份分值设置行样式 // 根据身份分值设置行样式
@ -256,7 +253,10 @@ const tabHeightFn = () => {
}; };
// 搜索 // 搜索
const onSearch = () => { const onSearch = (obj) => {
listQuery.yjlxList = obj.yjlxList || null
listQuery.yjjbList = obj.yjjbList || null
listQuery.yjlbList = obj.yjlbList || null
getList() getList()
} }