-
-
-
- {
- if (option.kind === "customer") {
- setForm((current) => ({
- ...current,
- customer: option.customerId,
- company: option.companyId,
- }));
- return;
- }
- setForm((current) => ({
- ...current,
- customer: "",
- company: option.companyId,
- }));
- }}
- />
-
-
-
-
-
- setForm({ ...form, rfq_number: e.target.value })}
- placeholder="Optional reference number"
- className="h-9"
- />
-
-
-
-
-
-
-
- {items.length === 0 ? (
-
-
- No items yet. Click "Add Item" to start.
-
- ) : (
-
- {items.map((item) => (
-
- setItems((current) =>
- current.map((row) => (row.id === item.id ? { ...row, ...patch } : row))
- )
- }
- onRemove={() =>
- setItems((current) => current.filter((row) => row.id !== item.id))
- }
- />
- ))}
-
- )}
-
-
-
-
-
-
-
-
-
-
-
-
-
-