fixed wish list

This commit is contained in:
Edward Yang 2022-07-27 16:59:21 +08:00
parent ef3e5dc70d
commit 3539d32cbc
1 changed files with 7 additions and 4 deletions

View File

@ -105,7 +105,7 @@ class CustomerRepo
}
/**
* @param $customer, Customer对象或id
* @param $customer , Customer对象或id
* @param $productId
* @return Customer|Builder|Builder[]|Collection|Model|mixed|null
*/
@ -120,7 +120,7 @@ class CustomerRepo
}
/**
* @param $customer, Customer对象或id
* @param $customer , Customer对象或id
* @param $productId
* @return void
*/
@ -144,12 +144,15 @@ class CustomerRepo
}
/**
* @param $product, 商品id或对象
* @param $customer, 顾客id或对象
* @param $product , 商品id或对象
* @param $customer , 顾客id或对象
* @return int
*/
public static function inWishlist($product, $customer)
{
if (!$customer) {
return false;
}
if ($product instanceof Product) {
$product = $product->id;
}