示例#1
0
echo '<input type="hidden" value="' . $contact["source_id"] . '" name="source_id" />';
echo '<input type="hidden" name="task" value="" />';
echo '<input type="hidden" name="close" value="false" />';
echo '<input type="hidden" name="return_to" value="' . $return_to . '" />';
echo '<input type="hidden" name="contact_id" value="' . $contact_id . '" />';
echo '<table border="0"><tr>';
$title = $contact_id > 0 ? $ab_contact : $contacts_add;
$tabtable = new tabtable('contact_table', $title, '100%', '400', '120', '', true, 'left', 'top', 'add', 'vertical');
if ($contact_id > 0) {
    $tabtable->add_tab('profile', $contact_profile);
    if ($custom_fields_plugin) {
        require_once $custom_fields_plugin['path'] . 'classes/custom_fields.class.inc';
        $cf = new custom_fields('ab_custom_contact_fields');
        if ($cf->get_catagories($GO_SECURITY->user_id) > 0) {
            while ($cf->next_record()) {
                $tabtable->add_tab($cf->f('id'), $cf->f('name'));
            }
        }
    }
    $projects_module = $GO_MODULES->get_module('projects');
    if ($projects_module) {
        if ($GO_SECURITY->has_permission($GO_SECURITY->user_id, $projects_module['acl_read']) || $GO_SECURITY->has_permission($GO_SECURITY->user_id, $projects_module['acl_write'])) {
            $tabtable->add_tab('projects', $lang_modules['projects']);
        }
    }
    $notes_module = $GO_MODULES->get_module('notes');
    if ($notes_module) {
        if ($GO_SECURITY->has_permission($GO_SECURITY->user_id, $notes_module['acl_read']) || $GO_SECURITY->has_permission($GO_SECURITY->user_id, $notes_module['acl_write'])) {
            $tabtable->add_tab('notes', $lang_modules['notes']);
            echo '<td  class="ModuleIcons" nowrap>';
            echo '<a href="' . $notes_module['url'] . 'note.php?contact_id=' . $contact_id . '&return_to=' . rawurlencode($link_back) . '"><img src="' . $GO_THEME->images['ab_notes'] . '" border="0" height="32" width="32" /><br />' . $ab_new_note . '</td>';
示例#2
0
     $dropbox->add_value('ab_contacts.last_name', $strLastName);
     $dropbox->add_value('ab_contacts.email', $strEmail);
     $dropbox->add_value('ab_contacts.department', $strDepartment);
     $dropbox->add_value('ab_contacts.function', $strFunction);
     $dropbox->add_value('ab_contacts.address', $strAddress);
     $dropbox->add_value('ab_contacts.city', $strCity);
     $dropbox->add_value('ab_contacts.zip', $strZip);
     $dropbox->add_value('ab_contacts.state', $strState);
     $dropbox->add_value('ab_contacts.country', $strCountry);
     $dropbox->add_value('ab_contacts.comment', $ab_comment);
     if ($custom_fields_plugin) {
         require_once $custom_fields_plugin['class_path'] . 'custom_fields.class.inc';
         $cf = new custom_fields('ab_custom_contact_fields');
         if ($cf->get_fields()) {
             while ($cf->next_record()) {
                 $dropbox->add_value('ab_custom_contact_fields.`' . $cf->f('field') . '`', $cf->f('field'));
             }
         }
     }
     break;
 case 'users':
     $_search_field = isset($_POST['search_field']) ? $_POST['search_field'] : 'users.first_name';
     $search_field = isset($ab_settings['search_users_field']) ? $ab_settings['search_users_field'] : $_search_field;
     $dropbox->add_value('users.first_name', $strFirstName);
     $dropbox->add_value('users.last_name', $strLastName);
     $dropbox->add_value('users.email', $strEmail);
     $dropbox->add_value('users.department', $strDepartment);
     $dropbox->add_value('users.function', $strFunction);
     $dropbox->add_value('users.address', $strAddress);
     $dropbox->add_value('users.city', $strCity);
     $dropbox->add_value('users.zip', $strZip);