Univention Bugzilla – Bug 45601
Auto reload after switching school in UMC passwort reset moduls
Last modified: 2018-07-04 18:08:46 CEST
The customer asked for a autoload possibility in the password reset modul. She observed that school admins struggled in this modul because if they switch the school it do not auto-reload the users.
Is ucsschool/passwordreset/autosearch enabled?
(In reply to Daniel Tröder from comment #1) > Is ucsschool/passwordreset/autosearch enabled? Sure. But this Variable only handles the initial search during starting of the module. The customer asked for a possibility during schoolchange inside the module inside the school dropdown.
Same problem for classes. From the customer (usability) perspective they dont want a long autoload of all users at the beginning but a auto (re-)load if the user activaly choose a school or class.
The desired behavior can be implemented via onChange event listener on the ComboBox widgets. The question now would be how to make this behavior configurable. If we keep ucsschool/passwordreset/autosearch as the only variable controlling the autosearch we cannot realize the situation mentioned in comment #3 I would propose an additional variable like ucsschool/passwordreset/autosearch/dropdown to make the behaviors distinguishable in the config. Another usability situation we would have to face if we implement the requested change: If you have a specific class selected and then change the school. Do we reset the class to null (Alle Klassen und Arbeitsgruppen) to display all students of the school or does the user have to select an entry from the class dropdown before a reload happens? If we introduce the extra ucr variable we could solve the situation by making it depending on the ucsschool/passwordreset/autosearch variable. If it is set to true we load all students (so the class dropdown gets reset to null) and if false the user has to specify a class prior to reload.
(In reply to Ole Schwiegert from comment #4) > The desired behavior can be implemented via onChange event listener on the > ComboBox widgets. The question now would be how to make this behavior > configurable. Please discuss with Dirk what the best way of implementation might be. > If we keep ucsschool/passwordreset/autosearch as the only variable > controlling the autosearch we cannot realize the situation mentioned in > comment #3 You are right. > I would propose an additional variable like > ucsschool/passwordreset/autosearch/dropdown to make the behaviors > distinguishable in the config. I would suggest that the UCR variable ucsschool/passwordreset/autosearch is only used for the initial search. To enable the automatic search on changes of the group combobox, we should use the boolean UCR variable ucsschool/passwordreset/autosearch_on_change Can you please check, what the default for the UCR variable ucsschool/passwordreset/autosearch is? We should discuss later on, how the default of those UCR variables should look like. > Another usability situation we would have to face if we implement the > requested change: If you have a specific class selected and then change the > school. Do we reset the class to null (Alle Klassen und Arbeitsgruppen) to > display all students of the school or does the user have to select an entry > from the class dropdown before a reload happens? > > If we introduce the extra ucr variable we could solve the situation by > making it depending on the ucsschool/passwordreset/autosearch variable. If > it is set to true we load all students (so the class dropdown gets reset to > null) and if false the user has to specify a class prior to reload. As discussed, a new search should be triggered every time a school or group combobox is changed if ucsschool/passwordreset/autosearch_on_change is set to a "true" value. If another school is selected, the group combo box should be automatically reloaded and reset to the first entry and then searched for.
Please also implement a reload after passwords have been reset via the popup dialog. This should be done regardless of the state of the two UCR variables → always.
Created attachment 9477 [details] Proposed patch after consulting with Dirk After consulting with Dirk we came to the conclusion that the proposed patch (see attachments) is a sufficient solution to this bug/feature request.
On branch oschwieg/45601 is a revised and improved version of the code (reworked by Johannes)
*** Bug 27093 has been marked as a duplicate of this bug. ***
Should this behavior also be implemented in the administrate workgroups module as mentioned in comment #1 of Bug #2709 (duplicate)?
Sorry wrong bug reference. I mean: Bug #27093
(In reply to Sönke Schwardt-Krummrich from comment #5) > Can you please check, what the default for the UCR variable > ucsschool/passwordreset/autosearch is? > > We should discuss later on, how the default of those UCR variables > should look like. searched for. Currently I would suggest that both UCR variables ucsschool/passwordreset/autosearch_on_change and ucsschool/passwordreset/autosearch are set to "yes" as default value. Please set the default values in debian/….postinst. Can you please document here all 4 cases, what the behaviour is, when the UCR variables are set to yes/no?
passwordreset|passwordreset_on_change ------------------------------------- 0|0|No users are loaded at module start, no users are loaded after changing class or school 0|1|No users are loaded at module start, users are loaded after changing class or school 1|0|Users are loaded at module start, no users are loaded after changing class or school 1|1|Users are loaded at module start, Users are loaded after changing class or school While working on this I realized one problem with the description of the ucr variable ucsschool/passwordreset/autosearch. It reads as follows: Deactivates the automatic search when opening the module "Passwords (students/teacher)". In my understanding this text implies that the autosearch is activated by default and will be disabled when this variable is set to yes. This is not the implemented behavior though.
(In reply to Ole Schwiegert from comment #13) > While working on this I realized one problem with the description of the ucr > variable ucsschool/passwordreset/autosearch. It reads as follows: > > Deactivates the automatic search when opening the module "Passwords > (students/teacher)". Yes, the affected UCR variable descriptions should be overhauled in the packages ucs-school-umc-users and ucs-school-umc-groups.
Package: ucs-school-umc-groups Version: 8.0.0-2A~4.3.0.201804271048 Package: ucs-school-umc-users Version: 14.0.2-1A~4.3.0.201804271047
Please change the postinst to set ucsschool/passwordreset/autosearch_on_change to false if ucsschool/passwordreset/autosearch is set to false. Also please include the full ucr variable in ucs-school-umc-users.yaml. Otherwise it looks good :)
package: ucs-school-umc-users version: 14.0.2-2A~4.3.0.201805090843
Sorry I forgot one line in the postinst package: ucs-school-umc-users version: 14.0.2-3A~4.3.0.201805090903
OK
UCS@school 4.3 v4 has been released. https://docs.software-univention.de/changelog-ucsschool-4.3v4-de.html If this error occurs again, please clone this bug.