'保安项目提交'

This commit is contained in:
esacpe
2025-09-22 09:01:41 +08:00
commit 21e2a12e3c
1439 changed files with 336271 additions and 0 deletions

View File

@ -0,0 +1,95 @@
<template>
<div class="dialog" v-if="dialogForm">
<div class="head_box">
<span class="title">临时任务统计详情</span>
<div>
<el-button size="small" @click="close">关闭</el-button>
</div>
</div>
<div class="cntinfo">
<el-form :model="listQuery" label-position="right">
<el-form-item label="任务名称">
<el-input v-model="listQuery.rwmc" placeholder="请输入任务名称" />
</el-form-item>
<el-form-item label="所属辖区">
<el-input v-model="listQuery.ssbm" placeholder="请输入所属辖区" />
</el-form-item>
<el-form-item label="任务地点">
<el-input v-model="listQuery.rwdz" placeholder="请输入任务地点" />
</el-form-item>
<el-form-item label="任务时间">
<el-input v-model="listQuery.rwsj" placeholder="请输入任务时间" />
</el-form-item>
<el-form-item label="任务类型">
<el-select :disabled="true" v-model="listQuery.rwlx" placeholder="请选择任务类型">
<el-option v-for="item in dic.D_BZ_JBLDRWLX" :key="item" :label="item.zdmc" :value="item.dm"></el-option>
</el-select>
</el-form-item>
<el-form-item label="任务状态">
<el-select :disabled="true" v-model="listQuery.rwzt" placeholder="请选择任务状态">
<el-option v-for="item in dic.JBLDRWZT" :key="item" :label="item.zdmc" :value="item.dm"></el-option>
</el-select>
</el-form-item>
<el-form-item label="任务描述" style="width:100%">
<el-input type="textarea" style="width:100%" v-model="listQuery.rwms" placeholder="请输入任务描述" :rows="4" />
</el-form-item>
</el-form>
</div>
</div>
</template>
<script setup>
import { qcckGet, qcckPost, qcckDelete } from "@/api/qcckApi.js";
import { ref, reactive } from 'vue';
const props = defineProps({
dic: {
type: Object,
default: {}
}
})
const dialogForm = ref(false);
const listQuery = ref({});
// 初始化数据
const init = (row) => {
dialogForm.value = true;
// 根据type和row初始化表单数据
qcckGet({ id: row.id }, "/mosty-jbld/rw/selectByid").then(res => {
listQuery.value = res;
})
};
const close = () => {
dialogForm.value = false;
FormRef.value.reset()
};;
defineExpose({ init })
</script>
<style lang="scss" scoped>
.dialog {
padding: 20px;
.head_box {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 20px;
}
.cntinfo {
height: calc(100% - 70px);
overflow: hidden;
overflow-y: auto;
}
::v-deep .el-form{
display: flex;
flex-wrap: wrap;
padding: 0 12rem;
.el-form-item--default{
width: 23%;
margin-right: 20px;
}
}
}
</style>

View File

@ -0,0 +1,128 @@
<template>
<div>
<Search :searchArr="searchConfiger" @submit="onSearch" />
</div>
<div class="Count-Cnt flex">
<div class="left">
<MyTable :tableData="pageData.tableData" :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
:tableColumn="pageData.tableColumn" :tableHeight="pageData.tableHeight" :key="pageData.keyCount"
:tableConfiger="pageData.tableConfiger">
</MyTable>
</div>
<div class="right">
<BarHatEcharts echartsId="counrtEchars" :data='obj'></BarHatEcharts>
</div>
</div>
</template>
<script setup>
import { qcckGet} from "@/api/qcckApi.js";
import MyTable from "@/components/aboutTable/MyTable.vue";
import BarHatEcharts from "@/components/echarts/barHatEcharts.vue";
import Search from "@/components/aboutTable/Search.vue";
import { ref, onMounted, reactive } from "vue";
const searchConfiger = ref([
{ label: "时间段", prop: "time", showType: "daterange" },
]);
const obj = ref({
xDate: [],
list: []
})
const paramsObj = ref({})
const pageData = reactive({
tableData: [],
keyCount: 0,
tableHeight: 620,
tableConfiger: {
rowHieght: 61,
showSelectType: "null",
loading: false,
haveControls: false,
showIndex: false,
rowKey: 'ssbmdm',
lazy: false
},
controlsWidth: 100, // No controls needed based on prototype
tableColumn: [
{ label: "", prop: "mc" },
{ label: "跟踪侦察", prop: "xlzsl" },
{ label: "人员线索", prop: "xlrs" },
]
});
onMounted(() => {
getData()
});
const getData = () => {
qcckGet(paramsObj.value, "/mosty-jbld/rw/getRwtj").then(res => {
if (res && res.length > 0) {
pageData.tableColumn = res[0].list.map((el) => {
return { label: el.zdmc, prop: el.py }
})
pageData.tableColumn.unshift({ label: "", prop: "mc" })
pageData.tableData = res.map((item) => {
let big = {};
big.mc = item.ssbm;
big.ssbmdm = item.ssbmdm;
item.list.forEach((el) => {
big[el.py] = el.count
})
return big
})
obj.value.list = res[0]?.list.map((el) => {
return { name: el.zdmc, value: [], hatColor: '#087df9', color: ['rgba(0,244,255,1)', 'rgba(0,77,167,1)'] }
})
obj.value.list?.forEach((w) => {
res.forEach((el) => {
el.list.forEach((item) => {
if (w.name == item.zdmc) {
w.value.push(item.count)
}
})
})
})
obj.value.xDate = res.map((el) => el.ssbm)
}
})
}
const onSearch = (params) => {
if (params.time.length > 0) {
paramsObj.value.kssj = params.time[0]
paramsObj.value.jssj = params.time[1]
}
getData()
};
// 获取统计数据
const getCount = () =>{
qcckGet({},'/mosty-jbld/rw/getRwtj').then(res=>{
console.log(res,'============00');
let arr = res || [];
})
}
</script>
<style lang="scss" scoped>
.Count-Cnt {
width: 100%;
height: calc(100vh - 267px);
/* Adjust height as needed */
background: #fff;
padding: 10px;
box-sizing: border-box;
.left {
width: 500px;
height: 100%;
}
.right {
flex: 1 0 0;
margin-left: 10px;
height: 100%;
border: 1px solid #e9e9e9;
}
}
</style>

View File

@ -0,0 +1,31 @@
<template>
<div>
<div class="titleBox">
<PageTitle title="临时任务管理">
<el-button @click="activeName = '列表'">列表</el-button>
<el-button @click="activeName = '统计图表'">统计图表</el-button>
</PageTitle>
</div>
<Count v-if="activeName == '统计图表'"></Count>
<ListTable @lookDetail="lookDetail" v-if="activeName == '列表'" :dic="{ D_BZ_JBLDRWLX, JBLDRWZT }"></ListTable>
<!-- 详情 -->
<DetailForm ref="detailDiloag" :dic="{ D_BZ_JBLDRWLX, JBLDRWZT }" />
</div>
</template>
<script setup>
import DetailForm from "./components/detailForm.vue";
import PageTitle from "@/components/aboutTable/PageTitle.vue";
import { reactive, ref, defineEmits, onMounted, getCurrentInstance } from "vue";
import ListTable from "./listTable.vue";
import Count from "./count.vue";
const { proxy } = getCurrentInstance();
const { D_BZ_JBLDRWLX, JBLDRWZT } = proxy.$dict("D_BZ_JBLDRWLX", "JBLDRWZT");
const activeName = ref("列表");
const detailDiloag = ref();
const lookDetail = (row) => {
detailDiloag.value.init(row);
};
</script>
<style></style>

View File

@ -0,0 +1,142 @@
<template>
<!-- 搜索 -->
<div ref="searchBox">
<Search :searchArr="searchConfiger" @submit="onSearch" :key="pageData.keyCount" />
</div>
<!-- 表格 -->
<div class="tabBox">
<MyTable :tableData="pageData.tableData" :tableColumn="pageData.tableColumn" :tableHeight="pageData.tableHeight"
:key="pageData.keyCount" :tableConfiger="pageData.tableConfiger" :controlsWidth="pageData.controlsWidth"
@chooseData="chooseData">
<template #rwlx="{ row }">
<dict-tag :options="dic.D_BZ_JBLDRWLX" :value="row.rwlx" :tag="false" />
</template>
<template #controls="{ row }">
<el-link type="primary" link @click="addEdit(row)">详情</el-link>
</template>
</MyTable>
<Pages @changeNo="changeNo" @changeSize="changeSize" :tableHeight="pageData.tableHeight" :pageConfiger="{
...pageData.pageConfiger,
total: pageData.total
}"></Pages>
</div>
</template>
<script setup>
import MyTable from "@/components/aboutTable/MyTable.vue";
import Pages from "@/components/aboutTable/Pages.vue";
import Search from "@/components/aboutTable/Search.vue";
import { qcckGet, qcckPost, qcckDelete } from "@/api/qcckApi.js"; // Temporarily comment out as API logic might change
import { reactive, ref, defineEmits, onMounted, getCurrentInstance } from "vue";
const { proxy } = getCurrentInstance();
const props = defineProps({
dic: {
type: Object,
default: {}
}
})
const emit = defineEmits(["lookDetail"]);
const queryFrom = ref({})
const searchBox = ref(); //搜索框
const searchConfiger = ref([
{
label: "任务名称",
prop: "rwmc",
placeholder: "请输入任务名称",
showType: "input"
},
{
label: "所属辖区",
prop: "ssbmdm",
placeholder: "请选择所属辖区",
showType: "department"
},
{
label: "任务类型",
prop: "rwlx",
placeholder: "请选择任务类型",
showType: "select",
options:props.dic.D_BZ_JBLDRWLX
}
]);
const pageData = reactive({
tableData: [],
keyCount: 0,
tableConfiger: {
rowHieght: 61,
showSelectType: "null",
loading: false,
showIndex: true
},
total: 5,
pageConfiger: {
pageSize: 20,
pageCurrent: 1
},
controlsWidth: 100,
tableColumn: [
{ label: "任务名称", prop: "rwmc" },
{ label: "所属辖区", prop: "ssbm" },
{ label: "任务地点", prop: "rwdz" },
{ label: "任务时间", prop: "rwsj" },
{ label: "任务类型", prop: "rwlx", showSolt: true }
]
});
onMounted(() => {
getList();
tabHeightFn();
});
// 搜索
const onSearch = (val) => {
queryFrom.value = { ...val };
pageData.pageConfiger.pageCurrent = 1;
getList();
};
const changeNo = (val) => {
pageData.pageConfiger.pageNum = val;
getList();
};
const changeSize = (val) => {
pageData.pageConfiger.pageSize = val;
getList();
};
// 获取列表
const getList = (val) => {
// Mock data is used for now, uncomment and adapt API call when needed
pageData.tableConfiger.loading = true;
let data = { ...pageData.pageConfiger, ...queryFrom.value };
let url = "/mosty-jbld/rw/selectPage"; // Example API endpoint
qcckGet(data, url)
.then((res) => {
pageData.tableData = res.records || [];
pageData.total = res.total;
pageData.tableConfiger.loading = false;
})
.catch(() => {
pageData.tableConfiger.loading = false;
});
};
const addEdit = (row) => {
emit("lookDetail", row);
};
// 表格高度计算
const tabHeightFn = () => {
pageData.tableHeight =
window.innerHeight - searchBox.value.offsetHeight - 250;
window.onresize = function () {
tabHeightFn();
};
};
const evaluate = (row) => {
emit("evaluate", row);
};
</script>
<style></style>