|
@@ -12,6 +12,7 @@ Page({
|
|
|
tabChange({
|
|
|
detail
|
|
|
}) {
|
|
|
+ console.log(detail)
|
|
|
this.setData({
|
|
|
active: detail.index
|
|
|
})
|
|
@@ -20,10 +21,17 @@ Page({
|
|
|
* 生命周期函数--监听页面加载
|
|
|
*/
|
|
|
onLoad(options) {
|
|
|
- console.log(options)
|
|
|
- if (options.viewData) this.setData({
|
|
|
- viewData: options.viewData
|
|
|
+ let dataAuth = '';
|
|
|
+ if (options.auth.includes('团队内部数据分析') && options.auth.includes('经销商数据分析')) {
|
|
|
+ dataAuth = 'all';
|
|
|
+ } else {
|
|
|
+ dataAuth = options.auth.includes('团队内部数据分析') ? '内部' : '经销商'
|
|
|
+ }
|
|
|
+ this.setData({
|
|
|
+ viewData: options.auth.includes('团队内部数据分析') || options.auth.includes('经销商数据分析'),
|
|
|
+ dataAuth
|
|
|
});
|
|
|
+
|
|
|
_Http.basic({
|
|
|
"classname": "saletool.courseware.courseware",
|
|
|
"method": "selectDetail",
|