From b795ba8f9a376fceb0e26627ddf1139da9250c87 Mon Sep 17 00:00:00 2001 From: linyao <602604991@qq.com> Date: Tue, 12 Nov 2019 14:01:47 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9B=E5=BB=BA=E5=95=86=E5=93=81=E9=83=A8?= =?UTF-8?q?=E5=88=86=E3=80=81=E5=9F=BA=E7=A1=80=E9=83=A8=E5=88=86=E3=80=81?= =?UTF-8?q?=E4=B8=AA=E4=BA=BA=E9=83=A8=E5=88=86=E3=80=81=E8=AE=A2=E5=8D=95?= =?UTF-8?q?=E9=83=A8=E5=88=86=E3=80=81=E6=94=AF=E4=BB=98=E9=83=A8=E5=88=86?= =?UTF-8?q?=E3=80=81=E6=96=87=E4=BB=B6=E9=83=A8=E5=88=86=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E8=A1=A8model=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- common/models/ars/Address.php | 86 +++++++++++++++++ common/models/ars/AfterSale.php | 78 +++++++++++++++ common/models/ars/Area.php | 50 ++++++++++ common/models/ars/Attribute.php | 79 +++++++++++++++ common/models/ars/Brand.php | 72 ++++++++++++++ common/models/ars/Cart.php | 82 ++++++++++++++++ common/models/ars/Category.php | 85 ++++++++++++++++ common/models/ars/City.php | 50 ++++++++++ common/models/ars/Collection.php | 71 ++++++++++++++ common/models/ars/Comment.php | 78 +++++++++++++++ common/models/ars/Delivery.php | 84 ++++++++++++++++ common/models/ars/ExpressTemplate.php | 93 ++++++++++++++++++ common/models/ars/File.php | 85 ++++++++++++++++ common/models/ars/FilterAttr.php | 76 +++++++++++++++ common/models/ars/Goods.php | 133 ++++++++++++++++++++++++++ common/models/ars/GoodsAttr.php | 76 +++++++++++++++ common/models/ars/GoodsSku.php | 103 ++++++++++++++++++++ common/models/ars/Order.php | 119 +++++++++++++++++++++++ common/models/ars/OrderGoods.php | 84 ++++++++++++++++ common/models/ars/PaymentLog.php | 84 ++++++++++++++++ common/models/ars/Province.php | 48 ++++++++++ common/models/ars/RefundLog.php | 70 ++++++++++++++ common/models/ars/SearchHistory.php | 78 +++++++++++++++ common/models/ars/ShopCategory.php | 94 ++++++++++++++++++ common/models/ars/Supplier.php | 79 +++++++++++++++ common/models/ars/TakingSite.php | 82 ++++++++++++++++ common/models/ars/TemFile.php | 79 +++++++++++++++ 27 files changed, 2198 insertions(+) create mode 100644 common/models/ars/Address.php create mode 100644 common/models/ars/AfterSale.php create mode 100644 common/models/ars/Area.php create mode 100644 common/models/ars/Attribute.php create mode 100644 common/models/ars/Brand.php create mode 100644 common/models/ars/Cart.php create mode 100644 common/models/ars/Category.php create mode 100644 common/models/ars/City.php create mode 100644 common/models/ars/Collection.php create mode 100644 common/models/ars/Comment.php create mode 100644 common/models/ars/Delivery.php create mode 100644 common/models/ars/ExpressTemplate.php create mode 100644 common/models/ars/File.php create mode 100644 common/models/ars/FilterAttr.php create mode 100644 common/models/ars/Goods.php create mode 100644 common/models/ars/GoodsAttr.php create mode 100644 common/models/ars/GoodsSku.php create mode 100644 common/models/ars/Order.php create mode 100644 common/models/ars/OrderGoods.php create mode 100644 common/models/ars/PaymentLog.php create mode 100644 common/models/ars/Province.php create mode 100644 common/models/ars/RefundLog.php create mode 100644 common/models/ars/SearchHistory.php create mode 100644 common/models/ars/ShopCategory.php create mode 100644 common/models/ars/Supplier.php create mode 100644 common/models/ars/TakingSite.php create mode 100644 common/models/ars/TemFile.php diff --git a/common/models/ars/Address.php b/common/models/ars/Address.php new file mode 100644 index 0000000..b7b9ad9 --- /dev/null +++ b/common/models/ars/Address.php @@ -0,0 +1,86 @@ + 20], + [['province', 'city', 'area'], 'string', 'max' => 10], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'user_id' => '用户id', + 'consignee' => '收件人', + 'phone' => '电话', + 'province' => '省份', + 'city' => '城市', + 'area' => '区域', + 'address' => '详细地址', + 'status' => '状态,0-默认值 1-默认地址', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/AfterSale.php b/common/models/ars/AfterSale.php new file mode 100644 index 0000000..4f0cced --- /dev/null +++ b/common/models/ars/AfterSale.php @@ -0,0 +1,78 @@ + 64], + [['take_shipping_sn', 'send_shipping_sn'], 'string', 'max' => 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'operator_id' => '操作者', + 'user_id' => '用户id', + 'wx_refund_id' => '微信退款单号', + 'after_sale_sn' => '售后单号', + 'order_goods_id' => '订单商品id', + 'count' => '退换货的商品数量', + 'amount' => '退货时实际退的金额', + 'type' => '类型', + 'reason' => '退换货理由', + 'description' => '描述', + 'take_shipping_sn' => '用户发货物流单号', + 'send_shipping_sn' => '换货商家发货的物流单号', + 'remarks' => '店家备注', + 'applyed_at' => '申请时间', + 'dealed_at' => '处理时间', + 'finished_at' => '完成时间', + ]; + } + +} diff --git a/common/models/ars/Area.php b/common/models/ars/Area.php new file mode 100644 index 0000000..e42ee4f --- /dev/null +++ b/common/models/ars/Area.php @@ -0,0 +1,50 @@ + 32], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => 'name', + 'area_id' => 'area_id', + 'city_id' => 'city_id', + ]; + } + +} diff --git a/common/models/ars/Attribute.php b/common/models/ars/Attribute.php new file mode 100644 index 0000000..664fb60 --- /dev/null +++ b/common/models/ars/Attribute.php @@ -0,0 +1,79 @@ + 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '属性名', + 'value' => '属性值', + 'type' => '类型', + 'sort_order' => '排序', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Brand.php b/common/models/ars/Brand.php new file mode 100644 index 0000000..cbe1618 --- /dev/null +++ b/common/models/ars/Brand.php @@ -0,0 +1,72 @@ + 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '品牌名', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Cart.php b/common/models/ars/Cart.php new file mode 100644 index 0000000..3af30be --- /dev/null +++ b/common/models/ars/Cart.php @@ -0,0 +1,82 @@ + 120], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'user_id' => '用户id', + 'goods_id' => '商品id', + 'goods_name' => '商品名称', + 'goods_img' => '商品图片', + 'goods_price' => '商品售价', + 'sku_id' => '商品sku的id', + 'goods_count' => '商品数量', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Category.php b/common/models/ars/Category.php new file mode 100644 index 0000000..3e67792 --- /dev/null +++ b/common/models/ars/Category.php @@ -0,0 +1,85 @@ + 60], + [['icon'], 'string', 'max' => 64], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '类别名称', + 'pid' => '父级id', + 'goods_count' => '商品数量', + 'sort_order' => '排序', + 'icon_type' => '图标类型', + 'icon' => '图标', + 'is_show' => '是否显示,1为不显示', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/City.php b/common/models/ars/City.php new file mode 100644 index 0000000..3b4096f --- /dev/null +++ b/common/models/ars/City.php @@ -0,0 +1,50 @@ + 32], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'city_id' => 'city_id', + 'name' => 'name', + 'province_id' => 'province_id', + ]; + } + +} diff --git a/common/models/ars/Collection.php b/common/models/ars/Collection.php new file mode 100644 index 0000000..69937f3 --- /dev/null +++ b/common/models/ars/Collection.php @@ -0,0 +1,71 @@ + 'id', + 'user_id' => '用户id', + 'goods_id' => '商品id', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Comment.php b/common/models/ars/Comment.php new file mode 100644 index 0000000..2fe43aa --- /dev/null +++ b/common/models/ars/Comment.php @@ -0,0 +1,78 @@ + 'id', + 'user_id' => '用户id', + 'order_goods_id' => '订单详情商品id', + 'star' => '星级', + 'content' => '评论内容', + 'status' => '状态:1为显示,0为不显示', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Delivery.php b/common/models/ars/Delivery.php new file mode 100644 index 0000000..e9760bd --- /dev/null +++ b/common/models/ars/Delivery.php @@ -0,0 +1,84 @@ + 50], + [['shipping_id'], 'string', 'max' => 10], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'order_id' => '订单id', + 'shipping_name' => '货流名称', + 'shipping_id' => '运货单位', + 'type' => '类型', + 'goods' => '商品', + 'status' => '状态', + 'decription' => '描述', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/ExpressTemplate.php b/common/models/ars/ExpressTemplate.php new file mode 100644 index 0000000..d91b966 --- /dev/null +++ b/common/models/ars/ExpressTemplate.php @@ -0,0 +1,93 @@ + 255], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '名称', + 'province' => '省份', + 'city' => '城市', + 'area' => '区域', + 'billing_type' => '账单类型', + 'extra_weight_type' => '续重重量类型', + 'exemption_type' => '包邮类型', + 'basic_price' => '基本运费', + 'extra_price' => '续重运费', + 'exemption_amount' => '包邮金额', + 'support_taking' => '是否支持自提,1为不支持', + 'taking_site' => '自提地点', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/File.php b/common/models/ars/File.php new file mode 100644 index 0000000..c58b34e --- /dev/null +++ b/common/models/ars/File.php @@ -0,0 +1,85 @@ + 255], + [['alias'], 'string', 'max' => 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'pid' => '父级id', + 'name' => '名称', + 'type' => '类型', + 'own_type' => '拥有者类型', + 'own_id' => '拥有者id', + 'alias' => '别名', + 'path' => '地址', + 'is_delete' => '是否删除,1为已删除', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/FilterAttr.php b/common/models/ars/FilterAttr.php new file mode 100644 index 0000000..95d6513 --- /dev/null +++ b/common/models/ars/FilterAttr.php @@ -0,0 +1,76 @@ + 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'goods_id' => '商品id', + 'attr_id' => '属性id', + 'attr_value' => '属性值', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Goods.php b/common/models/ars/Goods.php new file mode 100644 index 0000000..8b7aa93 --- /dev/null +++ b/common/models/ars/Goods.php @@ -0,0 +1,133 @@ + 120], + [['sn'], 'string', 'max' => 60], + [['code'], 'string', 'max' => 50], + [['unit'], 'string', 'max' => 16], + [['brief'], 'string', 'max' => 255], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'pid' => '父级id', + 'cat_id' => '后台商品类别id', + 'brand_id' => '品牌id', + 'shop_cat_id' => '前端商品类别id', + 'name' => '商品名称', + 'sn' => '商品唯一货号', + 'code' => '商品货码', + 'supplier_id' => '供应商id', + 'weight' => '重量', + 'length' => '长度', + 'width' => '宽度', + 'height' => '高度', + 'diameter' => '直径', + 'unit' => '单位', + 'sold_count' => '已售数量', + 'limit_count' => '限购数量', + 'stock' => '库存', + 'stock_warn' => '库存警告', + 'market_price' => '市场价', + 'price' => '销售价', + 'brief' => '简介', + 'description' => '详细介绍', + 'image' => '图片id', + 'model_id' => '模型id', + 'is_sale' => '该商品是否开放销售,1为是,0为否', + 'sort_order' => '排序', + 'bouns_points' => '奖励积分', + 'experience_points' => '经验值', + 'is_delete' => '是否删除,1为已删除', + 'express_template' => '配送详情id', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/GoodsAttr.php b/common/models/ars/GoodsAttr.php new file mode 100644 index 0000000..1a96b10 --- /dev/null +++ b/common/models/ars/GoodsAttr.php @@ -0,0 +1,76 @@ + 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'goods_id' => '商品id', + 'attr_id' => '属性id', + 'attr_value' => '属性名', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/GoodsSku.php b/common/models/ars/GoodsSku.php new file mode 100644 index 0000000..8d523fc --- /dev/null +++ b/common/models/ars/GoodsSku.php @@ -0,0 +1,103 @@ + 50], + [['goods_sn', 'goods_attr'], 'string', 'max' => 60], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'goods_id' => '商品id', + 'goods_code' => '商品条码', + 'goods_sn' => '商品唯一货号', + 'goods_attr' => '属性匹配', + 'weight' => '重量', + 'length' => '长度', + 'width' => '宽度', + 'height' => '高度', + 'diameter' => '直径', + 'sold_count' => '已售数量', + 'stock' => '库存', + 'market_price' => '市场价', + 'price' => '销售价', + 'model_id' => '模型id', + 'is_sale' => '该商品是否开放销售,1为是,0为否', + 'sort_order' => '排序', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Order.php b/common/models/ars/Order.php new file mode 100644 index 0000000..c74f2b0 --- /dev/null +++ b/common/models/ars/Order.php @@ -0,0 +1,119 @@ + 64], + [['consignee', 'phone'], 'string', 'max' => 20], + [['province', 'city', 'area'], 'string', 'max' => 10], + [['payment_sn'], 'string', 'max' => 120], + [['remarks'], 'string', 'max' => 255], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'user_id' => '用户id', + 'order_sn' => '订单号', + 'invoice_id' => '发票单号', + 'status' => '状态', + 'type' => '类型', + 'goods_count' => '商品数量', + 'goods_amount' => '商品金额', + 'shipping_amount' => '物流金额', + 'shipping_type' => '物流类型', + 'consignee' => '收件人', + 'phone' => '手机号码', + 'province' => '省份', + 'city' => '城市', + 'area' => '区域', + 'taking_site' => '自提点', + 'pay_type' => '支付方式', + 'pay_at' => '支付时间', + 'payment_sn' => '付款单号', + 'payment_amount' => '支付金额', + 'receivables' => '应收款', + 'remarks' => '备注', + 'discount_amount' => '折扣金额', + 'discount_decription' => '折扣说明', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/OrderGoods.php b/common/models/ars/OrderGoods.php new file mode 100644 index 0000000..f98ceea --- /dev/null +++ b/common/models/ars/OrderGoods.php @@ -0,0 +1,84 @@ + 120], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'order_id' => '订单id', + 'goods_id' => '商品id', + 'goods_img' => '商品图片', + 'goods_name' => '商品名称', + 'goods_count' => '商品数量', + 'sku_value' => '商品sku', + 'price' => '销售价', + 'market_price' => '市场价', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/PaymentLog.php b/common/models/ars/PaymentLog.php new file mode 100644 index 0000000..ad85810 --- /dev/null +++ b/common/models/ars/PaymentLog.php @@ -0,0 +1,84 @@ + 64], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'order_id' => '订单id', + 'wx_refund_id' => '微信退款单号', + 'mch_id' => '商户号', + 'order_amount' => '订单金额', + 'payment_amount' => '支付金额', + 'type' => '类型', + 'status' => '状态', + 'refund_account' => '退款账户', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Province.php b/common/models/ars/Province.php new file mode 100644 index 0000000..26506c4 --- /dev/null +++ b/common/models/ars/Province.php @@ -0,0 +1,48 @@ + 16], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => 'name', + 'province_id' => 'province_id', + ]; + } + +} diff --git a/common/models/ars/RefundLog.php b/common/models/ars/RefundLog.php new file mode 100644 index 0000000..9f281b8 --- /dev/null +++ b/common/models/ars/RefundLog.php @@ -0,0 +1,70 @@ + 64], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'order_id' => '订单id', + 'wx_refund_id' => '微信退款单号', + 'reason' => '理由', + 'order_amount' => '订单金额', + 'refund_amount' => '退款金额', + 'refunded_amount' => '已退款金额', + 'type' => '类型', + 'status' => '状态', + 'refund_account' => '退款账户', + 'operator_id' => '操作者', + 'applyed_at' => '申请时间', + 'confirmed_at' => '确认时间', + 'finished_at' => '完成时间', + ]; + } + +} diff --git a/common/models/ars/SearchHistory.php b/common/models/ars/SearchHistory.php new file mode 100644 index 0000000..6be7b5f --- /dev/null +++ b/common/models/ars/SearchHistory.php @@ -0,0 +1,78 @@ + 255], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'user_id' => '用户id', + 'keyword' => '关键字', + 'count' => '次数', + 'status' => '状态', + 'type' => '类型', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/ShopCategory.php b/common/models/ars/ShopCategory.php new file mode 100644 index 0000000..5df7d3d --- /dev/null +++ b/common/models/ars/ShopCategory.php @@ -0,0 +1,94 @@ + 60], + [['keywords'], 'string', 'max' => 100], + [['desc'], 'string', 'max' => 255], + [['icon'], 'string', 'max' => 64], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '类别名称', + 'pid' => '父级id', + 'goods_count' => '商品数量', + 'keywords' => '关键字', + 'desc' => '描述', + 'sort_order' => '排序', + 'icon_type' => '图标类型', + 'icon' => '图标', + 'filter_attr' => '筛选属性', + 'is_show' => '是否显示,1为不显示', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/Supplier.php b/common/models/ars/Supplier.php new file mode 100644 index 0000000..6733a35 --- /dev/null +++ b/common/models/ars/Supplier.php @@ -0,0 +1,79 @@ + 50], + [['phone'], 'string', 'max' => 20], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '供应商名称', + 'full_name' => '供应商全称', + 'phone' => '手机号码', + 'address' => '地址', + 'is_delete' => '是否删除,1为已删除', + 'created_at' => '创建时间', + 'updated_at' => '更新时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/TakingSite.php b/common/models/ars/TakingSite.php new file mode 100644 index 0000000..f147e62 --- /dev/null +++ b/common/models/ars/TakingSite.php @@ -0,0 +1,82 @@ + 120], + [['province', 'city', 'area'], 'string', 'max' => 10], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'name' => '名称', + 'province' => '省份', + 'city' => '城市', + 'area' => '区域', + 'address' => '地址', + 'is_default' => '是否为默认,1为默认', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +} diff --git a/common/models/ars/TemFile.php b/common/models/ars/TemFile.php new file mode 100644 index 0000000..df9bab0 --- /dev/null +++ b/common/models/ars/TemFile.php @@ -0,0 +1,79 @@ + 255], + [['alias'], 'string', 'max' => 50], + ]; + } + + /** + * {@inheritdoc} + */ + public function attributeLabels() + { + return [ + 'id' => 'id', + 'user_id' => '父级id', + 'name' => '名称', + 'type' => '类型', + 'alias' => '别名', + 'path' => '地址', + 'updated_at' => '更新时间', + 'created_at' => '创建时间', + ]; + } + + /** + * @author linyao + * @email 602604991@qq.com + * @created Nov 8, 2019 + * + * 行为存储创建时间和更新时间 + */ + public function behaviors() + { + return [ + [ + 'class' => TimestampBehavior::className(), + 'createdAtAttribute' => 'created_at', + 'updatedAtAttribute' => 'updated_at', + 'value' => function() { + return time(); + }, + ], + ]; + } +}