Browse Source

Merge branch 'dev-登录返回旧业面' into dev-烟台中转登录2

dev-烟台中转登录2
dai_siki 3 years ago
parent
commit
a6d5e6fa95
  1. 7
      src/assets/scss/main-shuju.scss
  2. 39
      src/views/main-shuju/main.vue
  3. 2
      src/views/main.vue

7
src/assets/scss/main-shuju.scss

@ -159,6 +159,13 @@
} }
} }
} }
&.z-iframe {
padding-top: 0;
.aui-content--tabs {
padding-top: 0;
}
}
} }
/* Navbar /* Navbar

39
src/views/main-shuju/main.vue

@ -1,22 +1,27 @@
<template> <template>
<fixed1920> <fixed1920>
<div v-loading.fullscreen.lock="loading" <div
:element-loading-text="$t('loading')" v-loading.fullscreen.lock="loading"
:class="[ :element-loading-text="$t('loading')"
:class="[
'g-bd', 'g-bd',
{ 'z-sidebar--fold': $store.state.sidebarFold }, { 'z-sidebar--fold': $store.state.sidebarFold },
{ {
'z-sidebar--noside': true, 'z-sidebar--noside': true,
}, },
]"> { 'z-iframe': $store.state.inIframe },
]"
>
<template v-if="!loading"> <template v-if="!loading">
<main-navbar ref="ref_navbar" /> <main-navbar ref="ref_navbar" v-if="!$store.state.inIframe" />
<div class="g-cnt"> <div class="g-cnt">
<main-content v-if="!$store.state.contentIsNeedRefresh" <main-content
@changeCustomerName="changeCustomerName" /> v-if="!$store.state.contentIsNeedRefresh"
@changeCustomerName="changeCustomerName"
/>
</div> </div>
<main-theme-tools v-if="!$store.state.inIframe" /> <main-theme-tools />
</template> </template>
</div> </div>
</fixed1920> </fixed1920>
@ -33,10 +38,10 @@ import fixed1920 from "@/views/components/fixed1920.vue";
import MainThemeTools from "./main-theme-tools"; import MainThemeTools from "./main-theme-tools";
export default { export default {
provide () { provide() {
return { return {
// //
refresh () { refresh() {
this.$store.state.contentIsNeedRefresh = true; this.$store.state.contentIsNeedRefresh = true;
this.$nextTick(() => { this.$nextTick(() => {
this.$store.state.contentIsNeedRefresh = false; this.$store.state.contentIsNeedRefresh = false;
@ -44,7 +49,7 @@ export default {
}, },
}; };
}, },
data () { data() {
return { return {
loading: true, loading: true,
userType: localStorage.getItem("userType"), userType: localStorage.getItem("userType"),
@ -54,13 +59,13 @@ export default {
MainNavbar, MainNavbar,
MainContent, MainContent,
fixed1920, fixed1920,
MainThemeTools MainThemeTools,
}, },
watch: { watch: {
$route: "routeHandle", $route: "routeHandle",
}, },
async created () { async created() {
this.windowResizeHandle(); this.windowResizeHandle();
this.routeHandle(this.$route); this.routeHandle(this.$route);
Promise.all([this.getWorkUserInfo()]).then(() => { Promise.all([this.getWorkUserInfo()]).then(() => {
@ -69,11 +74,11 @@ export default {
}, },
computed: {}, computed: {},
methods: { methods: {
changeCustomerName (customerName) { changeCustomerName(customerName) {
this.$refs["ref_navbar"].changeCustomerName(customerName); this.$refs["ref_navbar"].changeCustomerName(customerName);
}, },
// //
windowResizeHandle () { windowResizeHandle() {
this.$store.state.sidebarFold = this.$store.state.sidebarFold =
document.documentElement["clientWidth"] <= 992 || false; document.documentElement["clientWidth"] <= 992 || false;
window.addEventListener( window.addEventListener(
@ -85,7 +90,7 @@ export default {
); );
}, },
// , // ,
routeHandle (route) { routeHandle(route) {
if (!route.meta.isTab) { if (!route.meta.isTab) {
this.$store.state.mainShuju.activeName = ""; this.$store.state.mainShuju.activeName = "";
this.$store.state.mainShuju.contentTabsActiveName = ""; this.$store.state.mainShuju.contentTabsActiveName = "";
@ -111,7 +116,7 @@ export default {
}, },
// //
async getWorkUserInfo () { async getWorkUserInfo() {
const url = "/epmetuser/customerstaff/staffbasicinfo"; const url = "/epmetuser/customerstaff/staffbasicinfo";
let params = {}; let params = {};
const { data, code, msg } = await requestPost(url, params); const { data, code, msg } = await requestPost(url, params);

2
src/views/main.vue

@ -22,7 +22,7 @@
@changeCustomerName="changeCustomerName" @changeCustomerName="changeCustomerName"
/> />
</div> </div>
<main-theme-tools v-if="!$store.state.inIframe" /> <main-theme-tools />
<!-- <secretary-log-notice v-if="!$store.state.inIframe" /> --> <!-- <secretary-log-notice v-if="!$store.state.inIframe" /> -->
</template> </template>

Loading…
Cancel
Save