CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviCase (Moderator: Dave Greenberg) »
  • CiviCase and Webform
Pages: [1]

Author Topic: CiviCase and Webform  (Read 1298 times)

Parvez

  • I post occasionally
  • **
  • Posts: 91
  • Karma: 7
CiviCase and Webform
December 12, 2012, 02:07:27 pm
Hi All

We're working on a project at the moment which we will model using CiviCase. The system to be implemented is to allow branches to file plans for the coming year into CiviCRM. We'll be doing this using CiviCase to allow the branches to manage the activities around the plans and to be to able to have some workflow to the completion of a plan etc.

We've started to use Webform to configure the user interface as the Branch users are not going to be trained CiviCRM users, the aim being to produce a simple set of fields for them to complete, resulting in the creation of a case.

We have the following issues at present and are hoping someone can shed some light on them

1. Following the successful submission of a webform a case is created as expected. What we'd like to do is to present the user with the case overview - is there any way we can get the case id created during the submission so that we can navigate to the case overview page?

2. We'd like to have the case description as part of the web form but it doesn't appear as a field we can select, the same issue applies to the start date of the case. Is there any way we can get these fields to appear in webforms?

Thanks in advance

Parvez

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: CiviCase and Webform
December 12, 2012, 10:03:43 pm
Case subject I believe is already exposed as a webform field.
Start date is currently hardcoded to now(). We'd need to expose that as a field
To get the case ID we'd also need to expose that as a field.
Adding fields in webform_civicrm isn't hard, although in both cases simply adding the field isn't quite enough you'd also need to ensure they are processed correctly.
Try asking your question on the new CiviCRM help site.

Parvez

  • I post occasionally
  • **
  • Posts: 91
  • Karma: 7
Re: CiviCase and Webform
December 13, 2012, 03:22:18 am
Thanks Coleman.

I think Case Subject is exposed but not the case Description, which we need.

If you could point me in the direction of what to read/look at I'm happy to give it a shot locally and supply some patches for the work done.

Thanks

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: CiviCase and Webform
December 13, 2012, 09:20:58 am
well in theory if you simply add a field to the wf_crm_get_fields() function in webform_civicrm_utils.inc and use the name supported by the api and fill in the field info as supported by webform, it will work. But you'll also need to get rid of the code that auto-sets the start date (or make it conditional, in case the api does not supply this default). And you'll also need to make sure the hidden id field gets populated. Take a look at how we do that for the hidden contact id fields.
Try asking your question on the new CiviCRM help site.

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: CiviCase and Webform
December 13, 2012, 10:14:21 am
Quote from: Coleman Watts on December 13, 2012, 09:20:58 am
well in theory if you simply add a field to the wf_crm_get_fields() function in webform_civicrm_utils.inc and use the name supported by the api and fill in the field info as supported by webform, it will work.
I love this guy's idea of 'simply' ;-)
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviCase (Moderator: Dave Greenberg) »
  • CiviCase and Webform

This forum was archived on 2017-11-26.