https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30657

--- Comment #19 from Martin Renvoize <[email protected]> ---
What are people's general opinion on the accessors proposed here?

With this patch we add accessors per attribute code.

For non-repatable it's as simple as:
[% borrower.attribute_code %]

Whilst for repeatable we have:
[% FOR attribute IN borrower.attribute_code %]
    [% attribute %]
[% END %]

This adds a bit of code complexity and possibly has some effect on performance
whilst we do already offer some alternatives.

For non-repeatable we already support:
[% attribute = borrower.get_extended_attribute(attribute_code) %]
[% attribute.description %]

For repeatable we have
[% FOREACH ba IN borrower.extended_attributes %]
     [% IF ba.code == 'UNCLE' %]
              [% alt_id = ba.attribute %]
     [% END %]
[% END %]

Is the extra code I introduce here to simplify for the end user worth it's
weight?

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to