!27 妙选商城库存同步推送修改

Merge pull request !27 from develop
This commit is contained in:
赵世界 2022-08-18 05:58:40 +00:00 committed by Gitee
commit 2e37befdda
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 3 additions and 2 deletions

View File

@ -18,13 +18,14 @@ class Goods
public static function incrQuantity($shopId, $quantity, $businessGoods)
{
[$goodsCode, $skuCode] = explode('_', $businessGoods['external_sku_id']);
return [
'data' => [
'stock' => $quantity,
'business_sku_id' => $businessGoods['sku_id'],
'business_goods_id' => $businessGoods['goods_id'],
'erp_shop_id' => $shopId,
'erp_sku_id' => $businessGoods['external_sku_id'],
'erp_sku_id' => $skuCode,
],
'type' => '更新库存',
];

View File

@ -20,7 +20,7 @@ class CreateUsersTable extends Migration
$table->string('email')->nullable()->unique();
$table->timestamp('email_verified_at')->nullable();
$table->string('password');
$table->string('api_token', 80)->unique()->nullable(false);
$table->string('api_token', 80)->unique();
$table->softDeletes();
$table->rememberToken();
$table->timestamps();