add contract for product and refund parse
This commit is contained in:
@@ -10,7 +10,7 @@ use App\Platform\Shopee\Constants\ReturnStatus as ShopeeReturnStatus;
|
||||
use App\Model\Company;
|
||||
use App\Model\Order;
|
||||
use App\Model\Store;
|
||||
use App\Entity\Parse\EntityParse;
|
||||
use App\Platform\AbstractRefundParse;
|
||||
use Carbon\Carbon;
|
||||
use Hyperf\Collection\LazyCollection;
|
||||
use InvalidArgumentException;
|
||||
@@ -21,7 +21,7 @@ use InvalidArgumentException;
|
||||
* Shopee 具有完整的父子退款结构:一个 return 包含多个 item。
|
||||
* 每个 return 同时写入 refunds(主记录)和 refund_items(明细)两张表。
|
||||
*/
|
||||
class Refund extends EntityParse
|
||||
class Refund extends AbstractRefundParse
|
||||
{
|
||||
/**
|
||||
* 缓存 entityMap 中查询到的订单日期映射,供 formatRefundItemsFromRaw 复用
|
||||
@@ -178,7 +178,7 @@ class Refund extends EntityParse
|
||||
* @param array $platform_refund_id_to_local_refund_id_map [platform_refund_id => local db refund id]
|
||||
* @return array
|
||||
*/
|
||||
public function formatRefundItemsFromRaw(array $raw_data, array $platform_refund_id_to_local_refund_id_map): array
|
||||
public function formatRefundItemsFromRaw(array $raw_data, ?array $platform_refund_id_to_local_refund_id_map): array
|
||||
{
|
||||
$records = isset($raw_data[0]) ? $raw_data : [$raw_data];
|
||||
$items = [];
|
||||
|
||||
Reference in New Issue
Block a user