刘翔宇-旅管家 3 years ago
parent 3dde9efa64
commit 88edb554e4

@ -2,5 +2,5 @@
ENV = 'development' ENV = 'development'
# base api # base api
VUE_APP_BASE_API = http://starter.ali251.langye.net VUE_APP_BASE_API = http://weiyuan-ziliao-test.ali251.langye.net
VUE_APP_UPLOAD_API = http://starter.ali251.langye.net/api/admin/upload-file VUE_APP_UPLOAD_API = http://weiyuan-ziliao-test.ali251.langye.net/api/admin/upload-file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 88 KiB

After

Width:  |  Height:  |  Size: 44 KiB

@ -40,9 +40,9 @@ export default {
// padding-top: 10px; // padding-top: 10px;
font-weight: bold; font-weight: bold;
font-size: 15px; font-size: 15px;
color: #444140; color: #0077CC;
white-space: nowrap; white-space: nowrap;
border-bottom: 2px solid #444140; border-bottom: 2px solid #0077CC;
> span { > span {
position: relative; position: relative;

@ -6,6 +6,7 @@
<img src="../../../assets/logo-mini.png?v=1" class="sidebar-logo"> <img src="../../../assets/logo-mini.png?v=1" class="sidebar-logo">
</router-link> </router-link>
<router-link v-else key="expand" class="sidebar-logo-link" to="/"> <router-link v-else key="expand" class="sidebar-logo-link" to="/">
<img src="../../../assets/logo-mini.png?v=1" class="sidebar-logo">
<img src="../../../assets/logo.png?v=2" class="sidebar-name-logo" /> <img src="../../../assets/logo.png?v=2" class="sidebar-name-logo" />
</router-link> </router-link>
</transition> </transition>
@ -35,8 +36,8 @@
transition: opacity 1.5s; transition: opacity 1.5s;
} }
.sidebar-name-logo { .sidebar-name-logo {
width: 160px; width: 120px;
height: 36px; height: 22px;
} }
.sidebarLogoFade-enter, .sidebarLogoFade-enter,

@ -1,95 +1,104 @@
<template> <template>
<div v-if="!item.hidden"> <div v-if="!item.hidden">
<template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren)&&!item.alwaysShow"> <template
<app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path)"> v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren)&&!item.alwaysShow">
<el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}"> <app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path)">
<item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="onlyOneChild.meta.title" /> <el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}">
</el-menu-item> <item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="onlyOneChild.meta.title" />
</app-link> </el-menu-item>
</template> </app-link>
</template>
<el-submenu v-else ref="subMenu" :index="resolvePath(item.path)" popper-append-to-body>
<template slot="title"> <el-submenu v-else ref="subMenu" :index="resolvePath(item.path)" popper-append-to-body>
<item v-if="item.meta" :icon="item.meta && item.meta.icon" :title="item.meta.title" /> <template slot="title">
</template> <item v-if="item.meta" :icon="item.meta && item.meta.icon" :title="item.meta.title" />
<sidebar-item </template>
v-for="child in item.children" <sidebar-item v-for="child in item.children" :key="child.path" :is-nest="true" :item="child"
:key="child.path" :base-path="resolvePath(child.path)" class="nest-menu" />
:is-nest="true" </el-submenu>
:item="child" </div>
:base-path="resolvePath(child.path)" </template>
class="nest-menu"
/> <script>
</el-submenu> import path from 'path'
</div> import {
</template> isExternal
} from '@/utils/validate'
<script> import Item from './Item'
import path from 'path' import AppLink from './Link'
import { isExternal } from '@/utils/validate' import FixiOSBug from './FixiOSBug'
import Item from './Item'
import AppLink from './Link' export default {
import FixiOSBug from './FixiOSBug' name: 'SidebarItem',
components: {
export default { Item,
name: 'SidebarItem', AppLink
components: { Item, AppLink }, },
mixins: [FixiOSBug], mixins: [FixiOSBug],
props: { props: {
// route object // route object
item: { item: {
type: Object, type: Object,
required: true required: true
}, },
isNest: { isNest: {
type: Boolean, type: Boolean,
default: false default: false
}, },
basePath: { basePath: {
type: String, type: String,
default: '' default: ''
} }
}, },
data() { data() {
// To fix https://github.com/PanJiaChen/vue-admin-template/issues/237 // To fix https://github.com/PanJiaChen/vue-admin-template/issues/237
// TODO: refactor with render function // TODO: refactor with render function
this.onlyOneChild = null this.onlyOneChild = null
return {} return {}
}, },
methods: { methods: {
hasOneShowingChild(children = [], parent) { hasOneShowingChild(children = [], parent) {
const showingChildren = children.filter(item => { const showingChildren = children.filter(item => {
if (item.hidden) { if (item.hidden) {
return false return false
} else { } else {
// Temp set(will be used if only has one showing child) // Temp set(will be used if only has one showing child)
this.onlyOneChild = item this.onlyOneChild = item
return true return true
} }
}) })
// When there is only one child router, the child router is displayed by default // When there is only one child router, the child router is displayed by default
if (showingChildren.length === 1) { if (showingChildren.length === 1) {
return true return true
} }
// Show parent if there are no child router to display // Show parent if there are no child router to display
if (showingChildren.length === 0) { if (showingChildren.length === 0) {
this.onlyOneChild = { ... parent, path: '', noShowingChildren: true } this.onlyOneChild = {
return true ...parent,
} path: '',
noShowingChildren: true
return false }
}, return true
resolvePath(routePath) { }
if (isExternal(routePath)) {
return routePath return false
} },
if (isExternal(this.basePath)) { resolvePath(routePath) {
return this.basePath if (isExternal(routePath)) {
} return routePath
return path.resolve(this.basePath, routePath) }
} if (isExternal(this.basePath)) {
} return this.basePath
} }
</script> return path.resolve(this.basePath, routePath)
}
}
}
</script>
<style>
.el-submenu__title i {
color: #fff !important;
}
</style>

@ -1,6 +1,6 @@
module.exports = { module.exports = {
title: '朗业基础平台', title: '卫生学院内部资料汇编',
/** /**
* @type {boolean} true | false * @type {boolean} true | false

@ -1,5 +1,5 @@
/* 改变主题色变量 */ /* 改变主题色变量 */
$--color-primary: #444140; $--color-primary: #0077CC;
/* 改变 icon 字体路径变量,必需 */ /* 改变 icon 字体路径变量,必需 */
$--font-path: '~element-ui/lib/theme-chalk/fonts'; $--font-path: '~element-ui/lib/theme-chalk/fonts';

File diff suppressed because it is too large Load Diff

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -11,7 +11,7 @@
transition: width 0.28s; transition: width 0.28s;
width: $sideBarWidth !important; width: $sideBarWidth !important;
//background-color: $menuBg; //background-color: $menuBg;
background: linear-gradient(180deg, #d70c25, #ec5669); background: linear-gradient(180deg, #0284cd, #0077CC);
box-shadow: 1px 1px 15px 0px rgba(17, 76, 157, 0.2); box-shadow: 1px 1px 15px 0px rgba(17, 76, 157, 0.2);
height: 100%; height: 100%;
position: fixed; position: fixed;
@ -229,7 +229,7 @@
>.el-menu--popup { >.el-menu--popup {
max-height: 100vh; max-height: 100vh;
overflow-y: auto; overflow-y: auto;
background: #d70c25 !important; background: #0077CC !important;
&::-webkit-scrollbar-track-piece { &::-webkit-scrollbar-track-piece {
background: #d3dce6; background: #d3dce6;

@ -13,7 +13,7 @@ $subMenuHover:rgba(242, 242, 242, .4);
$submenuActiveBg:rgba(242, 242, 242, .4); $submenuActiveBg:rgba(242, 242, 242, .4);
$sideBarWidth: 210px; $sideBarWidth: 210px;
$primaryColor: #1a1a5e; $primaryColor: #0077CC;
// the :export directive is the magic sauce for webpack // the :export directive is the magic sauce for webpack
// https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass // https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass
:export { :export {

@ -1,4 +1,4 @@
@import '~view-design/src/styles/index.less'; @import '~view-design/src/styles/index.less';
// Here are the variables to cover, such as: // Here are the variables to cover, such as:
@primary-color: #444140; @primary-color: #0077CC;

@ -5,16 +5,7 @@
<panel-group :totaldata="list" /> <panel-group :totaldata="list" />
</div> </div>
<div class="chart">
<div class="chartItem" style="margin-right: 1%;">
<div class="chartItemTitle">营业与收入</div>
<div id="col-chart"></div>
</div>
<div class="chartItem" style="margin-left: 1%;">
<div class="chartItemTitle">客户与订单</div>
<div id="line-chart"></div>
</div>
</div>
</div> </div>
</template> </template>
@ -180,7 +171,7 @@
}, },
created() { created() {
this.loadData(); //this.loadData();
}, },
mounted() { mounted() {

@ -13,7 +13,7 @@ const name = defaultSettings.title // page title
// For example, Mac: sudo npm run // For example, Mac: sudo npm run
// You can change the port by the following methods: // You can change the port by the following methods:
// port = 9528 npm run dev OR npm run dev --port = 9528 // port = 9528 npm run dev OR npm run dev --port = 9528
const port = process.env.port || process.env.npm_config_port || 8000 // dev port const port = process.env.port || process.env.npm_config_port || 8089 // dev port
// All configuration item explanations can be find in https://cli.vuejs.org/config/ // All configuration item explanations can be find in https://cli.vuejs.org/config/
module.exports = { module.exports = {

Loading…
Cancel
Save