|
|
@@ -157,14 +157,20 @@ class Whlabelfz1 extends Start_Controller
|
|
|
exit(json_encode(['code'=>-1,'msg'=>'扫描数量不能大于2000','data'=>[],JSON_UNESCAPED_UNICODE]));
|
|
|
}
|
|
|
}
|
|
|
- $info = $this->whlabel_bh_scan->find("label ='".$label."'");
|
|
|
- if(!empty($info)){
|
|
|
- exit(json_encode(['code'=>-1,'msg'=>'该标签已被扫描','data'=>[],JSON_UNESCAPED_UNICODE]));
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
if($type == 1){
|
|
|
+ $info = $this->whlabel_bh_scan->find("label ='".$label."'");
|
|
|
+ if(!empty($info)){
|
|
|
+ exit(json_encode(['code'=>-1,'msg'=>'该标签已被扫描','data'=>[],JSON_UNESCAPED_UNICODE]));
|
|
|
+ }
|
|
|
$res = $this->_bbscan($orderinfo,$label);
|
|
|
}elseif($type == 2){
|
|
|
+ $start_time = strtotime(date("Y-m-d"),time());
|
|
|
+ $info = $this->whlabel_bh_scan->find("label ='".$label."' and scantime >= ");
|
|
|
+ if(!empty($info)){
|
|
|
+ exit(json_encode(['code'=>-1,'msg'=>'该标签已被扫描','data'=>[],JSON_UNESCAPED_UNICODE]));
|
|
|
+ }
|
|
|
$res = $this->_bqscan($orderinfo,$label,$num);
|
|
|
}
|
|
|
|