move task from contact to lead with action

  • 1
  • Problem
  • Updated 7 months ago
  • In Progress
I'm trying to move task records from a contact to a lead with an action and it's not working. My first action is to remove the value from the WhatId...and that works...but when I add an action to update the Who.Id it doesn't work. I've tried changing the WhoId.Type field to Lead before udpating the Who.Id to no avail. Below are my actions. I know that it's pulling the newly created Lead ID okay because it loads it into the next object just fine (the ReferralSource). Thanks for any guidance!

Photo of Lauren Ake

Lauren Ake

  • 368 Points 250 badge 2x thumb
  • frustratttttttted

Posted 7 months ago

  • 1
Photo of Stephen Sells

Stephen Sells, Official Rep

  • 16,856 Points 10k badge 2x thumb
What does $Model.Inquiry.data.0.Id return in the console when you have your page opened and you're about to press the button?
Photo of Lauren Ake

Lauren Ake

  • 368 Points 250 badge 2x thumb
Hmm...I'm not sure how to do that..........
Photo of Stephen Sells

Stephen Sells, Official Rep

  • 16,856 Points 10k badge 2x thumb
If you're using Chrome, this is what you'll want to do:

  • Open the Skuid page you're describing above.
  • Bring the page to the state where you're right about to press the button
  • Press Command + Alt + J to see the command console OR View > Developer > Javascript Console
  • Then type in skuid.model.map()
  • Press enter
  • This will return all the models in your page. To find¬†$Model.Inquiry.data.0.Id you'd first select Inquiry, then data, then 0, then check to see what Id says.
Photo of Lauren Ake

Lauren Ake

  • 368 Points 250 badge 2x thumb
Looks like it's there?
Photo of Stephen Sells

Stephen Sells, Official Rep

  • 16,856 Points 10k badge 2x thumb
Wonderful. That's what it looks like. Whether that's the right Id or not is something you'll have to know based on your context. But now that you have this method, see what changes on skuid.model.map() from before and after the button is pressed. 
This is a great method to find out what is happening to the who.id described above.