Browse Source

商品拍照识别,图片搜索商品

lizhen_gitee 11 months ago
parent
commit
0518ce7b7b
1 changed files with 4 additions and 0 deletions
  1. 4 0
      addons/unishop/controller/Product.php

+ 4 - 0
addons/unishop/controller/Product.php

@@ -149,6 +149,10 @@ class Product extends Base
         $image = input('image','');
         if(!empty($image)){
             $keyword = $this->search_by_image($image);
+            //dump($keyword);
+            if(empty($keyword)){
+                $this->success('', []);
+            }
         }
 
         $productModel = new productModel();