feat: 优化代码结构

This commit is contained in:
lbw 2023-03-08 15:22:28 +08:00
parent 18c0941817
commit 780c69459f
2 changed files with 4 additions and 4 deletions

View File

@ -94,7 +94,6 @@ const menuData = ref([]);
const dataRules = ref({
name: [{ required: true, message: 'name不能为空', trigger: 'blur' }],
code: [{ required: true, message: 'code不能为空', trigger: 'blur' }],
tenantDomain: [{ required: true, message: 'tenantDomain不能为空', trigger: 'blur' }],
startTime: [{ required: true, message: '开始时间不能为空', trigger: 'blur' }],
endTime: [{ required: true, message: '结束时间不能为空', trigger: 'blur' }],
status: [{ required: true, message: 'status不能为空', trigger: 'blur' }],

View File

@ -42,13 +42,14 @@
</template>
<script setup lang="ts" name="tenant-menu-form">
import { treemenu, addObj, putObj } from '/@/api/admin/tenant-menu';
import { useMessage } from '/@/hooks/message';
import { getObj } from '/@/api/admin/tenant-menu';
import { useDict } from '/@/hooks/dict';
import { useI18n } from 'vue-i18n';
const { status_type } = useDict('status_type');
const { t } = useI18n();
import { treemenu, addObj, putObj } from '/@/api/admin/tenant-menu';
import { useMessage } from '/@/hooks/message';
const emit = defineEmits(['refresh']);
const dataFormRef = ref();
@ -57,7 +58,7 @@ const menuTreeRef = ref();
const form = reactive({
id: '',
status: '',
status: '0',
name: '',
menuIds: '',
});