| | |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="项目码"> |
| | | <el-select v-model="queryParams.projectColorCode" clearable placeholder="请选择" class="select-option" |
| | | <el-select v-model="queryParams.coding" clearable placeholder="请选择" class="select-option" |
| | | @change="handleQuery"> |
| | | <el-option v-for="item in dict.type.sys_project_code" :key="item.value" :label="item.label" |
| | | :value="item.value"/> |
| | |
| | | @selection-change="handleSelectionChange" |
| | | height="100%" |
| | | sortable="custom" |
| | | :show-overflow-tooltip="true"> |
| | | > |
| | | <el-table-column type="selection" width="55" align="center"/> |
| | | <!-- 动态列 --> |
| | | <el-table-column |
| | |
| | | <template v-if="item.slotName === 'projectStatus'"> |
| | | <dict-tag :options="dict.type.sys_project_status" :value="scope.row.projectStatus"/> |
| | | </template> |
| | | <!-- projectColorCode插槽 --> |
| | | <template v-if="item.slotName === 'projectColorCode'"> |
| | | <dict-tag :options="dict.type.sys_project_code" :value="scope.row.projectColorCode"/> |
| | | <!-- coding插槽 --> |
| | | <template v-if="item.slotName === 'coding'"> |
| | | <dict-tag :options="dict.type.sys_project_code" :value="scope.row.coding"/> |
| | | </template> |
| | | <!-- projectType插槽 --> |
| | | <template v-if="item.slotName === 'projectType'"> |
| | |
| | | <template v-if="item.slotName === 'planStartTime'"> |
| | | {{ scope.row.planStartTime ? scope.row.planStartTime.split('-')[0] + '年' : '' }} |
| | | </template> |
| | | <!-- usedStatus插槽 --> |
| | | <template v-if="item.slotName === 'usedStatus'"> |
| | | <dict-tag :options="dict.type.sys_used_status" :value="scope.row.usedStatus"/> |
| | | </template> |
| | | </template> |
| | | <!-- 默认显示 --> |
| | | <span v-else>{{ scope.row[item.id] }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | <el-table-column v-if="this.$route.query.projectCategory==6" label="审核备注" width="140" align="center" prop="remark"/> |
| | | <!-- 操作列 --> |
| | | <el-table-column label="操作" width="140" align="center"> |
| | | <template slot-scope="scope"> |
| | | <el-button |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-view" |
| | | @click="handleDetail(scope.row)" |
| | | > |
| | | </el-button> |
| | | <el-button |
| | | v-if="isReserve" |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | > |
| | | </el-button> |
| | | <el-button |
| | | v-if="isReserve" |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-delete" |
| | | @click="handleDelete(scope.row)" |
| | | > |
| | | </el-button> |
| | | <el-tooltip class="item" effect="dark" content="审核" placement="top"> |
| | | <el-button |
| | | v-if="scope.row.auditRole && $route.query.projectCategory==='6'" |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-circle-check" |
| | | @click="handleDetail(scope.row)" |
| | | > |
| | | </el-button> |
| | | </el-tooltip> |
| | | <el-tooltip class="item" effect="dark" content="详情" placement="top"> |
| | | <el-button |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-view" |
| | | @click="handleDetail(scope.row)" |
| | | > |
| | | </el-button> |
| | | </el-tooltip> |
| | | <el-tooltip class="item" effect="dark" content="编辑" placement="top"> |
| | | <el-button |
| | | v-if="isReserve" |
| | | v-hasRole="['user']" |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | > |
| | | </el-button> |
| | | </el-tooltip> |
| | | <el-tooltip class="item" effect="dark" content="删除" placement="top"> |
| | | <el-button |
| | | v-if="isReserve" |
| | | size="medium" |
| | | type="text" |
| | | icon="el-icon-delete" |
| | | @click="handleDelete(scope.row)" |
| | | > |
| | | </el-button> |
| | | </el-tooltip> |
| | | |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | export default { |
| | | dicts: ['sys_administrative_divisions', 'sys_investment_type', 'sys_project_phases', |
| | | 'sys_funding_type', 'sys_association_status', 'sys_project_status', 'sys_project_code', |
| | | 'sys_project_tags', 'sys_key_categories', 'sys_project_type'], |
| | | 'sys_project_tags', 'sys_key_categories', 'sys_project_type','sys_used_status'], |
| | | name: "ProjectInfo", |
| | | components: { |
| | | FileDialog |
| | |
| | | projectType: '', // 项目类型 |
| | | importanceType: '', // 重点分类 |
| | | projectStatus: '', // 项目状态 |
| | | projectColorCode: '', // 项目码 |
| | | coding: '', // 项目码 |
| | | investmentType: '', // 资金类型 |
| | | projectPhase: '', // 项目阶段 |
| | | investType: '', // 投资类别 |
| | |
| | | created() { |
| | | this.queryParams.importanceType = this.$route.query.importanceType; |
| | | const projectCategory = this.$route.query.projectCategory; |
| | | if (!projectCategory || projectCategory === '1') { |
| | | if (!projectCategory || projectCategory === '1' || projectCategory === '6') { |
| | | this.isReserve = true; |
| | | } |
| | | if (projectCategory) { |
| | |
| | | item.index = index + 1; |
| | | item.key = index; |
| | | item.serialNumber = index + 1; |
| | | if(item.id ==='usedStatus' ){ |
| | | if(projectCategory !== '6') { |
| | | item.visible = false |
| | | } else { |
| | | item.visible = true |
| | | } |
| | | } |
| | | return item; |
| | | }); |
| | | this.columns = columns; |
| | |
| | | }, |
| | | handleDetail(row) { |
| | | this.removeStore(); |
| | | this.$router.push({path: '/projectEngineering/project/ProjectDetails', query: {projectId: row.id,disabled: 'true' }}); |
| | | const audit = this.$route.query.projectCategory==='6'? 1:0 |
| | | this.$router.push({path: '/projectEngineering/project/ProjectDetails', query: {projectId: row.id,disabled: 'true',audit: audit }}); |
| | | }, |
| | | // 新增页面 |
| | | add() { |
| | |
| | | item.index = index + 1; |
| | | item.key = index; |
| | | item.serialNumber = index + 1 |
| | | if(item.id ==='usedStatus' ){ |
| | | if(projectCategory !== '6') { |
| | | item.visible = false |
| | | } else { |
| | | item.visible = true |
| | | } |
| | | } |
| | | return item; |
| | | }); |
| | | this.columns = currentRest.map((item, index) => { |
| | | item.index = index + 1; |
| | | item.key = index; |
| | | item.serialNumber = index + 1 |
| | | if(item.id ==='usedStatus' ){ |
| | | if(projectCategory !== '6') { |
| | | item.visible = false |
| | | } else { |
| | | item.visible = true |
| | | } |
| | | } |
| | | return item; |
| | | }); |
| | | //强制table渲染 |