friend-list.vue
1.6 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
94
<template>
<div class="wrapper">
<div class="title-wrapper">
<TitleComp txt="我邀请的好友"></TitleComp>
</div>
<table class="table">
<thead class="header">
<tr>
<th width="28%" align="left">昵称</th>
<th width="60%" align="center">入驻时间</th>
<th width="12%" align="center">订单数</th>
</tr>
</thead>
<tbody class="tbody">
<tr v-for="item in list">
<td align="left">
<span class="nick-name">{{item.nickName}}</span>
</td>
<td align="center">
<span>{{item.enterTime}}</span>
</td>
<td align="center">
<span>{{item.orderNum}}</span>
</td>
</tr>
</tbody>
</table>
</div>
</template>
<script>
import TitleComp from './title';
export default {
name: 'FriendList',
components: {
TitleComp
},
props: {
list: {
type: Array,
default() {
return [];
}
}
}
};
</script>
<style lang="scss" scoped>
.wrapper {
text-align: center;
color: white;
}
.title-wrapper {
text-align: left;
margin-bottom: 60px;
}
.table {
margin-top: 20px;
width: 100%;
font-size: 24px;
th {
font-weight: bold;
color: white;
}
tbody {
tr {
height: 110px;
border-bottom: 1px solid rgba(255, 255, 255, 0.09);
span {
color: #94b0c4;
display: block;
height: 110px;
line-height: 110px;
}
}
}
}
.nick-name {
width: 150px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
</style>