Changeset 6004 in subversion


Ignore:
Timestamp:
Mar 14, 2012 4:27:18 AM (15 months ago)
Author:
thomasb
Message:

Request all needed fields from address book backends (#1488394)

Location:
trunk/roundcubemail/program/steps
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/roundcubemail/program/steps/addressbook/delete.inc

    r5966 r6004  
    8787 
    8888        // get records 
    89         $result = $source->list_records(array('name', 'email')); 
     89        $result = $source->list_records(array('name', 'firstname', 'surname', 'email')); 
    9090 
    9191        if (!$result->count) { 
  • trunk/roundcubemail/program/steps/addressbook/list.inc

    r5966 r6004  
    4747 
    4848        // get records 
    49         $result = $source->list_records(array('name', 'email')); 
     49        $result = $source->list_records(array('name', 'firstname', 'surname', 'email')); 
    5050 
    5151        while ($row = $result->next()) { 
     
    7777 
    7878    // get contacts for this user 
    79     $result = $CONTACTS->list_records(array('name')); 
     79    $result = $CONTACTS->list_records(array('name', 'firstname', 'surname', 'email')); 
    8080 
    8181    if (!$result->count && $result->searchonly) { 
  • trunk/roundcubemail/program/steps/addressbook/search.inc

    r5966 r6004  
    183183 
    184184        // get records 
    185         $result = $source->list_records(array('name', 'email')); 
     185        $result = $source->list_records(array('name', 'firstname', 'surname', 'email')); 
    186186 
    187187        while ($row = $result->next()) { 
  • trunk/roundcubemail/program/steps/mail/autocomplete.inc

    r5787 r6004  
    3030    $abook->set_group($gid); 
    3131    $abook->set_pagesize(1000);  // TODO: limit number of group members by config 
    32     $result = $abook->list_records(array('email','name')); 
     32    $result = $abook->list_records(array('name', 'firstname', 'surname', 'email')); 
    3333    while ($result && ($sql_arr = $result->iterate())) { 
    3434      foreach ((array)$sql_arr['email'] as $email) { 
    35         $members[] = format_email_recipient($email, $sql_arr['name']); 
     35        $members[] = format_email_recipient($email, rcube_addressbook::compose_list_name($sql_arr)); 
    3636        break;  // only expand one email per contact 
    3737      } 
     
    6868    $abook->set_pagesize($MAXNUM); 
    6969 
    70     if ($result = $abook->search(array('email','name'), $search, $mode, true, true, 'email')) { 
     70    if ($result = $abook->search(array('name', 'firstname', 'surname', 'email'), $search, $mode, true, true, 'email')) { 
    7171      while ($sql_arr = $result->iterate()) { 
    7272        // Contact can have more than one e-mail address 
     
    7979          } 
    8080 
     81          $sql_arr['name'] = rcube_addressbook::compose_list_name($sql_arr); 
    8182          $contact = format_email_recipient($email, $sql_arr['name']); 
    8283 
  • trunk/roundcubemail/program/steps/mail/list_contacts.inc

    r5871 r6004  
    6161    // get contacts for this user 
    6262    $CONTACTS->set_group(0); 
    63     $result = $CONTACTS->list_records(array('name', 'email')); 
     63    $result = $CONTACTS->list_records(array('name', 'firstname', 'surname', 'email')); 
    6464 
    6565    if (!$result->count && $result->searchonly) { 
Note: See TracChangeset for help on using the changeset viewer.