commit | author | age
|
90c639
|
1 |
<?php |
Z |
2 |
|
|
3 |
namespace app\models; |
|
4 |
|
|
5 |
use Yii; |
|
6 |
|
|
7 |
/** |
|
8 |
* This is the model class for table "{{%goods_share}}". |
|
9 |
* |
|
10 |
* @property int $id |
|
11 |
* @property string $share_commission_first 一级分销佣金比例 |
|
12 |
* @property string $share_commission_second 二级分销佣金比例 |
|
13 |
* @property string $share_commission_third 三级分销佣金比例 |
|
14 |
* @property int $goods_id |
|
15 |
* @property int $goods_attr_id |
|
16 |
* @property int $is_delete |
|
17 |
* @property int $level 分销商等级 |
|
18 |
*/ |
|
19 |
class GoodsShare extends ModelActiveRecord |
|
20 |
{ |
|
21 |
/** |
|
22 |
* {@inheritdoc} |
|
23 |
*/ |
|
24 |
public static function tableName() |
|
25 |
{ |
|
26 |
return '{{%goods_share}}'; |
|
27 |
} |
|
28 |
|
|
29 |
/** |
|
30 |
* {@inheritdoc} |
|
31 |
*/ |
|
32 |
public function rules() |
|
33 |
{ |
|
34 |
return [ |
|
35 |
[['share_commission_first', 'share_commission_second', 'share_commission_third'], 'number'], |
|
36 |
[['goods_id'], 'required'], |
|
37 |
[['goods_id', 'goods_attr_id', 'is_delete', 'level'], 'integer'], |
|
38 |
]; |
|
39 |
} |
|
40 |
|
|
41 |
/** |
|
42 |
* {@inheritdoc} |
|
43 |
*/ |
|
44 |
public function attributeLabels() |
|
45 |
{ |
|
46 |
return [ |
|
47 |
'id' => 'ID', |
|
48 |
'share_commission_first' => '一级分销佣金比例', |
|
49 |
'share_commission_second' => '二级分销佣金比例', |
|
50 |
'share_commission_third' => '三级分销佣金比例', |
|
51 |
'goods_id' => 'Goods ID', |
|
52 |
'goods_attr_id' => 'Goods Attr ID', |
|
53 |
'is_delete' => 'Is Delete', |
|
54 |
'level' => '分销商等级', |
|
55 |
]; |
|
56 |
} |
|
57 |
} |