소스 검색

Fix 修复部分问题

Yue 1 년 전
부모
커밋
ea82e93da1

+ 4 - 0
SERVER/VberAdminPlus/vber-system/pom.xml

@@ -25,6 +25,10 @@
             <groupId>com.vap</groupId>
             <artifactId>vber-oss</artifactId>
         </dependency>
+        <dependency>
+            <groupId>com.xuxueli</groupId>
+            <artifactId>xxl-job-core</artifactId>
+        </dependency>
     </dependencies>
 
 

+ 4 - 0
UI/VAP.Vue/src/assets/sass/_common.scss

@@ -59,3 +59,7 @@ dl {
 		}
 	}
 }
+
+.el-button.btn {
+	display: inline-flex !important;
+}

+ 1 - 1
UI/VAP.Vue/src/components/modal/VbModal.vue

@@ -232,7 +232,7 @@ defineExpose({ show, resetForm, validateForm, changePrefixTitle, modalFormRef })
 			:id="id">
 			<div class="modal-dialog" :class="modalDialogClass" :style="modalDialogStyle">
 				<div class="modal-content" :class="modalContentClass" :style="modalContentStyle">
-					<div class="modal-header py-3" :class="modalHeaderClass" :style="modalHeaderStyle">
+					<div class="modal-header justify-content-between py-3" :class="modalHeaderClass" :style="modalHeaderStyle">
 						<template v-if="$slots.title">
 							<slot name="title" />
 						</template>

+ 16 - 1
UI/VAP.Vue/src/components/tree/DeptTree.vue

@@ -1,5 +1,6 @@
 <script setup lang="ts">
 import apis from "@a"
+import appStore from "@s"
 const props = withDefaults(
 	defineProps<{
 		modelValue?: string | number
@@ -34,12 +35,26 @@ function handleNodeClick(data: any) {
 function loadTreeData() {
 	if (data?.value) {
 		treeData.value = data.value
+		if (treeData.value.length > 0) {
+			initDefaultKey(treeData.value[0].id)
+		}
 	} else {
 		apis.system.userApi.deptTreeSelect().then((res) => {
 			treeData.value = res.data
+			if (treeData.value.length > 0) {
+				initDefaultKey(treeData.value[0].id)
+			}
 		})
 	}
 }
+/** 初始化默认选中 */
+function initDefaultKey(id: any) {
+	emits("update:modelValue", id)
+	setTimeout(() => {
+		treeRef.value.setCurrentKey(id)
+	}, 50)
+}
+
 function init() {
 	loadTreeData()
 }
@@ -55,7 +70,7 @@ watch(
 </script>
 <template>
 	<div :class="treeBoxClass" :style="treeBoxStyle">
-		<el-input v-model="searchWords" placeholder="请输入部门名称" clearable prefix-icon="Search" />
+		<!-- <el-input v-model="searchWords" placeholder="请输入组织机构名称" clearable prefix-icon="Search" /> -->
 		<el-tree
 			class="pt-3"
 			ref="treeRef"

+ 3 - 1
UI/VAP.Vue/src/views/system/user/index.vue

@@ -248,6 +248,7 @@ const modalOpts = reactive({
 		}
 	] as any,
 	emptyFormData: {
+		id: undefined,
 		userId: undefined,
 		deptId: undefined,
 		userName: undefined,
@@ -263,7 +264,7 @@ const modalOpts = reactive({
 	}
 })
 const { title: modalTitle, emptyFormData, formItems } = toRefs(modalOpts)
-const form = ref(emptyFormData)
+const form = ref(emptyFormData.value)
 function reset() {
 	form.value = emptyFormData.value
 }
@@ -273,6 +274,7 @@ function handleCreate() {
 	reset()
 	apis.system.userApi.getUser().then(({ data }) => {
 		setOptions(data)
+		form.value = emptyFormData.value
 		form.value.password = initPassword.value
 		modalRef.value.show()
 	})