working commit

This commit is contained in:
2026-02-15 17:47:45 +02:00
parent 15a3379e5c
commit 2373af081e
10 changed files with 159 additions and 49 deletions
+8 -8
View File
@@ -124,8 +124,8 @@ type CreateAccountParams struct {
NewPassword string
}
type CreateAccountResult struct {
AccountID string `json:"accountId"`
GrantIDs []string `json:"grantsIds,omitempty"`
AccountID string `yaml:"accountId"`
GrantIDs []string `yaml:"grantsIds,omitempty"`
}
func (util *AccountUtil) CreateAccount(cmd *cobra.Command, args []string) {
@@ -179,7 +179,7 @@ type UpdateAccountParams struct {
NewPassword string
}
type UpdateAccountResult struct {
File *descr.File `json:"file,omitempty"`
File *descr.File `yaml:"file,omitempty"`
}
func (util *AccountUtil) UpdateAccount(cmd *cobra.Command, args []string) {
@@ -224,7 +224,7 @@ func (util *AccountUtil) GetAccount(cmd *cobra.Command, args []string) {
}
type GetAccountResult struct {
Account *descr.AccountShort `json:"account,omitempty"`
Account *descr.AccountShort `yaml:"account,omitempty"`
}
func (util *AccountUtil) getAccount(common *CommonAccountParams, params *GetAccountParams) (*GetAccountResult, error) {
@@ -300,13 +300,13 @@ type ListAccountsParams struct {
}
type Userinfo struct {
Username string `json:"username,omitempty"`
Rights []string `json:"rights,omitempty"`
Username string `yaml:"username,omitempty"`
Rights []string `yaml:"rights,omitempty"`
}
type ListAccountsResult struct {
Accounts []descr.AccountShort `json:"accounts,omitempty"`
Users []Userinfo `json:"users,omitempty"`
Accounts []descr.AccountShort `yaml:"accounts,omitempty"`
Users []Userinfo `yaml:"users,omitempty"`
}
func (util *AccountUtil) ListAccounts(cmd *cobra.Command, args []string) {