|
@@ -2,24 +2,37 @@
|
|
|
<!-- 全流程管理列表组件 -->
|
|
|
<div id="WholeProcessManagement">
|
|
|
<el-form :inline="true" ref="myTaskForm" :model="formInline" style="padding: 10px">
|
|
|
- <el-form-item label="任务类型">
|
|
|
- <el-select size="mini" v-model="formInline.taskType" placeholder="任务类型">
|
|
|
- <el-option-group v-for="group in taskTypeOptions" :key="group.label" :label="group.label">
|
|
|
- <el-option v-for="item in group.options" :key="item.value" :label="item.label" :value="item.value"> </el-option>
|
|
|
- </el-option-group>
|
|
|
+ <el-form-item label="项目类型">
|
|
|
+ <el-select size="mini" v-model="formInline.c_task_type" placeholder="项目类型" clearable filterable>
|
|
|
+ <el-option
|
|
|
+ v-for="item in selectSelectDataMap['projectType']"
|
|
|
+ :key="item.index"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.index"
|
|
|
+ ></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="关联项目">
|
|
|
- <el-select size="mini" v-model="formInline.associatedItems" placeholder="关联项目">
|
|
|
- <el-option v-for="item in associatedItemsOptions" :key="item.value" :label="item.label" :value="item.value">
|
|
|
+ <el-form-item label="所属街镇">
|
|
|
+ <el-select size="mini" v-model="formInline.c_owning_street_town" placeholder="所属街镇" clearable filterable>
|
|
|
+ <el-option
|
|
|
+ v-for="item in selectSelectDataMap['associatedItems']"
|
|
|
+ :key="item.index"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.index"
|
|
|
+ >
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="审计状态">
|
|
|
- <el-select size="mini" v-model="formInline.auditStatus" placeholder="审计状态">
|
|
|
- <el-option label="已审核" value="ReviewedAndApproved"></el-option>
|
|
|
- <el-option label="未审核" value="NotReviewed"></el-option>
|
|
|
- </el-select>
|
|
|
+ <el-form-item label="创建时间">
|
|
|
+ <el-date-picker
|
|
|
+ size="mini"
|
|
|
+ v-model="formInline.c_create_date"
|
|
|
+ type="daterange"
|
|
|
+ range-separator="至"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
</el-form-item>
|
|
|
<el-form-item style="float: right">
|
|
|
<el-button type="primary" @click="onSubmit">查询</el-button>
|
|
@@ -27,6 +40,7 @@
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
<el-table
|
|
|
+ v-loading="tableInitLoading"
|
|
|
:data="tableData"
|
|
|
style="width: calc(100% - 20px); padding: 0 10px"
|
|
|
height="calc(80vh - 400px)"
|
|
@@ -35,15 +49,23 @@
|
|
|
@row-click="rowClick"
|
|
|
>
|
|
|
<el-table-column type="index" width="50"> </el-table-column>
|
|
|
- <el-table-column prop="taskId" label="任务编号"> </el-table-column>
|
|
|
- <el-table-column prop="taskName" label="任务名称"> </el-table-column>
|
|
|
- <el-table-column prop="createDate" label="创建时间"> </el-table-column>
|
|
|
- <el-table-column prop="state" label="状态">
|
|
|
+ <el-table-column prop="c_project_id" label="项目编号"> </el-table-column>
|
|
|
+ <el-table-column prop="c_project_name" label="项目名称"> </el-table-column>
|
|
|
+ <el-table-column prop="c_task_type" label="项目类型">
|
|
|
<template slot-scope="scope">
|
|
|
- <el-tag :type="scope.row.state === '已审核' ? 'success' : 'info'" disable-transitions>{{ scope.row.state }}</el-tag>
|
|
|
+ {{ getSelectByIndex("projectType", scope.row.c_task_type) }}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="c_owning_street_town" label="所属街镇">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{ getSelectByIndex("associatedItems", scope.row.c_owning_street_town) }}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="c_create_date" label="创建时间">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{ $dayjs(scope.row.c_create_date).format("YYYY-MM-DD HH:mm:ss") }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="taskType" label="任务类型"> </el-table-column>
|
|
|
</el-table>
|
|
|
<div id="WholeProcessManagement-footer">
|
|
|
<Pagination :paginationData="paginationData" />
|
|
@@ -65,118 +87,26 @@ export default {
|
|
|
components: { StepsMyBox, Pagination },
|
|
|
data() {
|
|
|
return {
|
|
|
+ tableInitLoading: true,
|
|
|
+ // 数据字典暂存对象
|
|
|
+ selectSelectDataMap: {
|
|
|
+ projectType: [],
|
|
|
+ associatedItems: []
|
|
|
+ },
|
|
|
StepsMyBoxShowState: false,
|
|
|
// 查询条件
|
|
|
formInline: {
|
|
|
- taskType: "",
|
|
|
- associatedItems: "",
|
|
|
- auditStatus: ""
|
|
|
+ c_task_type: "",
|
|
|
+ c_owning_street_town: "",
|
|
|
+ c_create_date: ""
|
|
|
},
|
|
|
- // 任务类型options
|
|
|
- taskTypeOptions: [
|
|
|
- {
|
|
|
- label: "全部类型",
|
|
|
- options: [
|
|
|
- {
|
|
|
- value: "all",
|
|
|
- label: "全部类型"
|
|
|
- }
|
|
|
- ]
|
|
|
- },
|
|
|
- {
|
|
|
- label: "基本类型",
|
|
|
- options: [
|
|
|
- {
|
|
|
- value: "landResources",
|
|
|
- label: "土地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "ecologicalResources",
|
|
|
- label: "生态资源"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "forestLandResources",
|
|
|
- label: "林地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "waterResources",
|
|
|
- label: "水资源"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "townAreaTopic",
|
|
|
- label: "镇域专题"
|
|
|
- }
|
|
|
- ]
|
|
|
- },
|
|
|
- {
|
|
|
- label: "土地资源",
|
|
|
- options: [
|
|
|
- {
|
|
|
- value: "lr_bfm",
|
|
|
- label: "基本农田监控"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "lr_soclr",
|
|
|
- label: "建设用地减量化监管"
|
|
|
- }
|
|
|
- ]
|
|
|
- }
|
|
|
- ],
|
|
|
- // 关联项目options
|
|
|
- associatedItemsOptions: [
|
|
|
- {
|
|
|
- value: "1",
|
|
|
- label: "项目1"
|
|
|
- },
|
|
|
- {
|
|
|
- value: "2",
|
|
|
- label: "项目2"
|
|
|
- }
|
|
|
- ],
|
|
|
// 我的任务form表单
|
|
|
- tableData: [
|
|
|
- {
|
|
|
- createDate: "2016-05-03",
|
|
|
- taskName: "任务名称",
|
|
|
- taskId: "任务编号",
|
|
|
- state: "已审核",
|
|
|
- taskType: "土地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- createDate: "2016-05-03",
|
|
|
- taskName: "任务名称",
|
|
|
- taskId: "任务编号",
|
|
|
- state: "未审核",
|
|
|
- taskType: "土地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- createDate: "2016-05-03",
|
|
|
- taskName: "任务名称",
|
|
|
- taskId: "任务编号",
|
|
|
- state: "已审核",
|
|
|
- taskType: "土地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- createDate: "2016-05-03",
|
|
|
- taskName: "任务名称",
|
|
|
- taskId: "任务编号",
|
|
|
- state: "已审核",
|
|
|
- taskType: "土地资源"
|
|
|
- },
|
|
|
- {
|
|
|
- createDate: "2016-05-03",
|
|
|
- taskName: "任务名称",
|
|
|
- taskId: "任务编号",
|
|
|
- state: "已审核",
|
|
|
- taskType: "土地资源"
|
|
|
- }
|
|
|
- ],
|
|
|
+ tableData: [],
|
|
|
paginationData: {
|
|
|
- pageSize: 0,
|
|
|
- pagerCount: 5,
|
|
|
+ pageSize: 5,
|
|
|
currentPage: 1,
|
|
|
pageSizes: [5, 10, 20, 50],
|
|
|
- total: 200,
|
|
|
+ total: 0,
|
|
|
currentChange: val => {
|
|
|
this.handleCurrentChange(val);
|
|
|
},
|
|
@@ -187,28 +117,128 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
props: {},
|
|
|
- mounted() {},
|
|
|
+ mounted() {
|
|
|
+ // 首先获取数据字典中的下拉框数据
|
|
|
+ this.selectSelectData("0", "审计类别", "projectType");
|
|
|
+ this.selectSelectData("0", "浦东新区行政区划", "associatedItems");
|
|
|
+ this.onSubmit();
|
|
|
+ },
|
|
|
watch: {},
|
|
|
methods: {
|
|
|
+ // 数据字典查询
|
|
|
+ selectSelectData(type, cName, keyName) {
|
|
|
+ let params = new FormData();
|
|
|
+ params.append("type", type);
|
|
|
+ params.append("cName", cName);
|
|
|
+ this.$Post(this.urlsCollection.selectByCNameAType, params).then(
|
|
|
+ res => {
|
|
|
+ if (res.code === 200 && res.content.length > 0) {
|
|
|
+ this.selectSelectDataMap[keyName] = res.content;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ this.$message.error(error);
|
|
|
+ console.log(error);
|
|
|
+ }
|
|
|
+ );
|
|
|
+ },
|
|
|
+ // 数据字典对照显示
|
|
|
+ getSelectByIndex(selectName, index) {
|
|
|
+ let slotValue = "";
|
|
|
+ if (this.selectSelectDataMap[selectName] && this.selectSelectDataMap[selectName].length > 0) {
|
|
|
+ this.selectSelectDataMap[selectName].forEach(item => {
|
|
|
+ if (item.index == index) {
|
|
|
+ slotValue = item.name;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }
|
|
|
+ return slotValue;
|
|
|
+ },
|
|
|
// 切换条数
|
|
|
handleSizeChange(val) {
|
|
|
console.log(`每页 ${val} 条`);
|
|
|
- this.paginationData.currentPage = val;
|
|
|
+ this.paginationData.pageSize = val;
|
|
|
+ this.onSubmit();
|
|
|
},
|
|
|
// 切换页
|
|
|
handleCurrentChange(val) {
|
|
|
console.log(`当前页: ${val}`);
|
|
|
+ this.paginationData.currentPage = val;
|
|
|
+ this.onSubmit();
|
|
|
},
|
|
|
// 查询事件
|
|
|
onSubmit() {
|
|
|
- console.log("submit!");
|
|
|
+ if(!this.tableInitLoading){
|
|
|
+ this.tableInitLoading = true;
|
|
|
+ }
|
|
|
+ let params = new FormData();
|
|
|
+ params.append("columnId", "60");
|
|
|
+ params.append("states", "3");
|
|
|
+ params.append("pageSize", this.paginationData.pageSize);
|
|
|
+ params.append("page", this.paginationData.currentPage - 1);
|
|
|
+ let searchParam = [];
|
|
|
+ if (this.formInline.c_task_type) {
|
|
|
+ let param1 = {
|
|
|
+ field: "c_task_type",
|
|
|
+ searchType: "1",
|
|
|
+ content: {
|
|
|
+ value: this.formInline.c_task_type
|
|
|
+ }
|
|
|
+ };
|
|
|
+ searchParam.push(param1);
|
|
|
+ }
|
|
|
+ if (this.formInline.c_owning_street_town) {
|
|
|
+ let param1 = {
|
|
|
+ field: "c_owning_street_town",
|
|
|
+ searchType: "1",
|
|
|
+ content: {
|
|
|
+ value: this.formInline.c_owning_street_town
|
|
|
+ }
|
|
|
+ };
|
|
|
+ searchParam.push(param1);
|
|
|
+ }
|
|
|
+ if (this.formInline.c_create_date) {
|
|
|
+ let param1 = {
|
|
|
+ field: "c_create_date",
|
|
|
+ searchType: "3",
|
|
|
+ content: {
|
|
|
+ start: this.formInline.c_create_date[0],
|
|
|
+ end: this.formInline.c_create_date[0]
|
|
|
+ }
|
|
|
+ };
|
|
|
+ searchParam.push(param1);
|
|
|
+ }
|
|
|
+ params.append("search", JSON.stringify(searchParam));
|
|
|
+ this.$Post(this.urlsCollection.selectContentList, params).then(
|
|
|
+ res => {
|
|
|
+ if (res.code === 200 && res.content.count > 0) {
|
|
|
+ this.paginationData.total = res.content.count;
|
|
|
+ console.log("请求到的总条数为:", res.content.count, this.paginationData.total);
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ console.log(error);
|
|
|
+ }
|
|
|
+ );
|
|
|
+ this.$Post(this.urlsCollection.selectContentListInfo, params).then(
|
|
|
+ res => {
|
|
|
+ if (res.code === 200 && res.content.length > 0) {
|
|
|
+ this.tableData = res.content;
|
|
|
+ this.tableInitLoading = false;
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ this.tableInitLoading = false;
|
|
|
+ console.log(error);
|
|
|
+ }
|
|
|
+ );
|
|
|
},
|
|
|
// 查询条件重置
|
|
|
resetForm() {
|
|
|
this.formInline = {
|
|
|
- taskType: "",
|
|
|
- associatedItems: "",
|
|
|
- auditStatus: ""
|
|
|
+ c_task_type: "",
|
|
|
+ c_owning_street_town: "",
|
|
|
+ c_create_date: ""
|
|
|
};
|
|
|
this.onSubmit();
|
|
|
},
|