fix: 修复管理员更新用户信息时意外覆盖字段的问题
Build docker and publish / build (20.15.1) (push) Has been cancelled

- Enable/IsAdmin/OnlyFirstPurchase 改为 *bool,未传时不更新
- Avatar/Remark/ReferCode/ReferralPercentage 加空值保护
- getDeviceList: 恢复 hifastday@hifast.com 家庭成员受限逻辑

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-07 02:21:35 -07:00
parent 8bc8e81e95
commit 7d2f98b7c9
4 changed files with 105 additions and 35 deletions
+3 -3
View File
@@ -44,13 +44,13 @@ type (
Balance int64 `json:"balance"`
Commission int64 `json:"commission"`
ReferralPercentage uint8 `json:"referral_percentage"`
OnlyFirstPurchase bool `json:"only_first_purchase"`
OnlyFirstPurchase *bool `json:"only_first_purchase"`
GiftAmount int64 `json:"gift_amount"`
Telegram int64 `json:"telegram"`
ReferCode string `json:"refer_code"`
RefererId int64 `json:"referer_id"`
Enable bool `json:"enable"`
IsAdmin bool `json:"is_admin"`
Enable *bool `json:"enable"`
IsAdmin *bool `json:"is_admin"`
Remark string `json:"remark"`
}
UpdateUserNotifySettingRequest {