Пример #1
0
 public static function get_field_tooltip($label)
 {
     if (strpos($label, 'Utils_Tooltip') !== false) {
         return $label;
     }
     $args = func_get_args();
     array_shift($args);
     return Utils_TooltipCommon::ajax_create($label, array('Utils_RecordBrowserCommon', 'ajax_get_field_tooltip'), $args);
 }
Пример #2
0
 public static function contact_format_no_company($record, $nolink = false)
 {
     if (is_numeric($record)) {
         $record = self::get_contact($record);
     }
     if (!$record || $record == '__NULL__') {
         return null;
     }
     $ret = '';
     $format = Base_User_SettingsCommon::get('CRM_Contacts', 'contact_format');
     $label = str_replace(array('##l##', '##f##'), array($record['last_name'], $record['first_name']), $format);
     if (!$nolink) {
         $ret .= Utils_RecordBrowserCommon::record_link_open_tag('contact', $record['id']);
         $ret .= Utils_TooltipCommon::ajax_create($label, array('CRM_ContactsCommon', 'contact_get_tooltip'), array($record));
         $ret .= Utils_RecordBrowserCommon::record_link_close_tag();
     } else {
         $ret .= $label;
     }
     return $ret;
 }