fix: 修复typescript一些编译报错
This commit is contained in:
@@ -185,7 +185,7 @@ const state = reactive({
|
||||
// 表格树数据
|
||||
deptList: [],
|
||||
// 部门树选项
|
||||
deptOptions: [],
|
||||
deptOptions: [] as Array<any>,
|
||||
// 弹窗属性
|
||||
dialog: {
|
||||
title: '',
|
||||
|
||||
@@ -168,7 +168,9 @@ const state = reactive({
|
||||
name: undefined,
|
||||
code: undefined,
|
||||
status: undefined,
|
||||
remark: undefined
|
||||
remark: undefined,
|
||||
sort:undefined,
|
||||
value:undefined
|
||||
},
|
||||
rules: {
|
||||
name: [
|
||||
@@ -263,7 +265,9 @@ function resetForm() {
|
||||
name: undefined,
|
||||
code: undefined,
|
||||
status: undefined,
|
||||
remark: undefined
|
||||
remark: undefined,
|
||||
sort:undefined,
|
||||
value:undefined
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -206,7 +206,8 @@ const state = reactive({
|
||||
icon: '',
|
||||
sort: 1,
|
||||
component: 'Layout',
|
||||
path: undefined
|
||||
path: undefined,
|
||||
redirect:''
|
||||
},
|
||||
rules: {
|
||||
parentId: [
|
||||
@@ -356,7 +357,8 @@ function resetForm() {
|
||||
icon: '',
|
||||
sort: 1,
|
||||
component: 'Layout',
|
||||
path: undefined
|
||||
path: undefined,
|
||||
redirect:''
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
:inline="true"
|
||||
>
|
||||
<el-form-item>
|
||||
<el-button type="success" :icon="Plus" :disabled="state.disabled" @click="handleAdd">新增</el-button>
|
||||
<el-button type="success" :icon="Plus" :disabled="state.single" @click="handleAdd">新增</el-button>
|
||||
<el-button type="danger" :icon="Delete" :disabled="state.multiple" @click="handleDelete">删除</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
@@ -137,7 +137,7 @@
|
||||
<script setup lang="ts">
|
||||
import {listPermsWithPage, getPermDetail, addPerm, updatePerm, deletePerms} from "@/api/system/perm"
|
||||
import {Search, Plus, Edit, Refresh, Delete} from '@element-plus/icons'
|
||||
import {onMounted, watch, reactive, ref, unref, getCurrentInstance} from 'vue'
|
||||
import {onMounted, watch, reactive, ref, unref, getCurrentInstance, toRefs} from 'vue'
|
||||
import {ElForm, ElMessage, ElMessageBox} from "element-plus"
|
||||
|
||||
const {proxy}: any = getCurrentInstance();
|
||||
@@ -197,7 +197,7 @@ const state = reactive({
|
||||
]
|
||||
},
|
||||
microServiceOptions: [],
|
||||
requestMethodOptions: [],
|
||||
requestMethodOptions: [] as Array<any>,
|
||||
menuName: undefined,
|
||||
urlPerm: {
|
||||
requestMethod: undefined,
|
||||
@@ -206,6 +206,9 @@ const state = reactive({
|
||||
},
|
||||
})
|
||||
|
||||
toRefs(state)
|
||||
|
||||
|
||||
function handleQuery() {
|
||||
if (state.queryParams.menuId) {
|
||||
state.loading = true
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<el-tree
|
||||
ref="deptTreeRef"
|
||||
:data="deptOptions"
|
||||
:props="{ children: 'children',label: 'label'}"
|
||||
:props="{ children: 'children',label: 'label',disabled:''}"
|
||||
:expand-on-click-node="false"
|
||||
:filter-node-method="filterDeptNode"
|
||||
default-expand-all
|
||||
|
||||
Reference in New Issue
Block a user