webui: Add user birthday settings
- Store birth month and day in user_pref with default 10/18 - Migrate existing user_pref rows to fill missing birthday fields - Expose birthday editing in the webui profile page - Replace hardcoded birthday values in user info, top info, and product list responses - Fix birthday month/day field alignment in the profile form Signed-off-by: Sean Du <do4suki@gmail.com>
This commit is contained in:
@@ -278,6 +278,8 @@ func addUser(dbSession *xorm.Session, phone, password string, isDefault bool) (g
|
||||
SnsCoin: usermodel.DefaultUserSnsCoin,
|
||||
EnergyMax: usermodel.DefaultUserEnergyMax,
|
||||
OverMaxEnergy: usermodel.DefaultUserOverMaxEnergy,
|
||||
BirthMonth: usermodel.DefaultBirthMonth,
|
||||
BirthDay: usermodel.DefaultBirthDay,
|
||||
ProfileVersion: usermodel.CurrentUserPrefProfileVersion,
|
||||
UpdateTime: time.Now().Unix(),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user