mirror of
https://github.com/FJurmanovic/wallet-go-api.git
synced 2026-02-06 14:18:12 +00:00
fixed multipart form issue
This commit is contained in:
@@ -5,10 +5,14 @@ type Token struct {
|
||||
}
|
||||
|
||||
type Login struct {
|
||||
Email string
|
||||
Password string
|
||||
Email string `form:"email"`
|
||||
Password string `form:"password"`
|
||||
}
|
||||
|
||||
type Auth struct {
|
||||
Id string
|
||||
}
|
||||
|
||||
type CheckToken struct {
|
||||
Valid bool `json:"valid"`
|
||||
}
|
||||
|
||||
@@ -3,10 +3,10 @@ package models
|
||||
type User struct {
|
||||
tableName struct{} `pg:"users,alias:users"`
|
||||
BaseModel
|
||||
IsActive bool `json:"isActive" pg:"is_active"`
|
||||
Username string `json:"username" pg:"username"`
|
||||
Password string `json:"password" pg:"password"`
|
||||
Email string `json:"email" pg:"email"`
|
||||
IsActive bool `json:"isActive" pg:"is_active" form:"isActive"`
|
||||
Username string `json:"username" pg:"username" form:"username"`
|
||||
Password string `json:"password" pg:"password" form:"password"`
|
||||
Email string `json:"email" pg:"email" form:"email"`
|
||||
}
|
||||
|
||||
type UserReturnInfo struct {
|
||||
|
||||
@@ -8,6 +8,6 @@ type TransactionType struct {
|
||||
}
|
||||
|
||||
type NewTransactionTypeBody struct {
|
||||
Name string `json:"name"`
|
||||
Type string `json:"type"`
|
||||
Name string `json:"name" form:"name"`
|
||||
Type string `json:"type" form:"type"`
|
||||
}
|
||||
|
||||
@@ -15,8 +15,8 @@ type Transaction struct {
|
||||
}
|
||||
|
||||
type NewTransactionBody struct {
|
||||
WalletID string `json:"walletId"`
|
||||
TransactionTypeID string `json:"transactionTypeId"`
|
||||
TransactionDate time.Time `json:"transactionDate"`
|
||||
Description string `json:"description"`
|
||||
WalletID string `json:"walletId" form:"walletId"`
|
||||
TransactionTypeID string `json:"transactionTypeId" form:"transactionTypeId"`
|
||||
TransactionDate time.Time `json:"transactionDate" form:"transactionDate"`
|
||||
Description string `json:"description" form:"description"`
|
||||
}
|
||||
|
||||
@@ -9,6 +9,6 @@ type Wallet struct {
|
||||
}
|
||||
|
||||
type NewWalletBody struct {
|
||||
Name string `json:"name"`
|
||||
UserID string `json:"userId"`
|
||||
Name string `json:"name" form:"name"`
|
||||
UserID string `json:"userId" form:"userId"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user