|
@@ -1,191 +1,191 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<div v-if="!$route.path.includes('projectInfo')">
|
|
|
+ <search-layout :needBox="true">
|
|
|
+ <template slot="searchItem1">
|
|
|
+ <span class="label">项目ID</span>
|
|
|
+ <el-input
|
|
|
+ v-model="searchParams.projectId"
|
|
|
+ size="small"
|
|
|
+ clearable
|
|
|
+ placeholder="请输入"
|
|
|
+ maxlength="60"
|
|
|
+ @keyup.enter.native="doSearch"
|
|
|
+ >
|
|
|
+ </el-input>
|
|
|
+ </template>
|
|
|
+ <template slot="searchItem2">
|
|
|
+ <span class="label">项目名称</span>
|
|
|
+ <el-input
|
|
|
+ v-model="searchParams.projectName"
|
|
|
+ size="small"
|
|
|
+ clearable
|
|
|
+ placeholder="请输入"
|
|
|
+ maxlength="60"
|
|
|
+ @keyup.enter.native="doSearch"
|
|
|
+ >
|
|
|
+ </el-input>
|
|
|
+ </template>
|
|
|
+ <template slot="searchItem3">
|
|
|
+ <span class="label">进度</span>
|
|
|
+ <el-select v-model="searchParams.nowRunState">
|
|
|
+ <el-option
|
|
|
+ v-for="item in nowRunStateList"
|
|
|
+ :label="item.caption"
|
|
|
+ :value="item.code"
|
|
|
+ :key="item.code"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ <template slot="searchItem4">
|
|
|
+ <span class="label">评测等级</span>
|
|
|
+ <el-select v-model="searchParams.evaluationLevel">
|
|
|
+ <el-option
|
|
|
+ v-for="item in evaluationLevelList"
|
|
|
+ :label="item.caption"
|
|
|
+ :value="item.code"
|
|
|
+ :key="item.code"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ </template>
|
|
|
+ <template slot="searchItem5">
|
|
|
+ <span class="label">创建时间</span>
|
|
|
+ <el-date-picker
|
|
|
+ v-model="createDate"
|
|
|
+ type="daterange"
|
|
|
+ format="yyyy-MM-dd"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ range-separator="至"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </template>
|
|
|
+ <template slot="searchItem6">
|
|
|
+ <span class="label">完成时间</span>
|
|
|
+ <el-date-picker
|
|
|
+ v-model="finishDate"
|
|
|
+ type="daterange"
|
|
|
+ format="yyyy-MM-dd"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ range-separator="至"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </template>
|
|
|
|
|
|
- <search-layout :needBox="true">
|
|
|
- <template slot="searchItem1">
|
|
|
- <span class="label">项目ID</span>
|
|
|
- <el-input
|
|
|
- v-model="searchParams.projectId"
|
|
|
- size="small"
|
|
|
- clearable
|
|
|
- placeholder="请输入"
|
|
|
- maxlength="60"
|
|
|
- @keyup.enter.native="doSearch"
|
|
|
- >
|
|
|
- </el-input>
|
|
|
- </template>
|
|
|
- <template slot="searchItem2">
|
|
|
- <span class="label">项目名称</span>
|
|
|
- <el-input
|
|
|
- v-model="searchParams.projectName"
|
|
|
- size="small"
|
|
|
- clearable
|
|
|
- placeholder="请输入"
|
|
|
- maxlength="60"
|
|
|
- @keyup.enter.native="doSearch"
|
|
|
- >
|
|
|
- </el-input>
|
|
|
- </template>
|
|
|
- <template slot="searchItem3">
|
|
|
- <span class="label">进度</span>
|
|
|
- <el-select v-model="searchParams.nowRunState">
|
|
|
- <el-option
|
|
|
- v-for="item in nowRunStateList"
|
|
|
- :label="item.caption"
|
|
|
- :value="item.code"
|
|
|
- :key="item.code"
|
|
|
- ></el-option>
|
|
|
- </el-select>
|
|
|
- </template>
|
|
|
- <template slot="searchItem4">
|
|
|
- <span class="label">评测等级</span>
|
|
|
- <el-select v-model="searchParams.evaluationLevel">
|
|
|
- <el-option
|
|
|
- v-for="item in evaluationLevelList"
|
|
|
- :label="item.caption"
|
|
|
- :value="item.code"
|
|
|
- :key="item.code"
|
|
|
- ></el-option>
|
|
|
- </el-select>
|
|
|
- </template>
|
|
|
- <template slot="searchItem5">
|
|
|
- <span class="label">创建时间</span>
|
|
|
- <el-date-picker
|
|
|
- v-model="createDate"
|
|
|
- type="daterange"
|
|
|
- format="yyyy-MM-dd"
|
|
|
- value-format="yyyy-MM-dd"
|
|
|
- range-separator="至"
|
|
|
- start-placeholder="开始日期"
|
|
|
- end-placeholder="结束日期"
|
|
|
+ <template slot="searchBtn1">
|
|
|
+ <el-button type="primary" @click="doSearch">查询</el-button>
|
|
|
+ </template>
|
|
|
+ <template slot="searchBtn2">
|
|
|
+ <el-button type="primary" @click="doReset">重置</el-button>
|
|
|
+ </template>
|
|
|
+ </search-layout>
|
|
|
+
|
|
|
+ <div class="btnsPanel">
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ plain
|
|
|
+ icon="el-icon-delete"
|
|
|
+ @click="delRows"
|
|
|
+ >批量删除</el-button
|
|
|
>
|
|
|
- </el-date-picker>
|
|
|
- </template>
|
|
|
- <template slot="searchItem6">
|
|
|
- <span class="label">完成时间</span>
|
|
|
- <el-date-picker
|
|
|
- v-model="finishDate"
|
|
|
- type="daterange"
|
|
|
- format="yyyy-MM-dd"
|
|
|
- value-format="yyyy-MM-dd"
|
|
|
- range-separator="至"
|
|
|
- start-placeholder="开始日期"
|
|
|
- end-placeholder="结束日期"
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ icon="el-icon-circle-plus-outline"
|
|
|
+ @click="addOne"
|
|
|
+ >创建</el-button
|
|
|
>
|
|
|
- </el-date-picker>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template slot="searchBtn1">
|
|
|
- <el-button type="primary" @click="doSearch">查询</el-button>
|
|
|
- </template>
|
|
|
- <template slot="searchBtn2">
|
|
|
- <el-button type="primary" @click="doReset">重置</el-button>
|
|
|
- </template>
|
|
|
- </search-layout>
|
|
|
+ </div>
|
|
|
|
|
|
- <div class="btnsPanel">
|
|
|
- <el-button
|
|
|
- type="primary"
|
|
|
- plain
|
|
|
- icon="el-icon-delete"
|
|
|
- @click="delRows"
|
|
|
- >批量删除</el-button
|
|
|
+ <tableList
|
|
|
+ ref="table"
|
|
|
+ style="margin: 0 30px"
|
|
|
+ :columns="columns"
|
|
|
+ :getDataWay="getDataWay"
|
|
|
+ :pagination="pagination"
|
|
|
+ :checkedData="checkedArr"
|
|
|
+ selection
|
|
|
+ index
|
|
|
>
|
|
|
- <el-button
|
|
|
- type="primary"
|
|
|
- icon="el-icon-circle-plus-outline"
|
|
|
- @click="addOne"
|
|
|
- >创建</el-button
|
|
|
- >
|
|
|
- </div>
|
|
|
-
|
|
|
- <tableList
|
|
|
- ref="table"
|
|
|
- style="margin: 0 30px"
|
|
|
- :columns="columns"
|
|
|
- :getDataWay="getDataWay"
|
|
|
- :pagination="pagination"
|
|
|
- :checkedData="checkedArr"
|
|
|
- selection
|
|
|
- index
|
|
|
- >
|
|
|
- <el-table-column label="操作" slot="cgInfos" align="center">
|
|
|
- <template v-slot="scope">
|
|
|
- <i
|
|
|
- v-if="
|
|
|
- scope.row.nowRunState === '10' ||
|
|
|
- scope.row.nowRunState === '30' ||
|
|
|
- scope.row.nowRunState === '40'
|
|
|
- "
|
|
|
- @click="runRow(scope.row.id)"
|
|
|
- class="el-icon-video-play elIcon"
|
|
|
- title="运行"
|
|
|
- ></i>
|
|
|
- <i
|
|
|
- v-if="
|
|
|
- scope.row.nowRunState === '10' ||
|
|
|
- scope.row.nowRunState === '40'
|
|
|
- "
|
|
|
- @click="editRow(scope.row)"
|
|
|
- class="el-icon-edit-outline elIcon"
|
|
|
- title="编辑"
|
|
|
- ></i>
|
|
|
- <i
|
|
|
- @click="viewRow(scope.row.id)"
|
|
|
- class="el-icon-view elIcon"
|
|
|
- title="查看"
|
|
|
- ></i>
|
|
|
- <i
|
|
|
- v-if="scope.row.nowRunState === '20'"
|
|
|
- @click="stopRow(scope.row.id)"
|
|
|
- class="el-icon-video-pause elIcon"
|
|
|
- title="中止"
|
|
|
- ></i>
|
|
|
- <i
|
|
|
- v-if="
|
|
|
- scope.row.nowRunState === '10' ||
|
|
|
- scope.row.nowRunState === '30' ||
|
|
|
- scope.row.nowRunState === '40'
|
|
|
- "
|
|
|
- @click="delRow(scope.row.id)"
|
|
|
- class="el-icon-delete elIcon"
|
|
|
- title="删除"
|
|
|
- ></i>
|
|
|
- <i
|
|
|
- v-if="scope.row.nowRunState != '10'"
|
|
|
- @click="downRow(scope.row)"
|
|
|
- class="el-icon-download elIcon"
|
|
|
- title="下载"
|
|
|
- ></i>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
- </tableList>
|
|
|
-
|
|
|
- <el-dialog
|
|
|
- title="下载"
|
|
|
- :visible.sync="dialogVisible"
|
|
|
- width="690px"
|
|
|
- :close-on-click-modal="false"
|
|
|
- :close-on-press-escape="false"
|
|
|
- :before-close="cancelDown"
|
|
|
- >
|
|
|
- <div class="checkboxPanel">
|
|
|
- <el-checkbox-group v-model="downType">
|
|
|
- <el-checkbox
|
|
|
- label="工作报告"
|
|
|
- class="labelA"
|
|
|
- :disabled="downDisabled"
|
|
|
- ></el-checkbox>
|
|
|
- <el-checkbox label="任务文件包"></el-checkbox>
|
|
|
- </el-checkbox-group>
|
|
|
- </div>
|
|
|
- <span slot="footer">
|
|
|
- <el-button type="primary" @click="confirmDown">确 定</el-button>
|
|
|
- <el-button @click="cancelDown">取 消</el-button>
|
|
|
- </span>
|
|
|
- </el-dialog>
|
|
|
+ <el-table-column label="操作" slot="cgInfos" align="center">
|
|
|
+ <template v-slot="scope">
|
|
|
+ <i
|
|
|
+ v-if="
|
|
|
+ scope.row.nowRunState === '10' ||
|
|
|
+ scope.row.nowRunState === '30' ||
|
|
|
+ scope.row.nowRunState === '40'
|
|
|
+ "
|
|
|
+ @click="runRow(scope.row.id, scope.row.parallelism)"
|
|
|
+ class="el-icon-video-play elIcon"
|
|
|
+ title="运行"
|
|
|
+ ></i>
|
|
|
+ <i
|
|
|
+ v-if="
|
|
|
+ scope.row.nowRunState === '10' ||
|
|
|
+ scope.row.nowRunState === '40'
|
|
|
+ "
|
|
|
+ @click="editRow(scope.row)"
|
|
|
+ class="el-icon-edit-outline elIcon"
|
|
|
+ title="编辑"
|
|
|
+ ></i>
|
|
|
+ <i
|
|
|
+ @click="viewRow(scope.row.id)"
|
|
|
+ class="el-icon-view elIcon"
|
|
|
+ title="查看"
|
|
|
+ ></i>
|
|
|
+ <i
|
|
|
+ v-if="scope.row.nowRunState === '20'"
|
|
|
+ @click="stopRow(scope.row.id)"
|
|
|
+ class="el-icon-video-pause elIcon"
|
|
|
+ title="中止"
|
|
|
+ ></i>
|
|
|
+ <i
|
|
|
+ v-if="
|
|
|
+ scope.row.nowRunState === '10' ||
|
|
|
+ scope.row.nowRunState === '30' ||
|
|
|
+ scope.row.nowRunState === '40'
|
|
|
+ "
|
|
|
+ @click="delRow(scope.row.id)"
|
|
|
+ class="el-icon-delete elIcon"
|
|
|
+ title="删除"
|
|
|
+ ></i>
|
|
|
+ <i
|
|
|
+ v-if="scope.row.nowRunState != '10'"
|
|
|
+ @click="downRow(scope.row)"
|
|
|
+ class="el-icon-download elIcon"
|
|
|
+ title="下载"
|
|
|
+ ></i>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </tableList>
|
|
|
|
|
|
+ <el-dialog
|
|
|
+ title="下载"
|
|
|
+ :visible.sync="dialogVisible"
|
|
|
+ width="690px"
|
|
|
+ :close-on-click-modal="false"
|
|
|
+ :close-on-press-escape="false"
|
|
|
+ :before-close="cancelDown"
|
|
|
+ >
|
|
|
+ <div class="checkboxPanel">
|
|
|
+ <el-checkbox-group v-model="downType">
|
|
|
+ <el-checkbox
|
|
|
+ label="工作报告"
|
|
|
+ class="labelA"
|
|
|
+ :disabled="downDisabled"
|
|
|
+ ></el-checkbox>
|
|
|
+ <el-checkbox label="任务文件包"></el-checkbox>
|
|
|
+ </el-checkbox-group>
|
|
|
+ </div>
|
|
|
+ <span slot="footer">
|
|
|
+ <el-button type="primary" @click="confirmDown"
|
|
|
+ >确 定</el-button
|
|
|
+ >
|
|
|
+ <el-button @click="cancelDown">取 消</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
<router-view v-else></router-view>
|
|
|
</div>
|
|
@@ -336,12 +336,17 @@ export default {
|
|
|
},
|
|
|
});
|
|
|
},
|
|
|
- runRow(id) {
|
|
|
+ runRow(id, parallelism) {
|
|
|
this.$confirm("确认是否运行?", "提示", {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
|
type: "warning",
|
|
|
}).then(() => {
|
|
|
+ if (parallelism == "0") {
|
|
|
+ this.$message.error("并行度为0,不能运行");
|
|
|
+ return;
|
|
|
+ }
|
|
|
+
|
|
|
this.$axios({
|
|
|
method: "post",
|
|
|
url: this.$api.workManagement.updateProjectNowRunState,
|
|
@@ -426,7 +431,10 @@ export default {
|
|
|
},
|
|
|
|
|
|
viewRow(id) {
|
|
|
- this.$router.push({ path: "/manualRunProjectList/projectInfo", query: { id } });
|
|
|
+ this.$router.push({
|
|
|
+ path: "/manualRunProjectList/projectInfo",
|
|
|
+ query: { id },
|
|
|
+ });
|
|
|
},
|
|
|
downRow(row) {
|
|
|
this.curRow = row;
|
|
@@ -492,16 +500,12 @@ export default {
|
|
|
},
|
|
|
|
|
|
async mounted() {
|
|
|
- console.log(666);
|
|
|
+ // console.log(666);
|
|
|
await this.$dicsListsInit({
|
|
|
nowRunStateList: "projectRunState",
|
|
|
evaluationLevelList: "evaluationLevel",
|
|
|
});
|
|
|
- console.log(this.$route);
|
|
|
},
|
|
|
- activated(){
|
|
|
- console.log(6);
|
|
|
- }
|
|
|
};
|
|
|
</script>
|
|
|
|