| | |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="部门名称" prop="depId"> |
| | | <el-select v-model="approveRuleForm.depId" @change="clearValue" :disabled="!disabled" placeholder="请选择作业类型" class="input-add"> |
| | | <el-select v-model="approveRuleForm.depId" :disabled="!disabled" placeholder="请选择部门名称" class="input-add"> |
| | | <el-option v-for="item in departmentList" :key="item.id" :value="item.id" :label="item.department"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="创建审批链"> |
| | | <div style="width: 100%;padding-bottom: 10px" v-show="disabled"> |
| | | <div style="width: 100%;padding-bottom: 10px" v-if="disabled"> |
| | | <el-button type="primary" size="default" @click="openApproveLevelDialog('新增', '')">新增审批层级</el-button> |
| | | </div> |
| | | <div style="width: 100%; margin-left: -30px"> |
| | |
| | | </div> |
| | | </el-card> |
| | | </div> |
| | | <div v-show="disabled"> |
| | | <div v-if="disabled"> |
| | | <el-button type="primary" style="margin-left: 10px;margin-bottom: 10px" size="default" @click="openApproveLevelDialog('修改', item)">修改</el-button> |
| | | <el-button type="danger" size="default" @click="deleteApproveLevel(index, item)">删除</el-button> |
| | | </div> |
| | |
| | | </el-col> |
| | | </el-form> |
| | | <template #footer> |
| | | <div v-show="disabled" class="dialog-footer" align="right"> |
| | | <div v-if="disabled" class="dialog-footer" align="right"> |
| | | <el-button type="warning" @click="ifShowApproveRuleDialog = false" size="default" plain>取消</el-button> |
| | | <el-button type="primary" @click="submitApproveRule()" size="default">确认</el-button> |
| | | </div> |
| | |
| | | |
| | | <script> |
| | | import approveLevelDialog from './approveLevelDialog.vue'; |
| | | import {approveRuleApi} from "../../../../../api/approveRule"; |
| | | |
| | | export default { |
| | | name: 'approveRuleDialog', |
| | |
| | | this.userList = userList; |
| | | this.workTypeList = workTypeList; |
| | | this.departmentList = departmentList; |
| | | this.$nextTick(()=>{ |
| | | debugger |
| | | this.$nextTick(() =>{ |
| | | this.$refs["approveRuleFormRef"].clearValidate() |
| | | }) |
| | | if (type === '新增') { |
| | |
| | | this.approveRuleForm = JSON.parse(JSON.stringify(value)); |
| | | this.setValue(value.workType); |
| | | } else { |
| | | this.disabled = false; |
| | | this.disabled = true; |
| | | this.title = '查看审批规则'; |
| | | this.setValue(value.workType); |
| | | this.approveRuleForm = JSON.parse(JSON.stringify(value)); |