Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 3.4.4, 4.0.4
    • Fix Version/s: 4.1.0
    • Component/s: CiviCase
    • Labels:
      None

      Description

      Support the creation of custom fields attached to case records. The existing schema should support this feature; however the UI will need to be structured a bit differently given the way case records are currently managed.

      Administer Custom Data Sets
      ---------------------------------------
      Create new custom data set type = Cases if CiviCase is enabled, and allow assignment based on Case Type(s). Disable multiple-record option for case custom data sets.

      Open Case
      ---------------------------------------
      Open case interacts with both the case record and the open case activity.

      • One to N case custom data sets are conditionally injected in the open case form just below the Case Type dropdown when a case type is selected or changed.
      • Custom data(s) linked to "any" case type are injected immediate as the form is loaded. If a default case type has been configured, any custom data set(s) linked to that case type are injected as the form is loaded.
      • Modify open case form to include empty (' - select - ') option for Case Type dropdown. This prevents us from loading custom case pane(s) for a case type by default UNLESS the site has configured a default case type.

      Manage Case
      ---------------------------------------
      Inject an accordion pane for each custom data set associated with the currently viewed Case (determined by case type or for all cases). to group each case custom data set. Custom data panes display custom fields data in view mode and include an Edit button – located within each custom data set pane, and only impacting that set of data. Clicking the edit button should open a modal popup where the custom data can be edited (similar to how case tags are handled). This is important as the manage case screen is a collection of data in view mode; we don't want to unnecessarily redirect to a form view just to handle case custom fields.

      See attached screen shot for layout example ("Additional Case Info" is a case custom data pane).

      Record a "Change Custom Data" activity when case custom data is updated
      ---------------------------------------

      • Add a new activity type (new installs / upgrade). Label and Name = "Change Custom Data", compenent_id = CiviCase (7)
      • When custom data is modified via the modal popup, automatically insert a "Change Custom Data" activity:
      • source_contact_id = current user's contact id
      • target_contact_id = case "client"
      • details = json encoded string - name / value pairs for the "pre-update" custom fields (field label and field value)
      • content_type = "application/json" NOTE: See related issue to add content_type column to civicrm_activity table.
      • status = completed
      • subject = $customDataSet.title . " : change data"

      Search
      ---------------------------------------
      Extend case search (find cases and Cases pane in Advanced Search) to include "searchable" custom data sets/fields for searching.

      Export
      ---------------------------------------

      • Export Primary fields includes columns for all case custom data fields of any type (same rules as we have for Activity custom data export).
      • Export - Select fields exposes all case custom fields in hierarchical select for inclusion in export.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                lcdweb Brian Shaughnessy
                Reporter:
                lcdweb Brian Shaughnessy
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: