當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CommonModel::getfhPicture方法代碼示例

本文整理匯總了PHP中CommonModel::getfhPicture方法的典型用法代碼示例。如果您正苦於以下問題:PHP CommonModel::getfhPicture方法的具體用法?PHP CommonModel::getfhPicture怎麽用?PHP CommonModel::getfhPicture使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CommonModel的用法示例。


在下文中一共展示了CommonModel::getfhPicture方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: act_getPicture

 public function act_getPicture($ordersn, $starttime, $endtime, $scanuser, $pictype, $pic_status, $limit)
 {
     $srcArr = array();
     if (empty($ordersn) && $pictype == 'cz') {
         $picArr = CommonModel::getczPicture($ordersn, $starttime, $endtime, $scanuser, $limit);
         //稱重
         self::$errCode = $picArr['res_code'];
         self::$errMsg = "{$picArr['res_msg']}";
         if ($picArr['data']) {
             $audited = 0;
             foreach ($picArr['data'] as $value) {
                 $times = $value['scantime'];
                 //時間戳轉時間格式
                 $src1 = date("Y/m/d", "{$times}");
                 $src2 = $value['ebay_id'];
                 $src = self::$cz . $src1 . "/cz_" . $src2 . ".jpg";
                 /* $isright	=get_headers($src);
                 			if(!preg_match('/200/',$isright[0])){
                 				$src="http://cz.valsun.cn/$src1/cz_$src2.jpg";
                 			} */
                 $srconerror = "http://cz.valsun.cn/{$src1}/cz_{$src2}.jpg";
                 $status = PictureAuditModel::isaudit($src2, $pictype);
                 if (isset($pic_status) && $status == $pic_status) {
                     $srcArr[] = array("src" => $src, "srconerror" => $srconerror, "ebayid" => $src2, "scanuser" => $scanuser, "scantime" => $times, "stype" => "cz");
                 } else {
                     $audited += 1;
                 }
             }
             $srcArr['audited'] = $audited;
             return $srcArr;
         } else {
             return false;
         }
     }
     if (empty($ordersn) && $pictype == 'fh') {
         $picArr = CommonModel::getfhPicture($ordersn, $starttime, $endtime, $scanuser, $limit);
         //複核
         self::$errCode = $picArr['res_code'];
         self::$errMsg = "{$picArr['res_msg']}";
         //var_dump($picArr);
         if ($picArr['data']) {
             $audited = 0;
             foreach ($picArr['data'] as $value) {
                 $amount = $value['amount'];
                 $times = $value['scantime'];
                 //時間戳轉時間格式
                 $src1 = date("Y/m/d", "{$times}");
                 $src2 = $value['ebay_id'];
                 $src = self::$fh . $src1 . "/fh_" . $src2 . ".jpg";
                 /* $isright	=get_headers($src);
                 			if(!preg_match('/200/',$isright[0])){
                 				$src="http://fh.valsun.cn/$src1/fh_$src2.jpg";
                 			} */
                 $srconerror = "http://fh.valsun.cn/{$src1}/fh_{$src2}.jpg";
                 $status = PictureAuditModel::isaudit($src2, $pictype);
                 if (isset($pic_status) && $status == $pic_status) {
                     $srcArr[] = array("src" => $src, "srconerror" => $srconerror, "ebayid" => $src2, "scanuser" => $scanuser, "scantime" => $times, "stype" => "fh", "amount" => $amount);
                 } else {
                     $audited = $audited + 1;
                 }
             }
             $srcArr['audited'] = $audited;
             return $srcArr;
         } else {
             return false;
         }
         //var_dump($srcArr);exit;
         //return $srcArr;
     }
     if (!empty($ordersn)) {
         $srcArr = array();
         $picArr1 = CommonModel::getfhPicture($ordersn, "", "", "", "");
         //複核
         if (!empty($picArr1['data'])) {
             foreach ($picArr1['data'] as $value) {
                 $amount = $value['amount'];
                 $scanuser = $value['user'];
                 $times = $value['scantime'];
                 //時間戳轉時間格式
                 $src1 = date("Y/m/d", "{$times}");
                 $src2 = $value['ebay_id'];
                 $src = self::$fh . $src1 . "/fh_" . $src2 . ".jpg";
                 /* $isright	=get_headers($src);
                 			if(!preg_match('/200/',$isright[0])){
                 				$src="http://fh.valsun.cn/$src1/fh_$src2.jpg";
                 			} */
                 $srconerror = "http://fh.valsun.cn/{$src1}/fh_{$src2}.jpg";
                 //$status		=	PictureAuditModel::isaudit($src2);
                 $srcArr[] = array("src" => $src, "srconerror" => $srconerror, "ebayid" => $src2, "scanuser" => $scanuser, "scantime" => $times, "stype" => "fh", "amount" => $amount);
             }
         }
         $picArr2 = CommonModel::getczPicture($ordersn, "", "", "", "");
         //稱重
         if (!empty($picArr2['data'])) {
             foreach ($picArr2['data'] as $value) {
                 $scanuser = $value['packinguser'];
                 $times = $value['scantime'];
                 //時間戳轉時間格式
                 $src1 = date("Y/m/d", "{$times}");
                 $src2 = $value['ebay_id'];
//.........這裏部分代碼省略.........
開發者ID:ohjack,項目名稱:newErp,代碼行數:101,代碼來源:pictureAudit.action.php


注:本文中的CommonModel::getfhPicture方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。