/[virtual-ldap]/lib/LDAP/Koha.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /lib/LDAP/Koha.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 50 by dpavlin, Wed Apr 29 09:03:47 2009 UTC revision 51 by dpavlin, Wed Apr 29 09:18:11 2009 UTC
# Line 26  our $user     = 'unconfigured-user'; Line 26  our $user     = 'unconfigured-user';
26  our $passwd   = 'unconfigured-password';  our $passwd   = 'unconfigured-password';
27    
28  our $max_results = 3000; # FIXME must be enough for all users  our $max_results = 3000; # FIXME must be enough for all users
29    our $objectclass_default = 'hrEduPerson';
30    
31  our $objectclass = 'HrEduPerson';  our $objectclass;
32    
33  $SIG{__DIE__} = sub {  $SIG{__DIE__} = sub {
34          warn "!!! DIE ", @_;          warn "!!! DIE ", @_;
# Line 156  sub search { Line 157  sub search {
157    
158                  my $sql_where = '';                  my $sql_where = '';
159                  @values = ();                  @values = ();
160                    $objectclass = '';
161    
162                  foreach my $filter ( keys %{ $reqData->{'filter'} } ) {                  foreach my $filter ( keys %{ $reqData->{'filter'} } ) {
163    
# Line 185  sub search { Line 187  sub search {
187    
188                  }                  }
189    
190                    $objectclass ||= $objectclass_default;
191    
192                  my $sql_select = read_file( lc "sql/$objectclass.sql" );                  my $sql_select = read_file( lc "sql/$objectclass.sql" );
193                  if ( $sql_where ) {                  if ( $sql_where ) {
194                          if ( $sql_select !~ m{where}i ) {                          if ( $sql_select !~ m{where}i ) {

Legend:
Removed from v.50  
changed lines
  Added in v.51

  ViewVC Help
Powered by ViewVC 1.1.26