diff --git a/components/option/percentRankOption.js b/components/option/percentRankOption.js index dae570f..9f0b6ce 100644 --- a/components/option/percentRankOption.js +++ b/components/option/percentRankOption.js @@ -1,5 +1,11 @@ // 地区分布 -export default function pictographicOption(dRegion=[],dValue=[]){ +export default function pictographicOption(dRegion = [], dValue = []) { + if(dRegion.length < 5) { + let n = 5 - dRegion.length; + for(let i = 0; i < n; i++) { + dRegion.push('') + } + } return { tooltip: { trigger: "item", @@ -13,60 +19,61 @@ export default function pictographicOption(dRegion=[],dValue=[]){ extraCssText: "box-shadow: 0px 0px 10px 0px #3373CC;", confine: true }, - xAxis: { - show:false, - type:'value' - }, - yAxis: - { - data: dRegion, - inverse: true, - axisTick: { show: false }, - axisLine: { show: false }, - axisLabel: { - margin: 10, - color: '#333333', - fontSize: 12 - } - }, - grid: { - // top: 'center', - bottom:20, - height:186, - width:48, - left: 60, - }, - series: [ - { - itemStyle:{ - normal:{ - color:'#0084FF', - barBorderRadius:12 - }, - }, - // current data - type: 'bar', - barWidth:10, - data:dValue, - label: { - show: true, - formatter: function (params) { - return (params.value).toFixed(1) + ' %'; - }, - // position: 'right', - // offset: [20, 0], + xAxis: { + show: false, + type: 'value' + }, + yAxis: + { + data: dRegion, + axisTick: { show: false }, + axisLine: { show: false }, + inverse: true, + axisLabel: { + margin: 10, color: '#333333', - fontSize: 12, - position:[60,-1] - }, + fontSize: 12 + } + }, + grid: { + // top: 'center', + top: 'top', + bottom: 20, + height: 186, + width: 48, + left: 60, + }, + series: [ + { + itemStyle: { + normal: { + color: '#0084FF', + barBorderRadius: 12 + }, + }, + // current data + type: 'bar', + barWidth: 10, + data: dValue, + label: { + show: true, + formatter: function (params) { + return (params.value).toFixed(1) + ' %'; + }, + // position: 'right', + // offset: [20, 0], + color: '#333333', + fontSize: 12, + position: [60, -1] + }, showBackground: true, backgroundStyle: { - color: 'rgba(180, 180, 180, 0.2)' - }, - markLine: { - symbol: 'none', - }, - }, - ] -} + color: 'rgba(180, 180, 180, 0.2)' + }, + markLine: { + symbol: 'none', + }, + }, + ] + } } \ No newline at end of file diff --git a/components/option/pictographicOption.js b/components/option/pictographicOption.js index be09dfd..23cc9f2 100644 --- a/components/option/pictographicOption.js +++ b/components/option/pictographicOption.js @@ -33,11 +33,11 @@ export default function pictographicOption(dRegion = [], dValue = [], dSum = 0) } }, grid: { - top: '10%', - bottom: 20, + top: '10%', + bottom: 5, height: 186, width: 48, - left: 60, + left: 55, }, series: [{ itemStyle: { diff --git a/components/option/pictographicOption2.js b/components/option/pictographicOption2.js index 7fb8cb4..c3d14c6 100644 --- a/components/option/pictographicOption2.js +++ b/components/option/pictographicOption2.js @@ -36,9 +36,9 @@ export default function pictographicOption(dRegion = [], dValue = [], dSum = 0) } }, grid: { - height: 186, width: '50%', - left: 'center', + height: 186, + left:'23%', }, series: [{ itemStyle: { diff --git a/components/timeCustom/index.js b/components/timeCustom/index.js index 9c11ee2..3abcff5 100644 --- a/components/timeCustom/index.js +++ b/components/timeCustom/index.js @@ -20,9 +20,18 @@ Component({ }, lifetimes: { attached() { - wx.setStorageSync('sTimeType', '34'); - wx.setStorageSync('sStartTime', ''); - wx.setStorageSync('sEndTime', ''); + let st = wx.getStorageSync('sTimeType') + if (st) { + let n = this.data.valList.findIndex(ele => ele == st); + this.setData({ + intervalSel: n + }) + } else { + wx.setStorageSync('sTimeType', 34); + wx.setStorageSync('sStartTime', ''); + wx.setStorageSync('sEndTime', ''); + } + } }, methods: { diff --git a/contrastPackages/brandRatio/BBS/index.wxml b/contrastPackages/brandRatio/BBS/index.wxml index 2395038..2097452 100644 --- a/contrastPackages/brandRatio/BBS/index.wxml +++ b/contrastPackages/brandRatio/BBS/index.wxml @@ -52,7 +52,7 @@ 论坛正面话题对比 - + @@ -61,7 +61,7 @@ - {{item.name}} + {{item.name}} @@ -80,7 +80,7 @@ - {{item.name}} + {{item.name}} diff --git a/contrastPackages/brandRatio/BBS/index.wxss b/contrastPackages/brandRatio/BBS/index.wxss index a1cfc1f..9e1f3cc 100644 --- a/contrastPackages/brandRatio/BBS/index.wxss +++ b/contrastPackages/brandRatio/BBS/index.wxss @@ -94,5 +94,5 @@ height: 970rpx; background:#ffffff; border-radius: 8rpx; - padding-top:32rpx; + padding:32rpx 0; } diff --git a/contrastPackages/eventRatio/weibo/index.js b/contrastPackages/eventRatio/weibo/index.js index 273fd43..f501d98 100644 --- a/contrastPackages/eventRatio/weibo/index.js +++ b/contrastPackages/eventRatio/weibo/index.js @@ -152,7 +152,6 @@ Component({ obj.func = pieOption(['#FF4852', '#FF6E25', '#FFBF00', '#20CC62', '#00D6D6', '#00AAFF', '#7257FF'], i) newData.push(obj) } - console.log(newData); this.setData({ weiboDist: newData }) @@ -193,11 +192,13 @@ Component({ newRes.push(obj) } newRes = newRes.map(ele => { - ele.func = [pictographicOption(ele.region.slice(0, 5), ele.value.slice(0, 5), ele.sum), + ele.func = [pictographicOption(ele.region.slice(0, 5), ele.value.slice(0, 5), ele.sum,), pictographicOption(ele.region.slice(5, 10), ele.value.slice(5, 10), ele.sum) ] return ele }) + + console.log('ser',newRes) this.setData({ area: newRes }) diff --git a/contrastPackages/eventRatio/weibo/index.wxml b/contrastPackages/eventRatio/weibo/index.wxml index bf99ccb..4f7790b 100644 --- a/contrastPackages/eventRatio/weibo/index.wxml +++ b/contrastPackages/eventRatio/weibo/index.wxml @@ -71,16 +71,15 @@ 活跃用户信息 - - 事件一 - - + + {{indedx==0?"事件一":"事件二"}} + + - + - diff --git a/contrastPackages/eventRatio/weibo/index.wxss b/contrastPackages/eventRatio/weibo/index.wxss index 6c8ed1c..eef986a 100644 --- a/contrastPackages/eventRatio/weibo/index.wxss +++ b/contrastPackages/eventRatio/weibo/index.wxss @@ -1,7 +1,7 @@ .chart_box{ margin-top: 24rpx; width: 686rpx; - height: 486rpx; + height: 400rpx; padding-top:32rpx ; background: white; } @@ -70,10 +70,10 @@ .area_box{ margin-top: 24rpx; width: 686rpx; - height: 970rpx; + height: 880rpx; background:#ffffff; border-radius: 8rpx; - padding-top:32rpx; + padding:32rpx 0; } .event_distribution{ height: 894rpx; diff --git a/contrastPackages/themeRatio/BBS/index.wxml b/contrastPackages/themeRatio/BBS/index.wxml index 60e0dab..1187c22 100644 --- a/contrastPackages/themeRatio/BBS/index.wxml +++ b/contrastPackages/themeRatio/BBS/index.wxml @@ -61,9 +61,8 @@ - {{item.name}} - - + {{item.name}} + @@ -82,7 +81,7 @@ {{item.name}} - + diff --git a/contrastPackages/themeRatio/weibo/index.wxml b/contrastPackages/themeRatio/weibo/index.wxml index 9a4f36d..f1042f8 100644 --- a/contrastPackages/themeRatio/weibo/index.wxml +++ b/contrastPackages/themeRatio/weibo/index.wxml @@ -95,12 +95,12 @@ - {{item.name}} - - + {{item.name}} + + - + diff --git a/contrastPackages/themeRatio/weibo/index.wxss b/contrastPackages/themeRatio/weibo/index.wxss index 02d24d0..1e8bbde 100644 --- a/contrastPackages/themeRatio/weibo/index.wxss +++ b/contrastPackages/themeRatio/weibo/index.wxss @@ -5,6 +5,13 @@ padding:32rpx 0; background: white; } +.chart_box1{ + margin-top: 24rpx; + width: 686rpx; + height: 400rpx; + padding:32rpx 0; + background: white; +} .chart_box1{ margin-top: 24rpx; diff --git a/miniprogram_npm/@vant/weapp/tree-select/index.wxss b/miniprogram_npm/@vant/weapp/tree-select/index.wxss index 5bef0ac..f03e2da 100644 --- a/miniprogram_npm/@vant/weapp/tree-select/index.wxss +++ b/miniprogram_npm/@vant/weapp/tree-select/index.wxss @@ -1 +1,47 @@ -@import '../common/index.wxss';.van-tree-select{display:flex;font-size:var(--tree-select-font-size,14px);position:relative;-webkit-user-select:none;user-select:none}.van-tree-select__nav{--sidebar-padding:12px 8px 12px 12px;background-color:var(--tree-select-nav-background-color,#f7f8fa);flex:1}.van-tree-select__nav__inner{height:100%;width:100%!important}.van-tree-select__content{background-color:var(--tree-select-content-background-color,#fff);flex:2}.van-tree-select__item{font-weight:700;line-height:var(--tree-select-item-height,44px);padding:0 32px 0 var(--padding-md,16px);position:relative}.van-tree-select__item--active{color:var(--tree-select-item-active-color,#ee0a24)}.van-tree-select__item--disabled{color:var(--tree-select-item-disabled-color,#c8c9cc)}.van-tree-select__selected{position:absolute;right:var(--padding-md,16px);top:50%;transform:translateY(-50%)} \ No newline at end of file +@import '../common/index.wxss'; + +.van-tree-select { + display: flex; + font-size: var(--tree-select-font-size, 14px); + position: relative; + -webkit-user-select: none; + user-select: none +} + +.van-tree-select__nav { + --sidebar-padding: 12px 8px 12px 12px; + background-color: var(--tree-select-nav-background-color, #f7f8fa); + flex: 1 +} + +.van-tree-select__nav__inner { + height: 100%; + width: 100% !important +} + +.van-tree-select__content { + background-color: var(--tree-select-content-background-color, #fff); + flex: 2 +} + +.van-tree-select__item { + font-weight: 700; + line-height: var(--tree-select-item-height, 44px); + padding: 0 32px 0 var(--padding-md, 16px); + position: relative +} + +.van-tree-select__item--active { + color: var(--tree-select-item-active-color, #ee0a24) +} + +.van-tree-select__item--disabled { + color: var(--tree-select-item-disabled-color, #c8c9cc) +} + +.van-tree-select__selected { + position: absolute; + right: var(--padding-md, 16px); + top: 50%; + transform: translateY(-50%) +} \ No newline at end of file diff --git a/pages/index/Salesranking/Salesranking.js b/pages/index/Salesranking/Salesranking.js index 14b64a5..b8b9341 100644 --- a/pages/index/Salesranking/Salesranking.js +++ b/pages/index/Salesranking/Salesranking.js @@ -10,13 +10,14 @@ let iPageIndex = 1 // 当前第几页,0代表第一页 let iPageSize = 20 //每页显示多少数据 Page({ data: { + nengtitle1: '全部级别', + nengtitle2: '全部价格', + nengtitle3: '全部能源', active: 0, end: moment().format("YYYY-MM"), showChart: true, // select: false, - grade_value1: "", grade_value2: "", - grade_value3: "", grade_value4: 0, grades4: [{ text: '列表展示', @@ -48,15 +49,14 @@ Page({ sEnergyType: '', imageUrl: getApp().globalData.imageUrl, mockData: [], - show1: false, mainActiveIndex: 0, - mainActiveIndex2:0, + mainActiveIndex2: 0, activeId: '', + activeId2: '', // ec: { lazyLoad: true // 设置图表懒加载 }, - showvalue:false, }, // 标签切换点击事件 onChange(val) { @@ -173,8 +173,6 @@ Page({ }, //页面上拉触底事件的处理函数 onReachBottom: function () { - // console.log("上拉触底事件") - // console.log(iPageIndex) let that = this if (!that.data.loadMore) { that.setData({ @@ -207,7 +205,7 @@ Page({ } obj.children.push(ol) }) - } + } arr.push(obj) }) this.setData({ @@ -250,7 +248,7 @@ Page({ } obj.children.push(ol) }) - } + } arr.push(obj) }) this.setData({ @@ -266,33 +264,14 @@ Page({ this.data.builds = e.detail.val } }, - // 按级别 - mySelect1(e) { - iPageIndex = 1 - iPageSize = 20 - this.setData({ - ranking: [], - sSpec: e.detail, - }) - this.getTrend() - }, // 按价格 - mySelect2(e) { - iPageIndex = 1 - iPageSize = 20 - this.setData({ - ranking: [], - sPriceType: e.detail, - }) - this.getTrend() - }, - // 按能源 - mySelect3(e) { + mySelect2({ detail }) { iPageIndex = 1 iPageSize = 20 this.setData({ ranking: [], - sEnergyType: e.detail, + sPriceType: this.data.grades2[detail].value, + nengtitle2:this.data.grades2[detail].text, }) this.getTrend() }, @@ -303,7 +282,7 @@ Page({ this.setData({ ranking: [], a: e.detail != 0, - showvalue:false + showvalue: false }) this.getTrend() }, @@ -315,9 +294,9 @@ Page({ let dj = this.data.num % 2 == 0 this.setData({ ranking: [], - grade_value1: "", - grade_value2: "", - grade_value3: "", + nengtitle1: '全部级别', + nengtitle2: '全部价格', + nengtitle3: '全部能源', sSpec: '', sPriceType: '', sEnergyType: '', @@ -404,52 +383,76 @@ Page({ }) }, // 树形结构父级点击 - onClickNav({ detail = {} }) { + // 按能源 + onClickNav({ + detail = {} + }) { this.setData({ - mainActiveIndex: detail.index || 0, + mainActiveIndex: detail.index || 0, }); - let {grades3} = this.data; - if(!grades3[detail.index].children) { + let { + grades3 + } = this.data; + if (!grades3[detail.index].children) { this.setData({ ranking: [], - sEnergyType:grades3[detail.index].id || "", + sEnergyType: grades3[detail.index].id || "", + nengtitle3: grades3[detail.index].text, }) this.getTrend() - - } + } }, - onClickNav2({ detail = {} }) { + // 按级别 + onClickNav2({ + detail = {} + }) { this.setData({ - mainActiveIndex2: detail.index || 0, + mainActiveIndex2: detail.index || 0, }); - let {grades1} = this.data; - console.log('xds',grades1[detail.index]) - if(!grades1[detail.index].children) { + let { + grades1 + } = this.data; + if (!grades1[detail.index].children) { this.setData({ ranking: [], sSpec: grades1[detail.index].id || "", + nengtitle1: grades1[detail.index].text, }) this.getTrend() } }, + // 树形结构子级点击 + // 按能源 + onClickItem({ + detail = {} + }) { + const activeId = this.data.activeId === detail.id ? null : detail.id; + let { + mainActiveIndex + } = this.data; + this.setData({ + ranking: [], + activeId, + nengtitle3: detail.text, + sEnergyType: mainActiveIndex + "," + activeId, - // 树形结构子级点击 - onClickItem({ detail = {} }) { - const activeId = this.data.activeId === detail.id ? null : detail.id; - let {mainActiveIndex} = this.data; - this.setData({ - ranking: [], - sEnergyType: mainActiveIndex+","+activeId, - }); - this.getTrend() - }, - onClickItem2({ detail = {} }) { - const activeId = this.data.activeId === detail.id ? null : detail.id; - let {mainActiveIndex2} = this.data; - this.setData({ - ranking: [], - sSpec: mainActiveIndex2+","+activeId, - }); - this.getTrend() - }, + }); + this.getTrend() + }, + // 按级别 + onClickItem2({ + detail = {} + }) { + const activeId2 = this.data.activeId2 === detail.id ? null : detail.id; + let { + mainActiveIndex2 + } = this.data; + this.setData({ + ranking: [], + activeId2, + nengtitle1: detail.text, + sSpec: mainActiveIndex2 + "," + activeId2, + }); + this.getTrend() + }, }) \ No newline at end of file diff --git a/pages/index/Salesranking/Salesranking.wxml b/pages/index/Salesranking/Salesranking.wxml index b06803c..6e23b14 100644 --- a/pages/index/Salesranking/Salesranking.wxml +++ b/pages/index/Salesranking/Salesranking.wxml @@ -24,12 +24,12 @@ - - + + - - - + + + diff --git a/pages/index/Salesranking/Salesranking.wxss b/pages/index/Salesranking/Salesranking.wxss index e8ed6e9..596b4c2 100644 --- a/pages/index/Salesranking/Salesranking.wxss +++ b/pages/index/Salesranking/Salesranking.wxss @@ -2,13 +2,15 @@ .dropdown-menu { box-shadow: 0 0 0 !important; } + .detail-page { - position: relative; + position: relative; } -.van-dropdown-menu__item{ - border: 1px solid #F9F9F9; - position: relative; - margin:10rpx; + +.van-dropdown-menu__item { + border: 1px solid #F9F9F9; + position: relative; + margin: 10rpx; } .menu-tabs .van-tabs__nav { @@ -283,13 +285,14 @@ } /* 下拉内容 */ -van-dropdown-item van-dropdown-item--down{ - position: fixed; - left: 0; - right: 0; - top: 0; - bottom: 0; +van-dropdown-item van-dropdown-item--down { + position: fixed; + left: 0; + right: 0; + top: 0; + bottom: 0; } + .select_box { background-color: #fff; /* padding: 0 20rpx; */ @@ -341,8 +344,17 @@ van-dropdown-item van-dropdown-item--down{ text-align: center; border-radius: 50rpx; } -.jb-item{ + +.jb-item { font-size: 20rpx; height: 30px; line-height: 30px; +} + +.show { + display: none; +} + +.is_show { + display: block; } \ No newline at end of file diff --git a/pages/insight/pages/brandInsight/brandDataList/index.js b/pages/insight/pages/brandInsight/brandDataList/index.js index a6bce78..1ee8936 100644 --- a/pages/insight/pages/brandInsight/brandDataList/index.js +++ b/pages/insight/pages/brandInsight/brandDataList/index.js @@ -228,6 +228,7 @@ Page({ sStartTime: result.detail.sStartTime, sEndTime: result.detail.sEndTime, }); + console.log('xs', result.detail.sTimeType) this.getData(); }, toEventDetail(e) { @@ -333,7 +334,7 @@ Page({ sCrisis: wjList.join(',') || '', sType: 'BrandData', sField: JSON.stringify(sField), //导出字段 - sFileName: "事件数据" + date, //文件名称 + sFileName: this.data.fileName, //文件名称 sCheckedIds: this.data.result.join(',') || '', //数据id iNum: this.data.result.length == 0 ? this.data.total : this.data.result.length, //导出条数 iTimeType: this.data.iTimeType, //0发布时间 1入库时间 diff --git a/pages/insight/pages/eventInsight/evDatalist/index.js b/pages/insight/pages/eventInsight/evDatalist/index.js index d04274e..b8a392c 100644 --- a/pages/insight/pages/eventInsight/evDatalist/index.js +++ b/pages/insight/pages/eventInsight/evDatalist/index.js @@ -332,7 +332,7 @@ Component({ sCrisis: wjList.join(',') || '', sType: 'BrandDataHot', sField: JSON.stringify(sField), //导出字段 - sFileName: "事件数据" + date, //文件名称 + sFileName: this.data.fileName, //文件名称 sCheckedIds: this.data.result.join(',') || '', //数据id iNum: this.data.result.length == 0 ? this.data.total : this.data.result.length, //导出条数 iTimeType: this.data.iTimeType, //0发布时间 1入库时间 diff --git a/pages/insight/pages/modalInsight/modalDataList/index.js b/pages/insight/pages/modalInsight/modalDataList/index.js index 33dda96..e57bd85 100644 --- a/pages/insight/pages/modalInsight/modalDataList/index.js +++ b/pages/insight/pages/modalInsight/modalDataList/index.js @@ -333,7 +333,7 @@ Page({ sCrisis: wjList.join(',') || '', sType: 'BrandData', sField: JSON.stringify(sField), //导出字段 - sFileName: "事件数据" + date, //文件名称 + sFileName: this.data.fileName, //文件名称 sCheckedIds: this.data.result.join(',') || '', //数据id iNum: this.data.result.length == 0 ? this.data.total : this.data.result.length, //导出条数 iTimeType: this.data.iTimeType, //0发布时间 1入库时间 diff --git a/pages/insight/pages/themeList/index.js b/pages/insight/pages/themeList/index.js index 511723e..399975c 100644 --- a/pages/insight/pages/themeList/index.js +++ b/pages/insight/pages/themeList/index.js @@ -427,7 +427,7 @@ Page({ sType: 'ZhuTiFenXiBl', sGuid: this.data.Guid, sField: JSON.stringify(sField), //导出字段 - sFileName: "事件数据" + date, //文件名称 + sFileName:this.data.fileName, //文件名称 sCheckedIds: this.data.result.join(',') || '', //数据id iNum: this.data.result.length == 0 ? this.data.total : this.data.result.length, //导出条数 iTimeType: this.data.iTimeType, //0发布时间 1入库时间