| | |
| | | </el-col> |
| | | <el-col :span="11" :offset="2"> |
| | | <el-form-item label="维修负责人" size="default"> |
| | | <el-input v-model="form.repairPersonId" placeholder="请选择"> |
| | | <el-input v-model="form.repairPersonName" placeholder="请选择"> |
| | | <template #append> <el-button :icon="Search" @click="openUser" /> </template |
| | | ></el-input> |
| | | </el-form-item> |
| | |
| | | <el-row> |
| | | <el-col :span="11"> |
| | | <el-form-item label="维修负责人单位" size="default"> |
| | | <el-select v-model="form.repairPersonDepartmentId" placeholder="请选择" style="width: 100%"> |
| | | <el-option label="xxxxx单位" value="1" /> |
| | | <el-option label="xxx单位" value="2" /> |
| | | </el-select> |
| | | <el-tree-select v-model="form.repairPersonDepartmentId" :data="data" check-strictly="true" class="w100" :props="propse" placeholder="请选择" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="11" :offset="2"> |
| | |
| | | </template> |
| | | <script lang="ts"> |
| | | import { defineComponent, ref, reactive } from 'vue'; |
| | | import { ElMessage, ElMessageBox} from 'element-plus'; |
| | | import { Search, FullScreen } from '@element-plus/icons-vue'; |
| | | import DailogSearchUser from '/@/components/DailogSearchUser/index.vue'; |
| | | import { goalManagementApi } from '/@/api/goalManagement'; |
| | | export default defineComponent({ |
| | | components: { DailogSearchUser }, |
| | | setup(props, { emit }) { |
| | |
| | | repairStatus: '', |
| | | repairMemo: '', |
| | | repairPersonId: '', |
| | | repairPersonName:'', |
| | | repairPersonDepartmentId: "", |
| | | repairStartDate: '', |
| | | repairEndDate: '', |
| | |
| | | const disabled = ref(false); |
| | | const dialogVisible = ref(false); |
| | | const openDailog = (title: string, data: any) => { |
| | | department() |
| | | dialogVisible.value = true; |
| | | titles.value = `${title}设备维修`; |
| | | if (title == '查看') { |
| | |
| | | }; |
| | | const User = (val: any) => { |
| | | form.value.repairPersonId = val.uid; |
| | | form.value.repairPersonName = val.realName; |
| | | }; |
| | | // 提交 |
| | | const submitForm = () => { |
| | |
| | | repairStatus: '', |
| | | repairMemo: '', |
| | | repairPersonId: '', |
| | | repairPersonName:'', |
| | | repairPersonDepartmentId: "", |
| | | repairStartDate: '', |
| | | repairEndDate: '', |
| | | }; |
| | | disabled.value = false; |
| | | }; |
| | | // 取消 |
| | | const resetForm = () => { |
| | |
| | | repairStatus: '', |
| | | repairMemo: '', |
| | | repairPersonId: '', |
| | | repairPersonName:"", |
| | | repairPersonDepartmentId: "", |
| | | repairStartDate: '', |
| | | repairEndDate: '', |
| | | }; |
| | | disabled.value = false; |
| | | }; |
| | | //全屏 |
| | | const full = ref(false); |
| | |
| | | full.value = false; |
| | | } |
| | | }; |
| | | //部门树 |
| | | const department = () => { |
| | | goalManagementApi() |
| | | .getTreedepartment() |
| | | .then((res) => { |
| | | if (res.data.code == 200) { |
| | | data.value = res.data.data; |
| | | } else { |
| | | ElMessage.error(res.data.msg); |
| | | } |
| | | }); |
| | | }; |
| | | const propse = { |
| | | label: 'depName', |
| | | children: 'children', |
| | | value: 'depId', |
| | | }; |
| | | const data = ref(); |
| | | return { |
| | | department, |
| | | propse, |
| | | data, |
| | | form, |
| | | titles, |
| | | disabled, |