|
@@ -50,44 +50,45 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
|
|
|
- <el-form-item label="项目经理" class="pull-left">
|
|
|
+ <el-form-item label="试卷状态" class="pull-left">
|
|
|
<el-select
|
|
|
- v-model="formSearch.pmId"
|
|
|
- placeholder="请选择"
|
|
|
- filterable
|
|
|
+ v-model="formSearch.paperStatus"
|
|
|
clearable
|
|
|
- remote
|
|
|
- :remote-method="searchPmList"
|
|
|
+ placeholder="请选择"
|
|
|
>
|
|
|
<el-option label="请选择" value=""></el-option>
|
|
|
<el-option
|
|
|
- v-for="item in pmList"
|
|
|
- :label="item.name"
|
|
|
- :value="item.id"
|
|
|
- :key="item.id"
|
|
|
+ v-for="item in coursePaperStatusList"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ :key="item.value"
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
|
|
|
- <el-form-item label="印刷供应商" class="pull-left">
|
|
|
+ <el-form-item label="课程名称" class="pull-left">
|
|
|
<el-select
|
|
|
- v-model="formSearch.supplierId"
|
|
|
+ v-model="formSearch.courseId"
|
|
|
placeholder="请选择"
|
|
|
filterable
|
|
|
clearable
|
|
|
remote
|
|
|
- :remote-method="searchSupplierList"
|
|
|
+ :remote-method="searchCourseList"
|
|
|
>
|
|
|
<el-option label="请选择" value=""></el-option>
|
|
|
<el-option
|
|
|
- v-for="item in supplierList"
|
|
|
+ v-for="item in courseList"
|
|
|
:label="item.name"
|
|
|
- :value="item.id"
|
|
|
- :key="item.id"
|
|
|
+ :value="item.code"
|
|
|
+ :key="item.code"
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
|
|
|
+ <el-form-item label="试卷名称" class="pull-left">
|
|
|
+ <el-input v-model="formSearch.paperName"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+
|
|
|
<el-form-item class="pull-right">
|
|
|
<el-button
|
|
|
size="small"
|
|
@@ -107,30 +108,32 @@
|
|
|
style="width:100%;"
|
|
|
border
|
|
|
>
|
|
|
- <el-table-column width="220" label="学校名称" prop="orgName" />
|
|
|
- <el-table-column label="考试名称" prop="examName" />
|
|
|
- <el-table-column width="200" label="印刷供应商" prop="supplierName" />
|
|
|
- <el-table-column width="150" label="项目经理" prop="pmName" />
|
|
|
+ <el-table-column label="课程名称" prop="courseName" />
|
|
|
+ <el-table-column width="150" label="课程代码" prop="courseCode" />
|
|
|
+ <el-table-column width="80" label="试卷类型" prop="paperType" />
|
|
|
+ <el-table-column width="80" label="试卷状态" prop="paperStatusName" />
|
|
|
+ <el-table-column width="200" label="试卷名称" prop="paperName" />
|
|
|
+ <el-table-column width="80" label="试卷P数" prop="paperP" />
|
|
|
+ <el-table-column width="100" label="考生人数" prop="totalStudent" />
|
|
|
|
|
|
- <el-table-column width="120" label="项目统计">
|
|
|
+ <el-table-column width="180" label="操作" :context="_self">
|
|
|
<template slot-scope="scope">
|
|
|
- <a
|
|
|
- href="javascript:void(0)"
|
|
|
- @click="gotoProjectStatistic(scope.row);"
|
|
|
- >查看
|
|
|
- </a>
|
|
|
- </template>
|
|
|
- </el-table-column>
|
|
|
+ <el-button
|
|
|
+ size="mini"
|
|
|
+ type="primary"
|
|
|
+ icon="el-icon-document"
|
|
|
+ v-show="scope.row.paperStatus == '2'"
|
|
|
+ @click="preview(scope.row);"
|
|
|
+ >预览
|
|
|
+ </el-button>
|
|
|
|
|
|
- <el-table-column width="120" label="操作" :context="_self">
|
|
|
- <template slot-scope="scope">
|
|
|
<el-button
|
|
|
size="mini"
|
|
|
type="primary"
|
|
|
- icon="el-icon-setting"
|
|
|
- @click="editProjectSetting(scope.row);"
|
|
|
- :disabled="!hasPermit"
|
|
|
- >项目设置
|
|
|
+ icon="el-icon-download"
|
|
|
+ v-show="scope.row.paperStatus == '2'"
|
|
|
+ @click="download(scope.row);"
|
|
|
+ >下载
|
|
|
</el-button>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
@@ -152,7 +155,12 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { print_api, core_api, userRole } from "../constants/constants.js";
|
|
|
+import {
|
|
|
+ print_api,
|
|
|
+ core_api,
|
|
|
+ userRole,
|
|
|
+ coursePaperStatusList
|
|
|
+} from "../constants/constants.js";
|
|
|
import { mapState } from "vuex";
|
|
|
|
|
|
export default {
|
|
@@ -161,8 +169,9 @@ export default {
|
|
|
formSearch: {
|
|
|
orgId: "",
|
|
|
examId: "",
|
|
|
- pmId: "",
|
|
|
- supplierId: "",
|
|
|
+ courseId: "",
|
|
|
+ paperStatus: "",
|
|
|
+ paperName: "",
|
|
|
pageNo: 1,
|
|
|
pageSize: 10
|
|
|
},
|
|
@@ -173,8 +182,8 @@ export default {
|
|
|
tableData: [],
|
|
|
orgList: [],
|
|
|
examList: [],
|
|
|
- pmList: [],
|
|
|
- supplierList: [],
|
|
|
+ courseList: [],
|
|
|
+ coursePaperStatusList: coursePaperStatusList,
|
|
|
rules: {}
|
|
|
};
|
|
|
},
|
|
@@ -205,7 +214,7 @@ export default {
|
|
|
}
|
|
|
|
|
|
this.loading = true;
|
|
|
- let url = print_api + "/printing/project/list";
|
|
|
+ let url = print_api + "/course/statistic/list";
|
|
|
this.$http.post(url, this.formSearch).then(
|
|
|
response => {
|
|
|
this.tableData = response.data.content;
|
|
@@ -230,41 +239,25 @@ export default {
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
- searchPmList(query) {
|
|
|
- /* 查询项目经理列表 */
|
|
|
- this.pmList = [];
|
|
|
- let url =
|
|
|
- core_api + "/user/query?rootOrgCode=qmth&roleCode=PRINT_PROJECT_LEADER";
|
|
|
-
|
|
|
- if (!this.isEmptyStr(query)) {
|
|
|
- url += "&name=" + query;
|
|
|
- }
|
|
|
-
|
|
|
- this.$http.get(url).then(response => {
|
|
|
- this.pmList = response.data;
|
|
|
- });
|
|
|
- },
|
|
|
- searchSupplierList(query) {
|
|
|
- /* 查询印刷供应商列表 */
|
|
|
- this.supplierList = [];
|
|
|
- let url =
|
|
|
- core_api + "/user/query?rootOrgCode=qmth-print&roleCode=PRINT_SUPPLIER";
|
|
|
+ searchCourseList(query) {
|
|
|
+ /* 查询课程列表 */
|
|
|
+ this.courseList = [];
|
|
|
+ let url = core_api + "/course/query?enable=true";
|
|
|
|
|
|
if (!this.isEmptyStr(query)) {
|
|
|
url += "&name=" + query;
|
|
|
}
|
|
|
|
|
|
this.$http.get(url).then(response => {
|
|
|
- this.supplierList = response.data;
|
|
|
+ this.courseList = response.data;
|
|
|
});
|
|
|
},
|
|
|
- gotoProjectStatistic(row) {
|
|
|
- /* 查看项目统计 */
|
|
|
- let url = "/print/project/statistic/" + row.orgId + "/" + row.examId;
|
|
|
- this.$router.push({ path: url });
|
|
|
+ preview(row) {
|
|
|
+ /* 预览试卷PDF */
|
|
|
+ console.log(row);
|
|
|
},
|
|
|
- editProjectSetting(row) {
|
|
|
- /* 项目设置 */
|
|
|
+ download(row) {
|
|
|
+ /* 下载试卷结构 */
|
|
|
console.log(row);
|
|
|
}
|
|
|
},
|
|
@@ -276,16 +269,8 @@ export default {
|
|
|
|
|
|
this.loadUserRole(this.user);
|
|
|
|
|
|
- if (this.curUserRole.isSuperLeader) {
|
|
|
- this.hasPermit = true;
|
|
|
- // this.searchPmList();
|
|
|
- // this.searchSupplierList();
|
|
|
- } else if (this.curUserRole.isPM) {
|
|
|
+ if (this.curUserRole.isSuperLeader || this.curUserRole.isPM) {
|
|
|
this.hasPermit = true;
|
|
|
- //this.loadPmInfo(this.user);
|
|
|
- } else if (this.curUserRole.isSupplier) {
|
|
|
- this.hasPermit = false;
|
|
|
- //this.loadSupplierInfo(this.user);
|
|
|
} else {
|
|
|
this.hasPermit = false;
|
|
|
}
|