add max payment method for cheque
All checks were successful
Deploy Amap / deploy (push) Successful in 34s
All checks were successful
Deploy Amap / deploy (push) Successful in 34s
This commit is contained in:
@@ -36,6 +36,7 @@ class UserCreate(UserBase):
|
||||
class PaymentMethodBase(SQLModel):
|
||||
name: str
|
||||
details: str
|
||||
max: int | None
|
||||
|
||||
class PaymentMethod(PaymentMethodBase, table=True):
|
||||
id: int | None = Field(default=None, primary_key=True)
|
||||
|
||||
@@ -47,7 +47,8 @@ def update_one(session: Session, id: int, productor: models.ProductorUpdate) ->
|
||||
models.PaymentMethod(
|
||||
name=pm["name"],
|
||||
details=pm["details"],
|
||||
productor_id=id
|
||||
productor_id=id,
|
||||
max=pm["max"]
|
||||
)
|
||||
)
|
||||
del productor_updates["payment_methods"]
|
||||
|
||||
Reference in New Issue
Block a user