|
@@ -93,6 +93,9 @@
|
|
|
<el-dropdown-item v-if="permissions.projectPhase && user.company.packageProject == 1">
|
|
|
<el-link type="primary" :underline="false" @click="phaseProjectDialog = true">项目阶段管理</el-link>
|
|
|
</el-dropdown-item>
|
|
|
+ <el-dropdown-item v-if="user.timeType.projectLevelState == 1">
|
|
|
+ <el-link type="primary" :underline="false" @click="projectLevelDialog = true">项目级别管理</el-link>
|
|
|
+ </el-dropdown-item>
|
|
|
</el-dropdown-menu>
|
|
|
</el-dropdown>
|
|
|
</el-form-item>
|
|
@@ -206,9 +209,10 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<!-- 级别 -->
|
|
|
- <el-table-column prop="level" label="级别" min-width="190" v-if="user.company.packageProject == 1">
|
|
|
+ <el-table-column :prop="user.timeType.projectLevelState == 1 ? 'levelName' : 'level'" label="级别" min-width="190" v-if="user.company.packageProject == 1">
|
|
|
<template slot-scope="scope">
|
|
|
- {{importanceListLable[scope.row.level - 1]}}
|
|
|
+ <span v-if="user.timeType.projectLevelState == 1">{{scope.row.levelName}}</span>
|
|
|
+ <span v-else>{{importanceListLable[scope.row.level - 1]}}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<!-- 供应商 -->
|
|
@@ -622,6 +626,43 @@
|
|
|
<el-button type="primary" @click="addPanthPro()" >新增项目阶段</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
+
|
|
|
+ <!-- 项目级别管理 -->
|
|
|
+ <el-dialog title="项目级别管理" show-header="false" v-if="projectLevelDialog" :visible.sync="projectLevelDialog" :close-on-click-modal="false" customClass="customWidth" width="600px">
|
|
|
+ <el-table :data="levelList" highlight-current-row height="400" style="width: 100%;">
|
|
|
+ <el-table-column type="index" width="60" label="序号">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ {{scope.$index+1+(page-1)*size}}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="projectLevelName" label="级别名称" ></el-table-column>
|
|
|
+ <el-table-column label="操作" width="150">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button size="small" type="primary" @click="addProjectLevel(scope.row)">编辑</el-button>
|
|
|
+ <el-button size="small" type="danger" @click="deleteProjectLevel(scope.row)">删除</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button type="primary" @click="projectLevelDialog = false" >关闭</el-button>
|
|
|
+ <el-button type="primary" @click="addProjectLevel()" >新增项目级别</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+ <!-- 新增/编辑项目级别 -->
|
|
|
+ <el-dialog title="新增/修改项目级别" v-if="addProjectLevelDialog" :visible.sync="addProjectLevelDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
|
|
|
+ <el-form ref="form2" :model="addLevelForm" :rules="rules" label-width="120px">
|
|
|
+ <el-form-item label="项目级别名称" prop="projectLevelName">
|
|
|
+ <el-input v-model="addLevelForm.projectLevelName" placeholder="请输入名称" clearable></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button @click="addProjectLevelDialog = false">取消</el-button>
|
|
|
+ <el-button type="primary" @click="submitLevelPro" :loading="addLoading">提交</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+
|
|
|
<!-- 新增/编辑 分类条目 -->
|
|
|
<el-dialog title="新增/修改分类条目" v-if="addClfDialog" :visible.sync="addClfDialog" :close-on-click-modal="false" customClass="customWidth" width="500px">
|
|
|
<el-form ref="form2" :model="addClf" :rules="rules" label-width="100px">
|
|
@@ -856,8 +897,10 @@ a {
|
|
|
return {
|
|
|
addFlgmainProjectDialog: false,
|
|
|
addFlgPanthProjectDialog: false,
|
|
|
+ addProjectLevelDialog: false,
|
|
|
mainProjectList: [],
|
|
|
mainProjectDialog: false,
|
|
|
+ projectLevelDialog: false,
|
|
|
showImportResult: false,
|
|
|
importResultMsg:null,
|
|
|
isganttshow: false,
|
|
@@ -938,6 +981,7 @@ a {
|
|
|
name: [{ required: true, message: "请输入名称", trigger: "blur" }],
|
|
|
code: [{ required: true, message: "请输入编号", trigger: "blur" }],
|
|
|
projectStageName: [{ required: true, message: "请输入名称", trigger: "blur" }],
|
|
|
+ projectLevelName: [{ required: true, message: "请输入名称", trigger: "blur" }],
|
|
|
},
|
|
|
ause: [],
|
|
|
auseList: [],
|
|
@@ -957,6 +1001,10 @@ a {
|
|
|
id: '',
|
|
|
projectStageName: ''
|
|
|
},
|
|
|
+ addLevelForm: {
|
|
|
+ id: '',
|
|
|
+ projectStageName: ''
|
|
|
+ },
|
|
|
statusClf:null,
|
|
|
permissionsObj: {},
|
|
|
|
|
@@ -988,6 +1036,7 @@ a {
|
|
|
listHeader: [], // 列表表头
|
|
|
rowid: '',
|
|
|
phaseProjectDialog: false, // 项目阶段
|
|
|
+ levelList: [], // 项目级别
|
|
|
};
|
|
|
},
|
|
|
// 过滤器
|
|
@@ -1054,6 +1103,66 @@ a {
|
|
|
});
|
|
|
});
|
|
|
},
|
|
|
+ // 获取级别
|
|
|
+ getProjectLevel(){
|
|
|
+ this.http.post('/project-level/list', {},
|
|
|
+ res => {
|
|
|
+ if (res.code == "ok") {
|
|
|
+ this.levelList = res.data
|
|
|
+ // this.$set(this, 'levelList', res.data)
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ message: res.msg,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ this.$message({
|
|
|
+ message: error,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ });
|
|
|
+ },
|
|
|
+ addProjectLevel(row){
|
|
|
+ this.addProjectLevelDialog = true
|
|
|
+ if(!row) {
|
|
|
+ this.addLevelForm = {
|
|
|
+ projectLevelName: '',
|
|
|
+ id: ''
|
|
|
+ // companyId:''
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ this.addLevelForm = {
|
|
|
+ id: row.id,
|
|
|
+ projectLevelName: row.projectLevelName
|
|
|
+ // companyId: row.companyId
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ submitLevelPro(){
|
|
|
+ this.http.post('/project-level/addOrMod',this.addLevelForm,
|
|
|
+ res => {
|
|
|
+ if (res.code == "ok") {
|
|
|
+ this.addProjectLevelDialog = false;
|
|
|
+ this.getProjectLevel()
|
|
|
+ } else {
|
|
|
+ this.$message({
|
|
|
+ message: res.msg,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error => {
|
|
|
+ this.$message({
|
|
|
+ message: error,
|
|
|
+ type: "error"
|
|
|
+ });
|
|
|
+ }
|
|
|
+ );
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
// 表格点击
|
|
|
tableCellClassName({row, column, rowIndex, columnIndex}) {
|
|
|
row.index=rowIndex;
|
|
@@ -3180,6 +3289,9 @@ a {
|
|
|
if(this.user.timeType.mainProjectState == 1){
|
|
|
this.getMainProject()
|
|
|
}
|
|
|
+ if(this.user.timeType.projectLevelState == 1){
|
|
|
+ this.getProjectLevel()
|
|
|
+ }
|
|
|
|
|
|
// 判断释放为专业版
|
|
|
if(this.user.company.packageProject == 1) {
|