TimestampBehavior::class, 'attributes' => [ ActiveRecord::EVENT_BEFORE_INSERT => ['created_at'], ] ] ]; } /** * {@inheritdoc} */ public function rules() { return [ [['store_id', 'is_delete', 'created_at', 'send_integral', 'first_commission', 'second_commission', 'third_commission', 'state', 'original_price'], 'integer'], [['pay_price'], 'number'], [['name'], 'required'], [['name'], 'string', 'max' => 255], ]; } /** * {@inheritdoc} */ public function attributeLabels() { return [ 'id' => 'ID', 'store_id' => 'Store ID', 'pay_price' => '支付金额', 'name' => '充值名称', 'is_delete' => 'Is Delete', 'created_at' => 'Add Time', 'send_integral' => '赠送积分', 'first_commission' => '一级佣金', 'second_commission' => '二级佣金', 'third_commission' => '三级佣金', 'state' => '是否启用', 'original_price' => '原价', ]; } }