Commit 873c4ec0 authored by zhangjianguo's avatar zhangjianguo

Merge branch 'master' of http://gitlab.oytour.com/viitto/mallapp

parents 864d597c 403d6acc
......@@ -33,8 +33,10 @@ export default {
(res) => {
uni.setStorageSync("basedata", res.data);
this.basedata = res.data;
this.$uiConfig.mainColor=this.basedata.mall.setting.mallStyle.main
this.$uiConfig.secondary=this.basedata.mall.setting.mallStyle.secondary
console.log("赋值:")
console.log(res.data.mall.setting.mallStyle.main)
this.$uiConfig.mainColor=res.data.mall.setting.mallStyle.main
this.$uiConfig.secondary=res.data.mall.setting.mallStyle.secondary
this.formatTabbar();
this.formatNavigation();
}
......
<template>
<scroll-view
:scroll-y="true"
@scrolltolower="lower"
:enable-back-to-top="true"
:enable-flex="true"
style="height: 100%; padding: 10px; padding-bottom: 0px;"
>
</scroll-view>
</template>
<script>
export default {
data() {
return {
mc: "",
secondary: "",
pageTitle: "直播列表",
page: 1,
list: [],
pageCount: 1,
loading: true,
};
},
onLoad(option) {
uni.showNavigationBarLoading();
this.init();
this.mc = this.$uiConfig.mainColor;
this.secondary = this.$uiConfig.secondary;
this.initPage();
this.init();
},
methods: {
initPage() {
let currentPages = getCurrentPages();
let u = "/" + currentPages[currentPages.length - 1].route;
let pages = uni.getStorageSync("basedata")
? uni.getStorageSync("basedata").bar_title
: [];
pages.forEach((x) => {
if (x.value == u) {
this.pageTitle = x.new_name ? x.new_name : x.name;
}
});
uni.setNavigationBarTitle({
title: this.pageTitle,
});
},
init() {
let h = this.apiheader();
if (page < pageCount) {
this.request(
{
url: "",
header: h,
data: {
r: "api/live/index",
page: this.page,
},
},
(res) => {
this.list = res.data.list;
this.pageCount = 1;
uni.hideNavigationBarLoading();
}
);
}
},
},
};
</script>
<style></style>
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