TimestampBehavior::class, 'value' => time() ] ]; } /** * @inheritdoc */ public function attributeLabels() { return [ 'id' => 'ID', 'store_id' => 'Store ID', 'user_id' => 'User ID', 'order_id' => 'Order ID', 'order_refund_no' => '退款单号', 'refund_price' => '退款金额', 'sub_balance' => '扣减余额', 'sub_integral' => '扣减积分', 'desc_user' => '退款说明(用户)', 'desc_admin' => '退款说明(管理员)', 'status' => '退款状态:0失败,1成功', 'status_desc' => '退款失败原因', 'audit_status' => '申请状态,0审核中,1已同意,2已拒绝', 'created_at' => 'Addtime', 'is_delete' => 'Is Delete', ]; } public function beforeSave($insert) { $this->desc_user = \yii\helpers\Html::encode($this->desc_user); $this->desc_admin = \yii\helpers\Html::encode($this->desc_admin); return parent::beforeSave($insert); } }