| | |
| | | </el-table-column> |
| | | <el-table-column fixed="right" label="操作" align="center" class-name="small-padding fixed-width" width="180"> |
| | | <template #default="scope"> |
| | | <el-button link type="primary" :disabled="state.dataForm.state >= 2 " v-if="scope.row.teamLeader === 1" @click="scope.row.teamLeader = 0">取消组长</el-button> |
| | | <el-button link type="primary" :disabled="state.dataForm.state >= 2" v-else @click="scope.row.teamLeader = 1">设为组长</el-button> |
| | | <el-button link type="primary" :disabled="state.dataForm.state >= 2 || state.isAdmin" v-if="scope.row.teamLeader === 1" @click="scope.row.teamLeader = 0">取消组长</el-button> |
| | | <el-button link type="primary" :disabled="state.dataForm.state >= 2 || state.isAdmin" v-else @click="scope.row.teamLeader = 1">设为组长</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | import axios from "axios"; |
| | | import {generateWordDocument} from "@/views/safetyReview/projectManage/components/exportWord"; |
| | | import {addProject, checkProject, choose, getCheckInfo, getFileInfo, getProjectList} from "@/api/projectManage"; |
| | | import Cookies from "js-cookie"; |
| | | const emit = defineEmits(["getNextStatus","backStatus"]); |
| | | const prop = defineProps(['projectId']) |
| | | const tableRef = ref() |
| | |
| | | Authorization: getToken() |
| | | }, |
| | | fileList: [], |
| | | projectId: null |
| | | projectId: null, |
| | | isAdmin: false |
| | | }); |
| | | const projectType = ref('') |
| | | const userInfo = ref() |
| | | onMounted(async () => { |
| | | if(prop.projectId){ |
| | | state.projectId = prop.projectId |
| | | await getList() |
| | | |
| | | } |
| | | userInfo.value = JSON.parse(Cookies.get('userInfo')) |
| | | state.isAdmin = userInfo.value.admin |
| | | |
| | | }) |
| | | const isView = ref(false) |
| | |
| | | console.log("type",type,val) |
| | | //生成审批按钮 |
| | | if(type === 'confirmApproval'){ |
| | | if (state.isAdmin) { |
| | | ElMessage.warning("当前用户暂无权限"); |
| | | return; |
| | | } |
| | | isView.value = false |
| | | if(state.dataForm.state == 2){ |
| | | dialogVisible.value = true |