dev
This commit is contained in:
parent
900650ace4
commit
9fe3041a44
@ -4,6 +4,7 @@ import (
|
||||
"context"
|
||||
"donat-widget/internal/model"
|
||||
"donat-widget/internal/model/api"
|
||||
"fmt"
|
||||
"log/slog"
|
||||
)
|
||||
|
||||
@ -39,10 +40,11 @@ func (donatService *ServiceDonat) CreateDonat(
|
||||
slog.Error("donatService.widgetRepo.GetAllWidget: ", err)
|
||||
return api.CreatePaymentResponse{}, err
|
||||
}
|
||||
fmt.Println(widgets)
|
||||
|
||||
var widgetID model.WidgetID
|
||||
for _, widget := range widgets {
|
||||
if widget.MinAmount <= amount {
|
||||
if widget.MinAmount >= amount {
|
||||
widgetID = widget.ID
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user