1339: Save requisition for Offline

Test Case #:1339

Test Case Name: Save requisition for Offline

System: OpenLMIS

Subsystem: blue

Test case designed by: Anna Czyrko

Design Date:04.01.2017

Short description

The workflow for a user will be:
* Open any requisition page
* The requisition will be automatically stored and saved offline in the browser's local storage *when the user first views the requisition*
* There is a *box that states the requisition is available offline and a button to remove the requisition*
* There is a save button that when pressed will save the requisition to the user's local storage (so if they refresh the page after saving they should be shown the changes — even if they were not stored online)
* There is a "Sync" button that when pressed the requisition is saved to the requisition service
* When the browser is offline, the sync button is disabled
* When a user click the remove local requisition, the user is shown a confirmation modal that says "You are about to remove your local version of this requisition. This requisition will no longer be available offline." (Ok/Cancel)
* There will be a 'store offline' button if the requisition isn't available offline

* A requisition that is stored offline will recieve an update made in another browser, if the offline browser hasn't made any edits to the requisition AND the browser with the 'offline requisition' is online
* Data that is entered into a requisition that is offline will be visible on another browser only once the sync button has be pressed and the second browser has been refreshed
* A requisition always 'syncs' its data before Submitting/Authorizing/Approving the requisition
* Requisitions are automatically synced when online, and the automatic sync interval can be set as a config variable in config.json

*NOTE: Changes to acceptance criteria*
* Added save button into specification because it is technically easier for now & removed auto-save feature -- Will address is follow up ticket

                                                                                                                                                   

Pre – conditions:

                                                                                                                                                                                                                                                       



Step

Action

Expected system response

Comment

1

Log into application as administrator. Open any requisition page.

                                                                                                                          

                                                 

2

Make some changes and click Save button


When pressed will save the requisition to the user's local storage (so if they refresh the page after saving they should be shown the changes — even if they were not stored online)

3

There is a "Sync" button that when pressed the requisition is saved to the requisition service. Check if the browser is offline, the sync button is disabled



4

click the remove local requisition, the user is shown a confirmation modal that says "You are about to remove your local version of this requisition. This requisition will no longer be available offline." (Ok/Cancel)


5

Check if 'store offline' button is available if the requisition isn't available offline

A requisition that is stored offline will recieve an update made in another browser, if the offline browser hasn't made any edits to the requisition AND the browser with the 'offline requisition' is online. Data that is entered into a requisition that is offline will be visible on another browser only once the sync button has be pressed and the second browser has been refreshed

6

A requisition always 'syncs' its data before Submitting/Authorizing/Approving the requisition



7

Requisitions are automatically synced when online, and the automatic sync interval can be set as a config variable in config.json



OpenLMIS: the global initiative for powerful LMIS software