How can I make a log info when user login

0
Hi,  I’m using the default login page. Now I need record the user’s login time, login name .etc when the user succeed login.  I can find the login.html in theme folder, but can’t find the place can be controled in code.  Could you  guide me where I can add a after-login microflow or any way can do this?
asked
4 answers
2

I found this and asked support… Here was their reply: 

 

“In Mendix 8 and above, the log messages for successful user login have been changed to Trace log level. You should be able to see them by changing the Log Level of the "CORE" log node on your environment to trace”

 

 

answered
1

Hi, Mendix already does this in the logs. See below for example

Why do you want to re-engineer this?

INFO - WebUI: Login FAILED: invalid password for user 'user1' (1 failed login).
INFO - WebUI: Login OK: user 'user1' (Number of concurrent sessions: 7).

I dont see a need for redeveloping this. OR are you trying to achieve something else?

answered
0

I am certain that in the past Mendix used to log each user login in the logfile by default. I am surprised that Mendix does not do that anymore.

Anyway, the only way i can think of the restore this behaviour is using custom after sign in logic: https://docs.mendix.com/refguide/login-behavior 

It will work, but somehow i feel there should be a better solution. Anyone else with a better idea?

answered
0

Hi guys, 

I added a microflow on the Default Home Page to resove this problem temporarily. Thank you! 

answered