Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
store-assistant-assemble
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 1ea13ca5
authored
Nov 02, 2023
by
杨明
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed
1 parent
778fb917
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
28 additions
and
18 deletions
login/index/components/authSetting/authSetting.wxml
pages/tab/stat/components/browse/browse.js
pages/tab/stat/components/car/car.wxml
pages/tab/stat/components/commodity/commodity.wxml
pages/tab/stat/components/custom/custom.wxml
pages/tab/stat/components/lodge/lodge.js
pages/tab/stat/components/lodge/lodge.wxml
pages/tab/stat/components/portrait/portrait.js
pages/tab/stat/components/timeline/timeline.js
utils/request/environment.js
login/index/components/authSetting/authSetting.wxml
View file @
1ea13ca
<view class='tips'>
<view class='tips'
bindtap="choose"
>
<view class='choose-box'
bindtap="choose"
>
<view class='choose-box'>
<view class='icon'>
<view class='icon'>
<icon wx:if="{{agree}}" class="icon-small" type="success" size="14" color="#4466F0"></icon>
<icon wx:if="{{agree}}" class="icon-small" type="success" size="14" color="#4466F0"></icon>
<icon wx:else class="icon-small" type="circle" size="14" color="#4466F0"></icon>
<icon wx:else class="icon-small" type="circle" size="14" color="#4466F0"></icon>
...
...
pages/tab/stat/components/browse/browse.js
View file @
1ea13ca
...
@@ -15,7 +15,7 @@ Component({
...
@@ -15,7 +15,7 @@ Component({
data
:
{
data
:
{
outputValue
:
[{
outputValue
:
[{
label
:
'订单总数(单)'
,
label
:
'订单总数(单)'
,
name
:
'ordersTotal
'
,
name
:
'ordersTotal'
,
unit
:
''
,
unit
:
''
,
iconUrl
:
'store-assistant-assemble/output/icon02.png'
iconUrl
:
'store-assistant-assemble/output/icon02.png'
},
{
},
{
...
...
pages/tab/stat/components/car/car.wxml
View file @
1ea13ca
<view class="box">
<view class="box">
<view class="box-title">车辆类型</view>
<view class="box-title">车辆类型</view>
<view class="box-body">
<view class="box-body">
<circle class="children-box" width="200" Id="car779" ratioList="{{
ratioList
}}"></circle>
<circle class="children-box" width="200" Id="car779" ratioList="{{
vehicleDistribution
}}"></circle>
<view class="children-box">
<view class="children-box">
<view class="children-item" wx:for="{{vehicleDistribution}}">
<view class="children-item" wx:for="{{vehicleDistribution}}">
<view class="icon" style="background: {{item.color}};"></view>
<view class="icon" style="background: {{item.color}};"></view>
...
...
pages/tab/stat/components/commodity/commodity.wxml
View file @
1ea13ca
<view class="box">
<view class="box">
<view class="box-title">消费能力</view>
<view class="box-title">消费能力</view>
<view class="box-body">
<view class="box-body">
<circle class="children-box" width="200" Id="com3479" ratioList="{{
ratioList
}}"></circle>
<circle class="children-box" width="200" Id="com3479" ratioList="{{
consumeDistribution
}}"></circle>
<view class="children-box">
<view class="children-box">
<view class="children-item" wx:for="{{consumeDistribution}}">
<view class="children-item" wx:for="{{consumeDistribution}}">
<view class="icon" style="background: {{item.color}};"></view>
<view class="icon" style="background: {{item.color}};"></view>
...
...
pages/tab/stat/components/custom/custom.wxml
View file @
1ea13ca
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
</view>
</view>
</view>
</view>
<circle width="200" Id="custom54" ratioList="{{
ratioList
}}"></circle>
<circle width="200" Id="custom54" ratioList="{{
sourceDistribution
}}"></circle>
</view>
</view>
</view>
</view>
\ No newline at end of file
\ No newline at end of file
pages/tab/stat/components/lodge/lodge.js
View file @
1ea13ca
...
@@ -7,16 +7,17 @@ Component({
...
@@ -7,16 +7,17 @@ Component({
/**
/**
* 组件的初始数据
* 组件的初始数据
*/
*/
data
:
{
data
:
{},
},
/**
/**
* 组件的方法列表
* 组件的方法列表
*/
*/
methods
:
{
methods
:
{
getRatio
(
n
)
{
getRatio
(
n
)
{
const
{
lodgeDistribution
}
=
n
const
{
this
.
setRatio
(
'lodgeDistribution'
,
lodgeDistribution
,[
'#F9CEF7'
,
'#5CF0D8'
])
lodgeDistribution
}
=
n
this
.
setRatio
(
'lodgeDistribution'
,
lodgeDistribution
,
[
'#F9CEF7'
,
'#5CF0D8'
])
}
}
}
}
})
})
\ No newline at end of file
\ No newline at end of file
pages/tab/stat/components/lodge/lodge.wxml
View file @
1ea13ca
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
</view>
</view>
</view>
</view>
<circle width="200" Id="lodge3479" ratioList="{{
ratioList
}}"></circle>
<circle width="200" Id="lodge3479" ratioList="{{
lodgeDistribution
}}"></circle>
</view>
</view>
</view>
</view>
\ No newline at end of file
\ No newline at end of file
pages/tab/stat/components/portrait/portrait.js
View file @
1ea13ca
...
@@ -24,9 +24,9 @@ Component({
...
@@ -24,9 +24,9 @@ Component({
sexDistribution
sexDistribution
}
=
obj
;
}
=
obj
;
this
.
setRatio
(
'sexDistribution'
,
sexDistribution
,
''
,
true
)
this
.
setRatio
(
'sexDistribution'
,
sexDistribution
,
''
,
true
)
this
.
setRatio
(
'ageDistribution'
,
ageDistribution
)
this
.
setRatio
(
'ageDistribution'
,
ageDistribution
.
reverse
()
)
this
.
setRatio
(
'eraDistribution'
,
eraDistribution
)
this
.
setRatio
(
'eraDistribution'
,
eraDistribution
.
reverse
()
)
this
.
setRatio
(
'childDistribution'
,
childDistribution
,
[
'#F9CEF7'
,
'#3582EE'
,
'#5CF0D8'
,
'#FCEE8D'
])
this
.
setRatio
(
'childDistribution'
,
childDistribution
.
reverse
()
,
[
'#F9CEF7'
,
'#3582EE'
,
'#5CF0D8'
,
'#FCEE8D'
])
}
}
}
}
})
})
\ No newline at end of file
\ No newline at end of file
pages/tab/stat/components/timeline/timeline.js
View file @
1ea13ca
...
@@ -24,9 +24,15 @@ Component({
...
@@ -24,9 +24,15 @@ Component({
this
.
getServerData
();
this
.
getServerData
();
},
},
getServerData
()
{
getServerData
()
{
let
_max
=
0
;
const
{
viewCustomerPortrait
:{
browseDistribution
}}
=
this
.
data
,
const
{
viewCustomerPortrait
:{
browseDistribution
}}
=
this
.
data
,
categories
=
browseDistribution
.
map
(
i
=>
i
.
name
).
filter
((
v
,
k
)
=>
k
%
2
==
1
),
categories
=
browseDistribution
.
map
((
i
,
k
)
=>
{
data
=
browseDistribution
.
map
(
i
=>
i
.
value
).
filter
((
v
,
k
)
=>
k
%
2
==
1
);
return
k
%
2
==
0
?
i
.
name
:
''
}),
data
=
browseDistribution
.
map
(
i
=>
{
_max
=
Math
.
max
(
_max
,
i
.
value
)
return
i
.
value
})
//模拟从服务器获取数据时的延时
//模拟从服务器获取数据时的延时
setTimeout
(()
=>
{
setTimeout
(()
=>
{
//模拟服务器返回数据,如果数据格式和标准格式不同,需自行按下面的格式拼接
//模拟服务器返回数据,如果数据格式和标准格式不同,需自行按下面的格式拼接
...
@@ -36,10 +42,11 @@ Component({
...
@@ -36,10 +42,11 @@ Component({
data
data
},
]
},
]
};
};
this
.
drawCharts
(
'MkatSdTACyZKZRwWnLaWPTKfZrUmkBlh'
,
res
);
this
.
drawCharts
(
'MkatSdTACyZKZRwWnLaWPTKfZrUmkBlh'
,
res
,
_max
);
},
500
);
},
500
);
},
},
drawCharts
(
id
,
data
)
{
drawCharts
(
id
,
data
,
_max
)
{
_max
=
Math
.
ceil
(
_max
/
5
)
*
5
const
query
=
wx
.
createSelectorQuery
().
in
(
this
);
const
query
=
wx
.
createSelectorQuery
().
in
(
this
);
query
.
select
(
'#'
+
id
).
fields
({
query
.
select
(
'#'
+
id
).
fields
({
node
:
true
,
node
:
true
,
...
@@ -78,6 +85,7 @@ Component({
...
@@ -78,6 +85,7 @@ Component({
data
:
[{
data
:
[{
axisLine
:
false
,
axisLine
:
false
,
fontColor
:
'#A6A6A6'
,
fontColor
:
'#A6A6A6'
,
max
:
_max
}]
}]
},
},
extra
:
{
extra
:
{
...
...
utils/request/environment.js
View file @
1ea13ca
...
@@ -13,6 +13,7 @@ const mockObj = {
...
@@ -13,6 +13,7 @@ const mockObj = {
3生产
3生产
*/
*/
// const index = 1
// const index = 1
const
accountInfo
=
wx
.
getAccountInfoSync
()
const
accountInfo
=
wx
.
getAccountInfoSync
()
const
systemInfo
=
wx
.
getSystemInfoSync
()
const
systemInfo
=
wx
.
getSystemInfoSync
()
// console.log(systemInfo);
// console.log(systemInfo);
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment