From a79f0bd0d3580490a0b7f0ff669c55c5b3db11ca Mon Sep 17 00:00:00 2001 From: limengnan <420004014@qq.com> Date: Mon, 10 Nov 2025 10:59:46 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E6=94=B9sass=E8=BF=90?= =?UTF-8?q?=E8=A1=8C=E8=AD=A6=E5=91=8A=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/layout/components/Sidebar/MixNav.vue | 4 ++- .../src/layout/components/Sidebar/index.vue | 4 +++ framework/frontend/src/layout/index.vue | 6 ++-- framework/frontend/src/styles/index.scss | 8 ++--- framework/frontend/src/styles/sidebar.scss | 32 ++++++++++--------- framework/frontend/vite.config.ts | 10 +++++- 6 files changed, 40 insertions(+), 24 deletions(-) diff --git a/framework/frontend/src/layout/components/Sidebar/MixNav.vue b/framework/frontend/src/layout/components/Sidebar/MixNav.vue index 55b8a7f..31adfbe 100644 --- a/framework/frontend/src/layout/components/Sidebar/MixNav.vue +++ b/framework/frontend/src/layout/components/Sidebar/MixNav.vue @@ -126,6 +126,8 @@ function logout() { + \ No newline at end of file diff --git a/framework/frontend/src/layout/components/Sidebar/index.vue b/framework/frontend/src/layout/components/Sidebar/index.vue index 8fdf4f4..f150716 100644 --- a/framework/frontend/src/layout/components/Sidebar/index.vue +++ b/framework/frontend/src/layout/components/Sidebar/index.vue @@ -41,3 +41,7 @@ const activeMenu = computed(() => { + + \ No newline at end of file diff --git a/framework/frontend/src/layout/index.vue b/framework/frontend/src/layout/index.vue index af0c28d..8383406 100644 --- a/framework/frontend/src/layout/index.vue +++ b/framework/frontend/src/layout/index.vue @@ -91,8 +91,8 @@ function toggleSideBar() { + \ No newline at end of file diff --git a/framework/frontend/src/styles/index.scss b/framework/frontend/src/styles/index.scss index e0fa2bc..e6e58e4 100644 --- a/framework/frontend/src/styles/index.scss +++ b/framework/frontend/src/styles/index.scss @@ -1,7 +1,7 @@ -@import 'src/styles/variables.module'; -@import 'src/styles/element-plus'; -@import './sidebar.scss'; -@import './tailwind.scss'; +@use 'src/styles/variables.module' as variables; +@use 'src/styles/element-plus' as element-plus; +@use './sidebar' as sidebar; +@use './tailwind' as tailwind; html,body,#app{ height: 100%; diff --git a/framework/frontend/src/styles/sidebar.scss b/framework/frontend/src/styles/sidebar.scss index d0c50ae..a0e5c74 100644 --- a/framework/frontend/src/styles/sidebar.scss +++ b/framework/frontend/src/styles/sidebar.scss @@ -1,3 +1,5 @@ +@use 'src/styles/variables.module' as variables; + svg { vertical-align: text-bottom !important; } @@ -5,14 +7,14 @@ svg { .main-container { // min-height: 100%; transition: margin-left 0.28s; - margin-left: $sideBarWidth; + margin-left: variables.$sideBarWidth; position: relative; } .sidebar-container { transition: width 0.28s; - width: $sideBarWidth !important; - background-color: $menuBg; + width: variables.$sideBarWidth !important; + background-color: variables.$menuBg; height: calc(100vh - 60px); padding-top: 15px; position: absolute; @@ -70,25 +72,25 @@ svg { .submenu-title-noDropdown, .el-sub-menu__title { &:hover { - color: $menuHover !important; + color: variables.$menuHover !important; } } // .is-active > .el-sub-menu__title { - // color: $subMenuActiveText !important; + // color: variables.$subMenuActiveText !important; // } & .nest-menu .el-sub-menu > .el-sub-menu__title, & .el-sub-menu .el-menu-item { - min-width: $sideBarWidth !important; - background-color: $subMenuBg !important; + min-width: variables.$sideBarWidth !important; + background-color: variables.$subMenuBg !important; &:hover { - color: $subMenuHover !important; + color: variables.$subMenuHover !important; } } .el-menu-item.is-active { - border-right: 3px solid $subMenuHover; + border-right: 3px solid variables.$subMenuHover; background: #e8f3ff !important; } } @@ -159,7 +161,7 @@ svg { } .el-menu--collapse .el-menu .el-sub-menu { - min-width: $sideBarWidth !important; + min-width: variables.$sideBarWidth !important; } // mobile responsive @@ -170,14 +172,14 @@ svg { .sidebar-container { transition: transform 0.28s; - width: $sideBarWidth !important; + width: variables.$sideBarWidth !important; } &.hideSidebar { .sidebar-container { pointer-events: none; transition-duration: 0.3s; - transform: translate3d(-$sideBarWidth, 0, 0); + transform: translate3d(- variables.$sideBarWidth, 0, 0); } } } @@ -206,8 +208,8 @@ svg { .el-menu-item { &:hover { background-color: #ffffff; - // you can use $subMenuHover - color: $menuHover !important; + // you can use variables.$subMenuHover + color: variables.$menuHover !important; } } @@ -250,4 +252,4 @@ body[layout="mix"] { margin-right: 16px; } -} +} \ No newline at end of file diff --git a/framework/frontend/vite.config.ts b/framework/frontend/vite.config.ts index 7b198e2..e458fbb 100644 --- a/framework/frontend/vite.config.ts +++ b/framework/frontend/vite.config.ts @@ -39,6 +39,14 @@ export default ({ mode }: ConfigEnv): UserConfig => { alias: { '@': path.resolve('./src') } + }, + css: { + preprocessorOptions: { + scss: { + silenceDeprecations: ['legacy-js-api'], + api: 'modern-compiler' // 使用现代API + } + } } }; -}; +}; \ No newline at end of file From 3a8b721d7c89d1f6c4291989590b3fedce214a26 Mon Sep 17 00:00:00 2001 From: limengnan <420004014@qq.com> Date: Mon, 10 Nov 2025 11:41:42 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix=EF=BC=9A=E5=88=9D=E5=A7=8B=E5=8C=96?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/.gitignore | 8 +++ .idea/JavaProjectRepo.iml | 9 +++ .idea/compiler.xml | 19 ++++++ .idea/encodings.xml | 6 ++ .idea/inspectionProfiles/Project_Default.xml | 6 ++ .idea/jarRepositories.xml | 20 ++++++ .idea/misc.xml | 14 ++++ .idea/modules.xml | 8 +++ .idea/prettier.xml | 6 ++ .idea/vcs.xml | 6 ++ framework/frontend/src/layout/index.vue | 2 +- framework/pom.xml | 66 +------------------ .../com/yfd/platform/PlatformApplication.java | 5 +- 13 files changed, 108 insertions(+), 67 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/JavaProjectRepo.iml create mode 100644 .idea/compiler.xml create mode 100644 .idea/encodings.xml create mode 100644 .idea/inspectionProfiles/Project_Default.xml create mode 100644 .idea/jarRepositories.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/prettier.xml create mode 100644 .idea/vcs.xml diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..13566b8 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,8 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/JavaProjectRepo.iml b/.idea/JavaProjectRepo.iml new file mode 100644 index 0000000..d6ebd48 --- /dev/null +++ b/.idea/JavaProjectRepo.iml @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/compiler.xml b/.idea/compiler.xml new file mode 100644 index 0000000..c025d3e --- /dev/null +++ b/.idea/compiler.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/encodings.xml b/.idea/encodings.xml new file mode 100644 index 0000000..37cb34a --- /dev/null +++ b/.idea/encodings.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml new file mode 100644 index 0000000..03d9549 --- /dev/null +++ b/.idea/inspectionProfiles/Project_Default.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml new file mode 100644 index 0000000..712ab9d --- /dev/null +++ b/.idea/jarRepositories.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..ba63d7d --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,14 @@ + + + + + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..3dc5630 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/prettier.xml b/.idea/prettier.xml new file mode 100644 index 0000000..b0c1c68 --- /dev/null +++ b/.idea/prettier.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/framework/frontend/src/layout/index.vue b/framework/frontend/src/layout/index.vue index 8383406..4b217e6 100644 --- a/framework/frontend/src/layout/index.vue +++ b/framework/frontend/src/layout/index.vue @@ -95,7 +95,7 @@ function toggleSideBar() { @use '@/styles/variables.module.scss' as variables; .app-wrapper { - @include clearfix; + // @include clearfix; position: relative; height: 100%; width: 100%; diff --git a/framework/pom.xml b/framework/pom.xml index a416d3b..bf9f6cf 100644 --- a/framework/pom.xml +++ b/framework/pom.xml @@ -312,70 +312,8 @@ - - - org.codehaus.mojo - exec-maven-plugin - 3.1.0 - - - frontend-install - generate-resources - - exec - - - npm - ${project.basedir}/frontend - - install - - - - - frontend-build - generate-resources - - exec - - - npm - ${project.basedir}/frontend - - run - build:mvn - - - - - - - org.apache.maven.plugins - maven-resources-plugin - 3.3.1 - - - copy-frontend - process-resources - - copy-resources - - - true - true - false - ${project.basedir}/src/main/resources/static - - - ${project.basedir}/frontend/dist - false - - - - - - + org.asciidoctor asciidoctor-maven-plugin @@ -402,7 +340,7 @@ -Dfile.encoding=UTF-8 - true + org.projectlombok diff --git a/framework/src/main/java/com/yfd/platform/PlatformApplication.java b/framework/src/main/java/com/yfd/platform/PlatformApplication.java index a98fea6..769402c 100644 --- a/framework/src/main/java/com/yfd/platform/PlatformApplication.java +++ b/framework/src/main/java/com/yfd/platform/PlatformApplication.java @@ -6,6 +6,7 @@ import com.yfd.platform.utils.SpringContextHolder; import org.mybatis.spring.annotation.MapperScan; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.boot.autoconfigure.data.redis.RedisAutoConfiguration; import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; import org.springframework.boot.web.servlet.ServletComponentScan; import org.springframework.cache.annotation.EnableCaching; @@ -18,8 +19,8 @@ import org.springframework.web.bind.annotation.RestController; @RestController @EnableTransactionManagement @ServletComponentScan("com.yfd.platform.config") -@MapperScan(basePackages = "com.yfd.platform.modules.*.mapper,com.yfd.platform.*.mapper") -@SpringBootApplication(exclude= {DataSourceAutoConfiguration.class}) +@MapperScan(basePackages = "com.yfd.platform.*.mapper") +@SpringBootApplication(exclude= {DataSourceAutoConfiguration.class, RedisAutoConfiguration.class}) @Import({DynamicDataSourceConfig.class}) @EnableCaching public class PlatformApplication {