| 
					
				 | 
			
			
				@@ -37,6 +37,17 @@ class ShopController extends Curd 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return $this->doFormat($query, $format, $limit); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public function selectList() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        $class = get_class($this->model); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        $data = $class::where('shop_status', 1) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            ->select('shop_id', 'shop_name') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            ->get() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            ->toArray(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        return json_success('', $data); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @Desc 插入数据处理 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -85,11 +96,14 @@ class ShopController extends Curd 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         foreach ($items as &$item) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             $item->shop_logo = getenv('STORAGE_DOMAIN').$item->shop_logo; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            $shopBusinessHoursArr = explode('~', $item->shop_business_hours); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            foreach ($shopBusinessHoursArr as $key => $v){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                $shopBusinessHoursArr[$key] = date("Y-m-d\TH:i:s\Z",strtotime(date('Y-m-d ').$v)-8*3600); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (!empty($item->shop_business_hours)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                $shopBusinessHoursArr = explode('~', $item->shop_business_hours); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                foreach ($shopBusinessHoursArr as $key => $v){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $shopBusinessHoursArr[$key] = date("Y-m-d\TH:i:s\Z",strtotime(date('Y-m-d ').$v)-8*3600); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                $item->shop_business_hours = $shopBusinessHoursArr; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            $item->shop_business_hours = $shopBusinessHoursArr; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             $item->shop_label = !empty($item->shop_label) ? explode(',',$item->shop_label) : []; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return $items; 
			 |