Commit 2721c9fb authored by mengweifu's avatar mengweifu

update:ota manage

parent d0653a77
...@@ -64,7 +64,7 @@ class OtaValidate extends \Validate\BaseValidate ...@@ -64,7 +64,7 @@ class OtaValidate extends \Validate\BaseValidate
} }
protected function is_label_printer_sn($value){ public function is_label_printer_sn($value){
if( substr($value, 3, 1) != '2' ){ if( substr($value, 3, 1) != '2' ){
return false; return false;
} }
......
...@@ -91,6 +91,9 @@ class FeiPrinter extends \Api\PhpServices\Printer\Printer ...@@ -91,6 +91,9 @@ class FeiPrinter extends \Api\PhpServices\Printer\Printer
if (is_array($res['response']['data']['ok']) && count($res['response']['data']['ok']) > 0) { if (is_array($res['response']['data']['ok']) && count($res['response']['data']['ok']) > 0) {
return true; return true;
} }
if (strpos($res['response']['data']['no'][0], '已被添加过')) {
return true;
}
throw new \Exception($res['response']['data']['no'][0]); throw new \Exception($res['response']['data']['no'][0]);
} }
throw new \Exception($res['response']['msg']); throw new \Exception($res['response']['msg']);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment