diff options
author | MikunoNaka <bokuwakanojogahoshii@yahoo.com> | 2021-04-17 13:12:11 +0530 |
---|---|---|
committer | MikunoNaka <bokuwakanojogahoshii@yahoo.com> | 2021-04-17 13:12:11 +0530 |
commit | 2efc453d20aca682ac3f34af8687d4bb28642195 (patch) | |
tree | 4c1c36b66e50829d9bec7161456f450bad338148 /src/components/Display | |
parent | f1475f5815d2accd40342c95ed2cf97a96e6d676 (diff) |
now data is properly being passed from AddNewItemForm to ItemsDisplay which properly renders it
Diffstat (limited to 'src/components/Display')
-rw-r--r-- | src/components/Display/ItemsDisplay.js | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/components/Display/ItemsDisplay.js b/src/components/Display/ItemsDisplay.js index 9507e5b..766d16f 100644 --- a/src/components/Display/ItemsDisplay.js +++ b/src/components/Display/ItemsDisplay.js @@ -7,13 +7,20 @@ const ItemsDisplay = (props) => { return ( <div className={"ItemsDisplay"}> <ol> - { - items.map( - (item) => { - return <li key={item}>{item}</li> - } - ) - } + {items.map( (item) => { + return ( + <li> + <ul> + <li key={item.Model}>{item.Model}</li> + <li key={item.Description}>{item.Description}</li> + <li key={item.Quantity}>{item.Quantity}</li> + <li key={item.Price}>{item.Price}</li> + <li key={item.Discount}>{item.Discount}</li> + <li key={item.GST}>{item.GST}</li> + </ul> + </li> + ); + })} </ol> </div> ); |