Browse Source

订单商品表增加sku_id字段

wechat_public_accounts
linyaostalker 5 years ago
parent
commit
1f04774af5
  1. 4
      common/models/ars/OrderGoods.php

4
common/models/ars/OrderGoods.php

@ -20,6 +20,7 @@ use yii\behaviors\TimestampBehavior;
* @property int $updated_at 更新时间 * @property int $updated_at 更新时间
* @property int $created_at 创建时间 * @property int $created_at 创建时间
* @property int $weight 重量 * @property int $weight 重量
* @property int $sku_id sku_id
*/ */
class OrderGoods extends \yii\db\ActiveRecord class OrderGoods extends \yii\db\ActiveRecord
{ {
@ -38,7 +39,7 @@ class OrderGoods extends \yii\db\ActiveRecord
{ {
return [ return [
[['order_id', 'goods_id'], 'required'], [['order_id', 'goods_id'], 'required'],
[['order_id', 'goods_id', 'goods_img', 'goods_count', 'price', 'market_price', 'weight'], 'integer'],
[['order_id', 'goods_id', 'goods_img', 'goods_count', 'price', 'market_price', 'weight', 'sku_id'], 'integer'],
[['goods_name', 'sku_value'], 'string', 'max' => 120], [['goods_name', 'sku_value'], 'string', 'max' => 120],
]; ];
} }
@ -61,6 +62,7 @@ class OrderGoods extends \yii\db\ActiveRecord
'updated_at' => '更新时间', 'updated_at' => '更新时间',
'created_at' => '创建时间', 'created_at' => '创建时间',
'weight' => '重量', 'weight' => '重量',
'sku_id' => 'sku_id',
]; ];
} }

Loading…
Cancel
Save