Commit 707136ae by 张立顺

feat 功能开发

1 parent 31c063f4
...@@ -19,15 +19,18 @@ Page({ ...@@ -19,15 +19,18 @@ Page({
merchantInfo: {}, merchantInfo: {},
tabList: [{ tabList: [{
label: '精品升级-太阳膜', label: '精品升级-太阳膜',
width: '34%' width: '34%',
tabIndx: 1
}, },
{ {
label: '售后众筹', label: '售后众筹',
width: '25%' width: '25%',
tabIndx: 3
}, },
{ {
label: '会员权益/升级', label: '会员权益/升级',
width: '30%' width: '30%',
tabIndx: 0
} }
], ],
lineChart: {}, lineChart: {},
...@@ -35,6 +38,7 @@ Page({ ...@@ -35,6 +38,7 @@ Page({
data: [] data: []
}, },
tabIndx: 0, tabIndx: 0,
seletTabIndx: 0,
// 众筹 // 众筹
scrollLeft: 0, scrollLeft: 0,
activityActive: 0, activityActive: 0,
...@@ -133,7 +137,7 @@ Page({ ...@@ -133,7 +137,7 @@ Page({
let { let {
tabIndx tabIndx
} = this.data } = this.data
if(tabIndx == 0)this.getAnalysisTendency(tabIndx) if (tabIndx == 0) this.getAnalysisTendency(tabIndx)
console.log(tabIndx, 'tabIndx') console.log(tabIndx, 'tabIndx')
}, },
changeStatus() { changeStatus() {
...@@ -251,7 +255,9 @@ Page({ ...@@ -251,7 +255,9 @@ Page({
let { let {
detail detail
} = e } = e
let { tabList } = this.data
this.setData({ this.setData({
seletTabIndx: tabList[detail].tabIndx,
tabIndx: detail tabIndx: detail
}) })
this.initData() this.initData()
...@@ -538,12 +544,18 @@ Page({ ...@@ -538,12 +544,18 @@ Page({
onRoute() { onRoute() {
console.log('onRoute') console.log('onRoute')
this.initTime() this.initTime()
let { tabList } = this.data
// this.getAnalysisTendency(this.data.tabIndx) // this.getAnalysisTendency(this.data.tabIndx)
wx.$router.getData(obj => { wx.$router.getData(obj => {
console.log(obj, 'obj') console.log(obj, 'obj')
// obj.sceneTypeList = [1, 2]
tabList = tabList.filter(item => obj.info.sceneTypeList.includes(item.tabIndx))
console.log(tabList, 'tabList');
this.setData({ this.setData({
merchantInfo: obj.info, merchantInfo: obj.info,
searchForm: obj.searchForm searchForm: obj.searchForm,
tabList,
seletTabIndx: tabList[0].tabIndx
}) })
this.rangeSelect({ detail: { date: { start: obj.searchForm.yearMonth, end: obj.searchForm.yearMonth }, type: 'dayType' } }) this.rangeSelect({ detail: { date: { start: obj.searchForm.yearMonth, end: obj.searchForm.yearMonth }, type: 'dayType' } })
this.initData() this.initData()
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<wxs src="../../index.wxs" module="filter" /> <wxs src="../../index.wxs" module="filter" />
<navigation-bar wx:if="{{isPc}}" showBack navStyle="background-color: transparent;" bindnavbarReady="navbarReady"> <navigation-bar wx:if="{{isPc}}" showBack navStyle="background-color: transparent;" bindnavbarReady="navbarReady">
{{merchantInfo.merchantName}} {{merchantInfo.merchantName}}
</navigation-bar> </navigation-bar>
<view class="layout" style="padding-top:{{tabBarStyle}}px; height:100vh"> <view class="layout" style="padding-top:{{tabBarStyle}}px; height:100vh">
<!-- <view class="titleBox"> <!-- <view class="titleBox">
...@@ -14,33 +14,18 @@ ...@@ -14,33 +14,18 @@
</view> --> </view> -->
<tab tab="{{ tabList }}" itemWidth="{{ '30%' }}" index="{{ tabIndx }}" bindclick="changeTabIndx" class="tabContainer" /> <tab tab="{{ tabList }}" itemWidth="{{ '30%' }}" index="{{ tabIndx }}" bindclick="changeTabIndx" class="tabContainer" />
<block wx:if="{{ tabIndx==0 }}"> <block wx:if="{{ seletTabIndx==1 }}">
<view class="searchBar"> <view class="searchBar">
<view class="checkCon" > <view class="checkCon">
<view class="checkoutBox checkBox" bind:tap="changeStatus" wx:if="{{ !allType }}"></view> <view class="checkoutBox checkBox" bind:tap="changeStatus" wx:if="{{ !allType }}"></view>
<image class="checkBox" bind:tap="changeStatus" wx:if="{{ allType }}" src="../../images/checkoutIcon.png"></image> <image class="checkBox" bind:tap="changeStatus" wx:if="{{ allType }}" src="../../images/checkoutIcon.png"></image>
查看全品类 查看全品类
</view> </view>
<view class="calendarMonthCon"> <view class="calendarMonthCon">
<view class="monthNow {{ dateObj.nowMonth ? 'active' : '' }}" bind:tap="handleMonthNow">本月</view> <view class="monthNow {{ dateObj.nowMonth ? 'active' : '' }}" bind:tap="handleMonthNow">本月</view>
<CalendarMonth <CalendarMonth allowSameDay shortcut bind:select="rangeSelect" bind:tapCalendar="tapCalendar" rangeAll dateType="range" calenderColor="#3666FE" vertical minDate="2020-10-01" maxDate="{{ dateObj.today }}" isComponents isChangeType="{{ false }}" forceFullSucreen="{{ bottomLift>0?true:false }}" dayType="{{ 0 }}">
allowSameDay
shortcut
bind:select="rangeSelect"
bind:tapCalendar="tapCalendar"
rangeAll
dateType="range"
calenderColor="#3666FE"
vertical
minDate="2020-10-01"
maxDate="{{ dateObj.today }}"
isComponents
isChangeType="{{ false }}"
forceFullSucreen="{{ bottomLift>0?true:false }}"
dayType="{{ 0 }}"
>
<view class="item dateNum {{ dateObj.nowMonth ? 'custom' : '' }}"> <view class="item dateNum {{ dateObj.nowMonth ? 'custom' : '' }}">
<view wx:if="{{ dateObj.type == 'today' }}">自定义</view> <view wx:if="{{ dateObj.type == 'today' }}">自定义</view>
<view wx:elif="{{ dateObj.nowMonth }}">{{ dateObj.today }}</view> <view wx:elif="{{ dateObj.nowMonth }}">{{ dateObj.today }}</view>
...@@ -54,47 +39,29 @@ ...@@ -54,47 +39,29 @@
</view> </view>
<view class="conCom"> <view class="conCom">
<view wx:if="{{ tabIndx == 1 }}" class="activity-content container"> <view wx:if="{{ tabIndx == 1 }}" class="activity-content container">
<output-crowdfund <output-crowdfund wx:if="{{ isShowData }}" orderObj="{{ activityList[activityActive].outputData }}" bind:handleZhanReport="handleZhanReport" bind:posterTrack="posterTrack" hasReport="{{ !isMock.SC004 }}" />
wx:if="{{ isShowData }}"
orderObj="{{ activityList[activityActive].outputData }}"
bind:handleZhanReport="handleZhanReport"
bind:posterTrack="posterTrack"
hasReport="{{ !isMock.SC004 }}"
/>
<view wx:else class="content-empty"> <view wx:else class="content-empty">
<image class="img-empty" src="{{ IMGURL}}output/sun-empty-transparent.png?v={{img_version }}" /> <image class="img-empty" src="{{ IMGURL}}output/sun-empty-transparent.png?v={{img_version }}" />
</view> </view>
<view <view wx:if="{{ activityList.length && isShowData && activityList[activityActive].outputData.shareBtnIdx && activityList[activityActive].outputData.shareBtnIdx != -1 }}" class="isFullSucreen btn-box shadow" bindtap="handleBtnShare">
wx:if="{{ activityList.length && isShowData && activityList[activityActive].outputData.shareBtnIdx && activityList[activityActive].outputData.shareBtnIdx != -1 }}"
class="isFullSucreen btn-box shadow"
bindtap="handleBtnShare"
>
<view class="btn"> <view class="btn">
<view class="btn-share">活动进行中,分享母链海报开展活动</view> <view class="btn-share">活动进行中,分享母链海报开展活动</view>
</view> </view>
</view> </view>
</view> </view>
<output-echart <output-echart wx:elif="{{ tabIndx == 0 }}" class="container" revenueData="{{ revenueData }}" chartData="{{ lineChart }}" chartDataPie="{{ chartDataPie }}" tabIndex="{{ tabIndx }}" customerList="{{ customerList }}"></output-echart>
wx:elif="{{ tabIndx == 0 }}"
class="container"
revenueData="{{ revenueData }}"
chartData="{{ lineChart }}"
chartDataPie="{{ chartDataPie }}"
tabIndex="{{ tabIndx }}"
customerList="{{ customerList }}"
></output-echart>
</view> </view>
</block> </block>
<block wx:elif="{{tabIndx == 1}}"> <block wx:elif="{{seletTabIndx == 3}}">
<view style="height: calc(100%);"> <view style="height: calc(100%);">
<WorktableEntrance></WorktableEntrance> <WorktableEntrance></WorktableEntrance>
</view> </view>
</block> </block>
<block wx:else> <block wx:elif="{{seletTabIndx == 0}}">
<view style="height: calc(100%);"> <view style="height: calc(100%);">
<equity-value entranceType="2"></equity-value> <equity-value entranceType="2"></equity-value>
</view> </view>
</block> </block>
<!-- <output-echart></output-echart> <!-- <output-echart></output-echart>
<output-crowdfund></output-crowdfund> --> <output-crowdfund></output-crowdfund> -->
</view> </view>
......
...@@ -29,7 +29,7 @@ const systemInfo = wx.getSystemInfoSync() ...@@ -29,7 +29,7 @@ const systemInfo = wx.getSystemInfoSync()
const manual = false const manual = false
const release = false const release = false
let index = 1 let index = 2
// 判断小程序环境 // 判断小程序环境
// develop:开发版(正常开发工具,测试时) // develop:开发版(正常开发工具,测试时)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!