__table = 'civicrm_participant_status_type'; parent::__construct(); } /** * 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('Participant Status Type ID') , 'description' => 'unique participant status type id', 'required' => true, ) , 'participant_status' => array( 'name' => 'name', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Participant Status') , 'description' => 'non-localized name of the status type', 'maxlength' => 64, 'size' => CRM_Utils_Type::BIG, 'import' => true, 'where' => 'civicrm_participant_status_type.name', 'headerPattern' => '', 'dataPattern' => '', 'export' => true, ) , 'label' => array( 'name' => 'label', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Participant Status Label') , 'description' => 'localized label for display of this status type', 'maxlength' => 255, 'size' => CRM_Utils_Type::HUGE, ) , 'class' => array( 'name' => 'class', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Participant Status Class') , 'description' => 'the general group of status type this one belongs to', 'maxlength' => 8, 'size' => CRM_Utils_Type::EIGHT, 'html' => array( 'type' => 'Select', ) , 'pseudoconstant' => array( 'callback' => 'CRM_Event_PseudoConstant::participantStatusClassOptions', ) ) , 'is_reserved' => array( 'name' => 'is_reserved', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Participant Status Is Reserved?>') , 'description' => 'whether this is a status type required by the system', ) , 'is_active' => array( 'name' => 'is_active', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Participant Status is Active') , 'description' => 'whether this status type is active', 'default' => '1', ) , 'is_counted' => array( 'name' => 'is_counted', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Participant Status Counts?') , 'description' => 'whether this status type is counted against event size limit', ) , 'weight' => array( 'name' => 'weight', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Order') , 'description' => 'controls sort order', 'required' => true, ) , 'visibility_id' => array( 'name' => 'visibility_id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Participant Status Visibility') , 'description' => 'whether the status type is visible to the public, an implicit foreign key to option_value.value related to the `visibility` option_group', 'html' => array( 'type' => 'Select', ) , 'pseudoconstant' => array( 'optionGroupName' => 'visibility', 'optionEditPath' => 'civicrm/admin/options/visibility', ) ) , ); } return self::$_fields; } /** * Returns an array containing, for each field, the arary key used for that * field in self::$_fields. * * @return array */ static function &fieldKeys() { if (!(self::$_fieldKeys)) { self::$_fieldKeys = array( 'id' => 'id', 'name' => 'participant_status', 'label' => 'label', 'class' => 'class', 'is_reserved' => 'is_reserved', 'is_active' => 'is_active', 'is_counted' => 'is_counted', 'weight' => 'weight', 'visibility_id' => 'visibility_id', ); } return self::$_fieldKeys; } /** * Returns the names of this table * * @return string */ static function getTableName() { return CRM_Core_DAO::getLocaleTableName(self::$_tableName); } /** * Returns if this table needs to be logged * * @return boolean */ function getLog() { return self::$_log; } /** * Returns the list of fields that can be imported * * @param bool $prefix * * @return array */ static function &import($prefix = false) { $r = CRM_Core_DAO_AllCoreTables::getImports(__CLASS__, 'participant_status_type', $prefix, array()); return $r; } /** * Returns the list of fields that can be exported * * @param bool $prefix * * @return array */ static function &export($prefix = false) { $r = CRM_Core_DAO_AllCoreTables::getExports(__CLASS__, 'participant_status_type', $prefix, array()); return $r; } }