set payment ramburs only
This commit is contained in:
@@ -144,6 +144,16 @@ class ProductPage:
|
||||
)
|
||||
]
|
||||
)
|
||||
self.add_co_card_placeholder = ft.Column()
|
||||
if self.product['aviability'] == 'in_stock':
|
||||
self.add_co_card_placeholder.controls.append(
|
||||
ft.FilledButton(
|
||||
"Adauga in cos",
|
||||
icon=ft.Icons.SHOPPING_CART,
|
||||
width=150,
|
||||
on_click= lambda e, i=self.product: self.on_add_to_cart_btn_click(i)
|
||||
)
|
||||
)
|
||||
self.product_content_details = ft.Column(
|
||||
[
|
||||
|
||||
@@ -173,12 +183,7 @@ class ProductPage:
|
||||
ft.Row(
|
||||
[
|
||||
self.quantify_group,
|
||||
ft.FilledButton(
|
||||
"Adauga in cos",
|
||||
icon=ft.Icons.SHOPPING_CART,
|
||||
width=150,
|
||||
on_click= lambda e, i=self.product: self.on_add_to_cart_btn_click(i)
|
||||
)
|
||||
self.add_co_card_placeholder
|
||||
]
|
||||
)
|
||||
],
|
||||
|
||||
@@ -52,11 +52,12 @@ class Cart:
|
||||
content=ft.Row(
|
||||
[
|
||||
ft.Radio(value="ramburs", label="Ramburs la curier"),
|
||||
ft.Radio(value="plata_online_cu_cardul", label="Plata online cu cardul"),
|
||||
ft.Radio(value="plata_online_cu_cardul", label="Plata online cu cardul", disabled=True),
|
||||
]
|
||||
),
|
||||
on_change=self.on_payment_value_change
|
||||
)
|
||||
self.payment.value = 'ramburs'
|
||||
self.payment_message = ft.Text("")
|
||||
self.error_message = ft.Text(
|
||||
color=ft.Colors.RED
|
||||
@@ -200,6 +201,10 @@ class Cart:
|
||||
weight=ft.FontWeight.BOLD
|
||||
),
|
||||
self.payment,
|
||||
ft.Text(
|
||||
"Cost transport 17 lei.",
|
||||
weight=ft.FontWeight.BOLD
|
||||
),
|
||||
self.payment_message,
|
||||
ft.Row([self.error_message],alignment=ft.MainAxisAlignment.CENTER),
|
||||
ft.Row(
|
||||
|
||||
Reference in New Issue
Block a user