On 10/29/2010 07:46 PM, Endi Sukma Dewata wrote:

Please review the attached patch. Thanks!


The ipa_details_section class has been enhanced to support HTML
templates. This way the layout can be changed without modifying
the code. The ipa_details_field is used to setup the fields in
the template, also used to load and save the values.

If no template is specified, it will go back to the original
behavior: the section will be rendered using the dl/dt/dd tags.

Some fields have been added to support standard HTML widgets:
 - ipa_details_text: text field
 - ipa_details_radio: radio button
 - ipa_details_textarea: textarea
 - ipa_details_button: button

The HBAC details page has been implemented using this enhancement.
It uses the templates stored in hbac-details-*.html. It also uses
HBAC-specific widgets which are defined in these classes:
 - ipa_hbac_details_table: table for member enrollment
 - ipa_hbac_details_accesstime: table for access time

The buttons for adding and removing members are still not working.
There is no hint or undo functionality yet. They will be added in
subsequent patches.

The ipa_make_button() has been converted into ipa_button class which
can be used to replace the standard HTML button. The search-container
CSS class has been renamed to entity-container and used for all facets.

The unit test and test data have been updated accordingly.

Freeipa-devel mailing list
NACK, based on the templating issues we discussed on the phone.

TO lay out the issues for other people reading: we previously had a framework like what Endi is proposing here. We found that importing HTML fragments didn't provide much benefit, and lead to duplicated code. When Pavel did a major rework of the code in August, we removed the templating mechanism.

We are going to add it back in as part of this patch, but with a note that it is purely for Rapid prototyping purposes. For HBAC, Endi is going to make the Table code into a component that works without templating. Instead, weare going to generate the table code using Javascript, the same way that we do in the search code. This is the start of the work specified in


When we are done, we hope to havea reusable component that supports the search, associtions, record level attributes (like phone number) and the HBAC use cases. We'll produce a design document as we get better clarity.

Freeipa-devel mailing list

Reply via email to