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

In smart groups, for CiviCase fields, relative date ranges are saved as fixed ranges

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 4.7.15, 4.7.16, 4.7.17
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding
    • Verified?:
      No

      Description

      This was fixed for other fields in CRM-19250, but is still an issue for CiviCase fields such as `Case Start Date` and `Case End Date`.

      I don't know whether this used to work in any previous version.

      Steps to reproduce:
      1. Configure CiviCase as needed, and create a case with end date of yesterday's date (today is 2017-03-01, so I would use 2017-02-28).
      2. Perform an Advanced Search for cases with Case End Date of "yesterday".
      3. Save all search results as a Smart Group, "Cases ending yesterday".
      4. Observe that the smart group contains the correct number of contacts.
      5. Make no changes to End Dates for any case included in the Smart Group, and the next day, view Smart Group results again.

      Expected behavior:
      1. Contacts with Case End Date of 2017-02-28 should no longer be in the smart group.
      2. When editing Smart Group criteria (e.g., /civicrm/contact/search/advanced?reset=1&force=1&ssID=N), the Case End Date criteria should be selected to "Yesterday".

      Actual behavior:
      1. Contacts with Case End Date of 2017-02-28 are still in the smart group, even after several days have passed, and after clearing smart group cache, etc.
      2. When editing Smart Group criteria (e.g., /civicrm/contact/search/advanced?reset=1&force=1&ssID=N), the Case End Date criteria is oddly written as "To: 20170228235959 (see attached case_relative_date.png)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                allenshaw Allen Shaw
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated: