Rename users table fields and loan documents table, expand branch billing credentials, switch to /api/admin prefix, refactor auth endpoints, replace PATCH with PUT for status updates, remove file upload APIs, and regenerate Swagger with ordered tags. Co-authored-by: Cursor <cursoragent@cursor.com>
72 lines
3.0 KiB
Go
72 lines
3.0 KiB
Go
package branches
|
|
|
|
type LocalizedText struct {
|
|
En string `json:"en"`
|
|
Ru string `json:"ru"`
|
|
Tm string `json:"tm"`
|
|
}
|
|
|
|
type BranchDTO struct {
|
|
Id int64 `json:"id"`
|
|
Title LocalizedText `json:"title"`
|
|
ProvinceId int64 `json:"provinceId"`
|
|
LocationId int64 `json:"locationId"`
|
|
UnikalNomer string `json:"unikalNomer"`
|
|
Address LocalizedText `json:"address"`
|
|
BillingUsername string `json:"billingUsername"`
|
|
BillingPassword string `json:"billingPassword"`
|
|
BillingUsernameSber string `json:"billingUsernameSber"`
|
|
BillingPasswordSber string `json:"billingPasswordSber"`
|
|
BillingUsernameVisa string `json:"billingUsernameVisa"`
|
|
BillingPasswordVisa string `json:"billingPasswordVisa"`
|
|
BillingUsernameSwift string `json:"billingUsernameSwift"`
|
|
BillingPasswordSwift string `json:"billingPasswordSwift"`
|
|
}
|
|
|
|
type CreateBranchDTO struct {
|
|
Title LocalizedText `json:"title" binding:"required"`
|
|
ProvinceId int64 `json:"provinceId" binding:"required"`
|
|
LocationId int64 `json:"locationId" binding:"required"`
|
|
UnikalNomer string `json:"unikalNomer" binding:"required"`
|
|
Address LocalizedText `json:"address" binding:"required"`
|
|
BillingUsername string `json:"billingUsername"`
|
|
BillingPassword string `json:"billingPassword"`
|
|
BillingUsernameSber string `json:"billingUsernameSber"`
|
|
BillingPasswordSber string `json:"billingPasswordSber"`
|
|
BillingUsernameVisa string `json:"billingUsernameVisa"`
|
|
BillingPasswordVisa string `json:"billingPasswordVisa"`
|
|
BillingUsernameSwift string `json:"billingUsernameSwift"`
|
|
BillingPasswordSwift string `json:"billingPasswordSwift"`
|
|
}
|
|
|
|
type UpdateBranchDTO struct {
|
|
Title LocalizedText `json:"title" binding:"required"`
|
|
ProvinceId int64 `json:"provinceId" binding:"required"`
|
|
LocationId int64 `json:"locationId" binding:"required"`
|
|
UnikalNomer string `json:"unikalNomer" binding:"required"`
|
|
Address LocalizedText `json:"address" binding:"required"`
|
|
BillingUsername string `json:"billingUsername"`
|
|
BillingPassword string `json:"billingPassword"`
|
|
BillingUsernameSber string `json:"billingUsernameSber"`
|
|
BillingPasswordSber string `json:"billingPasswordSber"`
|
|
BillingUsernameVisa string `json:"billingUsernameVisa"`
|
|
BillingPasswordVisa string `json:"billingPasswordVisa"`
|
|
BillingUsernameSwift string `json:"billingUsernameSwift"`
|
|
BillingPasswordSwift string `json:"billingPasswordSwift"`
|
|
}
|
|
|
|
type ListFilter struct {
|
|
ProvinceID *int64
|
|
LocationID *int64
|
|
ProvinceName string
|
|
BranchName string
|
|
UnikalNomer string
|
|
Page int
|
|
Limit int
|
|
}
|
|
|
|
type ListBranchDTO struct {
|
|
Count int64 `json:"count"`
|
|
Branches []BranchDTO `json:"branches"`
|
|
}
|