Force organization when login

Description

As discussed in http://www.globalqss.com/wiki/index.php/IDempiere/FullMeeting20121003, it could be useful to add a 'Preferred Organization' field on user, to overwrite the one stored in properties file or preference, on the login panel.

When field is filled, this organization should be set in the panel ; otherwise, we don't do anything

Environment

None

Activity

Diego Ruiz 
May 9, 2020 at 5:48 PM

Triaged by Diego Ruiz,

This ticket can be easily solved with a plugin.

You can check a code example here: https://github.com/bxservice/de.bayen.freibier/commit/09d2927065d5a27f45a2becebb9fe9b490e99a3b

Carlos Ruiz 
April 17, 2015 at 8:16 PM

The afterlogin validator must allow you to overwrite that - haven't tested.

I remember there is another validator after load preferences that was intended also to overwrite the date after login.

Nicolas Micoud 
April 17, 2015 at 10:28 AM

Hi Carlos,

It's ok to make it through a plugin, but it means that m_userpreference (from RolePanel) could be manipulated before login.
In order to overwrite the default org which is set in RolePanel.updateOrganisationList.

Wondering if the whole panel shouldn't be enhanced in order to be able to show/hide ; force value for all those fields... as discussed in https://groups.google.com/d/msg/idempiere/a_KDBRAYoh8/JSSU_834ugYJ.

WDYT ?

Carlos Ruiz 
April 15, 2015 at 9:16 PM

I think this ticket can be solved better by a Login Validator plugin. Maybe good candidate for a plugin.

Won't Fix

Details

Assignee

Reporter

Components

Priority

Created October 3, 2012 at 10:14 PM
Updated July 1, 2020 at 7:52 PM
Resolved May 9, 2020 at 5:48 PM