Documentation ¶
Index ¶
- Variables
- type AccountsApi
- func (a *AccountsApi) AccountCreateHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountDeleteHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountGetHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountHideHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountModifyHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *AccountsApi) AccountMoveHandler(c *core.Context) (interface{}, *errs.Error)
- type AmapApiProxy
- type AuthorizationsApi
- type DataManagementsApi
- type DefaultApi
- type ExchangeRatesApi
- type ForgetPasswordsApi
- type HealthsApi
- type MapImageProxy
- type QrCodesApi
- type TokensApi
- func (a *TokensApi) TokenListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TokensApi) TokenRefreshHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TokensApi) TokenRevokeAllHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TokensApi) TokenRevokeCurrentHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TokensApi) TokenRevokeHandler(c *core.Context) (interface{}, *errs.Error)
- type TransactionCategoriesApi
- func (a *TransactionCategoriesApi) CategoryCreateBatchHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryCreateHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryDeleteHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryGetHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryHideHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryModifyHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionCategoriesApi) CategoryMoveHandler(c *core.Context) (interface{}, *errs.Error)
- type TransactionTagsApi
- func (a *TransactionTagsApi) TagCreateHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagDeleteHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagGetHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagHideHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagModifyHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionTagsApi) TagMoveHandler(c *core.Context) (interface{}, *errs.Error)
- type TransactionsApi
- func (a *TransactionsApi) TransactionAmountsHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionCountHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionCreateHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionDeleteHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionGetHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionModifyHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionMonthAmountsHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionMonthListHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TransactionsApi) TransactionStatisticsHandler(c *core.Context) (interface{}, *errs.Error)
- type TwoFactorAuthorizationsApi
- func (a *TwoFactorAuthorizationsApi) TwoFactorDisableHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TwoFactorAuthorizationsApi) TwoFactorEnableConfirmHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TwoFactorAuthorizationsApi) TwoFactorEnableRequestHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TwoFactorAuthorizationsApi) TwoFactorRecoveryCodeRegenerateHandler(c *core.Context) (interface{}, *errs.Error)
- func (a *TwoFactorAuthorizationsApi) TwoFactorStatusHandler(c *core.Context) (interface{}, *errs.Error)
- type UsersApi
Constants ¶
This section is empty.
Variables ¶
var ( Accounts = &AccountsApi{ accounts: services.Accounts, } )
Initialize an account api singleton instance
var (
AmapApis = &AmapApiProxy{}
)
Initialize a amap api proxy singleton instance
var ( Authorizations = &AuthorizationsApi{ users: services.Users, tokens: services.Tokens, twoFactorAuthorizations: services.TwoFactorAuthorizations, } )
Initialize a authorization api singleton instance
var ( DataManagements = &DataManagementsApi{ exporter: &converters.GoFireCSVFileExporter{}, tokens: services.Tokens, users: services.Users, accounts: services.Accounts, transactions: services.Transactions, categories: services.TransactionCategories, tags: services.TransactionTags, } )
Initialize a data management api singleton instance
var (
Default = &DefaultApi{}
)
Initialize a default api singleton instance
var (
ExchangeRates = &ExchangeRatesApi{}
)
Initialize a exchange rate api singleton instance
var ( ForgetPasswords = &ForgetPasswordsApi{ users: services.Users, tokens: services.Tokens, forgetPasswords: services.ForgetPasswords, } )
Initialize a user api singleton instance
var (
Healths = &HealthsApi{}
)
Initialize a healths api singleton instance
var (
MapImages = &MapImageProxy{}
)
Initialize a map image proxy singleton instance
var (
QrCodes = &QrCodesApi{}
)
Initialize a qrcode generator api singleton instance
Initialize a token api singleton instance
var ( TransactionCategories = &TransactionCategoriesApi{ categories: services.TransactionCategories, } )
Initialize a transaction category api singleton instance
var ( TransactionTags = &TransactionTagsApi{ tags: services.TransactionTags, } )
Initialize a transaction tag api singleton instance
var ( Transactions = &TransactionsApi{ transactions: services.Transactions, transactionCategories: services.TransactionCategories, transactionTags: services.TransactionTags, accounts: services.Accounts, users: services.Users, } )
Initialize a transaction api singleton instance
var ( TwoFactorAuthorizations = &TwoFactorAuthorizationsApi{ twoFactorAuthorizations: services.TwoFactorAuthorizations, users: services.Users, tokens: services.Tokens, } )
Initialize a 2fa api singleton instance
var ( Users = &UsersApi{ users: services.Users, tokens: services.Tokens, accounts: services.Accounts, } )
Initialize a user api singleton instance
Functions ¶
This section is empty.
Types ¶
type AccountsApi ¶
type AccountsApi struct {
// contains filtered or unexported fields
}
AccountsApi represents account api
func (*AccountsApi) AccountCreateHandler ¶
func (a *AccountsApi) AccountCreateHandler(c *core.Context) (interface{}, *errs.Error)
AccountCreateHandler saves a new account by request parameters for current user
func (*AccountsApi) AccountDeleteHandler ¶
func (a *AccountsApi) AccountDeleteHandler(c *core.Context) (interface{}, *errs.Error)
AccountDeleteHandler deletes an existed account by request parameters for current user
func (*AccountsApi) AccountGetHandler ¶
func (a *AccountsApi) AccountGetHandler(c *core.Context) (interface{}, *errs.Error)
AccountGetHandler returns one specific account of current user
func (*AccountsApi) AccountHideHandler ¶
func (a *AccountsApi) AccountHideHandler(c *core.Context) (interface{}, *errs.Error)
AccountHideHandler hides an existed account by request parameters for current user
func (*AccountsApi) AccountListHandler ¶
func (a *AccountsApi) AccountListHandler(c *core.Context) (interface{}, *errs.Error)
AccountListHandler returns accounts list of current user
func (*AccountsApi) AccountModifyHandler ¶
func (a *AccountsApi) AccountModifyHandler(c *core.Context) (interface{}, *errs.Error)
AccountModifyHandler saves an existed account by request parameters for current user
func (*AccountsApi) AccountMoveHandler ¶
func (a *AccountsApi) AccountMoveHandler(c *core.Context) (interface{}, *errs.Error)
AccountMoveHandler moves display order of existed accounts by request parameters for current user
type AmapApiProxy ¶
type AmapApiProxy struct { }
AmapApiProxy represents amap api proxy
func (*AmapApiProxy) AmapApiProxyHandler ¶
func (p *AmapApiProxy) AmapApiProxyHandler(c *core.Context) (*httputil.ReverseProxy, *errs.Error)
AmapApiProxyHandler returns amap api response
type AuthorizationsApi ¶
type AuthorizationsApi struct {
// contains filtered or unexported fields
}
AuthorizationsApi represents authorization api
func (*AuthorizationsApi) AuthorizeHandler ¶
func (a *AuthorizationsApi) AuthorizeHandler(c *core.Context) (interface{}, *errs.Error)
AuthorizeHandler verifies and authorizes current login request
func (*AuthorizationsApi) TwoFactorAuthorizeByRecoveryCodeHandler ¶
func (a *AuthorizationsApi) TwoFactorAuthorizeByRecoveryCodeHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorAuthorizeByRecoveryCodeHandler verifies and authorizes current 2fa login by recovery code
func (*AuthorizationsApi) TwoFactorAuthorizeHandler ¶
func (a *AuthorizationsApi) TwoFactorAuthorizeHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorAuthorizeHandler verifies and authorizes current 2fa login by passcode
type DataManagementsApi ¶
type DataManagementsApi struct {
// contains filtered or unexported fields
}
DataManagementsApi represents data management api
func (*DataManagementsApi) ClearDataHandler ¶
func (a *DataManagementsApi) ClearDataHandler(c *core.Context) (interface{}, *errs.Error)
ClearDataHandler deletes all user data
func (*DataManagementsApi) DataStatisticsHandler ¶
func (a *DataManagementsApi) DataStatisticsHandler(c *core.Context) (interface{}, *errs.Error)
DataStatisticsHandler returns user data statistics
func (*DataManagementsApi) ExportDataHandler ¶
ExportDataHandler returns exported data in csv format
type DefaultApi ¶
type DefaultApi struct{}
DefaultApi represents default api
func (*DefaultApi) ApiNotFound ¶
func (a *DefaultApi) ApiNotFound(c *core.Context) (interface{}, *errs.Error)
ApiNotFound returns api not found error
func (*DefaultApi) MethodNotAllowed ¶
func (a *DefaultApi) MethodNotAllowed(c *core.Context) (interface{}, *errs.Error)
MethodNotAllowed returns method not allowed error
type ExchangeRatesApi ¶
type ExchangeRatesApi struct{}
ExchangeRatesApi represents exchange rate api
func (*ExchangeRatesApi) LatestExchangeRateHandler ¶
func (a *ExchangeRatesApi) LatestExchangeRateHandler(c *core.Context) (interface{}, *errs.Error)
LatestExchangeRateHandler returns latest exchange rate data
type ForgetPasswordsApi ¶
type ForgetPasswordsApi struct {
// contains filtered or unexported fields
}
ForgetPasswordsApi represents user forget password api
func (*ForgetPasswordsApi) UserForgetPasswordRequestHandler ¶
func (a *ForgetPasswordsApi) UserForgetPasswordRequestHandler(c *core.Context) (interface{}, *errs.Error)
UserForgetPasswordRequestHandler generates password reset link and send user an email with this link
func (*ForgetPasswordsApi) UserResetPasswordHandler ¶
func (a *ForgetPasswordsApi) UserResetPasswordHandler(c *core.Context) (interface{}, *errs.Error)
UserResetPasswordHandler resets user password by request parameters
type HealthsApi ¶
type HealthsApi struct{}
HealthsApi represents health api
func (*HealthsApi) HealthStatusHandler ¶
func (a *HealthsApi) HealthStatusHandler(c *core.Context) (interface{}, *errs.Error)
HealthStatusHandler returns the health status of current service
type MapImageProxy ¶
type MapImageProxy struct { }
MapImageProxy represents map image proxy
func (*MapImageProxy) MapTileImageProxyHandler ¶
func (p *MapImageProxy) MapTileImageProxyHandler(c *core.Context) (*httputil.ReverseProxy, *errs.Error)
MapTileImageProxyHandler returns map tile image
type QrCodesApi ¶
type QrCodesApi struct { }
QrCodesApi represents qrcode generator api
func (*QrCodesApi) MobileUrlQrCodeHandler ¶
MobileUrlQrCodeHandler returns a mobile url qr code image
type TokensApi ¶
type TokensApi struct {
// contains filtered or unexported fields
}
TokensApi represents token api
func (*TokensApi) TokenListHandler ¶
TokenListHandler returns available token list of current user
func (*TokensApi) TokenRefreshHandler ¶
TokenRefreshHandler refresh current token of current user
func (*TokensApi) TokenRevokeAllHandler ¶
TokenRevokeAllHandler revokes all tokens of current user except current token
func (*TokensApi) TokenRevokeCurrentHandler ¶
TokenRevokeCurrentHandler revokes current token of current user
type TransactionCategoriesApi ¶
type TransactionCategoriesApi struct {
// contains filtered or unexported fields
}
TransactionCategoriesApi represents transaction category api
func (*TransactionCategoriesApi) CategoryCreateBatchHandler ¶
func (a *TransactionCategoriesApi) CategoryCreateBatchHandler(c *core.Context) (interface{}, *errs.Error)
CategoryCreateBatchHandler saves some new transaction category by request parameters for current user
func (*TransactionCategoriesApi) CategoryCreateHandler ¶
func (a *TransactionCategoriesApi) CategoryCreateHandler(c *core.Context) (interface{}, *errs.Error)
CategoryCreateHandler saves a new transaction category by request parameters for current user
func (*TransactionCategoriesApi) CategoryDeleteHandler ¶
func (a *TransactionCategoriesApi) CategoryDeleteHandler(c *core.Context) (interface{}, *errs.Error)
CategoryDeleteHandler deletes an existed transaction category by request parameters for current user
func (*TransactionCategoriesApi) CategoryGetHandler ¶
func (a *TransactionCategoriesApi) CategoryGetHandler(c *core.Context) (interface{}, *errs.Error)
CategoryGetHandler returns one specific transaction category of current user
func (*TransactionCategoriesApi) CategoryHideHandler ¶
func (a *TransactionCategoriesApi) CategoryHideHandler(c *core.Context) (interface{}, *errs.Error)
CategoryHideHandler hides an existed transaction category by request parameters for current user
func (*TransactionCategoriesApi) CategoryListHandler ¶
func (a *TransactionCategoriesApi) CategoryListHandler(c *core.Context) (interface{}, *errs.Error)
CategoryListHandler returns transaction category list of current user
func (*TransactionCategoriesApi) CategoryModifyHandler ¶
func (a *TransactionCategoriesApi) CategoryModifyHandler(c *core.Context) (interface{}, *errs.Error)
CategoryModifyHandler saves an existed transaction category by request parameters for current user
func (*TransactionCategoriesApi) CategoryMoveHandler ¶
func (a *TransactionCategoriesApi) CategoryMoveHandler(c *core.Context) (interface{}, *errs.Error)
CategoryMoveHandler moves display order of existed transaction categories by request parameters for current user
type TransactionTagsApi ¶
type TransactionTagsApi struct {
// contains filtered or unexported fields
}
TransactionTagsApi represents transaction tag api
func (*TransactionTagsApi) TagCreateHandler ¶
func (a *TransactionTagsApi) TagCreateHandler(c *core.Context) (interface{}, *errs.Error)
TagCreateHandler saves a new transaction tag by request parameters for current user
func (*TransactionTagsApi) TagDeleteHandler ¶
func (a *TransactionTagsApi) TagDeleteHandler(c *core.Context) (interface{}, *errs.Error)
TagDeleteHandler deletes an existed transaction tag by request parameters for current user
func (*TransactionTagsApi) TagGetHandler ¶
func (a *TransactionTagsApi) TagGetHandler(c *core.Context) (interface{}, *errs.Error)
TagGetHandler returns one specific transaction tag of current user
func (*TransactionTagsApi) TagHideHandler ¶
func (a *TransactionTagsApi) TagHideHandler(c *core.Context) (interface{}, *errs.Error)
TagHideHandler hides an transaction tag by request parameters for current user
func (*TransactionTagsApi) TagListHandler ¶
func (a *TransactionTagsApi) TagListHandler(c *core.Context) (interface{}, *errs.Error)
TagListHandler returns transaction tag list of current user
func (*TransactionTagsApi) TagModifyHandler ¶
func (a *TransactionTagsApi) TagModifyHandler(c *core.Context) (interface{}, *errs.Error)
TagModifyHandler saves an existed transaction tag by request parameters for current user
func (*TransactionTagsApi) TagMoveHandler ¶
func (a *TransactionTagsApi) TagMoveHandler(c *core.Context) (interface{}, *errs.Error)
TagMoveHandler moves display order of existed transaction tags by request parameters for current user
type TransactionsApi ¶
type TransactionsApi struct {
// contains filtered or unexported fields
}
TransactionsApi represents transaction api
func (*TransactionsApi) TransactionAmountsHandler ¶
func (a *TransactionsApi) TransactionAmountsHandler(c *core.Context) (interface{}, *errs.Error)
TransactionAmountsHandler returns transaction amounts of current user
func (*TransactionsApi) TransactionCountHandler ¶
func (a *TransactionsApi) TransactionCountHandler(c *core.Context) (interface{}, *errs.Error)
TransactionCountHandler returns transaction total count of current user
func (*TransactionsApi) TransactionCreateHandler ¶
func (a *TransactionsApi) TransactionCreateHandler(c *core.Context) (interface{}, *errs.Error)
TransactionCreateHandler saves a new transaction by request parameters for current user
func (*TransactionsApi) TransactionDeleteHandler ¶
func (a *TransactionsApi) TransactionDeleteHandler(c *core.Context) (interface{}, *errs.Error)
TransactionDeleteHandler deletes an existed transaction by request parameters for current user
func (*TransactionsApi) TransactionGetHandler ¶
func (a *TransactionsApi) TransactionGetHandler(c *core.Context) (interface{}, *errs.Error)
TransactionGetHandler returns one specific transaction of current user
func (*TransactionsApi) TransactionListHandler ¶
func (a *TransactionsApi) TransactionListHandler(c *core.Context) (interface{}, *errs.Error)
TransactionListHandler returns transaction list of current user
func (*TransactionsApi) TransactionModifyHandler ¶
func (a *TransactionsApi) TransactionModifyHandler(c *core.Context) (interface{}, *errs.Error)
TransactionModifyHandler saves an existed transaction by request parameters for current user
func (*TransactionsApi) TransactionMonthAmountsHandler ¶
func (a *TransactionsApi) TransactionMonthAmountsHandler(c *core.Context) (interface{}, *errs.Error)
TransactionMonthAmountsHandler returns every month transaction amounts of current user
func (*TransactionsApi) TransactionMonthListHandler ¶
func (a *TransactionsApi) TransactionMonthListHandler(c *core.Context) (interface{}, *errs.Error)
TransactionMonthListHandler returns all transaction list of current user by month
func (*TransactionsApi) TransactionStatisticsHandler ¶
func (a *TransactionsApi) TransactionStatisticsHandler(c *core.Context) (interface{}, *errs.Error)
TransactionStatisticsHandler returns transaction statistics of current user
type TwoFactorAuthorizationsApi ¶
type TwoFactorAuthorizationsApi struct {
// contains filtered or unexported fields
}
TwoFactorAuthorizationsApi represents 2fa api
func (*TwoFactorAuthorizationsApi) TwoFactorDisableHandler ¶
func (a *TwoFactorAuthorizationsApi) TwoFactorDisableHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorDisableHandler disables 2fa for current user
func (*TwoFactorAuthorizationsApi) TwoFactorEnableConfirmHandler ¶
func (a *TwoFactorAuthorizationsApi) TwoFactorEnableConfirmHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorEnableConfirmHandler enables 2fa for current user
func (*TwoFactorAuthorizationsApi) TwoFactorEnableRequestHandler ¶
func (a *TwoFactorAuthorizationsApi) TwoFactorEnableRequestHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorEnableRequestHandler returns a new 2fa secret and qr code for current user to set 2fa and verify passcode next
func (*TwoFactorAuthorizationsApi) TwoFactorRecoveryCodeRegenerateHandler ¶
func (a *TwoFactorAuthorizationsApi) TwoFactorRecoveryCodeRegenerateHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorRecoveryCodeRegenerateHandler returns new 2fa recovery codes and revokes old recovery codes for current user
func (*TwoFactorAuthorizationsApi) TwoFactorStatusHandler ¶
func (a *TwoFactorAuthorizationsApi) TwoFactorStatusHandler(c *core.Context) (interface{}, *errs.Error)
TwoFactorStatusHandler returns 2fa status of current user
type UsersApi ¶
type UsersApi struct {
// contains filtered or unexported fields
}
UsersApi represents user api
func (*UsersApi) UserProfileHandler ¶
UserProfileHandler returns user profile of current user
func (*UsersApi) UserRegisterHandler ¶
UserRegisterHandler saves a new user by request parameters