Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-422

Change Individual.Prefix, Suffix and Gender to Dynamic Configurable Values Sets

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: None
    • Fix Version/s: 1.2
    • Component/s: None
    • Labels:
      None

      Description

      Users have requested the ability to modify and extend the values for these three fields (which currently use hard-coded enum sets).

      1. Create three new DB tables to store values for these enums:

      • civicrm_individual_prefix
      • civicrm_individual_suffix
      • civicrm_gender

      Table columns for all 3 = id, domain_id, name, weight, is_active (we don't need description and is_reserved for these tables)

      2. Modify the schema for civicrm_individual table - change prefix, suffix and gender to INTs and set them as Foreign Keys to the corresponding new table.

      3. Modify contact edit and display forms as needed to derive option values from new tables. Options should be ordered by weight. For Prefix and Suffix, prepend the null options ('title' and 'suffix'). The Gender form element should still be displayed as radio buttons, with 'n' items (derived from the "enabled" civicrm_gender records).

      4. Remove hard-coded functions which define these from Core/SelectValues.php.

      5. Modify civicrm_data.mysql to populate existing enum values by default for the three tables (e.g. populate civicrm_gender w/ "Male", Female, Transgender; populate civicrm_individual_prefix w/ )

      6. Create admin listing/add/edit/disable functionality to allow management of each the value sets (same functionality as admin/activityType - except we don't have the is_reserved property/column and we have a 'weight' property). NOTE: Add these to the Menu.php $items array, but set the crmType as CALLBACK rather than LOCAL_TASK - we will link to them from a new Administer CiviCRM Control Panel (to be spec'd) rather than adding more tabs.

        Attachments

          Activity

            People

            • Assignee:
              kurund Kurund Jalmi
              Reporter:
              dgg David Greenberg
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: