Bug 8109 - Changing profile order can overwrite other changes
Summary: Changing profile order can overwrite other changes
Status: NEW
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: Web Administration (show other bugs)
Version: trunk
Hardware: PC Unknown
: P2 Normal
Target Milestone: LowPrio
Assignee: Bugzilla mail exporter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-06 13:15 CET by Pierre Ossman
Modified: 2023-03-07 13:37 CET (History)
0 users

See Also:
Acceptance Criteria:


Attachments

Description Pierre Ossman cendio 2023-03-06 13:15:25 CET
The behaviour of the order buttons for the profiles in tlwebadm can be a bit confusing in the event that something has changed on disk.

Rather than just move a single entry, as suggested by the button, the current behaviour is that the entire new order is saved. This gets worse given that we use the order to determine if something is active or not.

E.g., we start with this:

  Active:

    A
    B
    C

  Inactive:

    D
    E

Someone else modifies things to:

  Active:

   C
   B
   D
   E

  Inactive:

   A

If the first user now clicks to move B up one step, the result will be:

  Active:

    B
    A
    C

  Inactive:

    D
    E

I.e., A is reactivated, and D and E are disabled again.
Comment 1 Pierre Ossman cendio 2023-03-06 13:16:31 CET
It's unclear what we can do here, as it is unclear what the user expects to happen. The safe approach might be to simply refuse to do anything if we can detect that things are out of sync.
Comment 2 Pierre Ossman cendio 2023-03-06 16:36:08 CET
The issue is actually worse than described above. The order will persist with the browser until the user navigates to a different page. As long as they keep submitting forms, the old order will be retained by being passed back and forth.

That means that other operations will also revert to the previous order, overwriting any changes that might have happened since the user loaded the page.
Comment 3 Pierre Ossman cendio 2023-03-06 16:37:09 CET
r39846 for bug 7909 mitigates that last issue. The problem is now confined to just the reordering buttons.

Note You need to log in before you can comment on or make changes to this bug.