mirror of
https://github.com/R0m1k3/Regisflow.git
synced 2026-10-23 15:18:17 +02:00
Improve how payment options and ID types are handled in the sales form
Refactors IDENTITY_TYPES and PAYMENT_METHODS to string arrays and adds keys to SelectItem components in NewSaleFormMultiProduct.tsx. Replit-Commit-Author: Agent Replit-Commit-Session-Id: c7151ec8-4e6b-4fcf-b628-65b094ac18fd Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/0715008c-7244-40f4-befc-26c014852236/c7151ec8-4e6b-4fcf-b628-65b094ac18fd/0c6Tusu
This commit is contained in:
1 parent
2ad8acfb48
commit
4be6f23f1f
3 files changed
+12
-12
No files matched your search
Binary file not shown.
|
After Width: | Height: | Size: 34 KiB |
@@ -477,8 +477,8 @@ export default function NewSaleFormMultiProduct() {
|
|||||||
</SelectTrigger>
|
</SelectTrigger>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<SelectContent>
|
<SelectContent>
|
||||||
{PAYMENT_METHODS.map((method) => (
|
{PAYMENT_METHODS.map((method, methodIndex) => (
|
||||||
<SelectItem key={`payment-${method}`} value={method}>
|
<SelectItem key={`payment-method-${methodIndex}`} value={method}>
|
||||||
{method}
|
{method}
|
||||||
</SelectItem>
|
</SelectItem>
|
||||||
))}
|
))}
|
||||||
@@ -511,8 +511,8 @@ export default function NewSaleFormMultiProduct() {
|
|||||||
</SelectTrigger>
|
</SelectTrigger>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<SelectContent>
|
<SelectContent>
|
||||||
{IDENTITY_TYPES.map((type) => (
|
{IDENTITY_TYPES.map((type, typeIndex) => (
|
||||||
<SelectItem key={`identity-${type}`} value={type}>
|
<SelectItem key={`identity-type-${typeIndex}`} value={type}>
|
||||||
{type}
|
{type}
|
||||||
</SelectItem>
|
</SelectItem>
|
||||||
))}
|
))}
|
||||||
|
|||||||
@@ -81,15 +81,15 @@ export const ARTICLE_CATEGORY_MAPPING = {
|
|||||||
} as const;
|
} as const;
|
||||||
|
|
||||||
export const IDENTITY_TYPES = [
|
export const IDENTITY_TYPES = [
|
||||||
{ value: "CNI", label: "Carte Nationale d'Identité" },
|
"Carte Nationale d'Identité",
|
||||||
{ value: "Passeport", label: "Passeport" },
|
"Passeport",
|
||||||
{ value: "Permis de conduire", label: "Permis de conduire" }
|
"Permis de conduire"
|
||||||
] as const;
|
] as const;
|
||||||
|
|
||||||
export const PAYMENT_METHODS = [
|
export const PAYMENT_METHODS = [
|
||||||
{ value: "Carte Bancaire", label: "Carte Bancaire" },
|
"Carte Bancaire",
|
||||||
{ value: "Espèce", label: "Espèce" },
|
"Espèce",
|
||||||
{ value: "Chèque", label: "Chèque" },
|
"Chèque",
|
||||||
{ value: "Carte Cadeau", label: "Carte Cadeau" },
|
"Carte Cadeau",
|
||||||
{ value: "Autre", label: "Autre" }
|
"Autre"
|
||||||
] as const;
|
] as const;
|
||||||
Reference in new issue
Block a user