fixed status

This commit is contained in:
2025-01-24 11:57:58 -06:00
parent d593d0753e
commit 25f767979e
4 changed files with 7 additions and 4 deletions
+1
View File
@@ -15,6 +15,7 @@ public class InventoryItems
public string Brand { get; set; }
public string? SerialNumber { get; set; }
public ItemStatus Status { get; set; }
public string? StatusId { get; set; }
public float? RentalPrice { get; set; }
public float? ReplacementCost { get; set; }
public string? Notes { get; set; }
@@ -15,7 +15,8 @@ function EditItem() {
initialValues: {
name: "",
brand: "",
status: "",
statusId: "",
status: {name: "", id: ""},
serialNumber: "",
rentalPrice: 0,
replacementCost: 0,
@@ -94,8 +95,8 @@ function EditItem() {
placeholder="Brand" {...editItemForm.getInputProps('brand')}/>
<TextInput withAsterisk key={editItemForm.key('name')} size="md" label="Name"
placeholder="Name" {...editItemForm.getInputProps('name')}/>
<TextInput size="md" key={editItemForm.key('status')} label="Status"
placeholder="Status" {...editItemForm.getInputProps('status')}/>
<TextInput size="md" key={editItemForm.key('statusId')} label="Status"
placeholder="Status" {...editItemForm.getInputProps('statusId')}/>
<TextInput size="md" key={editItemForm.key('serialNumber')} label="Serial Number"
placeholder="Serial Number"{...editItemForm.getInputProps('serialNumber')}/>
<NumberInput size="md" key={editItemForm.key('rentalPrice')} label="Rental Price"
@@ -59,7 +59,7 @@ function InventoryList() {
<Table.Td>{data.id}</Table.Td>
<Table.Td>{data.brand}</Table.Td>
<Table.Td>{data.name}</Table.Td>
<Table.Td>{data.status}</Table.Td>
<Table.Td>{data.statusId}</Table.Td>
<Table.Td>
<Link to={`/itemDetail/${data.id}`}>Details</Link>
</Table.Td>
@@ -3,6 +3,7 @@ export interface InventoryItem {
brand: string,
name: string,
status: {id: string; name: string},
statusId: string;
serialNumber: string,
rentalPrice: number,
replacementCost: number,