修改代码
This commit is contained in:
parent
c107101ef9
commit
05ecd67e3b
|
|
@ -1,2 +1,2 @@
|
|||
VUE_APP_BASE=/ #打包路径
|
||||
VITE_API_URL=http://192.168.195.30:91
|
||||
VITE_API_URL=http://localhost:901/
|
||||
2
admin-client/dist/index.html
vendored
2
admin-client/dist/index.html
vendored
|
|
@ -7,7 +7,7 @@
|
|||
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>寰梦后台管理</title>
|
||||
<script type="module" crossorigin src="/static/js/index-DZ3SCI4I.js"></script>
|
||||
<script type="module" crossorigin src="/static/js/index-D6L9FI9G.js"></script>
|
||||
<link rel="stylesheet" crossorigin href="/static/css/index-CzwB8sLn.css">
|
||||
</head>
|
||||
|
||||
|
|
|
|||
4
admin-client/src/components.d.ts
vendored
4
admin-client/src/components.d.ts
vendored
|
|
@ -40,6 +40,7 @@ declare module 'vue' {
|
|||
AInputSearch: typeof import('ant-design-vue/es')['InputSearch']
|
||||
ALayout: typeof import('ant-design-vue/es')['Layout']
|
||||
ALayoutContent: typeof import('ant-design-vue/es')['LayoutContent']
|
||||
ALayoutFooter: typeof import('ant-design-vue/es')['LayoutFooter']
|
||||
ALayoutHeader: typeof import('ant-design-vue/es')['LayoutHeader']
|
||||
ALayoutSider: typeof import('ant-design-vue/es')['LayoutSider']
|
||||
AMenu: typeof import('ant-design-vue/es')['Menu']
|
||||
|
|
@ -81,6 +82,7 @@ declare module 'vue' {
|
|||
AUploadDragger: typeof import('ant-design-vue/es')['UploadDragger']
|
||||
BarChartTransverse: typeof import('./core/components/charts/BarChartTransverse.vue')['default']
|
||||
ColumnSetting: typeof import('./core/components/curd/components/ColumnSetting.vue')['default']
|
||||
copy: typeof import('./core/components/layouts/LayoutMode1 copy.vue')['default']
|
||||
ExternalJump: typeof import('./core/components/ExternalJump.vue')['default']
|
||||
FindBack: typeof import('./core/components/FindBack.vue')['default']
|
||||
GenerateCron: typeof import('./core/components/GenerateCron.vue')['default']
|
||||
|
|
@ -103,6 +105,8 @@ declare module 'vue' {
|
|||
LayoutMenuPc: typeof import('./core/components/layouts/LayoutMenuPc.vue')['default']
|
||||
LayoutMenuSub: typeof import('./core/components/layouts/menus/LayoutMenuSub.vue')['default']
|
||||
LayoutMode1: typeof import('./core/components/layouts/LayoutMode1.vue')['default']
|
||||
LayoutMode2: typeof import('./core/components/layouts/LayoutMode2.vue')['default']
|
||||
LayoutMode3: typeof import('./core/components/layouts/LayoutMode3.vue')['default']
|
||||
LayoutSettings: typeof import('./core/components/layouts/LayoutSettings.vue')['default']
|
||||
LayoutSider: typeof import('./core/components/layouts/LayoutSider.vue')['default']
|
||||
LayoutTabs: typeof import('./core/components/layouts/LayoutTabs.vue')['default']
|
||||
|
|
|
|||
|
|
@ -1,11 +1,12 @@
|
|||
<script lang="ts" setup>
|
||||
import LayoutMode1 from "./LayoutMode1.vue";
|
||||
import LayoutMode2 from "./LayoutMode2.vue";
|
||||
import LayoutSettings from "./LayoutSettings.vue";
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="hzy-layout">
|
||||
<LayoutMode1 />
|
||||
<LayoutMode2 />
|
||||
<!--设置弹框-->
|
||||
<LayoutSettings />
|
||||
</div>
|
||||
|
|
|
|||
124
admin-client/src/core/components/layouts/LayoutMode2.vue
Normal file
124
admin-client/src/core/components/layouts/LayoutMode2.vue
Normal file
|
|
@ -0,0 +1,124 @@
|
|||
<script lang="ts" setup>
|
||||
import { computed } from "vue";
|
||||
import LayoutHeaderVue from "./LayoutHeader.vue";
|
||||
import LayoutTabsVue from "./LayoutTabs.vue";
|
||||
import LayoutSider from "./LayoutSider.vue";
|
||||
import TabsStore from "@/core/store/layouts/TabsStore";
|
||||
import AppStore from "@/core/store/AppStore";
|
||||
import MenuStore, { EMenuMode } from "@/core/store/layouts/MenuStore";
|
||||
import CoreStore from "@/core/store/layouts/CoreStore";
|
||||
import LayoutIframe from "./LayoutIframe.vue";
|
||||
import ThemeStore from "@/core/store/layouts/ThemeStore";
|
||||
import LayoutMenuPcVue from "./LayoutMenuPc.vue";
|
||||
import router from "@/core/router";
|
||||
|
||||
const tabsStore = TabsStore();
|
||||
const appStore = AppStore();
|
||||
const menuStore = MenuStore();
|
||||
const coreStore = CoreStore();
|
||||
const themeStore = ThemeStore();
|
||||
console.log(tabsStore.state);
|
||||
console.log(tabsStore.state.tabs[0]);
|
||||
|
||||
//当前年份
|
||||
const year = new Date().getFullYear();
|
||||
|
||||
//计算与左侧边距
|
||||
let left = computed(() => {
|
||||
if (coreStore.state.isMobile) return 0 + "px";
|
||||
return (
|
||||
menuStore.state.width +
|
||||
(menuStore.state.menuMode == EMenuMode.left
|
||||
? menuStore.state.leftModeWidth
|
||||
: 0) +
|
||||
"px"
|
||||
);
|
||||
});
|
||||
|
||||
const activeKey = ref("zhuye");
|
||||
const newTabIndex = ref(0);
|
||||
let tabsList = reactive([]);
|
||||
onMounted(() => {
|
||||
// addTags();
|
||||
// router.push({
|
||||
// name:"aaa",
|
||||
// path: tabsStore.state.tabs[0].fullPath,
|
||||
// });
|
||||
});
|
||||
|
||||
watch(
|
||||
() => router.currentRoute.value.fullPath,
|
||||
(value) => {
|
||||
// console.log("切换页面", value);
|
||||
// tabsList.push({ name: value });
|
||||
// addTags();
|
||||
}
|
||||
);
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<a-layout>
|
||||
<LayoutMenuPcVue />
|
||||
<a-layout>
|
||||
<LayoutHeaderVue />
|
||||
<a-layout-content>
|
||||
<LayoutTabsVue />
|
||||
<div style="height: calc(100vh - 120px); overflow: auto">
|
||||
<router-view v-slot="{ Component, route }">
|
||||
<transition name="fade-transform" mode="out-in">
|
||||
<keep-alive>
|
||||
<component :is="Component" :key="route.fullPath" />
|
||||
</keep-alive>
|
||||
</transition>
|
||||
</router-view>
|
||||
</div>
|
||||
</a-layout-content>
|
||||
</a-layout>
|
||||
</a-layout>
|
||||
</template>
|
||||
|
||||
<style lang="less">
|
||||
.tabs {
|
||||
.ant-tabs-content-holder {
|
||||
.ant-tabs-content {
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.hzy-layout {
|
||||
.ant-layout {
|
||||
//background-color: #ffffff;
|
||||
|
||||
.ant-layout-sider {
|
||||
overflow: auto;
|
||||
left: 0;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.ant-layout-content {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.hzy-header-content {
|
||||
position: fixed;
|
||||
z-index: 9;
|
||||
right: 0;
|
||||
top: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.hzy-ground-glass {
|
||||
// 透明样式
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
top: 0;
|
||||
//background-image: radial-gradient(transparent 1px, #ffffff 1px);
|
||||
background-size: 4px 4px;
|
||||
backdrop-filter: saturate(50%) blur(1px);
|
||||
-webkit-backdrop-filter: saturate(50%) blur(1px);
|
||||
box-shadow: 0 4px 4px #00152914;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
109
admin-client/src/core/components/layouts/LayoutMode3.vue
Normal file
109
admin-client/src/core/components/layouts/LayoutMode3.vue
Normal file
|
|
@ -0,0 +1,109 @@
|
|||
<script lang="ts" setup>
|
||||
import { computed } from "vue";
|
||||
import LayoutHeaderVue from "./LayoutHeader.vue";
|
||||
import LayoutTabsVue from "./LayoutTabs.vue";
|
||||
import LayoutSider from "./LayoutSider.vue";
|
||||
import TabsStore from "@/core/store/layouts/TabsStore";
|
||||
import AppStore from "@/core/store/AppStore";
|
||||
import MenuStore, { EMenuMode } from "@/core/store/layouts/MenuStore";
|
||||
import CoreStore from "@/core/store/layouts/CoreStore";
|
||||
import LayoutIframe from "./LayoutIframe.vue";
|
||||
import ThemeStore from "@/core/store/layouts/ThemeStore";
|
||||
|
||||
const tabsStore = TabsStore();
|
||||
const appStore = AppStore();
|
||||
const menuStore = MenuStore();
|
||||
const coreStore = CoreStore();
|
||||
const themeStore = ThemeStore();
|
||||
|
||||
//当前年份
|
||||
const year = new Date().getFullYear();
|
||||
|
||||
//计算与左侧边距
|
||||
let left = computed(() => {
|
||||
if (coreStore.state.isMobile) return 0 + "px";
|
||||
return (
|
||||
menuStore.state.width +
|
||||
(menuStore.state.menuMode == EMenuMode.left
|
||||
? menuStore.state.leftModeWidth
|
||||
: 0) +
|
||||
"px"
|
||||
);
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<a-layout style="min-height: 100vh">
|
||||
<!-- 菜单 -->
|
||||
<LayoutSider />
|
||||
<!-- 头部 -->
|
||||
<a-card
|
||||
:bordered="false"
|
||||
:bodyStyle="{ padding: 0 }"
|
||||
class="hzy-header-content"
|
||||
:style="{ left, borderRadius: 0, boxShadow: 'none' }"
|
||||
>
|
||||
<div>
|
||||
<LayoutHeaderVue />
|
||||
<LayoutTabsVue />
|
||||
</div>
|
||||
</a-card>
|
||||
aa
|
||||
<a-layout :style="{ marginLeft: left }">
|
||||
<a-layout-content>
|
||||
<div style="height: calc(100vh - 120px); overflow: auto">
|
||||
<router-view v-slot="{ Component, route }">
|
||||
<transition name="fade-transform" mode="out-in">
|
||||
<keep-alive>
|
||||
<component :is="Component" :key="route.fullPath" />
|
||||
</keep-alive>
|
||||
</transition>
|
||||
</router-view>
|
||||
<!-- iframe 处理 -->
|
||||
<LayoutIframe />
|
||||
</div>
|
||||
<!-- 返回顶部 -->
|
||||
<!-- <a-back-top /> -->
|
||||
</a-layout-content>
|
||||
</a-layout>
|
||||
</a-layout>
|
||||
</template>
|
||||
|
||||
<style lang="less">
|
||||
.hzy-layout {
|
||||
.ant-layout {
|
||||
//background-color: #ffffff;
|
||||
|
||||
.ant-layout-sider {
|
||||
overflow: auto;
|
||||
left: 0;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.ant-layout-content {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.hzy-header-content {
|
||||
position: fixed;
|
||||
z-index: 9;
|
||||
right: 0;
|
||||
top: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.hzy-ground-glass {
|
||||
// 透明样式
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
top: 0;
|
||||
//background-image: radial-gradient(transparent 1px, #ffffff 1px);
|
||||
background-size: 4px 4px;
|
||||
backdrop-filter: saturate(50%) blur(1px);
|
||||
-webkit-backdrop-filter: saturate(50%) blur(1px);
|
||||
box-shadow: 0 4px 4px #00152914;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -70,10 +70,26 @@ const tabsTheme = computed(() => {
|
|||
},
|
||||
}"
|
||||
>
|
||||
<a-tabs hide-add tabPosition="top" type="editable-card" :tabBarGutter="0" @edit="onEdit" @change="tabOnChange" :activeKey="tabsStore.state.activeKey">
|
||||
<a-tab-pane v-for="item in tabsStore.state.tabs" :key="item.fullPath" :closable="item.meta.close">
|
||||
<a-tabs
|
||||
:destroyInactiveTabPane="false"
|
||||
hide-add
|
||||
tabPosition="top"
|
||||
type="editable-card"
|
||||
:tabBarGutter="0"
|
||||
@edit="onEdit"
|
||||
@change="tabOnChange"
|
||||
:activeKey="tabsStore.state.activeKey"
|
||||
>
|
||||
<a-tab-pane
|
||||
:forceRender="false"
|
||||
v-for="item in tabsStore.state.tabs"
|
||||
:key="item.fullPath"
|
||||
:closable="item.meta.close"
|
||||
>
|
||||
<template #tab>
|
||||
<span>{{ translate(`menu.${item.meta.menuId}`, item.meta.title) }}</span>
|
||||
<span>{{
|
||||
translate(`menu.${item.meta.menuId}`, item.meta.title)
|
||||
}}</span>
|
||||
</template>
|
||||
<template #closeIcon>
|
||||
<AppIcon name="CloseOutlined" :size="12" class="close" />
|
||||
|
|
@ -81,7 +97,12 @@ const tabsTheme = computed(() => {
|
|||
</a-tab-pane>
|
||||
<template #rightExtra>
|
||||
<a-dropdown placement="bottomRight">
|
||||
<AppIcon name="MoreOutlined" class="pl-16 pr-16" style="height: 100%" :size="16" />
|
||||
<AppIcon
|
||||
name="MoreOutlined"
|
||||
class="pl-16 pr-16"
|
||||
style="height: 100%"
|
||||
:size="16"
|
||||
/>
|
||||
<template #overlay>
|
||||
<a-menu>
|
||||
<a-menu-item key="2" @click="closeTabOther()">
|
||||
|
|
|
|||
|
|
@ -42,8 +42,12 @@ async function check() {
|
|||
const result = await LoginService.login(state.userName, state.userPassword);
|
||||
loading.value = false;
|
||||
if (result.code != 200) return;
|
||||
|
||||
console.log(result.data);
|
||||
|
||||
Tools.setAuthorization(result.data.token);
|
||||
// router.push("/");
|
||||
|
||||
window.location.href = window.location.origin;
|
||||
} catch (error) {
|
||||
loading.value = false;
|
||||
|
|
|
|||
|
|
@ -40,6 +40,7 @@ const refSearchForm = ref<FormInstance>();
|
|||
* 初始化
|
||||
*/
|
||||
onMounted(() => {
|
||||
console.log('加载')
|
||||
findList();
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ export default defineConfig({
|
|||
*/
|
||||
base: process.env.VUE_APP_BASE, // process.env.NODE_ENV == "production" ? "/client/" : "/",
|
||||
server: {
|
||||
port: 5501,
|
||||
port: 501,
|
||||
host: true,
|
||||
proxy: {
|
||||
"/api/v1": {
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
//"ConnectionString": "Server=localhost; port=3306; Database=hzy_admin_mysql_20230227; uid=root; pwd=123456; Convert Zero Datetime=False"
|
||||
//// 连接字符串 - sqlserver
|
||||
//"ConnectionString": "Server=192.168.195.2;Database=MiaoYu;User ID=zpc;Password=zpc;MultipleActiveResultSets=true;Encrypt=True;TrustServerCertificate=True;",
|
||||
"ConnectionString": "Server=192.168.195.2;Database=HZY;User ID=zpc;Password=zpc;MultipleActiveResultSets=true;Encrypt=True;TrustServerCertificate=True;"
|
||||
"ConnectionString": "Server=192.168.1.17;Database=HZY;User Id=sa;Password=Dbt@com@123;MultipleActiveResultSets=true;Encrypt=True;TrustServerCertificate=True;"
|
||||
//// 连接字符串 - postgresql
|
||||
//"ConnectionString": "User ID=postgres;Password=123456;Host=localhost;Port=5432;Database=hzy_microservices_pgsql_20230227;Pooling=true;TimeZone=Asia/Shanghai",
|
||||
//// 连接字符串 - oracle
|
||||
|
|
@ -32,7 +32,7 @@
|
|||
"Kestrel": {
|
||||
"Endpoints": {
|
||||
"Http": {
|
||||
"Url": "http://*:91"
|
||||
"Url": "http://*:901"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user