فهرست منبع

Merge branch 'test' of git.oschina.net:yiguanjia/php into test

洪海涛 8 سال پیش
والد
کامیت
b452a3bce1
1فایلهای تغییر یافته به همراه3 افزوده شده و 1 حذف شده
  1. 3 1
      www/protected/commands/GetKennelWorkCommand.php

+ 3 - 1
www/protected/commands/GetKennelWorkCommand.php

@@ -17,7 +17,6 @@ class GetKennelWorkCommand extends CConsoleCommand {
     public function getKennel(){
         $count = 0;
         $page = intval(Yii::app()->redis->get('page'));
-        $page = 0;
         if (empty($page)) $page =1;
         while($page) {
             if ($count >= 1000) {
@@ -56,6 +55,9 @@ class GetKennelWorkCommand extends CConsoleCommand {
                             $kennel->tags[$k] = $v;
                         $kennel->desc = $tmp['desc'];
                         foreach ($tmp['desc_pics'] as $k => $v) {
+                            if (!empty($v['url'])){
+                                $v['url'] = str_replace('wozhua-pics.qiniudn.com','pics.maiyizhi.cn',$v['url']);
+                            }
                             $kennel->desc_pics[$k] = $v;
                         }
                         $kennel->address = $tmp['address'];