Ejemplo n.º 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('Membership Status ID'), 'description' => 'Membership Id', 'required' => true), 'membership_status' => array('name' => 'name', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Membership Status'), 'description' => 'Name for Membership Status', 'maxlength' => 128, 'size' => CRM_Utils_Type::HUGE, 'import' => true, 'where' => 'civicrm_membership_status.name', 'headerPattern' => '', 'dataPattern' => '', 'export' => true), 'label' => array('name' => 'label', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Label'), 'description' => 'Label for Membership Status', 'maxlength' => 128, 'size' => CRM_Utils_Type::HUGE), 'start_event' => array('name' => 'start_event', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Start Event'), 'description' => 'Event when this status starts.', 'maxlength' => 12, 'size' => CRM_Utils_Type::TWELVE, 'html' => array('type' => 'Select'), 'pseudoconstant' => array('callback' => 'CRM_Core_SelectValues::eventDate')), 'start_event_adjust_unit' => array('name' => 'start_event_adjust_unit', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Start Event Adjust Unit'), 'description' => 'Unit used for adjusting from start_event.', 'maxlength' => 8, 'size' => CRM_Utils_Type::EIGHT, 'html' => array('type' => 'Select'), 'pseudoconstant' => array('callback' => 'CRM_Core_SelectValues::unitList')), 'start_event_adjust_interval' => array('name' => 'start_event_adjust_interval', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Start Event Adjust Interval'), 'description' => 'Status range begins this many units from start_event.'), 'end_event' => array('name' => 'end_event', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('End Event'), 'description' => 'Event after which this status ends.', 'maxlength' => 12, 'size' => CRM_Utils_Type::TWELVE, 'html' => array('type' => 'Select'), 'pseudoconstant' => array('callback' => 'CRM_Core_SelectValues::eventDate')), 'end_event_adjust_unit' => array('name' => 'end_event_adjust_unit', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('End Event Adjust Unit'), 'description' => 'Unit used for adjusting from the ending event.', 'maxlength' => 8, 'size' => CRM_Utils_Type::EIGHT, 'html' => array('type' => 'Select'), 'pseudoconstant' => array('callback' => 'CRM_Core_SelectValues::unitList')), 'end_event_adjust_interval' => array('name' => 'end_event_adjust_interval', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('End Event Adjust Interval'), 'description' => 'Status range ends this many units from end_event.'), 'is_current_member' => array('name' => 'is_current_member', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Current Membership?'), 'description' => 'Does this status aggregate to current members (e.g. New, Renewed, Grace might all be TRUE... while Unrenewed, Lapsed, Inactive would be FALSE).'), 'is_admin' => array('name' => 'is_admin', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Admin Assigned Only?'), 'description' => 'Is this status for admin/manual assignment only.'), 'weight' => array('name' => 'weight', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Order')), 'is_default' => array('name' => 'is_default', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Default Status?'), 'description' => 'Assign this status to a membership record if no other status match is found.'), 'is_active' => array('name' => 'is_active', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Is Active'), 'description' => 'Is this membership_status enabled.', 'default' => '1'), 'is_reserved' => array('name' => 'is_reserved', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Is Reserved'), 'description' => 'Is this membership_status reserved.'));
     }
     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), 'membership_status' => array('name' => 'name', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Membership Status'), 'maxlength' => 128, 'size' => CRM_Utils_Type::HUGE, 'import' => true, 'where' => 'civicrm_membership_status.name', 'headerPattern' => '', 'dataPattern' => '', 'export' => true), 'label' => array('name' => 'label', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Label'), 'maxlength' => 128, 'size' => CRM_Utils_Type::HUGE), 'start_event' => array('name' => 'start_event', 'type' => CRM_Utils_Type::T_ENUM, 'title' => ts('Start Event'), 'enumValues' => 'start_date, end_date, join_date'), 'start_event_adjust_unit' => array('name' => 'start_event_adjust_unit', 'type' => CRM_Utils_Type::T_ENUM, 'title' => ts('Start Event Adjust Unit'), 'enumValues' => 'day, month, year'), 'start_event_adjust_interval' => array('name' => 'start_event_adjust_interval', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Start Event Adjust Interval')), 'end_event' => array('name' => 'end_event', 'type' => CRM_Utils_Type::T_ENUM, 'title' => ts('End Event'), 'enumValues' => 'start_date, end_date, join_date'), 'end_event_adjust_unit' => array('name' => 'end_event_adjust_unit', 'type' => CRM_Utils_Type::T_ENUM, 'title' => ts('End Event Adjust Unit'), 'enumValues' => 'day, month, year'), 'end_event_adjust_interval' => array('name' => 'end_event_adjust_interval', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('End Event Adjust Interval')), 'is_current_member' => array('name' => 'is_current_member', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Current Membership?')), 'is_admin' => array('name' => 'is_admin', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Admin Assigned Only?')), 'weight' => array('name' => 'weight', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Weight')), 'is_default' => array('name' => 'is_default', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Default Status?')), 'is_active' => array('name' => 'is_active', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Is Active'), 'default' => ''), 'is_reserved' => array('name' => 'is_reserved', 'type' => CRM_Utils_Type::T_BOOLEAN, 'title' => ts('Is Reserved')));
     }
     return self::$_fields;
 }