commit | author | age
|
2207d6
|
1 |
<?php |
W |
2 |
|
|
3 |
namespace app\models; |
|
4 |
|
|
5 |
use Yii; |
|
6 |
|
|
7 |
/** |
|
8 |
* This is the model class for table "{{%template_record}}". |
|
9 |
* |
|
10 |
* @property int $id |
|
11 |
* @property int $mall_id |
|
12 |
* @property int $open_id |
|
13 |
* @property int $status 模板消息是否发送成功0--失败|1--成功 |
|
14 |
* @property string $data 模板消息内容 |
|
15 |
* @property string $error 错误信息 |
|
16 |
* @property string $created_at |
|
17 |
* @property string $token 模板消息发送标示 |
|
18 |
*/ |
|
19 |
class MpTemplateRecord extends ModelActiveRecord |
|
20 |
{ |
|
21 |
/** |
|
22 |
* {@inheritdoc} |
|
23 |
*/ |
|
24 |
public static function tableName() |
|
25 |
{ |
|
26 |
return '{{%mp_template_record}}'; |
|
27 |
} |
|
28 |
|
|
29 |
/** |
|
30 |
* {@inheritdoc} |
|
31 |
*/ |
|
32 |
public function rules() |
|
33 |
{ |
|
34 |
return [ |
|
35 |
[['mall_id', 'open_id'], 'required'], |
|
36 |
[['mall_id', 'status'], 'integer'], |
|
37 |
[['data', 'error'], 'string'], |
|
38 |
[['created_at'], 'safe'], |
|
39 |
[['token', 'open_id'], 'string', 'max' => 255], |
|
40 |
]; |
|
41 |
} |
|
42 |
|
|
43 |
/** |
|
44 |
* {@inheritdoc} |
|
45 |
*/ |
|
46 |
public function attributeLabels() |
|
47 |
{ |
|
48 |
return [ |
|
49 |
'id' => 'ID', |
|
50 |
'mall_id' => 'Mall ID', |
|
51 |
'user_id' => 'User ID', |
|
52 |
'status' => '模板消息是否发送成功0--失败|1--成功', |
|
53 |
'data' => '模板消息内容', |
|
54 |
'error' => '错误信息', |
|
55 |
'created_at' => 'Created At', |
|
56 |
'token' => '模板消息发送标示', |
|
57 |
]; |
|
58 |
} |
|
59 |
} |