* 'dev' of git.oa00.com:xiaowen/swsWecat: 1 cxw-010203 no message # Conflicts: # components/indexCom/eventChild/index.wxmldev
commit
927317a4f0
@ -1,22 +1,45 @@
|
||||
//app.js
|
||||
App({
|
||||
onLaunch: function () {
|
||||
// 展示本地存储能力
|
||||
var logs = wx.getStorageSync('logs') || []
|
||||
logs.unshift(Date.now())
|
||||
wx.setStorageSync('logs', logs)
|
||||
const systemInfo = wx.getSystemInfoSync(); //获取系统信息
|
||||
const menuInfo = wx.getMenuButtonBoundingClientRect(); // 获取胶囊按钮的信息
|
||||
this.globalData.menuHeight = menuInfo.height; // 获取胶囊按钮的高
|
||||
this.globalData.statusBarHeight = systemInfo.statusBarHeight; // 获取状态栏的高
|
||||
this.globalData.menuRight = menuInfo.right; // 获取胶囊按钮的距离屏幕最右边的距离(此处用于设置导航栏左侧距离屏幕的距离)
|
||||
this.globalData.navBarHeight = (menuInfo.top - systemInfo.statusBarHeight) * 2 + menuInfo.height; // 计算出导航栏的高度
|
||||
},
|
||||
onLaunch: function () {
|
||||
// 展示本地存储能力
|
||||
var logs = wx.getStorageSync('logs') || []
|
||||
logs.unshift(Date.now())
|
||||
wx.setStorageSync('logs', logs)
|
||||
const systemInfo = wx.getSystemInfoSync(); //获取系统信息
|
||||
const menuInfo = wx.getMenuButtonBoundingClientRect(); // 获取胶囊按钮的信息
|
||||
this.globalData.menuHeight = menuInfo.height; // 获取胶囊按钮的高
|
||||
this.globalData.statusBarHeight = systemInfo.statusBarHeight; // 获取状态栏的高
|
||||
this.globalData.menuRight = menuInfo.right; // 获取胶囊按钮的距离屏幕最右边的距离(此处用于设置导航栏左侧距离屏幕的距离)
|
||||
this.globalData.navBarHeight = (menuInfo.top - systemInfo.statusBarHeight) * 2 + menuInfo.height; // 计算出导航栏的高度
|
||||
},
|
||||
globalData: {
|
||||
imageUrl: "https://cdn.sws010.com/wxapp/images",
|
||||
navBarHeight:0,// 导航栏高度
|
||||
menuHeight:0,//胶囊按钮 高度
|
||||
statusBarHeight:0,//状态栏高度
|
||||
menuRight:0,//胶囊按钮 距离屏幕右边的距离
|
||||
navBarHeight: 0, // 导航栏高度
|
||||
menuHeight: 0, //胶囊按钮 高度
|
||||
statusBarHeight: 0, //状态栏高度
|
||||
menuRight: 0, //胶囊按钮 距离屏幕右边的距离
|
||||
request: function (prarms) {
|
||||
return new Promise((resolve, reject) => {
|
||||
wx.request({
|
||||
url: 'http://cloud.sws010.com/api/v7.ashx',
|
||||
data: {
|
||||
version: "0.0.1",
|
||||
...prarms
|
||||
},
|
||||
method: 'get',
|
||||
success: function (res) {
|
||||
//接口实际返回的内容在res.data中
|
||||
if (res.data.Code == 1) {
|
||||
resolve(res.data.Data);
|
||||
} else {
|
||||
reject(res.data)
|
||||
}
|
||||
},
|
||||
fail: function (err) {
|
||||
reject(err);
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
@ -0,0 +1,177 @@
|
||||
export default {
|
||||
tooltip: {
|
||||
trigger: 'axis',
|
||||
axisPointer: { // 坐标轴指示器,坐标轴触发有效
|
||||
type: 'line' // 默认为直线,可选为:'line' | 'shadow'
|
||||
},
|
||||
confine: true
|
||||
},
|
||||
legend: {
|
||||
icon: 'rectangle',//data图标样式
|
||||
itemWidth: 8,//data图标大小
|
||||
itemHeight: 8,
|
||||
left: 5,
|
||||
textStyle: {
|
||||
fontSize: 8,
|
||||
fontWeight: 400
|
||||
},
|
||||
data: ['微博', '其他','短视频', '微信','APP', '论坛', '新闻'],
|
||||
// color:['#FF4852','#FF6E25','#FFBF00','#20CC62','#00D6D6','#00AAFF','#7257FF'],
|
||||
},
|
||||
//图表位置
|
||||
grid: {
|
||||
left: 7,
|
||||
right: 7,
|
||||
bottom: 7,
|
||||
top: 36,
|
||||
containLabel: true
|
||||
},
|
||||
yAxis: [
|
||||
{
|
||||
type: 'value',
|
||||
axisTick:{
|
||||
show:false //去除刻度线
|
||||
},
|
||||
axisLine:{
|
||||
show:false //去除轴线
|
||||
},
|
||||
axisLabel: {
|
||||
color: '#999999',//y轴文本颜色
|
||||
textStyle: {
|
||||
fontSize : 9
|
||||
}
|
||||
},
|
||||
splitLine: { //分割线
|
||||
// lineStyle:{
|
||||
// // color:"#2d3436"
|
||||
|
||||
// }
|
||||
show: true,
|
||||
lineStyle: {
|
||||
type: 'dashed',
|
||||
color: '#E8E8E8',
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
xAxis: [
|
||||
{
|
||||
type: 'category',
|
||||
data: ['00:00', '04:00', '08:00', '12:00', '16:00', '20:00', '24:00'],
|
||||
axisTick:{
|
||||
show:false //去除刻度线
|
||||
},
|
||||
axisLine:{
|
||||
show:false, //去除轴线
|
||||
},
|
||||
axisLabel: {
|
||||
color: '#999999',//x轴文本颜色
|
||||
textStyle: {
|
||||
fontSize : 9
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
],
|
||||
series: [
|
||||
{
|
||||
name: '微博',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [1400, 2000, 1500, 1800, 1490, 900, 310],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#FF4852',
|
||||
lineStyle: {
|
||||
color: '#FF4852'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: '其他',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [1520, 1052, 141, 174, 1690, 250, 220],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#FF6E25',
|
||||
lineStyle: {
|
||||
color: '#FF6E25'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: '短视频',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [210, 322, 551, 364, 960, 1307, 10],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#FFBF00',
|
||||
lineStyle: {
|
||||
color: '#FFBF00'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
{
|
||||
name: '微信',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [250, 362, 71, 374, 970, 130, 170],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#20CC62',
|
||||
lineStyle: {
|
||||
color: '#20CC62'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'APP',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [20, 32, 41, 354, 90, 130, 10],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#00D6D6',
|
||||
lineStyle: {
|
||||
color: '#00D6D6'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: '论坛',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [200, 382, 661, 34, 909, 1308, 150],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#00AAFF',
|
||||
lineStyle: {
|
||||
color: '#00AAFF'
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: '新闻',
|
||||
type: 'line',
|
||||
symbol:'none', //去圆点
|
||||
data: [250, 326, 178, 349, 900, 1300, 140],
|
||||
itemStyle: {
|
||||
normal:{
|
||||
color: '#7257FF',
|
||||
lineStyle: {
|
||||
color: '#7257FF'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
@ -0,0 +1,42 @@
|
||||
export default [
|
||||
{
|
||||
url:'/ruku.png',
|
||||
text:'入库数据',
|
||||
num:'198,897,987',
|
||||
},
|
||||
{
|
||||
url:'/weibo.png',
|
||||
text:'微博数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/shipin.png',
|
||||
text:'短视频数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/weixin.png',
|
||||
text:'微信数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/app.png',
|
||||
text:'APP数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/luntan.png',
|
||||
text:'论坛数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/xinwen.png',
|
||||
text:'新闻数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
{
|
||||
url:'/qita.png',
|
||||
text:'其他数据',
|
||||
num:'198,897,987'
|
||||
},
|
||||
]
|
Loading…
Reference in new issue