diff --git a/.env.development b/.env.development index 260c812d..e2a61260 100644 --- a/.env.development +++ b/.env.development @@ -21,4 +21,4 @@ port= 9988 // 测试端 // target = http://192.168.10.241:32024 // 开发端 - target = http://192.168.10.241:30646 + target = http://192.168.1.17:8899 diff --git a/package.json b/package.json index 4f09441d..fcfb9d8a 100644 --- a/package.json +++ b/package.json @@ -55,10 +55,10 @@ "js-md5": "^0.7.3", "jsencrypt": "3.0.0-rc.1", "moment": "^2.29.4", - "node-sass": "^4.9.0", "nprogress": "0.2.0", "qrcodejs2": "^0.0.2", "quill": "1.3.7", + "sass": "1.32.12", "sass-loader": "^7.0.1", "save": "^2.5.0", "screenfull": "5.0.2", @@ -84,7 +84,6 @@ "eslint": "7.15.0", "eslint-plugin-vue": "7.2.0", "lint-staged": "10.5.3", - "node-sass": "^4.9.0", "runjs": "4.4.2", "sass-loader": "^7.0.1", "script-ext-html-webpack-plugin": "2.1.5", diff --git a/public/index.html b/public/index.html index 98fbbf47..af83335d 100644 --- a/public/index.html +++ b/public/index.html @@ -19,7 +19,7 @@ - + <%= webpackConfig.name %> + +
diff --git a/public/systenConfig.js b/public/systenConfig.js new file mode 100644 index 00000000..f1c89767 --- /dev/null +++ b/public/systenConfig.js @@ -0,0 +1,3 @@ +window._SYSTEMCONFIG = {} +window._SYSTEMCONFIG['logoURL'] = '@/assets/logo/drgy/logo.png' +window._SYSTEMCONFIG['systemName'] = '数字用电管理系统' diff --git a/src/assets/images/green-login/login-bg.png b/src/assets/images/green-login/login-bg.png new file mode 100644 index 00000000..cbb2396d Binary files /dev/null and b/src/assets/images/green-login/login-bg.png differ diff --git a/src/assets/logo/drgy/logo.png b/src/assets/logo/drgy/logo.png new file mode 100644 index 00000000..61044101 Binary files /dev/null and b/src/assets/logo/drgy/logo.png differ diff --git a/src/assets/styles/index.scss b/src/assets/styles/index.scss index d56b1a2c..44706b63 100644 --- a/src/assets/styles/index.scss +++ b/src/assets/styles/index.scss @@ -5,6 +5,7 @@ @import './sidebar.scss'; @import './btn.scss'; @import './e-custom-style.scss'; +@import "./theme.scss"; body { height: 100%; diff --git a/src/assets/styles/sidebar.scss b/src/assets/styles/sidebar.scss index 13822fb0..038567a9 100644 --- a/src/assets/styles/sidebar.scss +++ b/src/assets/styles/sidebar.scss @@ -87,7 +87,7 @@ & .nest-menu .el-submenu>.el-submenu__title, & .el-submenu .el-menu-item { min-width: $sideBarWidth !important; - background-color: $subMenuBg !important; + //background-color: $subMenuBg !important; &:hover { background-color: rgba(0, 0, 0, 0.06) !important; @@ -115,6 +115,19 @@ background-color: $subMenuHover !important; } } + + //& .theme-Green .is-active > .el-submenu__title { + // color: $menuGreenHover !important; + //} + // + & .theme-Green .nest-menu .el-submenu>.el-submenu__title, + & .theme-Green .el-submenu .el-menu-item { + background-color: $menuGreenBg !important; + + &:hover { + background-color: $menuGreenActiveHover !important; + } + } } .hideSidebar { diff --git a/src/assets/styles/theme.scss b/src/assets/styles/theme.scss new file mode 100644 index 00000000..f84a8ba1 --- /dev/null +++ b/src/assets/styles/theme.scss @@ -0,0 +1,187 @@ +//theme-green主题 +.theme-green{ + //logo + .sidebar-logo-container{ + background: $menuGreenLogoBg !important; + } + .sidebar-title{ + color: $menuGreenLogoColor !important; + } + + .sidebar-container{ + background-color: $menuGreenBg !important; + + .el-submenu>.el-submenu__title{ + background-color: $menuGreenBg !important; + color: $sidebarGreenTitle !important; + &:hover{ + background: $menuGreenActiveHover !important; + } + } + .el-menu,.el-menu-item{ + background-color: $menuGreenBg !important; + color: $sidebarGreenTitle !important; + &:hover{ + background: $menuGreenActiveHover !important; + } + + } + .el-submenu.is-active>.el-submenu__title,.el-submenu.is-active .el-menu-item{ + background-color: $menuGreenLogoBg !important; + } + .el-submenu.is-active>.el-submenu__title{ + background-color: $menuGreenActive !important; + color: $menuGreenActiveTxt !important; + } + .el-submenu.is-active .el-menu-item.is-active{ + background: $menuGreenActive !important; + color: $menuGreenActiveTxt !important; + } + } + .router-link-active>.is-active{ + color: $menuGreenActiveTxt !important; + background: $menuGreenActive !important; + } + //右上角颜色 + .right-menu-item{ + color: $menuGreenBg !important; + } + //tag样式 + .tags-view-container .tags-view-wrapper .tags-view-item.active{ + background-color: $menuGreenBg !important; + } +} + + +//theme-blue-black主题 +.theme-blue-black{ + //logo + .sidebar-logo-container{ + background: $menuBlueBlackLogoBg !important; + } + .sidebar-title{ + color: $menuBlueBlackLogoColor !important; + } + + .sidebar-container{ + background-color: $menuBlueBlackBg !important; + .el-submenu>.el-submenu__title{ + background-color: $menuBlueBlackBg !important; + color: $sidebarBlueBlackTitle !important; + &:hover{ + color: $menuBlueBlackLogoColor !important; + background: $menuBlueBlackActiveHover !important; + } + } + .el-menu,.el-menu-item{ + background-color: $menuBlueBlackBg !important; + color: $sidebarBlueBlackTitle !important; + &:hover{ + color: $menuBlueBlackLogoColor !important; + background: $menuBlueBlackActiveHover !important; + } + } + .el-submenu.is-active>.el-submenu__title,.el-submenu.is-active .el-menu-item{ + background-color: $menuBlueBlackActiveBg !important; + } + .el-submenu.is-active>.el-submenu__title{ + color: $menuBlueBlackLogoColor !important; + } + .el-submenu.is-active .el-menu-item.is-active{ + color: $menuBlueBlackLogoColor !important; + background: $menuBlueBlackActive !important; + } + } + .router-link-active>.is-active{ + color: $menuBlueBlackLogoColor !important; + background: $menuBlueBlackActive !important; + } + //右上角颜色 + .right-menu-item{ + color: $menuBlueBlackLogoColor !important; + } + //tag样式 + .tags-view-container .tags-view-wrapper .tags-view-item.active{ + background-color: $menuBlueBlackLogoColor !important; + } +} + +//theme-blue-white主题 +.theme-blue-white{ + //logo + .sidebar-logo-container{ + background: $menuBlueWhiteLogoBg !important; + } + .sidebar-title{ + color: $menuBlueWhiteLogoColor !important; + } + + .sidebar-container{ + background-color: $menuBlueWhiteBg !important; + .el-submenu>.el-submenu__title{ + background-color: $menuBlueWhiteBg !important; + .svg-icon{ + color: $sidebarBlueWhiteTitle !important; + } + //color: $sidebarBlueWhiteTitle !important; + &:hover{ + color: $menuBlueWhiteBg !important; + background: $menuBlueWhiteActiveHover !important; + .svg-icon{ + color: $menuBlueWhiteBg !important; + } + } + } + .el-menu,.el-menu-item{ + background-color: $menuBlueWhiteBg !important; + .svg-icon{ + color: $sidebarBlueWhiteTitle !important; + } + &:hover{ + color: $menuBlueWhiteBg !important; + background: $menuBlueWhiteActiveHover !important; + //.svg-icon{ + // color: $menuBlueWhiteText !important; + //} + } + } + .el-menu-item{ + &:hover{ + .svg-icon{ + color: $menuBlueWhiteText !important; + } + } + } + + .el-submenu.is-active .el-submenu__title{ + color: $menuBlueWhiteBg !important; + background: $menuBlueWhiteHover !important; + .svg-icon{ + color: $menuBlueWhiteText !important; + } + } + .el-submenu.is-active .el-menu-item.is-active{ + color: $menuBlueWhiteBg !important; + background: $menuBlueWhiteHover !important; + .svg-icon{ + color: $menuBlueWhiteText !important; + } + } + + } + .router-link-active>.is-active{ + color: $menuBlueWhiteBg !important; + background: $menuBlueWhiteHover !important; + .svg-icon{ + color: $menuBlueWhiteText !important; + } + } + //右上角颜色 + .right-menu-item{ + color: $menuBlueWhiteLogoColor !important; + } + //tag样式 + .tags-view-container .tags-view-wrapper .tags-view-item.active{ + background-color: $menuBlueWhiteLogoColor !important; + } +} diff --git a/src/assets/styles/variables.scss b/src/assets/styles/variables.scss index 040e3f12..d23a8b2e 100644 --- a/src/assets/styles/variables.scss +++ b/src/assets/styles/variables.scss @@ -21,10 +21,42 @@ $menuLightBg:#ffffff; $menuLightHover:#f0f1f5; $sidebarLightTitle: #001529; +$menuN1Text:#bfcbd9; $menuN1Bg:#07204b; $menuN1Hover:#051249; $sidebarN1Title: #ffffff; +//theme-Green 样式 +$menuGreenText:#ffffff; +$menuGreenLogoBg:#00a0a2; +$menuGreenLogoColor:#fff; +$menuGreenBg:#00a9ab; +$menuGreenHover:#55FDFF; +$menuGreenActive:#009698; +$menuGreenActiveTxt:#55FDFF; +$menuGreenActiveHover:#009fa1; +$sidebarGreenTitle: #ffffff; + +//theme-blue-black样式 +$menuBlueBlackText:#ffffff; +$menuBlueBlackLogoBg:#041a2f; +$menuBlueBlackLogoColor:#1890FF; +$menuBlueBlackBg:#041a2f; +$menuBlueBlackHover:#1d3144; +$menuBlueBlackActive:#1d3144; +$menuBlueBlackActiveBg:#11263a; +$menuBlueBlackActiveHover:#1d3144; +$sidebarBlueBlackTitle: #587A99; + +//theme-blue-white样式 +$menuBlueWhiteText:#ffffff; +$menuBlueWhiteLogoBg:#FFFFFF; +$menuBlueWhiteLogoColor:#0066CC; +$menuBlueWhiteBg:#FFFFFF; +$menuBlueWhiteHover:#0066cc; +$menuBlueWhiteActiveHover:#0066cc; +$sidebarBlueWhiteTitle: #0066CC; + $subMenuBg:#050d2f; $subMenuHover:#003083; @@ -42,9 +74,15 @@ $sideBarWidth: 200px; menuLightBg: $menuLightBg; menuLightHover: $menuLightHover; // + menuN1Text:$menuN1Text; menuN1Bg:$menuN1Bg; menuN1Hover:$menuN1Hover; sidebarN1Title:$sidebarN1Title; + //绿色背景 + menuGreenText:$menuGreenText; + menuGreenBg:$menuGreenBg; + menuGreenHover:$menuGreenHover; + sidebarGreenTitle:$sidebarGreenTitle; // subMenuBg: $subMenuBg; subMenuHover: $subMenuHover; diff --git a/src/config/env.js b/src/config/env.js index 7c441bd3..87302600 100644 --- a/src/config/env.js +++ b/src/config/env.js @@ -29,7 +29,8 @@ let httpProtocol = window.dasConfig.protocol ? window.dasConfig.protocol : 'http if (env.NODE_ENV == 'development') { flowIotUrl = 'http://127.0.0.1:1880/#flow/' - hrefHost = "power-tcore.histron.cn" + // hrefHost = "power-tcore.histron.cn" + hrefHost = "192.168.1.17" } else if(env.NODE_ENV == 'production') { // if (hrefHost.indexOf('.gkiiot.com') >= 0) { // iotHost = 'iot.gkiiot.com' @@ -42,7 +43,7 @@ if (env.NODE_ENV == 'development') { } port = window.dasConfig.port ? ':' + window.dasConfig.port : ''; port = port + (window.dasConfig.prodApi ? window.dasConfig.prodApi : '') - + } else if(env.NODE_ENV == 'test') { } sysWebSocket = sysWebSocket + hrefHost + port; diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index 9b979722..9d4224ba 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -150,7 +150,7 @@ export default { display: inline-block; padding: 0 8px; height: 100%; - font-size: 18px; + font-size: 16px; color: #5a5e66; vertical-align: text-bottom; diff --git a/src/layout/components/Sidebar/Logo.vue b/src/layout/components/Sidebar/Logo.vue index 02c41996..1879c48b 100644 --- a/src/layout/components/Sidebar/Logo.vue +++ b/src/layout/components/Sidebar/Logo.vue @@ -1,13 +1,13 @@