对比开发

dev
Esdese 3 years ago
parent cf6ed13500
commit b6967b121b

@ -24,6 +24,7 @@
"pages/mine/pages/myReport/index",
"pages/mine/pages/helpCenter/index",
"pages/varComm/pages/brandRatio/index",
"pages/varComm/pages/brandRatio/comm/survey/index",
"pages/brandCrisis/index"
],
"window": {

@ -4,15 +4,16 @@ const words = [];
Component({
data: {
mockData: [],
result: new Array(6)
result: new Array(6),
boxArr:new Array(6),
},
methods: {
startCp() {
wx.navigateTo({
url: `/pages/varComm/pages/brandRatio/index?name=${this.data.result}`,
wx.setStorageSync('brandData',this.data.boxArr)
wx.navigateTo({
url: `/pages/varComm/pages/brandRatio/index`,
})
},
del(index){
@ -35,9 +36,14 @@ Component({
}
}
result.length = 6
console.log(result);
let boxArr = result
boxArr = boxArr.map(ele=>{
return ele !=undefined ? JSON.parse(ele):undefined
})
console.log(this.data.boxArr);
this.setData({
result: result,
boxArr:boxArr
});
},
},

@ -2,7 +2,7 @@
<wxs src="./filter.wxs" module="filter"></wxs>
<view class="box">
<view class="add1">
<view style="display: inline-block;" wx:for="{{result}}" wx:key="idx" wx:for-index="index">
<view style="display: inline-block;" wx:for="{{boxArr}}" wx:key="idx" wx:for-index="index">
<view class="add_box1" wx:if="{{item==undefined}}">
<view class="heng1"></view>
<view class="shu1"></view>
@ -14,9 +14,9 @@
<text style="font-size: 24rpx;font-weight: 100;" > 删除</text>
</view>
<view class="brand_img_box">
<image src="http://v.sws010.com/img/brand/276.png" style="width:100%;" mode="widthFix" lazy-load="{{true}}"></image>
<image src="{{item.img}}" style="width:100%;" mode="widthFix" lazy-load="{{true}}"></image>
</view>
<view class="car_barnd">宝马</view>
<view class="car_barnd">{{item.brandname}}</view>
</view>
</view>

@ -124,7 +124,7 @@ page {
}
.car_barnd{
text-align: center;
font-size: 28rpx;
font-size: 20rpx;
font-weight: bold;
color: white;
margin-top: 4rpx;

@ -0,0 +1,17 @@
import brokenLine from "../../../../../components/option/stackingLineOption"
const app = getApp()
Component({
data:{
showChart: true,
transformOption: brokenLine([],[],[],[]),
},
lifetimes:{
attached() {
//页面数据
// app.globalData.request({
// action: 'getUserBrand',
// token: 't%2BrswgjvzGM=',
// })
}
}
})

@ -0,0 +1,6 @@
{
"usingComponents": {
"c-echars": "../../../../../../components/c-echars/index"
},
"component": true
}

@ -0,0 +1,4 @@
<view class="chart_box">
<view class="chart_title">信息量趋势</view>
<c-echars height="100%" showChart="{{showChart}}" canvasId="eventbar-canvas" chartId="eventbar" chartOption="{{transformOption}}"></c-echars>
</view>

@ -0,0 +1,11 @@
.chart_box{
width: 686rpx;
height: 454rpx;
padding-top:32rpx ;
background: white;
}
.chart_title{
font-size: 36rpx;
font-weight: bold;
margin-left:32rpx ;
}

@ -5,62 +5,22 @@ Page({
* 页面的初始数据
*/
data: {
boxArr:new Array(6),
tabActive:1,
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
console.log(options);
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
this.setData({
boxArr:wx.getStorageSync('brandData')
})
},
changeTab(val) {
let n = val.detail.index;
this.setData({
tabActive: n
})
}
})

@ -1,6 +1,7 @@
{
"usingComponents": {
"time-component":"/components/timecomponent/index"
"time-component":"/components/timecomponent/index",
"survey":"./comm/survey/index"
},
"navigationBarTitleText": "品牌对比"
}

@ -3,19 +3,35 @@
<time-component></time-component>
</view>
<view class="add1">
<view class="add_box">
<view class="del">
<text style="font-size: 24rpx;display: inline-block;margin-left: 64rpx;">×</text>
<text style="font-size: 24rpx;font-weight: 100;"> 删除</text>
<view style="display: inline-block;" wx:for="{{boxArr}}" wx:key="idx" wx:for-index="index">
<view class="add_box1" wx:if="{{item==undefined}}">
<view class="heng1"></view>
<view class="shu1"></view>
<view class="event1">添加品牌一</view>
</view>
<view class="brand_img_box">
<image src="http://v.sws010.com/img/brand/276.png" style="width:100%;" mode="widthFix" lazy-load="{{true}}"></image>
<view class="del_box" wx:else>
<view class="del" bindtap="del(index)">
<text style="font-size: 24rpx;display: inline-block;margin-left: 64rpx;">×</text>
<text style="font-size: 24rpx;font-weight: 100;" > 删除</text>
</view>
<view class="brand_img_box">
<image src="{{item.img}}" style="width:100%;" mode="widthFix" lazy-load="{{true}}"></image>
</view>
<view class="car_barnd">{{item.brandname}}</view>
</view>
<view class="car_barnd">宝马</view>
</view>
</view>
<view class="event_recom1">
<!-- 占位盒子 -->
<van-tabs class="view-tabs" active="{{ tabActive }}" bind:change="changeTab" swipe-threshold="3" >
<van-tab title="概括" wx:key="0"></van-tab>
<van-tab title="微博对比" wx:key="1"></van-tab>
<van-tab title="论坛对比" wx:key="2"></van-tab>
<van-tab title="尾翼对比" wx:key="3"></van-tab>
</van-tabs>
<view class="content_box">
<survey></survey>
</view>
</view>
</view>

@ -10,10 +10,11 @@ page {
}
.add1{
width:750rpx;
margin-top: 16rpx;
overflow-x:scroll;
white-space: nowrap;
}
.add_box {
.add_box1 {
display: inline-block;
height: 208rpx;
width: 200rpx;
@ -22,8 +23,36 @@ page {
border-radius: 8rpx;
border: 2rpx solid #85c3ff;
overflow: hidden;
margin-top: 16rpx;
}
.heng1 {
height: 8rpx;
width: 72rpx;
background: white;
border-radius: 6rpx;
position: relative;
left: 66rpx;
top: 82rpx
}
.shu1 {
width: 8rpx;
height: 72rpx;
background: white;
border-radius: 6rpx;
position: relative;
left: 98rpx;
top: 45rpx
}
.event1 {
display: inline-block;
color: white;
font-size: 28rpx;
margin-left: 32rpx;
margin-top: 60rpx;
}
.btns {
margin-top: 32rpx;
width: 686rpx;
@ -33,17 +62,56 @@ page {
color: rgba(0, 132, 255, 1);
font-size: 28rpx;
}
.event_recom {
.event_recom1 {
margin-top: 32rpx;
padding-top:18rpx;
min-height: 1000rpx;
background-color: #f9f9f9;
border-top-left-radius: 24rpx;
border-top-right-radius: 24rpx;
padding-top: 32rpx;
padding-left: 32rpx;
}
.add_box .del{
.van-index-anchor text{
font-size: 24rpx;
color: rgba(153, 153, 153, 1);
}
.event_recom1 .van-cell .van-cell__title{
font-size: 28rpx;
}
.my_cell{
width: 750rpx;
height: 96rpx;
background: white;
display: flex;
align-items: center;
}
.van-checkbox{
display: inline-block !important;
}
.my_cell text{
font-size: 28rpx;
margin-left: 24rpx;
}
.del_box {
display: inline-block;
height: 208rpx;
width: 200rpx;
margin-left: 32rpx;
background-color: #339cff;
border-radius: 8rpx;
border: 2rpx solid #85c3ff;
overflow: hidden;
/* margin-top: 16rpx; */
}
.content_box{
width: 686rpx;
height: 100vh;
background: pink;
margin-left: 32rpx;
}
.del_box .del{
/* background: pink; */
border-bottom: 1rpx solid ;
border-image: linear-gradient(to right,rgba(245, 245, 245, 0),rgba(238, 238, 238, 1),rgba(232, 232, 232, 0))1;
@ -63,8 +131,20 @@ page {
}
.car_barnd{
text-align: center;
font-size: 28rpx;
font-size: 20rpx;
font-weight: bold;
color: white;
margin-top: 4rpx;
}
}
.view-tabs .van-tab {
color: #999999; /* 字体颜色 */
background-color: #F9F9F9;/* 标签背景颜色 */
}
.view-tabs .van-tab--active{
color: #0084FF; /* 字体颜色 */
font-size: 40rpx;
}
.view-tabs .van-tabs__line {
background: transparent;
}
Loading…
Cancel
Save