Hello, I’m working on an inventory management mobile app that will be used in a small business that has 2 locations. Is there any way to set a persistent location value in each device so users don’t have to select a location each time?
Hi @Rkhan - you can set the location value into local storage. For example, you can add Select component in Profile screen where a user can select preferred location. For this Select component, add 'Run script' event handler on select value change that may look like this:
localStorage.setValue('location', select1.value);
To get the value from local storage use localStorage.values.location
expression.
Note that this local storage value will be set across all Retool Mobile apps (I think that's a cool thing)
I'm attaching example screenshot that should make more clear.
Hope this helps
Hey @Rkhan - I wonder if you resolved your question. If my post solved it feel free to mark it as a Solution