正在显示
1 个修改的文件
包含
1 行增加
和
10 行删除
| @@ -43,7 +43,7 @@ class DownloadProject extends Command | @@ -43,7 +43,7 @@ class DownloadProject extends Command | ||
| 43 | $data = $this->downloadProduct(); | 43 | $data = $this->downloadProduct(); |
| 44 | DB::disconnect('custom_mysql'); | 44 | DB::disconnect('custom_mysql'); |
| 45 | echo date('Y-m-d H:i:s') . 'end' . PHP_EOL; | 45 | echo date('Y-m-d H:i:s') . 'end' . PHP_EOL; |
| 46 | -// return $this->exportData($data); | 46 | + return $this->exportData($data); |
| 47 | } | 47 | } |
| 48 | 48 | ||
| 49 | public function downloadProduct() | 49 | public function downloadProduct() |
| @@ -55,16 +55,7 @@ class DownloadProject extends Command | @@ -55,16 +55,7 @@ class DownloadProject extends Command | ||
| 55 | $lists = $product->list(['status'=>1],'id',$filed); | 55 | $lists = $product->list(['status'=>1],'id',$filed); |
| 56 | if(!empty($lists)){ | 56 | if(!empty($lists)){ |
| 57 | $cate_data = $this->getCategoryList();//分类 | 57 | $cate_data = $this->getCategoryList();//分类 |
| 58 | - $detailModel = new Detail(); | ||
| 59 | foreach ($lists as $k => $v){ | 58 | foreach ($lists as $k => $v){ |
| 60 | - $detailInfo = $detailModel->read(['product_id'=>$v['id'],'column_id'=>1,'text_type'=>1],['content']); | ||
| 61 | - if($detailInfo === false || ($detailInfo['content']['content'] == null)){ | ||
| 62 | - $v['content'] = ''; | ||
| 63 | - }else{ | ||
| 64 | - echo date('Y-m-d H:i:s') . '数据详情$v:'. json_encode($detailInfo) . PHP_EOL; | ||
| 65 | - die(); | ||
| 66 | - $v['content'] = $detailInfo['content']['content']; | ||
| 67 | - } | ||
| 68 | $v['url'] = 'https://www.autsikinta.com/' . getRouteMap(RouteMap::SOURCE_PRODUCT,$v['id']); | 59 | $v['url'] = 'https://www.autsikinta.com/' . getRouteMap(RouteMap::SOURCE_PRODUCT,$v['id']); |
| 69 | $v['category_id_text'] = $this->categoryName($v['id'],$cate_data); | 60 | $v['category_id_text'] = $this->categoryName($v['id'],$cate_data); |
| 70 | //ToDo::处理图片及文件 | 61 | //ToDo::处理图片及文件 |
-
请 注册 或 登录 后发表评论