Bug 21994 - Multiple system preferences in a group should be separated into new lines
Summary: Multiple system preferences in a group should be separated into new lines
Status: In Discussion
Alias: None
Product: Koha
Classification: Unclassified
Component: System Administration (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-12-13 12:40 UTC by Andrew Isherwood
Modified: 2018-12-20 12:44 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Nasty (13.66 KB, image/png)
2018-12-13 12:40 UTC, Andrew Isherwood
Details
With bug 21988 applied (21.27 KB, image/png)
2018-12-20 11:56 UTC, Andrew Isherwood
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Isherwood 2018-12-13 12:40:56 UTC
Created attachment 83148 [details]
Nasty

If a syspref group has multiple entries, they are all displayed on a single line and wrap around. This makes them very hard to read. An example is attached.

Each item in the group should be within it's own block level element.
Comment 1 Andrew Isherwood 2018-12-17 11:00:26 UTC
Looking into this a bit further, it's not a straightforward as it first appears. There is no defined delimiter between multiple prefs within a group, so there's no way of knowing where one ends and the next begins. The template just iterates through all entries in a group (or "line" as they're called in the template) whether they're text, form inputs etc.

So, we either need to create a delimiter in the preferences/*.pref files to define where one pref in a group ends and the next begins. Or, and this feels like a better solution, stop putting multiple prefs in a single group. As far as I can see, there's no reason for doing this. If we chose the latter option, there would be a small amount of work involved in separating out multiple prefs into their own lines. A quick experiment with patrons.pref, suggests this is all that's required.

Setting this bug to "In discussion" in case anyone has any further insight into this.
Comment 2 Katrin Fischer 2018-12-17 11:38:15 UTC
Not sure I understand - the screenshot looks fine to me?
Comment 3 Andrew Isherwood 2018-12-17 11:48:16 UTC
Well, there's 3 bits of information being requested, the patch I was working when I noticed this added a fourth, which looked *really* messy. But for the example in the screenshot, would it not be better as:

Defined a username/login [        ] and a password [        ].

Override from address with [        ] for emails sent using "Email" send driver.

I think I've convinced myself that there's no practical reason why these should be grouped together in the same row anyway, regardless of how they're laid out. I think one pref per row is a fairly sane guideline, it will always ensure an easy to read layout and removes the arbitrary nature of the current situation of sometimes grouping prefs into a row and sometimes not.
Comment 4 Katrin Fischer 2018-12-17 22:44:23 UTC
But the first is still 2 prefs (username and password). Sometimes it makes sense :)
Comment 5 Andrew Isherwood 2018-12-20 11:56:32 UTC
Hi Katrin

You're absolutely right, it's not particularly clear cut.

The thing that really highlighted it for me was my work on Bug 21988, which adds an addition SMS preference. (see attachment) The seemingly obvious thing to do here was to add it to the same row as the existing SMS prefs however, as you can see, that results in a somewhat messy display.

I'm not sure what the answer is, other than going through all prefs and breaking up those (such as SMS) that don't look great when occupying the same row. I'm aware it's subjective as to whether anything needs doing at all, but I thought it was worth raising.
Comment 6 Andrew Isherwood 2018-12-20 11:56:38 UTC
Created attachment 83413 [details]
With bug 21988 applied
Comment 7 Katrin Fischer 2018-12-20 12:44:44 UTC
I think you are right, we should do it where it make sense, but not overdo it. If you put them under the same heading they will still show up together, but will look less messy.