Bug 8103 - The input is sometimes lost when getting errors on save
Summary: The input is sometimes lost when getting errors on save
Status: NEW
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: Web Administration (show other bugs)
Version: 4.14.0
Hardware: PC Unknown
: P2 Normal
Target Milestone: MediumPrio
Assignee: Bugzilla mail exporter
URL:
Keywords:
: 8113 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-02-20 14:28 CET by Frida Flodin
Modified: 2023-04-19 16:49 CEST (History)
2 users (show)

See Also:
Acceptance Criteria:


Attachments

Description Frida Flodin cendio 2023-02-20 14:28:11 CET
If there is an error when saving an entry in Web Admin I would expect the data in the fields to be untouched.

A scenario:
You create a new subcluster and add a lot of users and groups. You press save but you forgot to add the agents to the subcluster. Then the detailed view is closed and your user lists are gone.

This same kind of scenario can happen on more pages
- Desktop Customizer -> Menu Structure
- Desktop Customizer -> Application Groups
- Locations -> Locations
- Locations -> Terminals

For these pages I tested to save with empty name or already taken name.

In general it would be nice if the data was not lost in these cases.
Comment 1 Frida Flodin cendio 2023-02-28 08:50:27 CET
Profiles -> Profile List has the same problem when trying to save with a space in the Identification field.
Comment 2 Tobias cendio 2023-03-07 16:14:24 CET
Adding to the problem mentioned in comment 0, it's inconsistent across the modules whether the user is returned to the base page or remains in the detailed view upon encountering errors when trying to save a new or an existing table item.

Since dev build #3108, among the 7 relevant tlwebadm modules we can attribute the following statuses (X=buggy; ✔=fine) to them concerning saving when adding New or editing Existing table items:

* VSM/Subclusters
   New      : ✔
   Existing : ✔
* Profiles/Profile List
   New      : ✔ (a bit confusing that one can save an empty id and still be granted the
                 random id initially assigned)
   Existing : ✔
* Locations/Locations
   New      : X
   Existing : ✔
* Locations/Terminals
   New      : X
   Existing : ✔
* Desktop Customizer/Application Groups
   New      : ✔
   Existing : ✔
* Desktop Customizer/Applications (Manual)
   New      : ✔ (although the optional 'Application Name' field disappears if saved empty
                 when triggering errors pertaining to other fields)
   Existing : ✔
* Desktop Customizer/Menu Structure
   New      : ✔
   Existing : ✔
Comment 3 Tobias cendio 2023-03-07 16:15:29 CET
*** Bug 8113 has been marked as a duplicate of this bug. ***
Comment 5 Samuel Mannehed cendio 2023-04-06 10:31:11 CEST
One odd behavior that we noticed on the Profiles/Profile List page is that after pressing “Add new profile”, in the pop-up then pressing “Delete” without checking the confirm-checkbox, the pop-up just closes. We expect the confirm-checkbox to be required for the delete button to do anything.
Comment 6 Tobias cendio 2023-04-06 14:54:50 CEST
Unfortunately, commit r39973 introduced a regression which causes attempts to add new terminals with existing MAC addresses to result in a state where the existing terminal is being modified in the popup, with the possibility of modifying the MAC address -- an action which is normally prohibited.

It's possible this is due to the backend signaling it's still a new terminal being added -- which causes the MAC address field to be editable -- but the detailed view is actually displaying an existing terminal.
Comment 7 Samuel Mannehed cendio 2023-04-19 16:49:16 CEST
Regarding comment 2, I can no longer reproduce any problems with the popup closing on Locations/Terminals in recent builds. I tried saving a new terminal:

* Without a “Terminal name”
* Without a “Hardware (MAC) address”
* With an invalid “Hardware (MAC) address”

All of these result in nice errors being presented inside the popup. The Locations/Terminals page was likely fixed as part of commit r39973.

Issues regarding the popup closing on save errors remain on the Locations/Locations page, see bug 8123.

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