@@ -170,12 +171,14 @@ export default {
};
},
sellListShow() {
- let list = this.sellList.splice(0, 12);
- let total = 0;
- list.forEach(item => {
- item.total = total += item.amount;
- });
- return list.reverse();
+ let list = this.sellList.splice(0, 12);
+ let total = 0;
+ list.forEach(item => {
+ item.total = total += item.amount;
+ });
+ // console.log(list,'sellListShow' )
+ return list.reverse();
+ // return [];
},
buyListShow() {
let list = this.buyList.splice(0, 12);
@@ -183,7 +186,9 @@ export default {
list.forEach(item => {
item.total = total += item.amount;
});
+ // console.log(list, 'buyListShow')
return list;
+ // return [];
}
},
created() {
@@ -192,7 +197,8 @@ export default {
this.linkSocket();
}
bus.$on('collapse', msg => {
- this.newPriceObj.price =this.symbol=='BTC'? (msg.close).toFixed(1):(msg.close).toFixed(3);
+ // +字符串转数字
+ this.newPriceObj.price = +(this.symbol=='BTC'? (msg.close).toFixed(1):(msg.close).toFixed(3));
this.$emit("input", this.newPriceObj);
});
},
@@ -208,7 +214,9 @@ export default {
this.sellList = res.swapSellList;
this.buyList = res.swapBuyList;
this.tradeList = res.swapTradeList;
- this.newPriceObj = this.tradeList[0];
+ if(this.tradeList.length>0){
+ this.newPriceObj = this.tradeList[0];
+ }
this.$emit("input", this.newPriceObj);
});
},
diff --git a/src/views/contract/handicapRight.vue b/src/views/contract/handicapRight.vue
index 7ff9891..5b1acf1 100644
--- a/src/views/contract/handicapRight.vue
+++ b/src/views/contract/handicapRight.vue
@@ -21,7 +21,7 @@
+
{{ item.price }}
diff --git a/src/views/contract/hold-position.vue b/src/views/contract/hold-position.vue
index 7d71c64..7623da3 100644
--- a/src/views/contract/hold-position.vue
+++ b/src/views/contract/hold-position.vue
@@ -51,7 +51,7 @@
{{ item.avg_price * 1 }} |
{{ item.realtimePrice }} |
{{ item.flatPrice }} |
- {{ (parseFloat(item.unRealProfit)).toFixed(2) }} |
+ {{ (parseFloat(item.unRealProfit)).toFixed(2) }} |
{{ item.profitRate }} |
{{ item.tpPrice || "--" }}/{{ item.slPrice || "--" }} |
@@ -624,8 +624,8 @@ export default {
},
};
-
diff --git a/src/views/contract/transaction-record.vue b/src/views/contract/transaction-record.vue
index 45a56c2..1ce258c 100644
--- a/src/views/contract/transaction-record.vue
+++ b/src/views/contract/transaction-record.vue
@@ -14,7 +14,7 @@
| {{ item.log_type_text }} |
diff --git a/src/views/exchange/book-trades.vue b/src/views/exchange/book-trades.vue
index 589cb10..e4b0dcc 100644
--- a/src/views/exchange/book-trades.vue
+++ b/src/views/exchange/book-trades.vue
@@ -32,7 +32,7 @@
|
{{ $t("exchange.last-price") }}
- {{ newTrade.price}}
+ {{ newTrade.price}}
|
CNY
@@ -41,7 +41,7 @@
≈ {{newTrade.price*priceCny|omitTo(2)}}
≈ {{newTrade.price|omitTo(2)}}
|
-
+ |
{{ $t("exchange.change") }}
{{ changeRate }}
|
diff --git a/src/views/exchange/symbols.vue b/src/views/exchange/symbols.vue
index 9a69719..bb5eb32 100644
--- a/src/views/exchange/symbols.vue
+++ b/src/views/exchange/symbols.vue
@@ -79,7 +79,7 @@ export default {
marketInfoList: Array(10).fill({
coin_name: "-",
price: "-",
- increace: 0,
+ increase: 0,
increaseStr: "+0.00%",
}),
})
@@ -108,7 +108,7 @@ export default {
marketInfoList: Array(10).fill({
pair: "-",
price: "-",
- increace: 0,
+ increase: 0,
increaseStr: "+0.00%",
}),
},
diff --git a/src/views/home/index.vue b/src/views/home/index.vue
index 3e758dc..4e49956 100644
--- a/src/views/home/index.vue
+++ b/src/views/home/index.vue
@@ -33,7 +33,7 @@
{{ item.price }}
-
+
{{ item.increaseStr }}
@@ -145,7 +145,7 @@
{{ item.close }}
@@ -153,7 +153,7 @@
|
{{ item.increaseStr }}
@@ -236,7 +236,7 @@
|
{{ item.close }}
@@ -245,7 +245,7 @@
-
+
|