图表数据
This commit is contained in:
@@ -27,8 +27,8 @@ Page({
|
||||
deallist:'',
|
||||
hoursTip:'',
|
||||
|
||||
cityarray: ['第一季度', '第二季度', '第三季度','第四季度', ],
|
||||
cityobj: [
|
||||
quarterarray: ['第一季度', '第二季度', '第三季度','第四季度', ],
|
||||
quarterobj: [
|
||||
{
|
||||
id: 0,
|
||||
name: '第一季度'
|
||||
@@ -46,7 +46,7 @@ Page({
|
||||
name: '第四季度'
|
||||
},
|
||||
],
|
||||
cityIndex: 0,
|
||||
quarterIndex: 0,
|
||||
|
||||
},
|
||||
|
||||
@@ -95,10 +95,10 @@ Page({
|
||||
});
|
||||
},
|
||||
|
||||
//选择城市
|
||||
changeCity(e) {
|
||||
//选择季度
|
||||
changeQuarter(e) {
|
||||
this.setData({
|
||||
cityIndex: e.detail.value
|
||||
quarterIndex: e.detail.value
|
||||
})
|
||||
},
|
||||
|
||||
|
||||
@@ -32,9 +32,9 @@
|
||||
<view class="mt40 inner30 pt40 bg-fff box-shadow-000-10-10 ulib-r10">
|
||||
<view class="relative">
|
||||
<view class="font-36">数据分析·客户</view>
|
||||
<picker class="absolute right-0 box-middle" bindchange="changeCity" value="{{cityIndex}}" range="{{cityarray}}">
|
||||
<picker class="absolute right-0 box-middle" bindchange="changeQuarter" value="{{quarterIndex}}" range="{{quarterarray}}">
|
||||
<view class="pt10 pb10 pl20 pr20 bg-f6 ulib-r10 font-22">
|
||||
<text>{{cityarray[cityIndex]}}</text>
|
||||
<text>{{quarterarray[quarterIndex]}}</text>
|
||||
<i class="iconfont ml20 icon-xiala color-999"></i>
|
||||
</view>
|
||||
</picker>
|
||||
@@ -49,9 +49,9 @@
|
||||
<view class="mt40 inner30 pt40 bg-fff box-shadow-000-10-10 ulib-r10">
|
||||
<view class="relative">
|
||||
<view class="font-36">数据分析·订单</view>
|
||||
<picker class="absolute right-0 box-middle" bindchange="changeCity" value="{{cityIndex}}" range="{{cityarray}}">
|
||||
<picker class="absolute right-0 box-middle" bindchange="changeQuarter" value="{{quarterIndex}}" range="{{quarterarray}}">
|
||||
<view class="pt10 pb10 pl20 pr20 bg-f6 ulib-r10 font-22">
|
||||
<text>{{cityarray[cityIndex]}}</text>
|
||||
<text>{{quarterarray[quarterIndex]}}</text>
|
||||
<i class="iconfont ml20 icon-xiala color-999"></i>
|
||||
</view>
|
||||
</picker>
|
||||
|
||||
@@ -1,9 +1,56 @@
|
||||
import _ from '../../commons/js/commons'
|
||||
import popularData from '../../commons/js/lib/popularData';
|
||||
import * as echarts from '../../ecCanvas/components/ec-canvas/echarts';
|
||||
const app = getApp()
|
||||
Page({
|
||||
data: {
|
||||
imgUrl:_.config.imgUrl,
|
||||
|
||||
storearray: ['厦门店', '泉州店', '福州店', ],
|
||||
storeobj: [
|
||||
{
|
||||
id: 0,
|
||||
name: '厦门店'
|
||||
},
|
||||
{
|
||||
id: 1,
|
||||
name: '泉州店'
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: '福州店'
|
||||
},
|
||||
],
|
||||
storeIndex:0,
|
||||
|
||||
staffarray: ['张三', '李四', '王五', ],
|
||||
staffobj: [
|
||||
{
|
||||
id: 0,
|
||||
name: '张三'
|
||||
},
|
||||
{
|
||||
id: 1,
|
||||
name: '李四'
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: '王五'
|
||||
},
|
||||
],
|
||||
staffIndex:-1,
|
||||
|
||||
tabId:'1',
|
||||
tab:[
|
||||
{
|
||||
id: 1,
|
||||
title: '王五'
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
title: '王五'
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
onLoad(options) {
|
||||
@@ -12,6 +59,11 @@ Page({
|
||||
[key]: options[key]
|
||||
})
|
||||
}
|
||||
popularData.getDateLater(0,0).then(res => {
|
||||
this.setData({
|
||||
dateTime:res[0],
|
||||
})
|
||||
})
|
||||
|
||||
this.getBar()
|
||||
this.getLine()
|
||||
@@ -21,6 +73,35 @@ Page({
|
||||
|
||||
},
|
||||
|
||||
//选择门店
|
||||
changeStore(e) {
|
||||
this.setData({
|
||||
storeIndex: e.detail.value
|
||||
})
|
||||
},
|
||||
|
||||
//日期选择
|
||||
changeDate(e){
|
||||
this.setData({
|
||||
dateTime: e.detail.value,
|
||||
})
|
||||
},
|
||||
|
||||
//选择人员
|
||||
changeStaff(e) {
|
||||
this.setData({
|
||||
staffIndex: e.detail.value
|
||||
})
|
||||
},
|
||||
|
||||
//切换tab
|
||||
changeTab(e){
|
||||
this.setData({
|
||||
tabId:e.currentTarget.dataset.id,
|
||||
})
|
||||
//this.searchSubmit()
|
||||
},
|
||||
|
||||
getBar(){
|
||||
this.setData({
|
||||
ecBar: {
|
||||
|
||||
@@ -2,10 +2,47 @@
|
||||
<view class="inner30 img-top-cover" style="background-image:url({{imgUrl}}channel/theme.jpg);">
|
||||
|
||||
<!-- 管辖门店 -->
|
||||
<view class="mt20 inner30 pt40 bg-fff box-shadow-000-10-10 ulib-r10">
|
||||
<view class="bg-f6 inner30 font-32 fn-clear ulib-r10">
|
||||
<view class="inner30 pt40 bg-fff box-shadow-000-10-10 ulib-r10">
|
||||
<view class="bg-f6 pt25 pb25 pl30 pr30 font-32 fn-clear ulib-r10">
|
||||
<view class="fn-fl">门店</view>
|
||||
<view></view>
|
||||
<picker class="fn-fr" bindchange="changeStore" value="{{storeIndex}}" range="{{storearray}}">
|
||||
<view class="color-666">
|
||||
<text>{{storearray[storeIndex]}}</text>
|
||||
<i class="iconfont ml10 icon-gengduo font-26 color-999"></i>
|
||||
</view>
|
||||
</picker>
|
||||
</view>
|
||||
<view class="mt20 bg-f6 pt25 pb25 pl30 pr30 font-32 fn-clear ulib-r10">
|
||||
<view class="fn-fl">日期选择</view>
|
||||
<picker class="fn-fr" mode="date" value="{{dateTime}}" bindchange="changeDate">
|
||||
<view class="color-666">
|
||||
<text>{{dateTime}}</text>
|
||||
<i class="iconfont ml10 icon-gengduo font-26 color-999"></i>
|
||||
</view>
|
||||
</picker>
|
||||
</view>
|
||||
<view class="mt20 bg-f6 pt25 pb25 pl30 pr30 font-32 fn-clear ulib-r10">
|
||||
<view class="fn-fl">人员选择</view>
|
||||
<picker class="fn-fr" bindchange="changeStaff" value="{{staffIndex}}" range="{{staffarray}}">
|
||||
<view class="color-666">
|
||||
<text wx:if="{{staffIndex == -1}}">全部</text>
|
||||
<text wx:else>{{staffarray[staffIndex]}}</text>
|
||||
<i class="iconfont ml10 icon-gengduo font-26 color-999"></i>
|
||||
</view>
|
||||
</picker>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 客户数据 / 订单数据 -->
|
||||
<view class="mt40 bg-fff box-shadow-000-10-10 ulib-r10 overflowhidden">
|
||||
<view class="fn-flex font-36 text-center">
|
||||
<block wx:for='{{tab}}' wx:key='list'>
|
||||
<view class="fn-flex-item pt20 pb20 {{ tabId == item.id?'active color-36afa2':''}}" data-id="{{item.id}}" bindtap="changeTab">
|
||||
<view class="relative">{{item.title}}</view>
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
<view class="inner30">
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<!-- 数据分析·客户 -->
|
||||
|
||||
Reference in New Issue
Block a user