|
@@ -9,7 +9,8 @@
|
9
|
9
|
<li class="customer-card">
|
10
|
10
|
<div class="list-box">
|
11
|
11
|
<customerCard v-for="(item,index) in cardList" :key="index" :data='item' @record='record'></customerCard>
|
12
|
|
- <span class="noData" v-if="ajaxOff && !cardList.length">暂无数据</span>
|
|
12
|
+ <!-- <span class="noData" v-if="ajaxOff && !cardList.length">暂无数据</span> -->
|
|
13
|
+ <noMore v-if="ajaxOff && hasPic"></noMore>
|
13
|
14
|
</div>
|
14
|
15
|
</li>
|
15
|
16
|
</ul>
|
|
@@ -31,6 +32,7 @@ import customerCard from '../../../components/customerCard/customerCard'
|
31
|
32
|
import active from '../../../common/icon/check-box-checked.png'
|
32
|
33
|
import normal from '../../../common/icon/check-box-empty.png'
|
33
|
34
|
import topCaseInfo from '../../../components/topCaseInfo/index'
|
|
35
|
+import noMore from '../../../components/noMore/noMore'
|
34
|
36
|
import { mapState, createNamespacedHelpers } from 'vuex'
|
35
|
37
|
const { mapActions: actions } = createNamespacedHelpers('app')
|
36
|
38
|
const { mapActions: caseTableActions } = createNamespacedHelpers('placeOrderForCoffee')
|
|
@@ -51,6 +53,7 @@ export default {
|
51
|
53
|
normal: normal
|
52
|
54
|
},
|
53
|
55
|
ajaxOff: false,
|
|
56
|
+ hasPic: false,
|
54
|
57
|
key: '',
|
55
|
58
|
mask: true,
|
56
|
59
|
checked: true,
|
|
@@ -70,6 +73,7 @@ export default {
|
70
|
73
|
components: {
|
71
|
74
|
customerCard,
|
72
|
75
|
topCaseInfo,
|
|
76
|
+ noMore
|
73
|
77
|
},
|
74
|
78
|
created () {
|
75
|
79
|
this.getCaseList().then((res) => {
|
|
@@ -96,7 +100,7 @@ export default {
|
96
|
100
|
]),
|
97
|
101
|
record (item) {
|
98
|
102
|
// console.log(item)
|
99
|
|
- this.$router.push({ name: 'getRecord', query: {name: item.Name, phone: item.Phone, id: item.CustomerId} })
|
|
103
|
+ this.$router.push({ name: 'getRecord', query: { name: item.Name, phone: item.Phone, id: item.CustomerId } })
|
100
|
104
|
},
|
101
|
105
|
searchMask () {
|
102
|
106
|
this.getCustomerList({
|
|
@@ -105,11 +109,22 @@ export default {
|
105
|
109
|
isrecommend: false,
|
106
|
110
|
key: this.key,
|
107
|
111
|
}).then((res) => {
|
108
|
|
- // console.log(JSON.stringify(res))
|
109
|
|
- res = res || []
|
110
|
|
- for (var n = 0; n < res.length; n++) {
|
111
|
|
- this.cardList.push({...res[n], invalid: false})
|
|
112
|
+ if (res) {
|
|
113
|
+ for (var n = 0; n < res.length; n++) {
|
|
114
|
+ if (res[n].RecommendId === this.userInfo.customer.MapUser) {
|
|
115
|
+ res[n].showTag = true
|
|
116
|
+ } else {
|
|
117
|
+ res[n].showTag = false
|
|
118
|
+ }
|
|
119
|
+ this.cardList.push(res[n])
|
|
120
|
+ }
|
|
121
|
+ } else {
|
|
122
|
+ this.hasPic = true
|
112
|
123
|
}
|
|
124
|
+ // res = res || []
|
|
125
|
+ // for (var n = 0; n < res.length; n++) {
|
|
126
|
+ // this.cardList.push({...res[n], invalid: false})
|
|
127
|
+ // }
|
113
|
128
|
this.mask = false
|
114
|
129
|
this.ajaxOff = true
|
115
|
130
|
})
|