User History Introduction
The user history feature is designed to save the options selected by the user in the backend. When the user logs in again, the application retrieves this data from the backend, allowing the user to resume their previous selections without needing to reconfigure their choices. This enhances user experience by providing a personalized interaction with the app.
Schema definition:
The history data saved in the backend is defined by schema
, and will update constantly.
You can find the documentation about setting up schema
here.
The schema
number currently used is specified in .env
file. Currently the schema
contains most redux data and is structured as follows:
Note: The schema
is a structure similar to the redux data structure, some redux data which contains much data and is mainly retrieved by api calls during the app selection process, like cropData
, is not included in the data saved in the backend.
User experience:
To utilize the user history feature, the user must sign up and log in first. At the first page, click on Create New History
button to create a new history record with a nickname. After that, when the user make any selection and switch page(except switching from State selection page to Location selection page), the history will be saved in the backend.
To load the history, click on Import Previous History
button and use the dropdown to select one record and click Import
button to load the history. This allows the user
view the previous selections or make any changes. However, there are some information which are not able to change(like state
or location
since these will affect the further result). When the user attempt to make change, a popup will prompt the user to create a new record. Except for this, the user is able to edit other information, and the changes will be saved in the history.