Commit 36a95280 by 无尘

add: 引入公共插件到各个模块

parent 050b4fc1
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<link rel="shortcut icon" href="./favicon.ico"/> <link rel="shortcut icon" href="./favicon.ico"/>
<title>GIC-集团后</title> <title>好办管理平</title>
</head> </head>
<body style="background-color: #f0f2f5;min-width: 1400px;"> <body style="background-color: #f0f2f5;min-width: 1400px;">
<div id="app"></div> <div id="app"></div>
......
...@@ -11,10 +11,10 @@ ...@@ -11,10 +11,10 @@
}, },
"dependencies": { "dependencies": {
"@gic-test/vue-area-ab": "^1.4.3", "@gic-test/vue-area-ab": "^1.4.3",
"@gic-test/vue-gic-aside-menu": "^1.1.45",
"@gic-test/vue-gic-footer": "^1.0.8", "@gic-test/vue-gic-footer": "^1.0.8",
"@gic-test/vue-gic-header": "^1.3.31", "@gic-test/vue-gic-header": "^1.3.31",
"@gic-test/vue-office-header": "^1.0.2", "@gic-test/vue-office-aside": "^1.0.2",
"@gic-test/vue-office-header": "^1.0.5",
"@riophae/vue-treeselect": "0.0.29", "@riophae/vue-treeselect": "0.0.29",
"@tinymce/tinymce-vue": "^1.0.8", "@tinymce/tinymce-vue": "^1.0.8",
"element-ui": "^2.3.9", "element-ui": "^2.3.9",
......
...@@ -14,7 +14,7 @@ export default { ...@@ -14,7 +14,7 @@ export default {
console.log(response) console.log(response)
if (response.errorCode != 0) { if (response.errorCode != 0) {
if (response.errorCode == 401) { if (response.errorCode == 401) {
window.location.href = local + "/gic-web/#/"; // window.location.href = local + "/gic-web/#/";
return false; return false;
} }
Message.error({ Message.error({
......
...@@ -12,7 +12,7 @@ import '../static/font/iconfont.css' ...@@ -12,7 +12,7 @@ import '../static/font/iconfont.css'
import '../theme/index.css' import '../theme/index.css'
import vueOfficeHeader from '@gic-test/vue-office-header' import vueOfficeHeader from '@gic-test/vue-office-header'
import vueGicAsideMenu from '@gic-test/vue-gic-aside-menu' import vueOfficeAside from '@gic-test/vue-office-aside'
import vueAreaAb from '@gic-test/vue-area-ab' import vueAreaAb from '@gic-test/vue-area-ab'
// 新增公共 footer插件 // 新增公共 footer插件
import vueGicFooter from '@gic-test/vue-gic-footer' import vueGicFooter from '@gic-test/vue-gic-footer'
...@@ -20,7 +20,7 @@ import vueGicFooter from '@gic-test/vue-gic-footer' ...@@ -20,7 +20,7 @@ import vueGicFooter from '@gic-test/vue-gic-footer'
Vue.use(vueGicFooter) Vue.use(vueGicFooter)
Vue.use(vueAreaAb) Vue.use(vueAreaAb)
Vue.use(vueGicAsideMenu) Vue.use(vueOfficeAside)
Vue.use(vueOfficeHeader) Vue.use(vueOfficeHeader)
Vue.config.productionTip = false; Vue.config.productionTip = false;
...@@ -59,7 +59,7 @@ Vue.axios.interceptors.response.use( ...@@ -59,7 +59,7 @@ Vue.axios.interceptors.response.use(
// path: 'login', // path: 'login',
// query: {redirect: router.currentRoute.fullPath} // query: {redirect: router.currentRoute.fullPath}
// }); // });
window.location.href = window.location.origin + '/gic-web/#/'; // window.location.href = window.location.origin + '/gic-web/#/';
case 500: case 500:
Message.error('服务器500') Message.error('服务器500')
} }
......
<template> <template>
<div class="administrative-wrap"> <div class="administrative-wrap">
<div class="inline-block administrative-wrap__left common-wrap__left">
</div>
<div class="inline-block administrative-wrap__right common-wrap__right">
</div>
</div> </div>
</template> </template>
<script> <script>
...@@ -24,5 +30,28 @@ export default { ...@@ -24,5 +30,28 @@ export default {
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.administrative-wrap {
width: 100%;
font-size: 0;
&__left {
width: 260px;
height: 690px;
vertical-align: top;
font-size: 14px;
background: rgba(238,241,248,1);
border-radius: 2px;
}
&__right {
width: calc(100% - 260px);
min-height: 690px;
padding: 24px;
vertical-align: top;
font-size: 14px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
}
</style> </style>
<template> <template>
<div class="contact-wrap"> <div class="contact-wrap">
<!-- 公共头部菜单插件 -->
<vue-office-header :projectName="projectName" @collapseTag="collapseTag" @toRouterView="toRouterView"></vue-office-header>
<div class="contact-wrap__body">
<!-- 公共左侧菜单插件 -->
<vue-office-aside ref="leftMenus" :projectName="projectName" :collapseFlag="collapseFlag"></vue-office-aside>
<!-- 右侧 body -->
<div class="contact-wrap__right">
<topNav :navpath="navpath"></topNav>
<div class="contact-wrap__right__body">
<transition name="fade" mode="out-in">
<router-view></router-view>
</transition>
</div>
</div>
</div>
</div> </div>
</template> </template>
<script> <script>
import topNav from 'components/nav/nav'
export default { export default {
name: "contact", name: "contact",
data() { data() {
return { return {
projectName: 'gic-clique', // 当前项目名
collapseFlag: false, // 折叠参数
// 面包屑导航数据
navpath: [{
name: '首页',
path: '/'
},
{
name: '集团信息',
path: ''
}
],
} }
}, },
computed: { computed: {
}, },
methods: { methods: {
// 处理路由跳转
toRouterView(val) {
var that = this;
// 模拟检查数据
// //有两个参数
//{
// name:,
// path:
//}
console.log(val);
that.$router.push({
path: val.path
})
},
// 折叠事件
collapseTag(val) {
var that = this;
console.log(val);
that.collapseFlag = val
},
}, },
mounted() { mounted() {
}, },
components: {
topNav
},
} }
</script> </script>
<style lang="less" scoped> <style lang="less">
.contact-wrap {
position: relative;
&__body {
display: -ms-flexbox;
display: flex;
width: 100%;
overflow: hidden;
padding-top: 64px;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
overflow: auto;
min-width: 1400px;
background: #f5f7fa;
}
&__right {
-ms-flex: 1;
flex: 1;
overflow: auto;
width: 100%;
&__body {
padding: 24px;
}
}
}
</style> </style>
<template> <template>
<div class="enterprise-wrap"> <div class="enterprise-wrap">
<!-- 公共头部菜单插件 -->
<vue-office-header :projectName="projectName" @collapseTag="collapseTag" @toRouterView="toRouterView"></vue-office-header>
<div class="enterprise-wrap__body">
</div>
</div> </div>
</template> </template>
<script> <script>
...@@ -8,14 +12,35 @@ export default { ...@@ -8,14 +12,35 @@ export default {
name: "enterprise", name: "enterprise",
data() { data() {
return { return {
projectName: 'gic-clique', // 当前项目名
collapseFlag: false, // 折叠参数
} }
}, },
computed: { computed: {
}, },
methods: { methods: {
// 处理路由跳转
toRouterView(val) {
var that = this;
// 模拟检查数据
// //有两个参数
//{
// name:,
// path:
//}
console.log(val);
that.$router.push({
path: val.path
})
},
// 折叠事件
collapseTag(val) {
var that = this;
console.log(val);
that.collapseFlag = val
},
}, },
mounted() { mounted() {
......
...@@ -22,8 +22,9 @@ export default { ...@@ -22,8 +22,9 @@ export default {
name: 'index', name: 'index',
data() { data() {
return { return {
projectName: 'gic-clique', projectName: 'gic-clique', // 当前项目名
contentHeight: '0px', //页面内容高度 contentHeight: '0px', // 页面内容高度
collapseFlag: false, // 折叠参数
showCustomDialog: false, // 自定义弹框显示标志 showCustomDialog: false, // 自定义弹框显示标志
} }
......
<template> <template>
<div class="review-wrap"> <div class="review-wrap">
<!-- 公共头部菜单插件 -->
<vue-office-header :projectName="projectName" @collapseTag="collapseTag" @toRouterView="toRouterView"></vue-office-header>
<div class="review-wrap__body">
</div>
</div> </div>
</template> </template>
<script> <script>
...@@ -8,14 +12,35 @@ export default { ...@@ -8,14 +12,35 @@ export default {
name: "review", name: "review",
data() { data() {
return { return {
projectName: 'gic-clique', // 当前项目名
collapseFlag: false, // 折叠参数
} }
}, },
computed: { computed: {
}, },
methods: { methods: {
// 处理路由跳转
toRouterView(val) {
var that = this;
// 模拟检查数据
// //有两个参数
//{
// name:,
// path:
//}
console.log(val);
that.$router.push({
path: val.path
})
},
// 折叠事件
collapseTag(val) {
var that = this;
console.log(val);
that.collapseFlag = val
},
}, },
mounted() { mounted() {
......
<template> <template>
<div class="setting-wrap"> <div class="setting-wrap">
<!-- 公共头部菜单插件 -->
<vue-office-header :projectName="projectName" @collapseTag="collapseTag" @toRouterView="toRouterView"></vue-office-header>
<div class="review-wrap__body">
</div>
</div> </div>
</template> </template>
<script> <script>
...@@ -8,14 +12,35 @@ export default { ...@@ -8,14 +12,35 @@ export default {
name: "setting", name: "setting",
data() { data() {
return { return {
projectName: 'gic-clique', // 当前项目名
collapseFlag: false, // 折叠参数
} }
}, },
computed: { computed: {
}, },
methods: { methods: {
// 处理路由跳转
toRouterView(val) {
var that = this;
// 模拟检查数据
// //有两个参数
//{
// name:,
// path:
//}
console.log(val);
that.$router.push({
path: val.path
})
},
// 折叠事件
collapseTag(val) {
var that = this;
console.log(val);
that.collapseFlag = val
},
}, },
mounted() { mounted() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment