3

In Civi 4.6, when you filed/moved and activity to a case, you could choose a closed case from the list. In fact, there was a conditional to show closed cases with a strikethrough. In 4.7, when everything was moving to EntityRef that little piece was removed and all references to "file on case" assumes the case is open.

While I've been able to track down some lines I could comment out (in the parameters of the addEntityRef) to allow closed cases to populate the list again - that means a custom PHP file. I guess I was wondering if it is predominant that people only file on open cases? The behavior feels strange that you wouldn't want to be able to include (or have an option to on the form itself) closed cases.

Does anyone else file on closed cases and have a different workaround?

1 Answer 1

2

UPDATE: Can do this with an extension using hook_civicrm_alterEntityRefParams. It also magically adds a Case Status filter in the "refine search" dropdown that appears when you start typing a name. See https://lab.civicrm.org/dev/core/-/issues/2209#note_51075 and https://github.com/AsylumSeekersCentre/civicrm-moveActivityToAnyCase


While I'd vote to bring the ability to file on a closed case back, or maybe make it a configuration option to allow or not, one workaround is to use the email processor and put the case id in square brackets in the subject (https://issues.civicrm.org/jira/browse/CRM-21446). It will happily file it on a closed case. Information about setting up the email processor is here https://docs.civicrm.org/sysadmin/en/latest/setup/civimail/inbound/#autofiling-email-activities-via-emailprocessor

And if you edit an activity and add the case id in square brackets to the subject and then save, it will file on case, e.g. "this is the subject [case #1234]"

According to the issue you linked, https://issues.civicrm.org/jira/browse/CRM-17645 you should be able to use a hook_civicrm_entityGet in an extension to alter the query, but I'm not sure from those notes that it actually got implemented.

5
  • 2
    What magic is this!!? I didn't know the trick about editing the case subject. It totally still works, should anyone else stumble on this be sure to use the format listed in the jira issue Demerit linked - i.e. [case #12345]
    – RayWright
    Commented Nov 20, 2018 at 21:31
  • 1
    It's great to know someone else would benefit from filing on a closed case. Not sure what will work out, but I'm going to look into the hook for maintainability - thanks for that direction.
    – RayWright
    Commented Nov 20, 2018 at 21:33
  • only thing to note for others, perhaps as an edit to the answer, is that for this to work you need to have Inbound Emails set up too - google.co.nz/…. happy for Demerit to cut and paste in his answer
    – petednz - fuzion
    Commented Nov 21, 2018 at 1:38
  • 1
    also to note, i would probably support getting that feature back, as D says as an 'opt-in' setting - however I would also note we have many clients using Cases and have never had any request for this so not sure how much usage it would have
    – petednz - fuzion
    Commented Nov 21, 2018 at 1:39
  • @petednz the edit subject and save feature doesn't require it, but yes the email processor requires some setup. I will edit answer.
    – Demerit
    Commented Nov 21, 2018 at 4:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.