model update

This commit is contained in:
2026-02-10 13:07:55 +08:00
parent 2e0559227c
commit 8230f5e859
2 changed files with 12 additions and 36 deletions
+4 -15
View File
@@ -15,31 +15,20 @@ use Hyperf\DbConnection\Model\Model;
* @property string $platform_order_id 平台订单 ID * @property string $platform_order_id 平台订单 ID
* @property string $platform_refund_id 平台退款单 ID * @property string $platform_refund_id 平台退款单 ID
* @property int $refund_status_id 退款状态 ID * @property int $refund_status_id 退款状态 ID
* @property int $refund_status_id 退款状态 ID
* @property int $refund_status_id 退款状态 ID
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款 * @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property string $reason 退款原因 * @property string $reason 退款原因
* @property string $refund_amount 退款金额 * @property string $refund_amount 退款金额
* @property string $freight_refund 退运费金额 * @property string $freight_refund 退运费金额
* @property string $refund_total 退款合计金额,为退款金额+退运费金额,为主要参与聚合计算的字段 * @property string $refund_total 退款合计金额,为退款金额+退运费金额,为主要参与聚合计算的字段
* @property string $refund_total 退款合计金额,为退款金额+退运费金额,为主要参与聚合计算的字段
* @property string $refund_total 退款合计金额,为退款金额+退运费金额,为主要参与聚合计算的字段
* @property string $currency 币种
* @property string $currency 币种
* @property string $currency 币种
* @property string $currency 币种 * @property string $currency 币种
* @property string $buyer_user_id 平台买家 ID * @property string $buyer_user_id 平台买家 ID
* @property string $order_created_date 关联订单的创建时间 * @property string $order_created_date 关联订单的创建时间
* @property string $order_paid_date 关联订单的付款时间 * @property string $order_paid_date 关联订单的付款时间
* @property string $created_date 退款单在平台的创建时间 * @property string $created_date 退款单在平台的创建时间
* @property string $created_date 退款单在平台的创建时间
* @property string $updated_date 退款单在平台的更新时间 * @property string $updated_date 退款单在平台的更新时间
* @property string $completed_date 退款完成时间 * @property string $completed_date 退款完成时间
* @property string $completed_date 退款完成时间 * @property array $raw 平台返回的原始数据
* @property string $raw 平台返回的原始数据 * @property array $ext 扩展字段
* @property string $ext 扩展字段
* @property string $hash raw 字段的 MD5 哈希值,用于检测数据变化 * @property string $hash raw 字段的 MD5 哈希值,用于检测数据变化
* @property \Carbon\Carbon $created_at * @property \Carbon\Carbon $created_at
* @property \Carbon\Carbon $updated_at * @property \Carbon\Carbon $updated_at
@@ -55,10 +44,10 @@ class Refund extends Model
/** /**
* The attributes that are mass assignable. * The attributes that are mass assignable.
*/ */
protected array $fillable = ['id', 'company_id', 'platform_id', 'store_id', 'order_id', 'platform_order_id', 'platform_refund_id', 'refund_status_id', 'refund_status_id', 'refund_status_id', 'refund_type_id', 'refund_type_id', 'refund_type_id', 'reason', 'refund_amount', 'freight_refund', 'refund_total', 'refund_total', 'refund_total', 'currency', 'currency', 'currency', 'currency', 'buyer_user_id', 'order_created_date', 'order_paid_date', 'created_date', 'created_date', 'updated_date', 'completed_date', 'completed_date', 'raw', 'ext', 'hash', 'created_at', 'updated_at']; protected array $fillable = ['id', 'company_id', 'platform_id', 'store_id', 'order_id', 'platform_order_id', 'platform_refund_id', 'refund_status_id', 'refund_type_id', 'reason', 'refund_amount', 'freight_refund', 'refund_total', 'currency', 'buyer_user_id', 'order_created_date', 'order_paid_date', 'created_date', 'updated_date', 'completed_date', 'raw', 'ext', 'hash', 'created_at', 'updated_at'];
/** /**
* The attributes that should be cast to native types. * The attributes that should be cast to native types.
*/ */
protected array $casts = ['id' => 'integer', 'company_id' => 'integer', 'platform_id' => 'integer', 'store_id' => 'integer', 'order_id' => 'integer', 'refund_status_id' => 'integer', 'refund_status_id' => 'integer', 'refund_status_id' => 'integer', 'refund_type_id' => 'integer', 'refund_type_id' => 'integer', 'refund_type_id' => 'integer', 'created_at' => 'datetime', 'updated_at' => 'datetime']; protected array $casts = ['id' => 'integer', 'company_id' => 'integer', 'platform_id' => 'integer', 'store_id' => 'integer', 'order_id' => 'integer', 'refund_status_id' => 'integer', 'refund_type_id' => 'integer', 'raw' => 'json', 'ext' => 'json', 'created_at' => 'datetime', 'updated_at' => 'datetime'];
} }
+4 -17
View File
@@ -13,37 +13,24 @@ use Hyperf\DbConnection\Model\Model;
* @property int $store_id 店铺 ID * @property int $store_id 店铺 ID
* @property int $refund_id 关联本地 refunds 表 ID,业务层保证约束 * @property int $refund_id 关联本地 refunds 表 ID,业务层保证约束
* @property string $platform_parent_refund_id 平台父退款 ID, Tmall 售后单体系中的无此信息,使用默认值 * @property string $platform_parent_refund_id 平台父退款 ID, Tmall 售后单体系中的无此信息,使用默认值
* @property string $platform_parent_refund_id 平台父退款 ID, Tmall 售后单体系中的无此信息,使用默认值
* @property string $platform_refund_id 平台退款子项 ID,如 Tmall 售后单 ID
* @property string $platform_refund_id 平台退款子项 ID,如 Tmall 售后单 ID * @property string $platform_refund_id 平台退款子项 ID,如 Tmall 售后单 ID
* @property int $refund_status_id 退款状态 ID * @property int $refund_status_id 退款状态 ID
* @property int $refund_status_id 退款状态 ID
* @property int $refund_status_id 退款状态 ID
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款 * @property int $refund_type_id 退款类型:1 仅退款 2 退货退款 3 补偿退款
* @property string $reason 退款原因 * @property string $reason 退款原因
* @property string $currency 币种 * @property string $currency 币种
* @property string $currency 币种
* @property string $currency 币种
* @property string $currency 币种
* @property string $buyer_user_id 平台买家 ID * @property string $buyer_user_id 平台买家 ID
* @property string $platform_order_id 平台订单 ID * @property string $platform_order_id 平台订单 ID
* @property string $platform_sub_order_id 平台子订单 ID * @property string $platform_sub_order_id 平台子订单 ID
* @property string $platform_product_id 平台商品 ID * @property string $platform_product_id 平台商品 ID
* @property int $quantity 退款商品数量 * @property int $quantity 退款商品数量
* @property string $refund_amount 该子项退款金额 * @property string $refund_amount 该子项退款金额
* @property string $refund_amount 该子项退款金额
* @property string $refund_amount 该子项退款金额
* @property string $order_created_date 关联订单的创建时间 * @property string $order_created_date 关联订单的创建时间
* @property string $order_paid_date 关联订单的付款时间 * @property string $order_paid_date 关联订单的付款时间
* @property string $created_date 退款单在平台的创建时间 * @property string $created_date 退款单在平台的创建时间
* @property string $created_date 退款单在平台的创建时间
* @property string $updated_date 退款单在平台的更新时间 * @property string $updated_date 退款单在平台的更新时间
* @property string $completed_date 退款完成时间 * @property string $completed_date 退款完成时间
* @property string $completed_date 退款完成时间 * @property array $raw 平台返回的原始子项数据
* @property string $raw 平台返回的原始子项数据 * @property array $ext 扩展字段
* @property string $ext 扩展字段
* @property \Carbon\Carbon $created_at * @property \Carbon\Carbon $created_at
* @property \Carbon\Carbon $updated_at * @property \Carbon\Carbon $updated_at
* @mixin \App_Model_RefundItem * @mixin \App_Model_RefundItem
@@ -58,10 +45,10 @@ class RefundItem extends Model
/** /**
* The attributes that are mass assignable. * The attributes that are mass assignable.
*/ */
protected array $fillable = ['id', 'company_id', 'platform_id', 'store_id', 'refund_id', 'platform_parent_refund_id', 'platform_parent_refund_id', 'platform_refund_id', 'platform_refund_id', 'refund_status_id', 'refund_status_id', 'refund_status_id', 'refund_type_id', 'refund_type_id', 'refund_type_id', 'reason', 'currency', 'currency', 'currency', 'currency', 'buyer_user_id', 'platform_order_id', 'platform_sub_order_id', 'platform_product_id', 'quantity', 'refund_amount', 'refund_amount', 'refund_amount', 'order_created_date', 'order_paid_date', 'created_date', 'created_date', 'updated_date', 'completed_date', 'completed_date', 'raw', 'ext', 'created_at', 'updated_at']; protected array $fillable = ['id', 'company_id', 'platform_id', 'store_id', 'refund_id', 'platform_parent_refund_id', 'platform_refund_id', 'refund_status_id', 'refund_type_id', 'reason', 'currency', 'buyer_user_id', 'platform_order_id', 'platform_sub_order_id', 'platform_product_id', 'quantity', 'refund_amount', 'order_created_date', 'order_paid_date', 'created_date', 'updated_date', 'completed_date', 'raw', 'ext', 'created_at', 'updated_at'];
/** /**
* The attributes that should be cast to native types. * The attributes that should be cast to native types.
*/ */
protected array $casts = ['id' => 'integer', 'company_id' => 'integer', 'platform_id' => 'integer', 'store_id' => 'integer', 'refund_id' => 'integer', 'refund_status_id' => 'integer', 'refund_status_id' => 'integer', 'refund_status_id' => 'integer', 'refund_type_id' => 'integer', 'refund_type_id' => 'integer', 'refund_type_id' => 'integer', 'quantity' => 'integer', 'created_at' => 'datetime', 'updated_at' => 'datetime']; protected array $casts = ['id' => 'integer', 'company_id' => 'integer', 'platform_id' => 'integer', 'store_id' => 'integer', 'refund_id' => 'integer', 'refund_status_id' => 'integer', 'refund_type_id' => 'integer', 'quantity' => 'integer', 'raw' => 'json', 'ext' => 'json', 'created_at' => 'datetime', 'updated_at' => 'datetime'];
} }