support account color

This commit is contained in:
MaysWind
2020-11-17 01:54:26 +08:00
parent 391588fdf6
commit b4bd83e7a0
13 changed files with 153 additions and 9 deletions
+3
View File
@@ -343,6 +343,7 @@ func (a *AccountsApi) createNewAccount(uid int64, accountCreateReq *models.Accou
Category: accountCreateReq.Category,
Type: accountCreateReq.Type,
Icon: accountCreateReq.Icon,
Color: accountCreateReq.Color,
Currency: accountCreateReq.Currency,
Comment: accountCreateReq.Comment,
}
@@ -369,6 +370,7 @@ func (a *AccountsApi) getToUpdateAccount(uid int64, accountModifyReq *models.Acc
Name: accountModifyReq.Name,
Category: accountModifyReq.Category,
Icon: accountModifyReq.Icon,
Color: accountModifyReq.Color,
Comment: accountModifyReq.Comment,
Hidden: accountModifyReq.Hidden,
}
@@ -376,6 +378,7 @@ func (a *AccountsApi) getToUpdateAccount(uid int64, accountModifyReq *models.Acc
if newAccount.Name != oldAccount.Name ||
newAccount.Category != oldAccount.Category ||
newAccount.Icon != oldAccount.Icon ||
newAccount.Color != oldAccount.Color ||
newAccount.Comment != oldAccount.Comment ||
newAccount.Hidden != oldAccount.Hidden {
return newAccount