Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Goals: - To know how to create multiple scenes in one application and connect between them. - To practice the form validation. - To learn
Goals: To know how to create multiple scenes in one application and connect between them. To practice the form validation. To learn how to apply JavaFX Collections in real applications. To deal with Event Property and Listeners. To practice IO file management. Prompt: Warehouse inventory management is a process that involves receiving, storing, and tracking inventory in a warehouse. For this lab we will develop simple warehouse inventory application with two screens: The first scene titled "Warehouse Inventory" is for: Registering the items to warehouse by adding: Item Name Item Category Item Quantity Item Expiry Date Updating the quantities for the item and other information The second scene titled "Search" is for: Searching about item in the system and retrieve its information quantity and expiry date Filter the items by its category. The two screens should connect with each other by the buttons "Search" and "Back". Warehouse Inventory scene is the main screen Functionalities: Download the predesigned interface "Warehouselnventory.Java" then add the following functionalities: Task : ObservableList The Warehouselnventory scene has four ListViews to list all the items information: ListView to display the Item name ListView to display the Quantity of item. ListView to display the Item Category. ListView to display the Item Expiry Date. Those ListViews are already created in the interface but still missing the ObservableLists. Initialize the four empty ObservableLists obItems obQuantity obCategory, obExDate, obitemFilter then pass the: obltems to the IvItems ListView obQuantity to the lvQuantity ListView. obcategory to the lvCategory ListView. obExDate to the lVExDate ListView. obItemFilter to the IvItemsByCategory ListView. The content of the obItems obQuantity obCategory and obExDate ObservableLists and its ListViews will be obtained from the TextFields, ComboBoxes and DatePicker when the user clicks on the "Add" button in the Warehouselnventory scene. The content of the obItemFilter ListView will be obtained by filtering the registered items according to its category using the ComboBox in the search scene. Task: EventDriven Programming for the "Warehouselnventory" screen: Task : Add an ActionEvent on the Add button: To add a new item, user must: Fill the Item Name and Quantity using TextField. Choose the Quantity unit form the ComboBox Select the item Category from the ComboBox Choose the Expiry Date from the DatePicker. Click on the "Add" Button. Item name must be added directly as string to ob I tems Observablelist. inserting it to the obQuantity ObservableList. Example: if the quantity is
and the unit is "Boxes", the quantity must be combined as Boxes" before adding it to obQuantity ObservableList. Item category must be got from the ComboBox and added directly as string to obcategory Observablelist. The expiry date must be got from the DatePicker then added directly to obExDate ObservableList. Form Validation: If any of the TextFields are empty print in the blmsg lable Enter the item name and quantity". If the quantity text field contains nonnumeric letters print in the lblmsg lable The Quantity must be digit only If the item name is already exist in the list. print in the blmsg lable "The item already inserted" Initialize the four empty ObservableLists obItems obQuantity obCategory, obExDate, obitemFilter then pass the: obltems to the IvItems ListView obQuantity to the lvQuantity ListView. obcategory to the lvCategory ListView. obExDate to the lVExDate ListView. obItemFilter to the IvItemsByCategory ListView. The content of the obItems obQuantity obCategory and obExDate ObservableLists and its ListViews will be obtained from the TextFields, ComboBoxes and DatePicker when the user clicks on the "Add" button in the Warehouselnventory scene. The content of the obItemFilter ListView will be obtained by filtering the registered items according to its category using the ComboBox in the search scene. Task: EventDriven Programming for the "Warehouselnventory" screen: Task : Add an ActionEvent on the Add button: To add a new item, user must: Fill the Item Name and Quantity using TextField. Choose the Quantity unit form the ComboBox Select the item Category from the ComboBox Choose the Expiry Date from the DatePicker. Click on the "Add" Button. Item name must be added directly as string to ob I tems Observablelist. inserting it to the obQuantity ObservableList. Example: if the quantity is
and the unit is "Boxes", the quantity must be combined as Boxes" before adding it to obQuantity ObservableList. Item category must be got from the ComboBox and added directly as string to obcategory Observablelist. The expiry date must be got from the DatePicker then added directly to obExDate ObservableList.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started