jufubao-base 1.0.174-beta8 → 1.0.175

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jufubao-base",
3
- "version": "1.0.174-beta8",
3
+ "version": "1.0.175",
4
4
  "private": false,
5
5
  "description": "聚福宝业务组件基础插件包",
6
6
  "main": "index.js",
@@ -675,7 +675,11 @@
675
675
  }
676
676
  }
677
677
  }
678
-
678
+ .rule_wrap{
679
+ font-size: 32rpx;
680
+ line-height: 1.7;
681
+ font-weight: 400;
682
+ }
679
683
  .code_wrap{
680
684
  display: flex;
681
685
  flex-direction: column;
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <view class="search_all_list" >
3
3
  <template v-if="!loadingList">
4
- <view class="module_item" v-for="parent in list" :key="parent.setting_id"
4
+ <view class="module_item" v-for="(parent, pi) in list" :key="parent.setting_id"
5
5
  :style="moduleItemStyle"
6
6
  >
7
7
  <view class="module_title" :style="moduleItemTitleStyle">{{ parent.name }}</view>
@@ -18,7 +18,7 @@
18
18
  :color="{SEAT:listItemStyle.mainColor,CODE:listItemStyle.subMainColor,SELL:listItemStyle.successColor}"
19
19
  :border-radius="listItemStyle.imgRradius"
20
20
  :brand-color="listItemStyle.brandColor"
21
- @on-schedule="data => handleFilmDetail(data, parent)"
21
+ @on-schedule="data => handleSchedule(data, parent)"
22
22
  @on-cashier-detail="data => handleCashierDetail(data, parent)"
23
23
  @on-code-detail="data => handleCodeDetail(data, parent)"
24
24
  ></content-cinema>
@@ -71,7 +71,7 @@
71
71
  </view>
72
72
  </view>
73
73
  <view class="module_more">
74
- <view class="more_inner" :style="moduleMoreStyle" @click="switchMenu(parent)">查看全部</view>
74
+ <view class="more_inner" :style="moduleMoreStyle" @click="switchMenu(pi)">查看全部</view>
75
75
  </view>
76
76
  </view>
77
77
  <xd-no-data v-if="list && list.length ===0" height="60vh" icon-type="search">商品正在上架中</xd-no-data>
@@ -262,7 +262,9 @@
262
262
  }
263
263
  })
264
264
  },
265
- switchMenu(item){
265
+ switchMenu(index){
266
+ let item = this.list[index];
267
+ // console.log('switchMenu', item, pi);
266
268
  this.$emit('on-switch', {...item, value: item.tab});
267
269
  },
268
270
 
@@ -110,12 +110,12 @@
110
110
  this.errorStatus = true;
111
111
  },
112
112
  handleDetail(item){
113
- console.log('handleDetail.item',item,item.id);
114
- this.$emit('on-film-detail',item.id);
113
+ console.log('handleDetail.item',item,item);
114
+ this.$emit('on-film-detail',item);
115
115
  },
116
116
  handleBuy(item){
117
- console.log('handleDetail.item',item,item.id);
118
- this.$emit('on-buy',item.id);
117
+ console.log('handleDetail.item',item,item);
118
+ this.$emit('on-buy',item);
119
119
  }
120
120
  }
121
121
  }
@@ -10,7 +10,9 @@
10
10
  borderRadius: borderRadius + 'rpx',
11
11
  }"
12
12
  >
13
- <image :src="imageUrl" :alt="item['product_name']"></image>
13
+ <image v-if="errorStatus" :src="errorImage" :alt="item['product_name']" ></image>
14
+ <image v-if="!errorStatus" :src="imageUrl" :alt="item['product_name']" @error="handleError()"></image>
15
+ <xd-product-status :status="item['status']"></xd-product-status>
14
16
  </view>
15
17
  <view class="prodcut-content" :style="{marginTop:cell === 1? 0: (outSpacing + 'rpx') }">
16
18
  <view class="prodcut-content-info">
@@ -64,13 +66,15 @@
64
66
  import handleKeyword from "./handleKeyword";
65
67
  import getServiceUrl from "@/common/getServiceUrl";
66
68
  import XdFontIcon from "@/components/XdFontIcon/XdFontIcon.vue";
69
+ import XdProductStatus from "@/components/XdProductStatus/XdProductStatus";
67
70
  import XdUnit from "@/components/XdUnit/XdUnit.vue";
68
71
 
69
72
  export default {
70
73
  name: "ContentProduct",
71
74
  components:{
72
75
  XdFontIcon,
73
- XdUnit
76
+ XdUnit,
77
+ XdProductStatus
74
78
  },
75
79
  props:{
76
80
  keyword:{
@@ -153,7 +157,9 @@ export default {
153
157
  data(){
154
158
  return {
155
159
  tagObj: null,
156
- tagObjColor: null
160
+ tagObjColor: null,
161
+ errorStatus: false,
162
+ errorImage:'https://img0.jufubao.cn/common/empty/product.png?v1=1',
157
163
  }
158
164
  },
159
165
  created() {
@@ -161,10 +167,11 @@ export default {
161
167
  this.tagObjColor = this.$colorConfig.productTagsColor;
162
168
  },
163
169
  methods:{
170
+ handleError(){
171
+ this.errorStatus = true;
172
+ },
164
173
  handleDetail(){
165
- if(this.item.status === 'ok') {
166
- this.$emit('on-product-detail', this.item);
167
- }
174
+ this.$emit('on-product-detail', this.item);
168
175
  }
169
176
  }
170
177
  }
@@ -182,6 +189,7 @@ export default {
182
189
 
183
190
  .prodcut-image {
184
191
  flex-shrink: 0;
192
+ position: relative;
185
193
  }
186
194
 
187
195
  .prodcut-content {
@@ -200,6 +208,7 @@ export default {
200
208
  display: flex;
201
209
  justify-content: center;
202
210
  align-items: center;
211
+ position: relative;
203
212
  & > image {
204
213
  height: 100%;
205
214
  width: 100%;
@@ -1,7 +1,8 @@
1
1
  <template>
2
2
  <view class="content-item" @click="handleDetail(item)">
3
3
  <view class="content-item-image" :style="{marginRight:outSpacing+'rpx',borderRadius:borderRadius+'rpx'}">
4
- <image :src="imageUrl" :alt="item['resource_shop_name']"></image>
4
+ <image v-if="errorStatus" :src="errorImage" :alt="item['resource_shop_name']" ></image>
5
+ <image v-if="!errorStatus" :src="imageUrl+1" :alt="item['resource_shop_name']" @error="handleError()"></image>
5
6
  </view>
6
7
  <view class="content-item-cont">
7
8
  <view class="title">
@@ -77,11 +78,20 @@ export default {
77
78
  return `${sy}${this.item.address}`;
78
79
  },
79
80
  },
81
+ data(){
82
+ return {
83
+ errorStatus: false,
84
+ errorImage:'https://img0.jufubao.cn/common/empty/shop.png?v1=1',
85
+ }
86
+ },
80
87
  created() {
81
88
  // console.log(this.item)
82
89
  // debugger
83
90
  },
84
91
  methods:{
92
+ handleError(){
93
+ this.errorStatus = true;
94
+ },
85
95
  handleJhd(item){
86
96
  this.$emit('on-shop-jhd',item);
87
97
  },
@@ -132,6 +132,7 @@
132
132
  ></content-product>
133
133
  </view>
134
134
  </view>
135
+ <view class="hasNoData" v-if="dataList && dataList.length > 0 && page_token === ''">已经到底没有更多数据了</view>
135
136
  </view>
136
137
  </view>
137
138
  </view>
@@ -467,7 +468,8 @@ export default {
467
468
  text-align: center;
468
469
  color: #ccc;
469
470
  background-color: rgba(255, 255, 255, .05);
470
- margin: 20rpx 0
471
+ margin: 20rpx 0;
472
+ width: 100%;
471
473
  }
472
474
 
473
475
  </style>
@@ -310,6 +310,10 @@
310
310
  },
311
311
  handleSwitchMenu(item){
312
312
  this.tabId = item.value;
313
+ uni.pageScrollTo({
314
+ scrollTop: 0,
315
+ duration: 0
316
+ });
313
317
  },
314
318
  handleToSearch(item){
315
319
  this.keyword = item;
@@ -4,7 +4,7 @@ export default ($vm, str , keyword='', options={})=>{
4
4
  if(keyword === '') return str;
5
5
  try {
6
6
  let __option = {
7
- tag: 'text',
7
+ tag: 'span',
8
8
  color: 'red',
9
9
  weight: '500',
10
10
  };