|
@@ -220,7 +220,7 @@ class ShopModel |
|
@@ -220,7 +220,7 @@ class ShopModel |
220
|
|
220
|
|
221
|
|
221
|
|
222
|
/**
|
222
|
/**
|
223
|
- * 店铺Banner 资源位
|
223
|
+ * 店铺-经典Banner 资源位
|
224
|
* @param type $data []
|
224
|
* @param type $data []
|
225
|
*/
|
225
|
*/
|
226
|
public static function shopTopBanner($data)
|
226
|
public static function shopTopBanner($data)
|
|
@@ -231,21 +231,50 @@ class ShopModel |
|
@@ -231,21 +231,50 @@ class ShopModel |
231
|
'bannerHeight' => 150
|
231
|
'bannerHeight' => 150
|
232
|
);
|
232
|
);
|
233
|
|
233
|
|
234
|
- if (isset($data['resource_data'][0]['shopSrc'])) {
|
234
|
+ if (!empty($data['resource_data'][0]['shopSrc'])) {
|
235
|
$result['banner'] = self::imageView2($data['resource_data'][0]['shopSrc'], 1150, 150);
|
235
|
$result['banner'] = self::imageView2($data['resource_data'][0]['shopSrc'], 1150, 150);
|
236
|
}
|
236
|
}
|
237
|
|
237
|
|
238
|
- if (isset($data['resource_data'][0]['detailSrc'])) {
|
238
|
+ if (!empty($data['resource_data'][0]['detailSrc'])) {
|
239
|
$result['detailSrc'] = self::imageView2($data['resource_data'][0]['detailSrc'], 1150, 150);
|
239
|
$result['detailSrc'] = self::imageView2($data['resource_data'][0]['detailSrc'], 1150, 150);
|
240
|
}
|
240
|
}
|
241
|
|
241
|
|
242
|
- if (isset($data['resource_data'][0]['isShowShopName'])) {
|
242
|
+ if (!empty($data['resource_data'][0]['isShowShopName'])) {
|
243
|
$result['isShowShopName'] = $data['resource_data'][0]['isShowShopName'] === 'Y';
|
243
|
$result['isShowShopName'] = $data['resource_data'][0]['isShowShopName'] === 'Y';
|
244
|
}
|
244
|
}
|
245
|
return $result;
|
245
|
return $result;
|
246
|
|
246
|
|
247
|
}
|
247
|
}
|
248
|
/**
|
248
|
/**
|
|
|
249
|
+ * 店铺-基础Banner 资源位
|
|
|
250
|
+ * @param type $data
|
|
|
251
|
+ * @return type []
|
|
|
252
|
+ */
|
|
|
253
|
+ public static function shopTopBanner_base($data)
|
|
|
254
|
+ {
|
|
|
255
|
+ $result = array(
|
|
|
256
|
+ 'banner' => '',
|
|
|
257
|
+ 'isShowShopName' => false,
|
|
|
258
|
+ 'bannerHeight' => 150
|
|
|
259
|
+ );
|
|
|
260
|
+
|
|
|
261
|
+ if (!empty($data['resource_data'][0]['shopSrc'])) {
|
|
|
262
|
+ $result['banner'] = $data['resource_data'][0]['shopSrc'];
|
|
|
263
|
+ }
|
|
|
264
|
+
|
|
|
265
|
+ if (!empty($data['resource_data'][0]['detailSrc'])) {
|
|
|
266
|
+ $result['detailSrc'] = $data['resource_data'][0]['detailSrc'];
|
|
|
267
|
+ }
|
|
|
268
|
+
|
|
|
269
|
+ if (!empty($data['resource_data'][0]['isShowShopName'])) {
|
|
|
270
|
+ $result['isShowShopName'] = $data['resource_data'][0]['isShowShopName'] === 'Y';
|
|
|
271
|
+ }
|
|
|
272
|
+
|
|
|
273
|
+ return $result;
|
|
|
274
|
+
|
|
|
275
|
+ }
|
|
|
276
|
+
|
|
|
277
|
+ /**
|
249
|
* 导航栏 资源位
|
278
|
* 导航栏 资源位
|
250
|
* @param type $data
|
279
|
* @param type $data
|
251
|
* @return type []
|
280
|
* @return type []
|
|
@@ -573,7 +602,7 @@ class ShopModel |
|
@@ -573,7 +602,7 @@ class ShopModel |
573
|
if (is_callable("self::$fun")) {
|
602
|
if (is_callable("self::$fun")) {
|
574
|
$list = self::$fun(self::getResourceData($list), $parameters);
|
603
|
$list = self::$fun(self::getResourceData($list), $parameters);
|
575
|
switch ($fun) {
|
604
|
switch ($fun) {
|
576
|
- case 'shopTopBanner':
|
605
|
+ case 'shopTopBanner_base':
|
577
|
case 'signboard':
|
606
|
case 'signboard':
|
578
|
$data[$fun] = $list;
|
607
|
$data[$fun] = $list;
|
579
|
break;
|
608
|
break;
|