Log a Call or Task from Contact

I’m having an issue with a drawer button. I’d like to be able to log a call or just any task really related to a contact in a drawer.

A brief overview of how it’s setup. The main object is a custom object called registration and opening up the drawer it queries the related contact and displays some contact fields. 

I’d like to be able to log a task or a call using a button that will auto-fill and auto-relate the call to the contact. 

I’ve used this tutorial properly to get the appropriate contact info to display in the drawer here http://help.skuidify.com/m/components/l/269735-add-nested-rows-to-your-table-with-drawers.

But I can’t seem to transfer the queried contact to the Create a Task object. I just can’t figure out.

Any thoughts?


How is the contact related to the registration object?

  • junction
  • master-detail or lookup to Contact
  • master-detail or lookup from Contact

Lookup to Contact I believe. 

From the registation object, I’m able to select and drill down to the contact data. 

I’m assuming you mean that there is a Contact reference field on the Registration object.

Ok. Assuming you have the Contact__c, Contact__r.Id & Contact__r.Name fields on your Registration object.

1. Create a model for the Task object called “LogCall” with everything turned off in the Advanced settings.
2. Set two conditions. WhatId equal to Single Value Default Off. WhoId to Single Value default Off
3. Create a row action on the table with Action Type of Drawer
4. Set Drawer “Before Load Actions” to the following:
  a) Activate and Set Value of WhatId to {{Id}}
  b) Activate and Set Value of WhoId to {{Contact__c}}
  c) Query “LogCall” with Query Behaviour set to "Get More …"
5. Set the Context of the component(s) in the drawer of “Field = WhatId” and “Merge Field” = Id

The Contact should show in the drawer as the name set using the Contact__c value.
 

Hmm. I’m still having issues with it. I’ve done all of this successfully but I can’t seem to get it populating in the pop up field. 

I think the issue is that there’s the drawer, which is now running and querying appropriatetly, but now theres a pop up (Log a Call) with a title and field area but I can’t seem to transfer it to that pop up. 

Any ideas? 

Should the button be in a title area that is on the LogACall object or the contact or the registration?

Huh? Popup field?

Yea, so there’s a drawer and the there’s a button in the drawer for LogACall. The Log a Call and Log 2 or what I’m playing around with.

So table is showing registrations > Querying Contact to display contact fields in the drawer and Querying Log a Call.

Oh. What model(s) are used in the components in the drawer?

The drawer is opening the registration and there’s a query for Contact Model and now the LogACall Model in the LogACall pop up. 

Assuming the drawer is working, I’d do the following:

1. Create a model for the Task object called “LogCall” with everything turned off in the Advanced settings.
2. Set two conditions. WhatId equal to Single Value Default Off. WhoId to Single Value default Off
3. Create a button in a Page Title Component in the drawer. Ensure Page Title is set to the Registration model.
4. Set actions on the Button to the following:
  a) Empty Model Data of LogCall
  b) Activate and Set Value of WhatId to {{Id}}
  c) Activate and Set Value of WhoId to {{Contact__c}}
  d) Create a New Row in LogCall
  e) Show Popup

Assuming the drawer is working, I’d do the following:

1. Create a model for the Task object called “LogCall” with everything turned off in the Advanced settings.
2. Set two conditions. WhatId equal to Single Value Default Off. WhoId to Single Value default Off
3. Create a button in a Page Title Component in the drawer. Ensure Page Title is set to the Registration model.
4. Set actions on the Button to the following:
  a) Empty Model Data of LogCall
  b) Activate and Set Value of WhatId to {{Id}}
  c) Activate and Set Value of WhoId to {{Contact__c}}
  d) Create a New Row in LogCall
  e) Show Popup

Pat’s solution also assumes that the page title is connected to the contact model and that the same context condition you created on the contact field editors in the drawer are implemented for the page title component.  

To make sure you are getting the right data in context, put the merge field {{Contact__c}}  in the title area of the page title component. 

Ahh man we’re soooo close. 

So if I do that and add the ID fields to WhatId and ContactID it does populate the fields but… it keeps logging it to the top most registration in the table. 

Any ideas?

Figured it out Rob. Thanks a lot

GREAT!  I think your page title was looking at your registration data instead of your contact data.   Glad you got it working. 

Yea. And I didn’t double transfer the activate and set values. 

Thanks