Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Fedex
/
imac-vue
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
jinhui.wang
2022-01-07 09:36:18 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
0868105ea8ee18229c7c048e0ad158a9db14aa3c
0868105e
1 parent
b1a28610
增加版本号展示,接口地址更改
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
76 additions
and
48 deletions
src/layout/components/Sidebar/index.vue
src/utils/request.js
src/utils/zipdownload.js
vue.config.js
src/layout/components/Sidebar/index.vue
View file @
0868105
<template>
<div :class="{'has-logo':showLogo}" :style="{ backgroundColor: settings.sideTheme === 'theme-dark' ? variables.menuBg : variables.menuLightBg }">
<logo v-if="showLogo" :collapse="isCollapse" />
<!-- <el-scrollbar :class="settings.sideTheme" wrap-class="scrollbar-wrapper"> -->
<el-menu
:default-active="activeMenu"
:collapse="isCollapse"
:background-color="settings.sideTheme === 'theme-dark' ? variables.menuBg : variables.menuLightBg"
:text-color="settings.sideTheme === 'theme-dark' ? variables.menuText : 'rgba(0,0,0,.65)'"
:unique-opened="true"
:active-text-color="settings.theme"
:collapse-transition="false"
mode="vertical"
>
<sidebar-item
v-for="(route, index) in sidebarRouters"
:key="route.path + index"
:item="route"
:base-path="route.path"
/>
</el-menu>
<!-- </el-scrollbar> -->
</div>
<div
:class="{ 'has-logo': showLogo }"
:style="{
backgroundColor:
settings.sideTheme === 'theme-dark'
? variables.menuBg
: variables.menuLightBg,
}"
>
<logo v-if="showLogo" :collapse="isCollapse" />
<!-- <el-scrollbar :class="settings.sideTheme" wrap-class="scrollbar-wrapper"> -->
<el-menu
:default-active="activeMenu"
:collapse="isCollapse"
:background-color="
settings.sideTheme === 'theme-dark'
? variables.menuBg
: variables.menuLightBg
"
:text-color="
settings.sideTheme === 'theme-dark'
? variables.menuText
: 'rgba(0,0,0,.65)'
"
:unique-opened="true"
:active-text-color="settings.theme"
:collapse-transition="false"
mode="vertical"
>
<sidebar-item
v-for="(route, index) in sidebarRouters"
:key="route.path + index"
:item="route"
:base-path="route.path"
/>
</el-menu>
<div class="version">version:0.5.1</div>
<!-- </el-scrollbar> -->
</div>
</template>
<script>
...
...
@@ -30,28 +47,39 @@ import SidebarItem from "./SidebarItem";
import variables from "@/assets/styles/variables.scss";
export default {
components: { SidebarItem, Logo },
computed: {
...mapState(["settings"]),
...mapGetters(["sidebarRouters", "sidebar"]),
activeMenu() {
const route = this.$route;
const { meta, path } = route;
// if set path, the sidebar will highlight the path you set
if (meta.activeMenu) {
return meta.activeMenu;
}
return path;
},
showLogo() {
return this.$store.state.settings.sidebarLogo;
},
variables() {
return variables;
},
isCollapse() {
return !this.sidebar.opened;
}
}
components: { SidebarItem, Logo },
computed: {
...mapState(["settings"]),
...mapGetters(["sidebarRouters", "sidebar"]),
activeMenu() {
const route = this.$route;
const { meta, path } = route;
// if set path, the sidebar will highlight the path you set
if (meta.activeMenu) {
return meta.activeMenu;
}
return path;
},
showLogo() {
return this.$store.state.settings.sidebarLogo;
},
variables() {
return variables;
},
isCollapse() {
return !this.sidebar.opened;
},
},
};
</script>
<style scoped>
.version {
width: 100%;
font-size: 14px;
color: #fff;
position: absolute;
left: 5px;
bottom: 5px;
}
</style>
...
...
src/utils/request.js
View file @
0868105
...
...
@@ -11,7 +11,7 @@ const service = axios.create({
//baseURL: process.env.VUE_APP_BASE_API,
//baseURL: 'http://192.168.1.45:8080',
baseURL
:
`http://47.103.140.98:9002`
,
// baseURL: 'https://imacuat.zmd.apac.fedex.com
:9002
/IMAC2',
// baseURL: 'https://imacuat.zmd.apac.fedex.com/IMAC2',
// baseURL: 'http://192.168.1.134:18080',
// 超时
...
...
src/utils/zipdownload.js
View file @
0868105
...
...
@@ -5,7 +5,7 @@ const mimeMap = {
xlsx
:
'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
,
zip
:
'application/zip'
}
// const baseU
RL = 'https://imacuat.zmd.apac.fedex.com:9002
/IMAC2'
// const baseU
rl = 'https://imacuat.zmd.apac.fedex.com
/IMAC2'
const
baseUrl
=
'http://47.103.140.98:9002'
// const baseUrl = 'http://192.168.1.134:18080'
export
function
downLoadZip
(
str
,
filename
)
{
...
...
vue.config.js
View file @
0868105
...
...
@@ -35,7 +35,7 @@ module.exports = {
proxy
:
{
// detail: https://cli.vuejs.org/config/#devserver-proxy
[
process
.
env
.
VUE_APP_BASE_API
]:
{
// target: `https://imacuat.zmd.apac.fedex.com
:9002
/IMAC2`,
// target: `https://imacuat.zmd.apac.fedex.com/IMAC2`,
// target: `http://192.168.1.45:8080`,
target
:
`http://47.103.140.98:9002`
,
// target: `http://192.168.1.134:18080`,
...
...
Please
register
or
login
to post a comment