Commit 03a2859d by liangzhen

赛选项目

1 parent e551d5e3
...@@ -291,6 +291,10 @@ export function iPageRorm(params) { ...@@ -291,6 +291,10 @@ export function iPageRorm(params) {
export function auditTasks(params) { export function auditTasks(params) {
return post(`${ARCH_EVALUATION}/auditTasks/`, params) return post(`${ARCH_EVALUATION}/auditTasks/`, params)
} }
//自动稽核任务配置 全部项目
export function selProjectList(params) {
return post(`${ARCH_EVALUATION}/auditTasks/selProjectList`, params)
}
//新增自动稽核任务配置 //新增自动稽核任务配置
export function addauditTasks(params) { export function addauditTasks(params) {
return post(`${ARCH_EVALUATION}/auditTasks/ad`, params) return post(`${ARCH_EVALUATION}/auditTasks/ad`, params)
......
...@@ -408,39 +408,6 @@ ...@@ -408,39 +408,6 @@
<el-form-item class="RuleItem"> <el-form-item class="RuleItem">
<span class="zjquery" @click="checkRules()"> 查询 </span> <span class="zjquery" @click="checkRules()"> 查询 </span>
</el-form-item> </el-form-item>
<!-- <el-form-item label="检查说明:" prop="checkDesc" class="fromItem">
<el-input
v-model="ruleFormRule.checkDesc"
placeholder="请输入"
clearable
></el-input>
</el-form-item> -->
<!-- <el-form-item label="规则状态:" prop="ruleStatus" class="fromItem">
<el-select
v-model="ruleFormRule.ruleStatus"
placeholder="请选择"
clearable
>
<el-option label="开启" value="0"></el-option>
<el-option label="关闭" value="1"></el-option>
</el-select>
</el-form-item> -->
<!-- <el-form-item label="创建人:" prop="creator" class="fromItem">
<el-input
v-model="ruleFormRule.creator"
placeholder="请输入"
clearable
></el-input>
</el-form-item> -->
<!-- <el-form-item label="创建时间:" prop="createTime" class="fromItem">
<el-date-picker
v-model="ruleFormRule.createTime"
type="date"
placeholder="选择日期"
>
</el-date-picker>
</el-form-item> -->
</el-form> </el-form>
<div class="setscrolldialog"> <div class="setscrolldialog">
<el-table <el-table
...@@ -697,7 +664,7 @@ ...@@ -697,7 +664,7 @@
<p class="zjBtn">稽核规则</p> <p class="zjBtn">稽核规则</p>
<div class="setscrolldialogAdd"> <div class="setscrolldialogAdd">
<el-table <el-table
:data="XQtableData" :data="addtableData"
tooltip-effect="dark myTooltips" tooltip-effect="dark myTooltips"
style="width: 100%" style="width: 100%"
header-cell-class-name="custom-th-background" header-cell-class-name="custom-th-background"
...@@ -758,20 +725,20 @@ ...@@ -758,20 +725,20 @@
</el-table> </el-table>
</div> </div>
<el-pagination <el-pagination
@size-change="handleSizeChangeXQ" @size-change="handleSizeChangeBJGZ"
@current-change="handleCurrentChangeXQ" @current-change="handleCurrentChangeBJGZ"
:current-page="XQcurrentPage" :current-page="currentPageBJGZ"
:page-sizes="[5, 10, 20, 50]" :page-sizes="[5, 10, 20, 50]"
:page-size="1000" :page-size="5"
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
:total="XQtotal" :total="addtotal"
class="elpagination" class="elpagination"
> >
</el-pagination> </el-pagination>
<p class="zjBtn">待稽核项目</p> <p class="zjBtn">待稽核项目</p>
<div class="setscrolldialogAdd"> <div class="setscrolldialogAdd">
<el-table <el-table
:data="XQtableDataXM" :data="addtableDataXM"
tooltip-effect="dark myTooltips" tooltip-effect="dark myTooltips"
style="width: 100%" style="width: 100%"
header-cell-class-name="custom-th-background" header-cell-class-name="custom-th-background"
...@@ -838,9 +805,9 @@ ...@@ -838,9 +805,9 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination
@size-change="handleSizeChangeXQXM" @size-change="handleSizeChangeBJXM"
@current-change="handleCurrentChangeXQXM" @current-change="handleCurrentChangeBJXM"
:current-page="XQcurrentPageXM" :current-page="currentPageBJXM"
:page-sizes="[5, 10, 20, 50]" :page-sizes="[5, 10, 20, 50]"
:page-size="1000" :page-size="1000"
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
...@@ -910,12 +877,7 @@ ...@@ -910,12 +877,7 @@
<div class="setscrolldialogAdd"> <div class="setscrolldialogAdd">
<el-table <el-table
@selection-change="handleSelectionChangeZJ" @selection-change="handleSelectionChangeZJ"
:data=" :data="addtableData"
addtableData.slice(
(addcurrentPage - 1) * pageSizeAdd,
addcurrentPage * pageSizeAdd
)
"
tooltip-effect="dark myTooltips" tooltip-effect="dark myTooltips"
style="width: 100%" style="width: 100%"
header-cell-class-name="custom-th-background" header-cell-class-name="custom-th-background"
...@@ -986,11 +948,11 @@ ...@@ -986,11 +948,11 @@
</el-table> </el-table>
</div> </div>
<el-pagination <el-pagination
@size-change="handleSizeChangeAdd" @size-change="handleSizeChangeBJGZ"
@current-change="handleCurrentChangeAdd" @current-change="handleCurrentChangeBJGZ"
:current-page="addcurrentPage" :current-page="currentPageBJGZ"
:page-sizes="[5, 10, 20, 50]" :page-sizes="[5, 10, 20, 50]"
:page-size="1000" :page-size="5"
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
:total="addtotal" :total="addtotal"
class="elpagination" class="elpagination"
...@@ -1001,12 +963,7 @@ ...@@ -1001,12 +963,7 @@
</p> </p>
<div class="setscrolldialogAdd"> <div class="setscrolldialogAdd">
<el-table <el-table
:data=" :data="addtableDataXM"
addtableDataXM.slice(
(addcurrentPageXM - 1) * pageSizeAddXM,
addcurrentPageXM * pageSizeAddXM
)
"
tooltip-effect="dark myTooltips" tooltip-effect="dark myTooltips"
style="width: 100%" style="width: 100%"
header-cell-class-name="custom-th-background" header-cell-class-name="custom-th-background"
...@@ -1083,9 +1040,9 @@ ...@@ -1083,9 +1040,9 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination
@size-change="handleSizeChangeAddXM" @size-change="handleSizeChangeBJXM"
@current-change="handleCurrentChangeAddXM" @current-change="handleCurrentChangeBJXM"
:current-page="addcurrentPageXM" :current-page="currentPageBJXM"
:page-sizes="[5, 10, 20, 50]" :page-sizes="[5, 10, 20, 50]"
:page-size="1000" :page-size="1000"
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
...@@ -1117,6 +1074,7 @@ import { ...@@ -1117,6 +1074,7 @@ import {
delProject, delProject,
delRule, delRule,
iPageRorm, iPageRorm,
selProjectList
} from "@/api/index"; } from "@/api/index";
import { generateYearOptions, projectCategoryText } from "@/utils/cache"; import { generateYearOptions, projectCategoryText } from "@/utils/cache";
export default { export default {
...@@ -1242,10 +1200,13 @@ export default { ...@@ -1242,10 +1200,13 @@ export default {
XQtotal: 0, XQtotal: 0,
pageSizeXQ: 5, pageSizeXQ: 5,
XQcurrentPage: 1, XQcurrentPage: 1,
pageSizeXQXM: 5,
XQcurrentPageXM: 1, XQcurrentPageXM: 1,
totalXQXM: 0, totalXQXM: 0,
defaultDate: new Date(), defaultDate: new Date(),
currentPageBJXM:1,
pageSizeBJXM:5,
currentPageBJGZ:1,
pageSizeBJGZ:5,
}; };
}, },
watch: { watch: {
...@@ -1314,11 +1275,14 @@ export default { ...@@ -1314,11 +1275,14 @@ export default {
}, },
//详情 //详情
async detailsForm() { async detailsForm() {
this.currentPageBJXM=1
this.pageSizeBJXM=5
this.currentPageBJGZ=1
this.pageSizeBJGZ=5
if (this.checkedList.length != 1) { if (this.checkedList.length != 1) {
this.$message("请选择"); this.$message("请选择");
return; return;
} }
console.log(this.checkedList[0], "checkedList[0]");
this.ruleFormdialogXQ = this.checkedList[0]; this.ruleFormdialogXQ = this.checkedList[0];
this.ruleFormdialogXQ.dates = [ this.ruleFormdialogXQ.dates = [
this.checkedList[0].auditStartTime, this.checkedList[0].auditStartTime,
...@@ -1327,25 +1291,25 @@ export default { ...@@ -1327,25 +1291,25 @@ export default {
this.dialog = true; this.dialog = true;
let params = { let params = {
auditId: this.checkedList[0].auditId, auditId: this.checkedList[0].auditId,
current: this.XQcurrentPage, current: this.currentPageBJGZ,
pageSize: this.pageSizeXQ, pageSize: this.pageSizeBJGZ,
}; };
let params2 = { let params2 = {
auditId: this.checkedList[0].auditId, auditId: this.checkedList[0].auditId,
current: this.XQcurrentPageXM, current: this.currentPageBJXM,
pageSize: this.pageSizeXQXM, pageSize: this.pageSizeBJXM,
}; };
Promise.all([selRuleProject(params), selProject(params2)]).then((res) => { Promise.all([selRuleProject(params), selProject(params2)]).then((res) => {
this.XQtableData = res[0].data.records; this.addtableData = res[0].data.records;
this.XQtableDataXM = res[1].data.records; this.addtableDataXM = res[1].data.records;
this.XQtableDataXM.forEach((item) => { this.addtableDataXM.forEach((item) => {
this.$set( this.$set(
item, item,
"projectCategory", "projectCategory",
projectCategoryText(item.projectCategory) projectCategoryText(item.projectCategory)
); );
}); });
this.XQtotal = res[0].data.total; this.addtotal = res[0].data.total;
this.totalXQXM = res[1].data.total; this.totalXQXM = res[1].data.total;
this.dialogXQ = true; this.dialogXQ = true;
}); });
...@@ -1457,9 +1421,6 @@ export default { ...@@ -1457,9 +1421,6 @@ export default {
if (res.code == "200") { if (res.code == "200") {
this.dialogRule = true; this.dialogRule = true;
this.tableDataRule = res.data.records; this.tableDataRule = res.data.records;
// this.tableDataRule=this.tableDataRule.filter(item=>{
// return item.ruleStatus==0
// })
this.totalRule = res.data.total * 1; this.totalRule = res.data.total * 1;
} }
}, },
...@@ -1501,15 +1462,53 @@ export default { ...@@ -1501,15 +1462,53 @@ export default {
handleCurrentChangeXQ(val) { handleCurrentChangeXQ(val) {
this.XQcurrentPage = val; this.XQcurrentPage = val;
}, },
handleSizeChangeXQXM(val) {
this.pageSizeXQXM = val;
},
handleCurrentChangeXQXM(val) {
this.XQcurrentPageXM = val;
},
handleSizeChangeAddXM(val) { handleSizeChangeAddXM(val) {
this.pageSizeAddXM = val; this.pageSizeAddXM = val;
}, },
handleCurrentChangeBJXM(val){
this.currentPageBJXM = val;
this.handselProject()
},
handleSizeChangeBJXM(val) {
this.pageSizeBJXM = val;
this.handselProject()
},
handleCurrentChangeBJGZ(val){
this.currentPageBJGZ = val;
this. BJselRuleProject()
},
handleSizeChangeBJGZ(val) {
this.pageSizeBJGZ = val;
this. BJselRuleProject()
},
//分页从新调取
async handselProject(){
let params2 = {
auditId: this.checkedList[0].auditId,
current: this.currentPageBJXM,
pageSize: this.pageSizeBJXM,
};
let res=await selProject(params2)
this.addtableDataXM = res.data.records;
this.addtableDataXM.forEach(item=>{
this.$set(
item,
"projectCategory",
projectCategoryText(item.projectCategory)
);
})
},
//编辑规则
async BJselRuleProject(){
let params = {
auditId: this.checkedList[0].auditId,
current: this.currentPageBJGZ,
pageSize: this.pageSizeBJGZ,
};
let res=await selRuleProject(params)
this.addtableData = res.data.records;
},
handleCurrentChangeAddXM(val) { handleCurrentChangeAddXM(val) {
this.addcurrentPageXM = val; this.addcurrentPageXM = val;
}, },
...@@ -1522,6 +1521,11 @@ export default { ...@@ -1522,6 +1521,11 @@ export default {
}, },
//编辑 //编辑
edit() { edit() {
this.currentPageBJXM=1
this.pageSizeBJXM=5
this.currentPageBJGZ=1
this.pageSizeBJGZ=5
this.oldid=""
this.showDate = false; this.showDate = false;
if (this.checkedList.length != 1) { if (this.checkedList.length != 1) {
this.$message("请选择"); this.$message("请选择");
...@@ -1532,26 +1536,29 @@ export default { ...@@ -1532,26 +1536,29 @@ export default {
this.checkedList[0].auditStartTime, this.checkedList[0].auditStartTime,
this.checkedList[0].auditEndTime, this.checkedList[0].auditEndTime,
]; ];
this.addtableDataXM=[]
let params = { let params = {
auditId: this.checkedList[0].auditId, auditId: this.checkedList[0].auditId,
current: this.XQcurrentPage, current: this.currentPageBJGZ,
pageSize: this.pageSizeXQ, pageSize: this.pageSizeBJGZ,
}; };
let params2 = { let params2 = {
auditId: this.checkedList[0].auditId, auditId: this.checkedList[0].auditId,
current: this.XQcurrentPageXM, current: this.currentPageBJXM,
pageSize: this.pageSizeXQXM, pageSize: this.pageSizeBJXM,
}; };
Promise.all([selRuleProject(params), selProject(params2)]).then((res) => { Promise.all([selRuleProject(params), selProject(params2),selProjectList(params2)]).then((res) => {
this.addtableData = res[0].data.records; this.addtableData = res[0].data.records;
this.addtableDataXM = res[1].data.records; this.addtableDataXM = res[1].data.records;
this.addtotal = res[0].data.total; this.addtotal = res[0].data.total;
this.addtotalXM = res[1].data.total; this.addtotalXM = res[1].data.total;
let allList=res[2].data.records;
allList.forEach(item=>{
this.oldid = this.oldid.concat(item.projectId + ",");
})
this.dialogBJ = true; this.dialogBJ = true;
this.oldid = "";
if (this.addtableDataXM.length > 0) { if (this.addtableDataXM.length > 0) {
this.addtableDataXM.forEach((item) => { this.addtableDataXM.forEach((item) => {
this.oldid = this.oldid.concat(item.projectId + ",");
this.$set( this.$set(
item, item,
"projectCategory", "projectCategory",
...@@ -1559,6 +1566,7 @@ export default { ...@@ -1559,6 +1566,7 @@ export default {
); );
}); });
} }
console.log( this.oldid,this.addtableDataXM,'this.addtableDataXM')
}); });
}, },
//删除 //删除
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!