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 "{{%assistant_data}}". |
|
9 |
* |
|
10 |
* @property int $id |
|
11 |
* @property int $type 类型 0--淘宝 1--淘宝app |
|
12 |
* @property string $itemId 原始商品id |
|
13 |
* @property string $json 数据 |
|
14 |
* @property string $created_at |
|
15 |
*/ |
|
16 |
class AssistantData extends \app\models\ModelActiveRecord |
|
17 |
{ |
|
18 |
/** |
|
19 |
* {@inheritdoc} |
|
20 |
*/ |
|
21 |
public static function tableName() |
|
22 |
{ |
|
23 |
return '{{%assistant_data}}'; |
|
24 |
} |
|
25 |
|
|
26 |
/** |
|
27 |
* {@inheritdoc} |
|
28 |
*/ |
|
29 |
public function rules() |
|
30 |
{ |
|
31 |
return [ |
|
32 |
[['type'], 'integer'], |
|
33 |
[['json', 'created_at'], 'required'], |
|
34 |
[['json'], 'string'], |
|
35 |
[['created_at'], 'safe'], |
|
36 |
[['itemId'], 'string', 'max' => 255], |
|
37 |
]; |
|
38 |
} |
|
39 |
|
|
40 |
/** |
|
41 |
* {@inheritdoc} |
|
42 |
*/ |
|
43 |
public function attributeLabels() |
|
44 |
{ |
|
45 |
return [ |
|
46 |
'id' => 'ID', |
|
47 |
'type' => '类型 0--淘宝 1--淘宝app', |
|
48 |
'itemId' => '原始商品id', |
|
49 |
'json' => '数据', |
|
50 |
'created_at' => 'Created At', |
|
51 |
]; |
|
52 |
} |
|
53 |
} |