255], ]; } /** * @inheritdoc */ public function attributeLabels() { return [ 'id' => 'ID', 'store_id' => 'Store ID', 'pond_id' => 'Pond ID', 'user_id' => 'User ID', 'status' => ' 0未领取1 已领取', 'create_time' => 'Create Time', 'raffle_time' => '领取时间', 'type' => 'Type', 'num' => 'Num', 'gift_id' => 'Gift ID', 'coupon_id' => 'Coupon ID', 'price' => 'Price', 'attr' => 'Attr', 'order_id' => 'Order ID', ]; } public function getCoupon() { return $this->hasOne(Coupon::className(), ['id' => 'coupon_id']); } public function getGift() { return $this->hasOne(Goods::className(), ['id' => 'gift_id']); } public function getUser() { return $this->hasOne(User::className(), ['id' => 'user_id'])->alias('user'); } }