[Freeipa-devel] [PATCH] 058 Distinguishing of external values in association tables

Petr Vobornik pvoborni at redhat.com
Thu Dec 15 12:54:13 UTC 2011


Problem:
Rule association widget was displaying standard records with external 
records in one table. User couldn't distinguish the values. When 
clicking on the external record link it navigated to appropriate page 
for that entity. But for external value there is no record to show so it 
displayed error.

Solution:
* For tables with possible external values a 'external' column was 
added. It displays "True" if the value is external and nothing if not. 
Displaying nothing is intentional. If user sees some text in external 
column he immediately knows that the record is external without even 
reading the "True" text.
* Rows with external values don't have a link for navigating to record 
page. This prevents showing the error as no record exists.

Additional changes:
* Association table widget was stripped of get_records method. Loading 
records isn't its responsibility it's a responsibility of field.
* Column was extended by possible suppressing of link creation. It's 
done by optional suppress_link argument in setup method.
* To allow setting suppress_link attribute in inherited tables a new 
overridable method was created - setup_column.

Possible future improvements:
* Table is using dynamic setting of width for columns. Each column has 
the same width. For flag columns such as 'external' the width of the 
column is too big. It would be better to be able to set smaller fixed 
width and the rest of the columns width (without the width set) would be 
computed (to fit the table).
* When a table has displayed buttons in its last column header the cells 
in column header have different vertical alignment. It should be united.

https://fedorahosted.org/freeipa/ticket/1993
-- 
Petr Vobornik
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freeipa-pvoborni-0058-Distinguishing-of-external-values-in-association-tab.patch
Type: text/x-patch
Size: 9514 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20111215/d64cc033/attachment.bin>


More information about the Freeipa-devel mailing list