|
|
|
@ -1,5 +1,12 @@ |
|
|
|
<template> |
|
|
|
<div class="contract-page"> |
|
|
|
<div class="banner-block col-xs-8"> |
|
|
|
<el-carousel :interval="6000" height="450px"> |
|
|
|
<el-carousel-item v-for="item in pcBannerList" :key="item.id"> |
|
|
|
<img :src="item.imgurl" width="100%" height="100%" /> |
|
|
|
</el-carousel-item> |
|
|
|
</el-carousel> |
|
|
|
</div> |
|
|
|
<div class="page-top d-flex pt-2"> |
|
|
|
<div class="kline-box flex-fill mr-2"> |
|
|
|
<div |
|
|
|
@ -194,6 +201,7 @@ import exchangeStore from "./exchange-store.vue"; |
|
|
|
import pageBottom from "./page-bottom.vue"; |
|
|
|
import Contract from "../../api/contract"; |
|
|
|
import Socket from "@/api/server/Socket.js"; |
|
|
|
import Home from "@/api/home"; |
|
|
|
export default { |
|
|
|
components: { |
|
|
|
kline, |
|
|
|
@ -209,6 +217,7 @@ export default { |
|
|
|
holdPositionAll: false, |
|
|
|
holdPositionList: [], |
|
|
|
newPriceObj: {}, |
|
|
|
pcBannerList:[], |
|
|
|
accountInfo: {}, |
|
|
|
defaultPrice: "", |
|
|
|
wsUrl: this.Globals.Server.Path.WS1, |
|
|
|
@ -244,6 +253,7 @@ export default { |
|
|
|
// this.openStatus(); |
|
|
|
this.getMarketList(); |
|
|
|
this.holdPosition(); |
|
|
|
this.indexList(); |
|
|
|
this._time = setInterval(() => { |
|
|
|
if (this.contractOpen) { |
|
|
|
this.holdPosition(); |
|
|
|
@ -319,6 +329,14 @@ export default { |
|
|
|
this.$message.success(this.$t('contract.j9')); |
|
|
|
}); |
|
|
|
}, |
|
|
|
indexList() { |
|
|
|
Home.indexList().then((res) => { |
|
|
|
this.pcBannerList = res.pcBannerList |
|
|
|
setTimeout(() => { |
|
|
|
this.skroll(); |
|
|
|
}, 100); |
|
|
|
}).catch((res) => {}); |
|
|
|
}, |
|
|
|
//获取某一个持仓订单的数据 |
|
|
|
setactiveItem(index=0){ |
|
|
|
this.accountInfo=this.holdPositionList[index] |
|
|
|
|