Beispiel #1
0
 /**
  * Returns all the column names of this table
  *
  * @return array
  */
 static function &fields()
 {
     if (!self::$_fields) {
         self::$_fields = array('id' => array('name' => 'id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Note ID'), 'description' => 'Note ID', 'required' => true), 'entity_table' => array('name' => 'entity_table', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Note Entity'), 'description' => 'Name of table where item being referenced is stored.', 'required' => true, 'maxlength' => 64, 'size' => CRM_Utils_Type::BIG, 'pseudoconstant' => array('callback' => 'CRM_Core_BAO_Note::entityTables')), 'entity_id' => array('name' => 'entity_id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Note Entity ID'), 'description' => 'Foreign key to the referenced item.', 'required' => true), 'note' => array('name' => 'note', 'type' => CRM_Utils_Type::T_TEXT, 'title' => ts('Note'), 'description' => 'Note and/or Comment.', 'rows' => 4, 'cols' => 60, 'import' => true, 'where' => 'civicrm_note.note', 'headerPattern' => '/Note|Comment/i', 'dataPattern' => '//', 'export' => true, 'html' => array('type' => 'TextArea')), 'contact_id' => array('name' => 'contact_id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Note Created By'), 'description' => 'FK to Contact ID creator', 'FKClassName' => 'CRM_Contact_DAO_Contact'), 'modified_date' => array('name' => 'modified_date', 'type' => CRM_Utils_Type::T_DATE, 'title' => ts('Note Modified By'), 'description' => 'When was this note last modified/edited'), 'subject' => array('name' => 'subject', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Subject'), 'description' => 'subject of note description', 'maxlength' => 255, 'size' => 60, 'html' => array('type' => 'Text')), 'privacy' => array('name' => 'privacy', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Privacy'), 'description' => 'Foreign Key to Note Privacy Level (which is an option value pair and hence an implicit FK)', 'maxlength' => 255, 'size' => CRM_Utils_Type::HUGE, 'pseudoconstant' => array('optionGroupName' => 'note_privacy', 'optionEditPath' => 'civicrm/admin/options/note_privacy')));
     }
     return self::$_fields;
 }
 /**
  * returns all the column names of this table
  *
  * @access public
  * @return array
  */
 static function &fields()
 {
     if (!self::$_fields) {
         self::$_fields = array('id' => array('name' => 'id', 'type' => CRM_Utils_Type::T_INT, 'required' => true), 'entity_table' => array('name' => 'entity_table', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Entity Table'), 'required' => true, 'maxlength' => 64, 'size' => CRM_Utils_Type::BIG), 'entity_id' => array('name' => 'entity_id', 'type' => CRM_Utils_Type::T_INT, 'required' => true), 'note' => array('name' => 'note', 'type' => CRM_Utils_Type::T_TEXT, 'title' => ts('Note'), 'rows' => 4, 'cols' => 60, 'import' => true, 'where' => 'civicrm_note.note', 'headerPattern' => '/Note|Comment/i', 'dataPattern' => '//', 'export' => true), 'contact_id' => array('name' => 'contact_id', 'type' => CRM_Utils_Type::T_INT, 'FKClassName' => 'CRM_Contact_DAO_Contact'), 'modified_date' => array('name' => 'modified_date', 'type' => CRM_Utils_Type::T_DATE, 'title' => ts('Modified Date')), 'subject' => array('name' => 'subject', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Subject'), 'maxlength' => 255, 'size' => CRM_Utils_Type::HUGE), 'privacy' => array('name' => 'privacy', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Privacy'), 'maxlength' => 255, 'size' => CRM_Utils_Type::HUGE));
     }
     return self::$_fields;
 }