1.4 修改概念中心日期默认传值
This commit is contained in:
@@ -356,7 +356,6 @@
|
||||
this.selectStartMonth = startYear+'年'+startMonth+'月'
|
||||
this.startDateStr = this.selectStartDateStr = startYear+'-'+(startMonth>9?startMonth:('0'+startMonth))+'-'+(startDay>9?startDay:('0'+startDay))
|
||||
this.generateMonthDateListData()
|
||||
this.getConceptCenterData()
|
||||
this.getNewestPriceDateData()
|
||||
this.getRankListData()
|
||||
this.getMemberStatusData()
|
||||
@@ -551,7 +550,7 @@
|
||||
return
|
||||
}
|
||||
this.startDateStr = this.selectStartDateStr
|
||||
this.endDateStr = this.endDateStr
|
||||
this.endDateStr = this.selectEndDateStr
|
||||
this.getRankListData()
|
||||
},
|
||||
/**
|
||||
@@ -783,7 +782,14 @@
|
||||
*/
|
||||
getConceptCenterData()
|
||||
{
|
||||
let param = {query:this.keywords,size:10,page:this.page,sort_by:this.sortType,isJson:1,trade_date:this.selectDateStr}
|
||||
let dateStr = this.selectDateStr
|
||||
let selectDateTimestamp = new Date(this.selectDateStr).getTime()
|
||||
let newestTimeStamp = new Date(this.newestPriceDate).getTime()
|
||||
if (selectDateTimestamp > newestTimeStamp) {
|
||||
//如果选择的日期在最新交易日之前
|
||||
dateStr = this.newestPriceDate
|
||||
}
|
||||
let param = {query:this.keywords,size:10,page:this.page,sort_by:this.sortType,isJson:1,trade_date:dateStr}
|
||||
eventRelatedConcept(param).then(res=>{
|
||||
this.isRefreshing = false
|
||||
if (res.page == 1) {
|
||||
@@ -804,6 +810,7 @@
|
||||
getNewestPriceDateData(){
|
||||
newestPriceDate().then(res=>{
|
||||
this.newestPriceDate = res.latest_trade_date
|
||||
this.getConceptCenterData()
|
||||
}).catch(error=>{
|
||||
|
||||
})
|
||||
|
||||
@@ -119,9 +119,9 @@
|
||||
this.selectMonthIndex = 20*12+currentMonth-1
|
||||
this.selectMonth = currentYear+'年'+currentMonth+'月'
|
||||
//开始日期默认为当前月份第一天
|
||||
this.startDateStr = currentYear+'-'+currentMonth+'-'+'01'
|
||||
this.startDateStr = currentYear+'-'+(currentMonth>9?currentMonth:('0'+currentMonth))+'-'+'01'
|
||||
//结束日期默认为当前日期
|
||||
this.endDateStr = this.selectDateStr = currentYear+'-'+currentMonth+'-'+(currentDay>9?currentDay:('0'+currentDay))
|
||||
this.endDateStr = this.selectDateStr = currentYear+'-'+(currentMonth>9?currentMonth:('0'+currentMonth))+'-'+(currentDay>9?currentDay:('0'+currentDay))
|
||||
// this.getYesterdayDateData()
|
||||
this.generateMonthDateListData()
|
||||
if (e.id) {
|
||||
|
||||
@@ -124,15 +124,15 @@
|
||||
</view>
|
||||
<view class="commentLikeNumC flex">
|
||||
<view class="item">
|
||||
<image class="icon" src="/static/icon/home/browser.png" mode="widthFix"></image>
|
||||
<image class="icon" src="/static/icon/home/eventDetails/like.png" mode="widthFix"></image>
|
||||
<view>{{eventDetails.view_count}}</view>
|
||||
</view>
|
||||
<view class="item" @click="clickComment()">
|
||||
<image class="icon" src="/static/icon/home/comment.png" mode="widthFix"></image>
|
||||
<image class="icon" src="/static/icon/home/eventDetails/comment.png" mode="widthFix"></image>
|
||||
<view>{{eventDetails.post_count}}</view>
|
||||
</view>
|
||||
<view class="item" @click="clickFollow()">
|
||||
<image class="icon" src="/static/icon/home/follow.png" mode="widthFix"></image>
|
||||
<image class="icon" src="/static/icon/home/eventDetails/collect.png" mode="widthFix"></image>
|
||||
<view>{{eventDetails.follower_count}}</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
<view v-if="index<screenCategoryList.length-1" class="flex1"></view>
|
||||
</block>
|
||||
</view>
|
||||
<view class="timeCategoryC">
|
||||
<view :class="'item '+(selectTimeCategory==index?'select':'')" v-for="(item,index) in timeCategoryList" :key="index" @click="clickTimeCategoryItem(index)">{{item.name}}</view>
|
||||
<view class="timeCategoryC flex">
|
||||
<view :class="'item flex1 '+(selectTimeCategory==index?'select':'')" v-for="(item,index) in timeCategoryList" :key="index" @click="clickTimeCategoryItem(index)">{{item.name}}</view>
|
||||
</view>
|
||||
<!-- <scroll-view scroll-x :scroll-left="topScrollLeft" class="topCategoryC" id="topCategory">
|
||||
<view :class="'item relative '+(selectTopCategory==index?'select':'')" v-for="(item,index) in stockCategoryList" :key="index" @click="clickTopCategoryItem($event,index)">
|
||||
@@ -73,12 +73,16 @@
|
||||
<image class="icon" src="/static/icon/home/browser.png" mode="widthFix"></image>
|
||||
<text>{{item.view_count}}</text>
|
||||
</view>
|
||||
<view class="toolItem flex" @click.stop="clickFollowEvent(item.id)">
|
||||
<image class="icon" src="/static/icon/home/like.png" mode="widthFix"></image>
|
||||
<text>{{item.follower_count}}</text>
|
||||
</view>
|
||||
<view class="toolItem flex">
|
||||
<image class="icon" src="/static/icon/home/comment.png" mode="widthFix"></image>
|
||||
<text>{{item.post_count}}</text>
|
||||
</view>
|
||||
<view class="toolItem flex" @click.stop="clickFollowEvent(item.id)">
|
||||
<image class="icon" src="/static/icon/home/follow.png" mode="widthFix"></image>
|
||||
<image class="icon" src="/static/icon/home/collect.png" mode="widthFix"></image>
|
||||
<text>{{item.follower_count}}</text>
|
||||
</view>
|
||||
</view>
|
||||
@@ -88,7 +92,7 @@
|
||||
</scroll-view>
|
||||
<uni-popup ref="screenPopup" type="top">
|
||||
<view class="screenPopup" :style="'padding-top:'+menuTop+'px;'">
|
||||
<view class="navC flex" :style="'height:'+menuH+'px;'">
|
||||
<view class="navC flex" :style="'height:'+menuH+'px;'" @click="clickCancel()">
|
||||
<image class="icon" src="/static/icon/backBlack.png" mode="widthFix"></image>
|
||||
<view class="title">筛选</view>
|
||||
</view>
|
||||
@@ -209,7 +213,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="selectScreenCategory!=3" class="btnC flex">
|
||||
<view class="cancel btn flex1" @click="clickCancel()">取消</view>
|
||||
<view class="cancel btn flex1" @click="clickReset()">重置</view>
|
||||
<view class="certain btn flex1" @click="clickCertain()">确定</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -243,10 +247,6 @@
|
||||
{
|
||||
icon:'/static/icon/home/eventLevel.png',
|
||||
title:'事件等级',
|
||||
},
|
||||
{
|
||||
icon:'/static/icon/home/sort.png',
|
||||
title:'最新排序',
|
||||
}],
|
||||
keywords:'', //关键词
|
||||
timeCategoryList:[],
|
||||
@@ -487,7 +487,7 @@
|
||||
clickSortListItem(item)
|
||||
{
|
||||
this.selectSortKey = item.key
|
||||
this.$refs['screenPopup'].close()
|
||||
this.clickCancel()
|
||||
this.clickSearch()
|
||||
},
|
||||
/**
|
||||
@@ -501,9 +501,37 @@
|
||||
/**
|
||||
* 点击筛选弹窗取消
|
||||
*/
|
||||
clickCancel()
|
||||
clickCancel()
|
||||
{
|
||||
this.$refs["screenPopup"].close()
|
||||
this.$refs['screenPopup'].close()
|
||||
},
|
||||
/**
|
||||
* 点击筛选弹窗重置
|
||||
*/
|
||||
clickReset()
|
||||
{
|
||||
if (this.selectScreenCategory == 0) {
|
||||
//时间筛选
|
||||
this.selectQuickTimeIndex = -1;
|
||||
this.startDateStr = this.endDateStr = ''
|
||||
}else if (this.selectScreenCategory == 1) {
|
||||
//行业筛选
|
||||
this.industryKeywords = ''
|
||||
this.searchResultList = []
|
||||
this.selectIndustryTopCategory = 0
|
||||
this.selectIndustrySecondCategory = 0
|
||||
this.selectIndustryThirdCategory = 0
|
||||
this.searchIndustryTopCategory = 0
|
||||
this.searchIndustrySecondCategory = 0
|
||||
this.searchIndustryThirdCategory = 0
|
||||
}else if (this.selectScreenCategory == 2) {
|
||||
//事件等级
|
||||
for (let item of this.importanceList) {
|
||||
item.select = false
|
||||
}
|
||||
}
|
||||
this.clickCancel()
|
||||
this.clickSearch()
|
||||
},
|
||||
/**
|
||||
* 点击筛选弹窗确定
|
||||
@@ -865,24 +893,7 @@
|
||||
if(res.code==200)
|
||||
{
|
||||
resolve(1)
|
||||
let timeList = [...res.data.sort_options]
|
||||
this.timeCategoryList = timeList.splice(0,2)
|
||||
let sortList = [...res.data.sort_options]
|
||||
for (let item of sortList) {
|
||||
if(item.name=='最新')
|
||||
{
|
||||
item.icon = '/static/icon/home/new.png'
|
||||
}
|
||||
if(item.name=='热门')
|
||||
{
|
||||
item.icon = '/static/icon/home/hot.png'
|
||||
}
|
||||
if(item.name=='收益率')
|
||||
{
|
||||
item.icon = '/static/icon/home/yield.png'
|
||||
}
|
||||
}
|
||||
this.sortTypeList = res.data.sort_options.slice(0,3)
|
||||
this.timeCategoryList = res.data.sort_options
|
||||
this.importanceList = res.data.importance_options
|
||||
this.importanceList.unshift({desc: "全部",key: "all",name: "全部"})
|
||||
}else
|
||||
@@ -1262,11 +1273,10 @@ page
|
||||
margin-top: 10rpx;
|
||||
.item
|
||||
{
|
||||
display: inline-block;
|
||||
padding: 0 26rpx;
|
||||
line-height: 60rpx;
|
||||
font-size: 32rpx;
|
||||
color: #CCCDD1;
|
||||
text-align: center;
|
||||
}
|
||||
.item.select
|
||||
{
|
||||
|
||||
@@ -144,6 +144,11 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view v-if="isData&&(selectTab==0&&eventList.length==0||selectTab==1&&dataList.length==0)" class="noDataC flexColumnCenter">
|
||||
<image class="icon" src="/static/image/index/noData.png" mode="widthFix"></image>
|
||||
<view class="title">当前筛选条件下暂无数据</view>
|
||||
<view class="subtitle">请尝试调整筛选条件</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<uni-popup ref="popup" type="top">
|
||||
<view class="popup" :style="'margin-top:'+navH+'px;'">
|
||||
@@ -216,7 +221,8 @@
|
||||
loadAll:false,
|
||||
getLocaleHourMinute:getLocaleHourMinute,
|
||||
replaceAnswerLabel:replaceAnswerLabel,
|
||||
accMul:accMul
|
||||
accMul:accMul,
|
||||
isData:false //是否请求过数据了
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
@@ -503,6 +509,7 @@
|
||||
param.category = this.stockCategoryList[this.selectTopCategory].primary_sector
|
||||
}
|
||||
calendarEventList(param).then(res=>{
|
||||
this.isData = true
|
||||
this.isRefreshing = false
|
||||
if(res.code==200)
|
||||
{
|
||||
@@ -522,6 +529,7 @@
|
||||
})
|
||||
}).catch(error=>{
|
||||
this.isRefreshing = false
|
||||
this.isData = true
|
||||
})
|
||||
},
|
||||
/**
|
||||
@@ -1081,6 +1089,26 @@ page
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.noDataC {
|
||||
margin-top: 200rpx;
|
||||
font-weight: 500;
|
||||
.icon {
|
||||
width: 412rpx;
|
||||
height: auto;
|
||||
}
|
||||
.title {
|
||||
margin-top: 8rpx;
|
||||
font-size: 32rpx;
|
||||
color: #939393;
|
||||
}
|
||||
.subtitle {
|
||||
margin-top: 16rpx;
|
||||
font-size: 26rpx;
|
||||
color: #646464;
|
||||
}
|
||||
}
|
||||
|
||||
.popup
|
||||
{
|
||||
background-color: white;
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
<view class="item" v-for="(item,index) in investDetails.related_stocks" :key="index" @click="clickLookRelatedStockItem(item)">
|
||||
<view class="titleCorrelationC flex">
|
||||
<view class="title flex1">{{item.code+' '+item.name}} </view>
|
||||
<view class="correlation">相关度: {{accMul(item.score,100)}}%</view>
|
||||
<view class="correlation">相关度: {{item.score}}%</view>
|
||||
</view>
|
||||
<view v-if="item.sw_primary_sector" class="category">{{item.sw_primary_sector}}</view>
|
||||
<view class="content">{{item.description}}</view>
|
||||
|
||||
@@ -30,7 +30,10 @@
|
||||
<textarea v-model="profile" placeholder="简单介绍一下自己吧" placeholder-style="color:#AAA"></textarea>
|
||||
</view>
|
||||
</view>
|
||||
<view class="next fixed" @click="clickNext()">下一步</view>
|
||||
<view class="bottomC fixed flex">
|
||||
<view class="finish btn" @click="clickFinishOrNext(0)">完成</view>
|
||||
<view class="next btn flex1" @click="clickFinishOrNext(1)">下一步</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@@ -104,9 +107,9 @@
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 点击下一步
|
||||
* 点击完成或下一步
|
||||
*/
|
||||
clickNext()
|
||||
clickFinishOrNext(type)
|
||||
{
|
||||
if(!this.avatar&&!this.avatarUrl)
|
||||
{
|
||||
@@ -146,9 +149,12 @@
|
||||
let param = {avatar:this.avatar,nickname:this.nickname,gender:this.sex=='男'?'male':'female',phone:this.mobile,
|
||||
bio:this.profile,isFile:1}
|
||||
updateBasicInfo(param).then(res=>{
|
||||
uni.navigateTo({
|
||||
url:'/pages/mine/investPreference/investPreference'
|
||||
})
|
||||
if (type==1) {
|
||||
uni.navigateTo({
|
||||
url:'/pages/mine/investPreference/investPreference'
|
||||
})
|
||||
}else
|
||||
uni.navigateBack()
|
||||
}).catch(error=>{
|
||||
|
||||
})
|
||||
@@ -158,9 +164,12 @@
|
||||
let param = {nickname:this.nickname,gender:this.sex=='男'?'male':'female',phone:this.mobile,
|
||||
bio:this.profile}
|
||||
updateBasicInfo(param).then(res=>{
|
||||
uni.navigateTo({
|
||||
url:'/pages/mine/investPreference/investPreference'
|
||||
})
|
||||
if (type==1) {
|
||||
uni.navigateTo({
|
||||
url:'/pages/mine/investPreference/investPreference'
|
||||
})
|
||||
}else
|
||||
uni.navigateBack()
|
||||
}).catch(error=>{
|
||||
|
||||
})
|
||||
@@ -305,18 +314,33 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.next
|
||||
|
||||
.bottomC
|
||||
{
|
||||
background-color: #F97316;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 73rpx;
|
||||
margin: 0 25rpx;
|
||||
line-height: 80rpx;
|
||||
border-radius: 20rpx;
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
color: white;
|
||||
text-align: center;
|
||||
|
||||
.btn
|
||||
{
|
||||
line-height: 80rpx;
|
||||
border-radius: 20rpx;
|
||||
font-size: 26rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.finish
|
||||
{
|
||||
background-color: #FFE9D9;
|
||||
width: 226rpx;
|
||||
color: #F97316;
|
||||
}
|
||||
.next
|
||||
{
|
||||
background-color: #F97316;
|
||||
margin-left: 20rpx;
|
||||
color: white;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
<text>{{item.comment_count}}</text>
|
||||
</view>
|
||||
<view class="toolItem flex" @click.stop="clickFollowEvent(item.event_id,index)">
|
||||
<image class="icon" src="/static/icon/home/follow_s.png" mode="widthFix"></image>
|
||||
<image class="icon" src="/static/icon/home/collect_s.png" mode="widthFix"></image>
|
||||
<text>{{item.follower_count}}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
Reference in New Issue
Block a user