buyer-product.vue
1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<template>
<div class="product-info">
<div class="product-wrapper">
<div class="good-image">
<ImageFormat :src="data.goodImg" :width="180" :height="180"></ImageFormat>
</div>
<div class="product-price">
<div class="red">¥{{data.goodPrice}}</div>
<div class="product-name">{{data.productName}}</div>
<div class="price">{{data.colorName}},{{data.sizeName}}</div>
</div>
</div>
<div v-if="!getLogin" class="no-login-tip">完成“有货”登录授权后将显示商品优惠及运费信息,请先完成登录查看最终支付金额</div>
</div>
</template>
<script>
import { mapGetters } from 'vuex';
export default {
name: 'OrderProductInfo',
props: {
data: {
type: Object,
default() {
return {};
}
}
},
computed: {
...mapGetters(['getLogin'])
}
};
</script>
<style lang="scss" scoped>
.product-info {
display: flex;
flex-direction: column;
}
.good-image {
width: 180px;
height: 180px;
display: inline-block;
overflow: hidden;
img {
width: 100%;
height: 100%;
display: block;
}
}
.product-price {
display: inline-block;
vertical-align: top;
height: 100%;
width: 450px;
margin-left: 20px;
}
.price {
font-weight: bold;
font-size: 24px;
}
.tip {
font-size: 28px;
margin-top: 24px;
}
.product-name {
font-size: 24px;
color: #999;
display: inline-block;
margin-bottom: 24px;
line-height: 36px;
}
.no-login-tip {
color: #d0021b;
}
.red {
color: #d0021b;
font-size: 28px;
margin-bottom: 12px;
font-weight: bold;
@include num
}
</style>