| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071 |
- <?php
- namespace common\models;
- /**
- * This is the model class for table "xhLuckyDrawActivity".
- *
- * @property int $id
- * @property string $activityName 活动名称
- * @property int $merchantId 商户Id
- * @property int $startTime 活动开始时间
- * @property int $endTime 活动结束时间
- * @property int $drawCount 抽奖次数(机会)
- * @property int $needAttention 是否要求关注公众号:0、不要求(默认);1、必须是
- * @property int $needVip 是否要求会员:0、不要求(默认);1、必须是
- * @property int $participants 参与人数
- * @property int $inviteCount 获得一次抽奖机会需要邀请的好友数量
- * @property int $rewardCount 0或留空表示邀请好友没有奖励
- * @property string $introduce 活动介绍
- * @property string $awardIds 活动奖品ids,','分隔
- *
- */
- class xhLuckyDrawActivity extends xhBaseModel
- {
- /**
- * @inheritdoc
- */
- public static function tableName()
- {
- return 'xhLuckyDrawActivity';
- }
- /**
- * @inheritdoc
- */
- public function rules()
- {
- return [
- [['startTime', 'endTime', 'drawCount', 'needAttention', 'needVip', 'participants', 'inviteCount', 'rewardCount', 'merchantId'], 'integer'],
- [['urlQrCode'], 'string', 'max' => 100],
- [['introduce'], 'string', 'max' => 255],
- [['activityName'], 'required'],
- [['activityName'], 'unique', 'message'=>'抽奖活动名称重复'],
- [['createTime'], 'required', 'message' => '创建时间必须填写'],
- ];
- }
- /**
- * @inheritdoc
- */
- public function attributeLabels()
- {
- return [
- 'id' => 'ID',
- 'activityName' => 'Activity Name',
- 'merchantId' => '商户Id',
- 'startTime' => 'Start Time',
- 'endTime' => 'End Time',
- 'drawCount' => 'Draw Count',
- 'needAttention' => 'Need Attention',
- 'participants' => 'Participants',
- 'needVip' => 'Need Vip',
- 'introduce' => 'Introduce',
- 'awardIds' => 'Award Ids',
- 'inviteCount' => '邀请好友数量',
- 'rewardCount' => '最多奖励次数',
- 'urlQrCode' => '链接二维码',
- 'createTime' => 'Create Time',
- 'updateTime' => 'Update Time',
- ];
- }
- }
|