Mobile App used as a timeclock - which user

Could anyone please recommend how to configure users/logins for the following scenario:

I'm using OutSystems 11 to develop a mobile app which is going to be used as a TIMECLOCK that is fixed permanently onto the restaurant wall.
i.e. this is not a portable device which a USER will carry on.
But a FIXED device specific to an individual RESTAURANT.

Each RESTAURANT will have it's own data (be in a separate tenant with a multi-tenant app).

How do I configure the mobile app on the mobile device of a local restaurant to know which restaurant it is, and to NOT require manual login every 30 days to re-authenticate?

* do I save a username/password and automatically login?

Any ideas?

Hi Alan,

Not sure what the best way would be to guarantee you never need to re-login, other than having:

  1. The app interacting to the server regularly
  2. A user interacting with the mobile app regularly

The defaults for these two types of interaction are 30 days and 365 days respectively, and can be customised in Service Center (you can find details about it on the Documentation).

For 1. you could have some recurrent asynchronous Javascript logic (check setInterval(), might be useful) that would call one of your Client Actions that calls a Server Action.

For 2.... apart from interacting with your application, can't really think of anything of the top of my head... do you need to be logged in at all?

I do need to know which TENANT is appropriate for this app. 

Normally I would do this by logging in as a user from that tenant (thereby getting automatic tenant filtering on aggregates).

Is there another way to ensure I get tenant filtering? without requiring a user login to that tenant?

Yeah, for tenant filtering, the login would make things a lot simpler, yes...

Is there any sort of user interaction with your app at all?

Yes. Employees will choose their name  and choose if they clock in our out our go on a break.

Solution

Alan Telford(Maxtel) wrote:

Yes. Employees will choose their name  and choose if they clock in our out our go on a break.

Then, according to the documentation I linked to, you shouldn't need to re-login, as long as the number of days between user and server interactions is below those limits.


Solution

Thanks. This sounds like it should work for me.

I'm thinking I will have to create a user account specific to each store that will use the TimeClock app. Then roles can be assigned specific to that user.