Bug 4995

Summary: extended attributes replication from LDAP
Product: Koha Reporter: Dobrica Pavlinusic <dpavlin>
Component: AuthenticationAssignee: Galen Charlton <gmcharlt>
Status: CLOSED FIXED QA Contact: Bugs List <koha-bugs>
Severity: critical    
Priority: PATCH-Sent (DO NOT USE) CC: chris, dev_patches, dpavlin
Version: rel_3_0   
Hardware: All   
OS: All   
See Also: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=4256
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: fix mapping of extended attribute code and ldap attributes

Description Dobrica Pavlinusic 2010-07-13 21:39:27 UTC
Documentation for extended attributes is somewhat lacking, and my last patch in my previous bug report just fixed case without any extended attributes in LDAP.
Comment 1 Dobrica Pavlinusic 2010-07-13 21:44:35 UTC
Created attachment 2360 [details] [review]
fix mapping of extended attribute code and ldap attributes
Comment 2 Dobrica Pavlinusic 2010-07-13 21:57:07 UTC
This approach still require additional entry in koha-conf.xml mapping like this:

<JMBG is="hrEduPersonUniqueNumber_JMBG"></JMBG>

It's quite easy to add code to match existing types in extended attributes to ldap attribute names directly, so that it doesn't require change in koha-conf.xml, but I can see also argumentation against it along the lines of "it's really nice to have all LDAP configuration in one place in koha-conf.xml and I like ability to rename fields".
Comment 3 dev_patches 2010-09-09 17:52:59 UTC
Applied
Comment 4 Dobrica Pavlinusic 2011-07-14 20:20:06 UTC
I can't see this patch applied in current master. It would bring current LDAP implementation into fully-functional state, and still applies cleanly to master.
Comment 5 Chris Cormack 2011-07-28 22:12:30 UTC
It is there in master already, applying the patch causes this conflict

<<<<<<< HEAD
                my @attributes = grep{my $key=$_; any{$_ eq $key}@types;} keys %borrower;
        my $extended_patron_attributes;
        @{$extended_patron_attributes} =
          map { { code => $_, value => $borrower{$_} } } @attributes;
=======
                my @attributes = grep{my $key=$_; any{$_->{code} eq $key}@types;} keys %borrower;
                my $extended_patron_attributes = [ map{{code=>$_,value=>$borrower{$_}}}@attributes ];
>>>>>>> Bug 4995 - extended attributes replication from LDAP