2

I am currently implementing a pre-chat screen for Live Agent. I want the prescreen to open the account based on screen name (which is working correctly) and then open a case - bypassing record type screen. (Which is not working, it always opens to the "select record type" for case.)

Below is the code. Help me stackexchange, you're my only hope. :(

<!-- Map the detail inputs to the Account fields --> 
<input type="hidden" name="liveagent.prechat.findorcreate.map:Account" value="FirstName,first-name;LastName,last-name;Screen_Name__c,screen-name;" />

<!-- Try to find the Account by screen name (exact match) -->
<input type="hidden" name="liveagent.prechat.findorcreate.map.doFind:Account" value="Screen_Name__c,true;" />
<input type="hidden" name="liveagent.prechat.findorcreate.map.isExactMatch:Account" value="Screen_Name__c,true;" />

<!-- If the Account is not found, then create one with the following fields set -->
<input type="hidden" name="liveagent.prechat.findorcreate.map.doCreate:Account" value="FirstName,true;LastName,true;Screen_Name__c,true;" />

<!-- Save the Account on the Live Chat Transcript's Account Lookup -->
<input type="hidden" name="liveagent.prechat.findorcreate.saveToTranscript:Account" value="Account" />

<!-- Show the Account when it is found or created -->
<input type="hidden" name="liveagent.prechat.findorcreate.showOnCreate:Account" value="true" />

<!-- Create a Case every time -->
 <input type="hidden" name="liveagent.prechat:caseOrigin" value="Chat" />
  <input type="hidden" name="liveagent.prechat:caseRecordType" value="Incident" />
  <input type="hidden" name="liveagent.prechat.findorcreate.map.doCreate:Case" value="Origin,caseOrigin;RecordType,caseRecordType;Subject,drop-down;Description,issue" />
  <input type="hidden" name="liveagent.prechat.findorcreate.map.doCreate:Case" value="Origin,true;RecordType,true;Subject,true;Description,issue" />
  <input type="hidden" name="liveagent.prechat.findorcreate.saveToTranscript:Case" value="Case" />
  <input type="hidden" name="liveagent.prechat.findorcreate.showOnCreate:Case" value="true" />

<!-- Link the Account to the Case -->
  <input type= "hidden" name="liveagent.prechat.findorcreate.linkToEntity:Account" value="Case,AccountId" />
1
  • In a Guest Profile, you can restrict user to access only one Case record type so Record type selection will be bypassed. Nov 5, 2014 at 21:44

3 Answers 3

1

You seem to be using the doCreate case method twice, so I think that part is not working. Try changing it to:

  <input type="hidden" name="liveagent.prechat.findorcreate.map:Case" value="Origin,caseOrigin;RecordType,caseRecordType;Subject,drop-down;Description,issue" />

  <input type="hidden" name="liveagent.prechat.findorcreate.map.doCreate:Case" value="Origin,true;RecordType,true;Subject,true;Description,issue" />
0

We ran into the same issue. You need to reference the record type ID so your content should look something like this:

input type="hidden" name="liveagent.prechat:caseRecordType" value="0121a0000001nX3"

input type="hidden" name="liveagent.prechat.findorcreate.map:Case" value="RecordTypeId,caseRecordType"

input type="hidden" name="liveagent.prechat.findorcreate.map.doCreate:Case" value="RecordTypeId,true"

input type="hidden" name="liveagent.prechat.findorcreate.showOnCreate:Case" value="true"

I've left a record type ID in there just for the sake of the example, but just go to your record type and grab what you want to open.

0

If this isn't working for you make sure you check field requirements and validation rules. Make sure you are populating all required data in your page.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .