feat: 更新
This commit is contained in:
1 parent
851c940895
commit
4376017d12
2 files changed
+33
-7
No files matched your search
@@ -1,15 +1,21 @@
|
||||
<template>
|
||||
<div class="balance-view" :class="modeClass">
|
||||
<div class="balance-view-text">
|
||||
<label>{{ moneyStr }}</label>
|
||||
<p>
|
||||
<label>{{ unitStr }}</label>
|
||||
<span>{{ value }}</span>
|
||||
</p>
|
||||
<p>
|
||||
<label>{{ moneyStr }}</label>
|
||||
<span>{{ goldNum }}</span>
|
||||
</p>
|
||||
</div>
|
||||
<div class="balance-view-btn" @click="clickHandler"></div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { unit } from "@/config";
|
||||
import { unit, money } from "@/config";
|
||||
import eventBus from "@/lib/eventBus";
|
||||
export default {
|
||||
name: "BalanceView",
|
||||
@@ -21,11 +27,16 @@ export default {
|
||||
value: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
goldNum: {
|
||||
type: Number,
|
||||
default: 0
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
unit
|
||||
unit,
|
||||
money
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
@@ -33,8 +44,11 @@ export default {
|
||||
if (this.drawType === "turntable1") return "balance-view-xy";
|
||||
return "balance-view-hh";
|
||||
},
|
||||
unitStr() {
|
||||
return `${unit}:`;
|
||||
},
|
||||
moneyStr() {
|
||||
return `${unit}余额:`;
|
||||
return `${money}:`;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -53,20 +67,27 @@ export default {
|
||||
background-size: cover;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
&-text {
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
// align-items: center;
|
||||
justify-content: center;
|
||||
padding-left: 30px;
|
||||
font-size: 24px;
|
||||
& > label {
|
||||
line-height: 30px;
|
||||
|
||||
label {
|
||||
color: #fff;
|
||||
}
|
||||
& > span {
|
||||
|
||||
span {
|
||||
color: #ffe26c;
|
||||
}
|
||||
}
|
||||
|
||||
&-btn {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
@@ -75,14 +96,17 @@ export default {
|
||||
background-repeat: no-repeat;
|
||||
background-size: cover;
|
||||
background-image: url(../../assets/images/cz_bth.png);
|
||||
|
||||
&:active {
|
||||
background-image: url(../../assets/images/cz_bth_a.png);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.balance-view-xy {
|
||||
background-image: url(../../assets/images/yue_bg.png);
|
||||
}
|
||||
|
||||
.balance-view-hh {
|
||||
background-image: url(../../assets/images/yue_bg_g.png);
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
<balance-view
|
||||
:drawType="drawType"
|
||||
:value="remainTicketNum"
|
||||
:goldNum="goldNum"
|
||||
></balance-view>
|
||||
<lottery-btn :drawType="drawType"></lottery-btn>
|
||||
</div>
|
||||
@@ -47,6 +48,7 @@ export default {
|
||||
computed: {
|
||||
...mapGetters([
|
||||
"remainTicketNum",
|
||||
"goldNum",
|
||||
"ticketRule",
|
||||
"ticketRuleList",
|
||||
"ticketRuleConfig"
|
||||
|
||||
Reference in new issue
Block a user