Commit 32a0fa93 authored by mengqr's avatar mengqr

页面暂时修改

parent 8eba3388
...@@ -44,6 +44,26 @@ const testApi = { ...@@ -44,6 +44,26 @@ const testApi = {
queryFollowAccountReviews(data){ queryFollowAccountReviews(data){
return http.post('/invest/admin/pc/followaccount/queryFollowAccountReviews', data) return http.post('/invest/admin/pc/followaccount/queryFollowAccountReviews', data)
}, },
//调仓记录
followAccountZfzt(data){
return http.post('/invest/admin/pc/followaccount/queryFollowAccountDeals', data)
},
//跟投详情
followaccountDetail(data){
return http.post('/invest/admin/pc/followaccount/getFollowAccount', data)
},
//持仓配置
queryFollowAccountPositions(data){
return http.post('/invest/admin/pc/followaccount/queryFollowAccountPositions', data)
},
//行业占比信息
getFollowAccountIndustryPercent(data){
return http.post('/invest/admin/pc/followaccount/getFollowAccountIndustryPercent', data)
},
//曲线图
getFollowAccountYieldsRecords(data){
return http.post('/invest/admin/pc/followaccount/getFollowAccountYieldsRecords', data)
},
}; };
export default testApi export default testApi
...@@ -56,7 +56,7 @@ const router_modular = [ ...@@ -56,7 +56,7 @@ const router_modular = [
component: () => import('@/views/actualCombat/abnormalReview') component: () => import('@/views/actualCombat/abnormalReview')
}, },
{ {
path: '/record', path: '/actualCombatRecord',
name: 'record', name: 'record',
component: () => import('@/views/actualCombat/record') component: () => import('@/views/actualCombat/record')
}, },
......
<template> <template>
<div class="content"> <div class="content">
<div class="ster">
<img
src="../../assets/left.png"
alt=""
style="width: 0.5rem;
height: 0.8rem;
margin-top: 0.1rem;
margin-left: 0.2rem;"
@click="tab_oimg"
/>
<div class="deta">异动点评</div>
</div>
<div class="listBox" v-for="i in list" :key="i.id"> <div class="listBox" v-for="i in list" :key="i.id">
<div class="left-box"> <div class="left-box">
<div class="left-time"> <div class="left-time">
...@@ -46,7 +58,7 @@ export default { ...@@ -46,7 +58,7 @@ export default {
// ...mapMutations("store_modular", ["operation"]), // ...mapMutations("store_modular", ["operation"]),
getList() { getList() {
let temp={ let temp={
followAccountId:5, followAccountId:this.$route.query.id,
page:1, page:1,
pageSize:100 pageSize:100
} }
...@@ -107,6 +119,15 @@ let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSecond ...@@ -107,6 +119,15 @@ let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSecond
let GMT = Hour + ':' + Minute let GMT = Hour + ':' + Minute
return GMT return GMT
}, },
tab_oimg: function () {
this.$router.push({
path: '/detail',
query: {
id:this.$route.query.id
}
});
// this.$router.push("../detail");
},
}, },
}; };
...@@ -166,4 +187,19 @@ return GMT ...@@ -166,4 +187,19 @@ return GMT
color: blue; color: blue;
font-size: 0.3rem; font-size: 0.3rem;
} }
.ster {
display: flex;
background-color: rgb(226, 74, 68);
height: 1rem;
line-height: 1rem;
}
.deta {
width: 70%;
text-align: center;
margin-left: 34px;
font-size: 0.5rem;
color: white;
/* background: #e03939; */
font-weight: bolder;
}
</style> </style>
\ No newline at end of file
<template> <template>
<div class="content"> <div class="content">
<div class="ster">
<img
src="../../assets/left.png"
alt=""
style="width: 0.5rem;
height: 0.8rem;
margin-top: 0.1rem;
margin-left: 0.2rem;"
@click="tab_oimg"
/>
<div class="deta">{{formData.productName}}</div>
</div>
<div class="top-box"> <div class="top-box">
<div class="typeList"> <div class="typeList">
<div class="type-box"> <div class="type-box">
<span>激进型</span> <span>{{formData.tradeStyleName}}</span>
</div> </div>
<div class="type-box"> <div class="type-box">
<span>中风险</span> <span>{{formData.riskManagementName}}</span>
</div> </div>
<span class="numberPeople">117人已订阅</span> <span class="numberPeople">{{formData.memberNumber}}人已订阅</span>
</div> </div>
<span class="profit">总收益</span> <span class="profit">总收益</span>
<span class="percentage">40.27%</span> <span class="percentage">{{formData.yields*100}}%</span>
<!-- 线 --> <!-- 线 -->
<div class="line"></div> <div class="line"></div>
...@@ -41,29 +54,29 @@ ...@@ -41,29 +54,29 @@
<span>-10.83%</span> <span>-10.83%</span>
</div> --> </div> -->
<div class="tab-box-Two"> <div class="tab-box-Two">
<span>-10.83%</span> <span>{{formData.monthlyBackYields*100}}%</span>
</div> </div>
<div class="tab-box-Two"> <div class="tab-box-Two">
<span>-10.83%</span> <span>{{formData.position}}%</span>
</div> </div>
<div class="tab-box-Two"> <div class="tab-box-Two">
<span>-10.83%</span> <span>{{backYields*100}}%</span>
</div> </div>
<div class="tab-box-Two"> <div class="tab-box-Two">
<span>-10.83%</span> <span>{{formData.successPercent*100}}%</span>
</div> </div>
</div> </div>
</div> </div>
<div class="title-box"> <div class="title-box">
<span class="title-text">08-14 11:12 | 当⼊选002583⼤涨5.10%</span> <!-- <span class="title-text">08-14 11:12 | 当⼊选002583⼤涨5.10%</span> -->
</div> </div>
<!-- 分析师姓名 --> <!-- 分析师姓名 -->
<div class="infoBox"> <div class="infoBox">
<span class="infoName">姓名</span> <span class="infoName">{{formData.analystName}}</span>
<span class="infoList">简介减价二发生的该方法根据官方回复人很多家庭一款基于</span> <span class="infoList">{{formData.comments}}</span>
<div class="infoType"> <div class="infoType">
<span >#金牌投顾</span> <span >#{{formData.accountTypeName}}</span>
</div> </div>
</div> </div>
...@@ -76,13 +89,14 @@ ...@@ -76,13 +89,14 @@
color:gray; color:gray;
margin-top: 0.4rem; margin-top: 0.4rem;
margin-left: 3rem; margin-left: 3rem;
line-height: 1rem;"> line-height: 1rem;" @click="jumpAbnomal()">
<span>查看更多</span><van-icon name="arrow" /> <span>查看更多</span><van-icon name="arrow" />
</div> </div>
</div> </div>
<!-- 点评信息 --> <!-- 点评信息 -->
<div class="reviewInfo"> <div class="reviewInfo">
<span>{{abnoMalcomments}}</span>
</div> </div>
<div style="width:100%;height:1rem;display:flex"> <div style="width:100%;height:1rem;display:flex">
<div class="analystTwo"> <div class="analystTwo">
...@@ -93,7 +107,7 @@ ...@@ -93,7 +107,7 @@
width: 109%; width: 109%;
margin-top: 0.6rem; margin-top: 0.6rem;
line-height: 1rem;"> line-height: 1rem;">
<van-radio-group v-model="radio" direction="horizontal"> <van-radio-group v-model="radio" direction="horizontal" @change="clickMonth">
<van-radio name="1" icon-size="12px" checked-color="#ee0a24">近一月</van-radio> <van-radio name="1" icon-size="12px" checked-color="#ee0a24">近一月</van-radio>
<van-radio name="2" icon-size="12px" checked-color="#ee0a24">近三月</van-radio> <van-radio name="2" icon-size="12px" checked-color="#ee0a24">近三月</van-radio>
<van-radio name="3" icon-size="12px" checked-color="#ee0a24">近一年</van-radio> <van-radio name="3" icon-size="12px" checked-color="#ee0a24">近一年</van-radio>
...@@ -109,30 +123,30 @@ ...@@ -109,30 +123,30 @@
<div class="profitBox"> <div class="profitBox">
<div class="profitLeft"> <div class="profitLeft">
<span class="profitTitle">收益率:</span> <span class="profitTitle">收益率:</span>
<span class="profitNumber">40.27%</span> <span class="profitNumber">{{formData.yields*100}}%</span>
</div> </div>
<div class="profitright"> <div class="profitright">
<span class="profitTitle">总收益:</span> <span class="profitTitle">总收益:</span>
<span class="profitNumberTwo">402697.6</span> <span class="profitNumberTwo">{{formData.totalRevenue}}</span>
</div> </div>
</div> </div>
<div class="profitBoxTwo" style="margin-top:-0.3rem"> <div class="profitBoxTwo" style="margin-top:-0.3rem">
<div class="profitLeft"> <div class="profitLeft">
<span class="profitTitle">初始资金:</span> <span class="profitTitle">初始资金:</span>
<span class="profitNumber">10000000.00</span> <span class="profitNumber">{{formData.initMoney}}</span>
</div> </div>
<div class="profitright"> <div class="profitright">
<span class="profitTitle">仓位:</span> <span class="profitTitle">仓位:</span>
<span class="profitNumberTwo">26.35%</span> <span class="profitNumberTwo">{{formDataThree.positionPercent*100}}%</span>
</div> </div>
</div> </div>
<div class="profitBoxTwo" style="margin-top:0.3rem"> <div class="profitBoxTwo" style="margin-top:0.3rem">
<div class="profitLeft"> <div class="profitLeft">
<span class="profitTitle">可用资金:1033097.60</span> <span class="profitTitle">可用资金:{{formData.currentMoney}}</span>
<!-- <span class="profitNumber">10000000.00</span> --> <!-- <span class="profitNumber">10000000.00</span> -->
</div> </div>
<div class="profitright"> <div class="profitright">
<span class="profitTitle">股票市值:369600.00</span> <span class="profitTitle">股票市值:{{formDataThree.currentAmount}}</span>
<!-- <span class="profitNumberTwo">26.35%</span> --> <!-- <span class="profitNumberTwo">26.35%</span> -->
</div> </div>
</div> </div>
...@@ -158,14 +172,22 @@ ...@@ -158,14 +172,22 @@
</div> </div>
<!-- 已售罄 --> <!-- 已售罄 -->
<div class="soldOut"> <div class="soldOut">
<div class="soltBox"> <div class="soltBox" v-if="isBuy==2">
<span>已售罄</span> <!-- <span>已售罄</span> -->
<img style="height: 1rem;
margin-top: 0.2rem;" src="../../assets/sure.png" alt="">
</div>
<div v-if="isBuy==1" class="soldText">
<span>{{formDataThree.count}}</span>
</div>
<div v-if="isBuy==1" class="soldText">
<span>{{formDataThree.costPrice}}</span>
</div> </div>
<div class="soldText"> <div class="soldText">
<span>-1.12%</span> <span>{{formDataThree.yieldsAmount}}</span>
</div> </div>
<div class="soldText"> <div class="soldText">
<span>26.35%</span> <span>{{formDataThree.positionPercent*100}}%</span>
</div> </div>
</div> </div>
<div class="analystTwo"> <div class="analystTwo">
...@@ -184,7 +206,7 @@ ...@@ -184,7 +206,7 @@
height: 1rem; height: 1rem;
margin-top: 0.4rem; margin-top: 0.4rem;
margin-left: 3rem; margin-left: 3rem;
line-height: 1rem;"> line-height: 1rem;" @click="jumpRecord()">
<span>交易记录</span><van-icon name="arrow" /> <span>交易记录</span><van-icon name="arrow" />
</div> </div>
</div> </div>
...@@ -212,24 +234,29 @@ ...@@ -212,24 +234,29 @@
</div> </div>
</div> </div>
<div class="contect-list"> <div class="contect-list">
<div class="mai"> <div v-if="formDataTwo.direction==1" class="maiTwo">
<span ></span>
</div>
<div v-if="formDataTwo.direction==2" class="mai">
<span ></span> <span ></span>
</div> </div>
<div class="contectSold" @click="showPopup"> <div class="contectSold" v-if="isBuy==2" @click="showPopup">
<span>已售罄</span> <!-- <span>已售罄</span> -->
<img style="height: 1rem;
margin-top: 0.2rem;" src="../../assets/sure.png" alt="">
</div> </div>
<!-- <div class="contectBox"> <div class="contectBox" v-if="isBuy==1">
<span>300***</span> <span>{{formDataTwo.count}}</span>
</div>
<div class="contectBox" v-if="isBuy==1">
<span>{{formDataTwo.price}}</span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span>*</span> <span>{{formDataTwo.remark*100}}%</span>
</div> -->
<div class="contectBox">
<span>100%</span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span style="display:block;height:0.5rem;margin-top:-0.3rem">08/26</span> <span style="display:block;height:0.5rem;margin-top:-0.3rem">{{state_type(formDataTwo.created_TIME)}}</span>
<span>14:28</span> <span>{{state_typeTwo(formDataTwo.created_TIME)}}</span>
</div> </div>
</div> </div>
...@@ -304,9 +331,16 @@ export default { ...@@ -304,9 +331,16 @@ export default {
radio:'1', radio:'1',
radio2:'1', radio2:'1',
show:false, show:false,
isBuy:2,
morePoint:12345, morePoint:12345,
list: [], list: [],
formData:{},
formDataTwo:{},
formDataThree:{},
ifexchange:true, ifexchange:true,
backYields:0,
startDate:this.getLastMonth(1),
endDate:this.getLastMonth(),
checkList:[ checkList:[
{ {
id:'1', id:'1',
...@@ -329,13 +363,193 @@ export default { ...@@ -329,13 +363,193 @@ export default {
point:'1222', point:'1222',
} }
], ],
abnoMalcomments:'',
echartsOption: { // echarts选项,所有绘图数据和样式都在这里设置 echartsOption: { // echarts选项,所有绘图数据和样式都在这里设置
},
chart: null,
_thisForChart: null,
_thisForWindow: null,
colorItem: {
// "北京": '#ff6161',
// "上海": '#e0815b',
// "广州": '#ffaf33',
// "深圳": '#637be6',
// "成都": '#a1b2ff'
// "西安": '#b3daff',
},
echartData:[
// {
// name:'北京',
// value: '2',
// },
// {
// name:'上海',
// value: '3',
// },
// {
// name:'广州',
// value: '6',
// },
// {
// name:'深圳',
// value: '7',
// },
// {
// name:'成都',
// value: '5',
// },
// {
// name:'西安',
// value: '9',
// },
]
};
},
mounted(){
this.getFollowAccountIndustryPercent()
this.getList()
this.getFollowAccountYieldsRecords()
},
beforeDestroy () {
this.removeEventListenerToSidebarContainer()
this.removeEventListenerToWindowResize()
// this.getFollowAccountYieldsRecords()
},
methods: {
// ...mapMutations("store_modular", ["operation"]),
getList() {
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100
}
this.server.followaccountDetail(temp).then((res) =>{
this.formData=res.data.data
this.formData.position=parseFloat(res.data.data.position)*100
this.clickTab()
this.getAbnomalList()
this.getAcountList()
this.queryFollowAccountPositions()
// this.list.forEach((i,index)=>{
// if(i.comments.length<=48){
// i.ifMore=false
// }else{
// i.ifMore=true
// }
// })
})
// this.$toast.loading({
// message: '加载中...',
// forbidClick: true,
// duration:0
// });
},
//行业占比信息
getFollowAccountIndustryPercent(){
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100
}
this.server.getFollowAccountIndustryPercent(temp).then((res)=>{
this.echartData=res.data.data
// let list=res.data.data
this.echartData.forEach((i,intem)=>{
i.name=i.typeName
i.value=i.stockNumber
})
console.log("我的数据",this.echartData)
this.$nextTick(() => {
this.initPieChart();
this.addEventListenerToSidebarContainer(this)
this.addEventListenerToWindowResize(this)
});
// console.log("好好哄",res.data.data.list)
// this.profitList=res.data.data.list
// res.data.data.list.forEach((i,item)=>{
// if(i.id==this.$route.query.id){
// this.backYields=i.backYields
// this.isBuy=i.isBuy
// }
// })
// if()
// if(this.index)
})
},
//点击选择月份
clickMonth(val){
console.log("选择月份",val)
if(val==1){
this.startDate= this.getLastMonth(1)
}else if(val==2){
this.startDate= this.getLastMonth(3)
}else if(val==3){
this.startDate= this.getLastMonth(12)
}else if(val==4){
// startDate= this.getLastMonth(60)
this.startDate='1970-01-01'
// this.startDate=''
}
this.endDate=this.getLastMonth()
this.getFollowAccountYieldsRecords()
// console.log("最近一个月",startDate)
},
getLastMonth(val) {
console.log("选择士大夫月份",val)
const now = new Date(); // 当前日期
if(val==1){
now.setMonth(now.getMonth() - 1); // 设置为一个月前的日期
}else if(val==3){
now.setMonth(now.getMonth() - 3); // 设置为一个月前的日期
}else if(val==12){
now.setMonth(now.getMonth() - 12); // 设置为一个月前的日期
}else if(val==60){
now.setMonth(now.getMonth() - 60); // 设置为一个月前的日期
}
return now.toISOString().split('T')[0]; // 将日期转换为年月日格式
},
//曲线图列表
getFollowAccountYieldsRecords(){
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100,
startDate:this.startDate,
endDate:this.endDate
}
var monthList=[]
var yiledList=[]
this.server.getFollowAccountYieldsRecords(temp).then((res)=>{
// console.log("真么呀这是哈总二",this.echartsOption)
res.data.data.forEach((i,index)=>{
i.created_TIME= this.state_typeThree(i.created_TIME)
i.yields=i.yields*100
monthList.push(i.created_TIME)
yiledList.push(i.yields)
})
console.log("我来看看月份集合",monthList)
console.log("我来看看收益集合",yiledList)
// this.echartsOption.xAxis.data=monthList
// this.echartsOption.series[0].data=['1%','7%']
let echartsOption={
legend: { //图表上方的图例 legend: { //图表上方的图例
data: ['腾讯', '阿里巴巴', '华为', '字节跳动'] data: ['累计收益']
}, },
xAxis: { xAxis: {
type: 'category', type: 'category',
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'], // x轴数据 data: monthList, // x轴数据
// name: '日期', // x轴名称 // name: '日期', // x轴名称
nameTextStyle: { // x轴名称样式 nameTextStyle: { // x轴名称样式
fontWeight: 600, fontWeight: 600,
...@@ -345,6 +559,9 @@ export default { ...@@ -345,6 +559,9 @@ export default {
yAxis: { yAxis: {
type: 'value', type: 'value',
position:'right', position:'right',
axisLabel : {
formatter: '{value}%'
},
// name: '市值', // y轴名称 // name: '市值', // y轴名称
nameTextStyle: { // y轴名称样式 nameTextStyle: { // y轴名称样式
fontWeight: 600, fontWeight: 600,
...@@ -356,72 +573,173 @@ export default { ...@@ -356,72 +573,173 @@ export default {
}, },
series: [ //每条折线的数据系列 series: [ //每条折线的数据系列
{ {
name: '腾讯', name: '累计收益',
data: [820, 932, 901, 934, 1290, 1330, 1320], data: yiledList,
type: 'line' axisLabel : {
formatter: '{value}%'
}, },
{ // formatter: '{value}%',
name: '阿里巴巴',
data: [620, 711, 823, 934, 1445, 1456, 1178],
type: 'line' type: 'line'
}
]
}
let myChartTwo = echarts.dispose(document.getElementById('myChart'))
let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初始化echarts, theme为light
myChart.setOption(echartsOption) // echarts设置选项
// console.log("好好哄",res.data.data.list)
// // this.profitList=res.data.data.list
// res.data.data.list.forEach((i,item)=>{
// if(i.id==this.$route.query.id){
// this.backYields=i.backYields
// this.isBuy=i.isBuy
// }
// })
// if()
// if(this.index)
})
}, },
{
name: '华为', //跳转到异动点评
data: [612, 920, 1140, 1160, 1190, 1234, 1321], jumpAbnomal(){
type: 'line' this.$router.push({
path: '/abnormalReview',
query: {
id:this.$route.query.id
}
});
}, },
{ //跳转到调仓记录
name: '字节跳动', jumpRecord(){
data: [234, 320, 453, 567, 789, 999, 1200], this.$router.push({
type: 'line' path: '/actualCombatRecord',
query: {
id:this.$route.query.id
} }
], });
}, },
chart: null, state_type(row) {
_thisForChart: null, console.log("睡觉哦",row)
_thisForWindow: null, // if(cellValue==null){
colorItem: { // return cellValue
"北京": '#ff6161', // }
"上海": '#e0815b', let date = new Date(parseInt(row));
"广州": '#ffaf33', let Year = date.getFullYear();
"深圳": '#637be6', let Moth = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1);
"成都": '#a1b2ff' let Day = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate());
// "西安": '#b3daff', let Hour = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours());
let Minute = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
let GMT = Moth + '/' + Day
return GMT
}, },
}; state_typeTwo(row) {
console.log("睡觉哦",row)
// if(cellValue==null){
// return cellValue
// }
let date = new Date(parseInt(row));
let Year = date.getFullYear();
let Moth = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1);
let Day = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate());
let Hour = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours());
let Minute = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
let GMT = Hour + ':' + Minute
return GMT
}, },
mounted(){ state_typeThree(row) {
let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初始化echarts, theme为light // console.log("睡觉哦",row)
myChart.setOption(this.echartsOption) // echarts设置选项 // if(cellValue==null){
this.$nextTick(() => { // return cellValue
this.initPieChart(); // }
this.addEventListenerToSidebarContainer(this) let date = new Date(parseInt(row));
this.addEventListenerToWindowResize(this) let Year = date.getFullYear();
}); let Moth = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1);
let Day = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate());
let Hour = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours());
let Minute = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
let GMT = Year+'-'+ Moth + '-' + Day
return GMT
}, },
beforeDestroy () { //获取首页列表数据,补充详情不足数据
this.removeEventListenerToSidebarContainer() clickTab(){
this.removeEventListenerToWindowResize()
// this.tabIndex=index
// this.tableName=name
let temp={
page:1,
pageSize:10,
orderByColumn:'yields',
orderByDirection:'desc'
}
this.server.followaccount(temp).then((res)=>{
// console.log("好好哄",res.data.data.list)
// this.profitList=res.data.data.list
res.data.data.list.forEach((i,item)=>{
if(i.id==this.$route.query.id){
this.backYields=i.backYields
this.isBuy=i.isBuy
}
})
// if()
// if(this.index)
})
}, },
methods: { //异动点评列表
...mapMutations("store_modular", ["operation"]), getAbnomalList(){
getList() { let temp={
this.server followAccountId:this.$route.query.id,
.getListAPI({ num: this.num }) page:1,
.then((res) => (this.list = res.data.data)) pageSize:100
.catch((err) => console.log(err))
.finally(()=>{this.$toast.clear()});
if(this.num==0){
this.$toast.fail("数量不能为0");
return
} }
// this.$toast.loading({ this.server.queryFollowAccountReviews(temp).then((res) =>{
// message: '加载中...', this.abnoMalcomments=res.data.data.list[0].comments
// forbidClick: true, // this.list=res.data.data.list
// duration:0 // this.list.forEach((i,index)=>{
// }); // if(i.comments.length<=48){
// i.ifMore=false
// }else{
// i.ifMore=true
// }
// })
})
},
//调仓记录列表
getAcountList(){
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100
}
this.server.followAccountZfzt(temp).then((res) =>{
this.formDataTwo=res.data.data.list[0]
// var num = "3.1415926";
// var parsedNum = parseFloat(num);
// var roundedNum = parsedNum.toFixed(2);
var a=parseFloat(res.data.data.list[0].remark)
this.formDataTwo.remark= Math.round(a * 100) / 100
// parseFloat(res.data.data.position)*100
// this.list=res.data.data.list
// this.list.forEach((i,index)=>{
// i.remark=parseFloat(i.remark)*100
// })
})
},
//持仓配置列表
queryFollowAccountPositions(){
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100
}
this.server.queryFollowAccountPositions(temp).then((res) =>{
this.formDataThree=res.data.data[0]
// })
})
}, },
//选择积分 //选择积分
clickBox(val){ clickBox(val){
...@@ -436,37 +754,16 @@ let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初 ...@@ -436,37 +754,16 @@ let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初
} }
} }
}) })
},
tab_oimg: function () {
this.$router.push("../actualCombat");
}, },
showPopup(){ showPopup(){
this.show=true this.show=true
}, },
initPieChart () { initPieChart () {
let echartData = [ let echartData =this.echartData
{
name:'北京',
value: '0.99',
},
{
name:'上海',
value: '0.29',
},
{
name:'广州',
value: '0.44',
},
{
name:'深圳',
value: '0.14',
},
{
name:'成都',
value: '0.21',
},
// {
// name:'西安',
// value: '0.77',
// },
]
var chartDom = document.getElementById('pieChart1'); var chartDom = document.getElementById('pieChart1');
this.chart = echarts.init(chartDom); this.chart = echarts.init(chartDom);
let handleEchartData = echartData .map((item3) => { let handleEchartData = echartData .map((item3) => {
...@@ -524,13 +821,20 @@ let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初 ...@@ -524,13 +821,20 @@ let myChart = echarts.init(document.getElementById('myChart'), 'light') // 初
}, },
formatter: function(name) { formatter: function(name) {
let value let value
var sum = echartData.reduce(function(acc, obj) {
return acc + Number(obj.value) ;
}, 0);
for (let i = 0; i < echartData.length; i++) { for (let i = 0; i < echartData.length; i++) {
if (echartData[i].name === name) {
if (echartData[i].name == name) {
value = echartData[i].value value = echartData[i].value
} }
} }
console.log("看看总数",sum)
var val = value var val = value
return [`{name|${name}}` + '' + `{value|${val}%}`] var a=(val/sum*100).toFixed(2)
return [`{name|${name}}` + '' + `{value|${a}%}`]
}, },
}, },
series: [ series: [
...@@ -792,6 +1096,21 @@ line-height: 1rem; ...@@ -792,6 +1096,21 @@ line-height: 1rem;
font-size: 0.5rem; font-size: 0.5rem;
/* font-weight: bold; */ /* font-weight: bold; */
} }
.ster {
display: flex;
background-color: rgb(226, 74, 68);
height: 1rem;
line-height: 1rem;
}
.deta {
width: 70%;
text-align: center;
margin-left: 34px;
font-size: 0.5rem;
color: white;
/* background: #e03939; */
font-weight: bolder;
}
.analystTwo{ .analystTwo{
height: 0.8rem; height: 0.8rem;
line-height: 0.8rem; line-height: 0.8rem;
...@@ -824,12 +1143,13 @@ margin: auto; ...@@ -824,12 +1143,13 @@ margin: auto;
display: flex; display: flex;
} }
.reviewInfo{ .reviewInfo{
width: 94%; width: 91%;
height: 4rem; height: 4rem;
font-size: 0.3rem; font-size: 0.3rem;
/* color: white; */ /* color: white; */
margin: 0.7rem auto; padding-left: 0.6rem;
background-color:yellowgreen ; margin: 0.7rem auto;
/* background-color: yellowgreen; */
} }
#myChart{ #myChart{
...@@ -845,7 +1165,7 @@ font-size: 0.3rem; ...@@ -845,7 +1165,7 @@ font-size: 0.3rem;
/* color: white; */ /* color: white; */
margin: 0.7rem auto; margin: 0.7rem auto;
display: flex; display: flex;
background-color:yellowgreen ; /* background-color:yellowgreen ; */
} }
.profitBoxTwo{ .profitBoxTwo{
width: 94%; width: 94%;
...@@ -854,17 +1174,17 @@ font-size: 0.3rem; ...@@ -854,17 +1174,17 @@ font-size: 0.3rem;
/* color: white; */ /* color: white; */
margin: 0 auto; margin: 0 auto;
display: flex; display: flex;
background-color:yellowgreen ; /* background-color:yellowgreen ; */
} }
.profitLeft{ .profitLeft{
width: 50%; width: 50%;
height: 100%; height: 100%;
background-color: royalblue; /* background-color: royalblue; */
} }
.profitright{ .profitright{
width: 50%; width: 50%;
height: 100%; height: 100%;
background-color: yellow; /* background-color: yellow; */
} }
.profitTitle{ .profitTitle{
display: block; display: block;
...@@ -894,7 +1214,7 @@ display: flex; ...@@ -894,7 +1214,7 @@ display: flex;
.soltBox{ .soltBox{
width: 50%; width: 50%;
height: 100%; height: 100%;
background-color:gray ; /* background-color:gray ; */
color: white; color: white;
text-align: center; text-align: center;
line-height: 1.2rem; line-height: 1.2rem;
...@@ -925,7 +1245,7 @@ line-height: 1.5rem; ...@@ -925,7 +1245,7 @@ line-height: 1.5rem;
.contectSold{ .contectSold{
height: 100%; height: 100%;
width: 40%; width: 40%;
background: gray; /* background: gray; */
border-radius: 0.2rem; border-radius: 0.2rem;
color: white; color: white;
text-align: center; text-align: center;
...@@ -1008,4 +1328,15 @@ right: 0; ...@@ -1008,4 +1328,15 @@ right: 0;
font-size: 0.4rem; font-size: 0.4rem;
margin: 3rem auto; margin: 3rem auto;
} }
.maiTwo{
display: block;
height: 1rem;
width: 1rem;
border: 1px solid rgb(214, 85, 72);
color: rgb(214, 85, 72);
text-align: center;
line-height: 1rem;
margin: auto;
border-radius: 50%;
}
</style> </style>
\ No newline at end of file
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</div> </div>
<!-- 卡片盒子 --> <!-- 卡片盒子 -->
<div class="card-box"> <div class="card-box">
<div class="left-card"> <div class="left-card" @click="jumpDetail(profitIdTwo)">
<div class="card-title"> <div class="card-title">
<span style="display:block;margin-bottom:0.1rem">{{tableName}}</span> <span style="display:block;margin-bottom:0.1rem">{{tableName}}</span>
<span style="display:block;font-size:0.5rem;">{{profitSecond*100}}%</span> <span style="display:block;font-size:0.5rem;">{{profitSecond*100}}%</span>
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
<span v-if="isBuyFirst==1" class="clickBtnGray" >已兑换</span> <span v-if="isBuyFirst==1" class="clickBtnGray" >已兑换</span>
</div> </div>
<div class="center-card"> <div class="center-card" @click="jumpDetail(profitIdFirst)">
<div class="card-title"> <div class="card-title">
<span style="display:block;margin-bottom:0.1rem">{{tableName}}</span> <span style="display:block;margin-bottom:0.1rem">{{tableName}}</span>
<span style="display:block;font-size:0.5rem;">{{profitFirst*100}}%</span> <span style="display:block;font-size:0.5rem;">{{profitFirst*100}}%</span>
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
<span v-if="isBuyTwo==2" class="clickBtn" @click="showPopup(profitIdFirst)">兑换解锁</span> <span v-if="isBuyTwo==2" class="clickBtn" @click="showPopup(profitIdFirst)">兑换解锁</span>
<span v-if="isBuyTwo==1" class="clickBtnGray" >已兑换</span> <span v-if="isBuyTwo==1" class="clickBtnGray" >已兑换</span>
</div> </div>
<div class="rigth-card"> <div class="rigth-card" @click="jumpDetail(profitThree)">
<div class="card-title"> <div class="card-title">
<span style="display:block;margin-bottom:0.1rem">{{tableName}}</span> <span style="display:block;margin-bottom:0.1rem">{{tableName}}</span>
<span style="display:block;font-size:0.5rem;">{{profitThree*100}}%</span> <span style="display:block;font-size:0.5rem;">{{profitThree*100}}%</span>
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
</div> </div>
<!-- 内容盒子 --> <!-- 内容盒子 -->
<div style="padding-bottom:0.5rem"> <div style="padding-bottom:0.5rem">
<div class="bottomcontect-box" v-for="(i,index) in profitList" :key="i.id" style="margin-bottom:0.5rem"> <div class="bottomcontect-box" v-for="(i,index) in profitList" :key="i.id" @click="jumpDetail(i.id)" style="margin-bottom:0.5rem">
<div class="topthis-box"> <div class="topthis-box">
<div class="top-left"> <div class="top-left">
<span style="display:block;font-size:0.5rem">{{i.productName}}</span> <span style="display:block;font-size:0.5rem">{{i.productName}}</span>
...@@ -236,6 +236,15 @@ this.clickTab('yields','总收益') ...@@ -236,6 +236,15 @@ this.clickTab('yields','总收益')
this.checkList=res.data.data this.checkList=res.data.data
}) })
}, },
//跳转到详情页
jumpDetail(id){
this.$router.push({
path: '/detail',
query: {
id:id
}
});
},
//点击标签页 //点击标签页
clickTab(index,name){ clickTab(index,name){
console.log() console.log()
......
<template> <template>
<div class="content"> <div class="content">
<div class="ster">
<img
src="../../assets/left.png"
alt=""
style="width: 0.5rem;
height: 0.8rem;
margin-top: 0.1rem;
margin-left: 0.2rem;"
@click="tab_oimg"
/>
<div class="deta">调仓记录</div>
</div>
<div class="head-box"> <div class="head-box">
<div class="tab-box"> <div class="tab-box">
<span>买/卖</span> <span>买/卖</span>
...@@ -22,22 +34,26 @@ ...@@ -22,22 +34,26 @@
<div class="line"> <div class="line">
</div> </div>
<div class="contect-list"> <div v-for="i in list" :key="i.code">
<div class="mai"> <div class="contect-list">
<div v-if="i.direction==1" class="maiTwo">
<span ></span>
</div>
<div v-if="i.direction==2" class="mai">
<span ></span> <span ></span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span>300***</span> <span>{{i.count}}</span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span>*</span> <span>{{i.price}}</span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span>100%</span> <span>{{i.remark.toFixed(2)}}%</span>
</div> </div>
<div class="contectBox"> <div class="contectBox">
<span style="display:block;height:0.5rem;margin-top:-0.3rem">08/26</span> <span style="display:block;height:0.5rem;margin-top:-0.3rem">{{state_type(i.created_TIME)}}</span>
<span>14:28</span> <span>{{state_typeTwo(i.created_TIME)}}</span>
</div> </div>
</div> </div>
<!-- 灰线 --> <!-- 灰线 -->
...@@ -45,6 +61,8 @@ ...@@ -45,6 +61,8 @@
</div> </div>
</div> </div>
</div>
</template> </template>
<script> <script>
...@@ -61,9 +79,72 @@ export default { ...@@ -61,9 +79,72 @@ export default {
list: [], list: [],
}; };
}, },
mounted(){
this.getList()
},
methods: { methods: {
// ...mapMutations("store_modular", ["operation"]), // ...mapMutations("store_modular", ["operation"]),
getList() {
let temp={
followAccountId:this.$route.query.id,
page:1,
pageSize:100
}
this.server.followAccountZfzt(temp).then((res) =>{
this.list=res.data.data.list
this.list.forEach((i,index)=>{
i.remark=parseFloat(i.remark)*100
})
})
// this.$toast.loading({
// message: '加载中...',
// forbidClick: true,
// duration:0
// });
},
tab_oimg: function () {
this.$router.push({
path: '/detail',
query: {
id:this.$route.query.id
}
});
// this.$router.push("../detail");
},
state_type(row) {
console.log("睡觉哦",row)
// if(cellValue==null){
// return cellValue
// }
let date = new Date(parseInt(row));
let Year = date.getFullYear();
let Moth = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1);
let Day = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate());
let Hour = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours());
let Minute = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
let GMT = Moth + '/' + Day
return GMT
},
state_typeTwo(row) {
console.log("睡觉哦",row)
// if(cellValue==null){
// return cellValue
// }
let date = new Date(parseInt(row));
let Year = date.getFullYear();
let Moth = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1);
let Day = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate());
let Hour = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours());
let Minute = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes());
let Sechond = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
let GMT = Hour + ':' + Minute
return GMT
},
}, },
...@@ -75,7 +156,7 @@ export default { ...@@ -75,7 +156,7 @@ export default {
height: 1.2rem; height: 1.2rem;
width: 100%; width: 100%;
display: flex; display: flex;
background-color: yellow; /* background-color: yellow; */
} }
.tab-box{ .tab-box{
width: 20%; width: 20%;
...@@ -83,7 +164,7 @@ height: 100%; ...@@ -83,7 +164,7 @@ height: 100%;
text-align: center; text-align: center;
line-height: 1.2rem; line-height: 1.2rem;
font-size: 0.35rem; font-size: 0.35rem;
background-color: aquamarine; /* background-color: aquamarine; */
} }
.line{ .line{
width: 100%; width: 100%;
...@@ -99,7 +180,7 @@ background-color: aquamarine; ...@@ -99,7 +180,7 @@ background-color: aquamarine;
display: flex; display: flex;
height: 1.5rem; height: 1.5rem;
width: 100%; width: 100%;
background-color: yellowgreen; /* background-color: yellowgreen; */
font-size: 0.5rem; font-size: 0.5rem;
} }
.contectBox{ .contectBox{
...@@ -120,4 +201,30 @@ line-height: 1.5rem; ...@@ -120,4 +201,30 @@ line-height: 1.5rem;
border-radius: 50%; border-radius: 50%;
} }
.maiTwo{
display: block;
height: 1rem;
width: 1rem;
border: 1px solid rgb(214, 85, 72);
color: rgb(214, 85, 72);
text-align: center;
line-height: 1rem;
margin: auto;
border-radius: 50%;
}
.ster {
display: flex;
background-color: rgb(226, 74, 68);
height: 1rem;
line-height: 1rem;
}
.deta {
width: 70%;
text-align: center;
margin-left: 34px;
font-size: 0.5rem;
color: white;
/* background: #e03939; */
font-weight: bolder;
}
</style> </style>
\ No newline at end of file
...@@ -10,6 +10,9 @@ module.exports = defineConfig({ ...@@ -10,6 +10,9 @@ module.exports = defineConfig({
port: 8080, port: 8080,
hot: true, hot: true,
https: false, https: false,
client: {
overlay: false,
},
proxy: { //配置多个代理 proxy: { //配置多个代理
"/testIp": { "/testIp": {
target: "http://197.0.0.1:8088", target: "http://197.0.0.1:8088",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment