add payment text
This commit is contained in:
39
internal/payment/paymenttexts/dto.go
Normal file
39
internal/payment/paymenttexts/dto.go
Normal file
@@ -0,0 +1,39 @@
|
||||
// Package paymenttexts holds the admin-editable, localized texts (warnings,
|
||||
// hints) shown to clients around a visa/master/sber payout. Rows are keyed by
|
||||
// a fixed code the client apps depend on, so the admin API can only edit
|
||||
// existing rows - codes are added by migration.
|
||||
package paymenttexts
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"online-back/internal/shared"
|
||||
)
|
||||
|
||||
type PaymentTextDTO struct {
|
||||
Id int64 `json:"id"`
|
||||
Code string `json:"code"`
|
||||
Name string `json:"name"`
|
||||
Text shared.LocalizedText `json:"text"`
|
||||
IsActive bool `json:"isActive"`
|
||||
UpdatedById *int64 `json:"updatedById,omitempty"`
|
||||
UpdatedByName string `json:"updatedByName,omitempty"`
|
||||
UpdatedAt time.Time `json:"updatedAt"`
|
||||
}
|
||||
|
||||
type ListPaymentTextDTO struct {
|
||||
Count int `json:"count"`
|
||||
Items []PaymentTextDTO `json:"items"`
|
||||
}
|
||||
|
||||
type UpdatePaymentTextDTO struct {
|
||||
Name string `json:"name" binding:"required"`
|
||||
Text shared.LocalizedText `json:"text"`
|
||||
IsActive *bool `json:"isActive" binding:"required"`
|
||||
UpdatedBy *int64 `json:"-"`
|
||||
}
|
||||
|
||||
type ListFilter struct {
|
||||
Search string
|
||||
ActiveOnly bool
|
||||
}
|
||||
Reference in New Issue
Block a user