Is it possible to Upload an Attachment on a New Record?

  • 2
  • Question
  • Updated 2 years ago
  • Answered
Photo of Jacob Flatter

Jacob Flatter

  • 1,512 Points 1k badge 2x thumb

Posted 5 years ago

  • 2
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
There has to be an existing record before the Skuid file component can attach its file to the record.  We've not built the ability for it to use the "Proto" Ids we use in new records.   I'd reccomend a two step process where the bare minimum record creation data is saved first - and then redirected to a page where the full record is fleshed out - including the image. 

Sorry. 
Photo of Bill White

Bill White

  • 362 Points 250 badge 2x thumb
I have the same issue of wanting to add some standard template attachments when creating a new Case record.  

I see this was answered a year ago.  Would the solution now be to use Action Framework to create the redirection?  Also, is it now possible to add attachments automatically in the Action Framework?

I am sure an alternative is to create a shopping cart popup concept automatically.  I have done this for adding child Case records, but not straight attachments to the Case object.  Is that possible?
Photo of Anna Wiersema

Anna Wiersema

  • 10,890 Points 10k badge 2x thumb
Yes Bill, you can use the actions framework to save the record and then activate conditions on your attachment model (so it picks up the newly-generated full Parent Id). Then a user could upload an attachment via the file upload component.  Is that what you mean by adding attachments automatically?
Photo of Aishwarya

Aishwarya

  • 290 Points 250 badge 2x thumb
Hi Anna, 

It seems a possible work around, could you please elaborate your solution a bit more. I need to implement this if it could work.

Thanks 
Photo of Bill White

Bill White

  • 362 Points 250 badge 2x thumb
Anna,

Not exactly what I am asking.  I have a set of standard template documents that need to be attached to a new record.  I would like to restrict the variability of adhoc manual attaching of these standard document sets.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
I don't think the action framework is going to help you here. 

What you need to do is create a new copy of an existing attachment and pass that new attachment ID to the appropriate field in your new record.  I really don't think you want to do that client side in Skuid - it sounds more like an "after insert" trigger. 
Photo of mB Pat Vachon

mB Pat Vachon, Champion

  • 42,714 Points 20k badge 2x thumb
What you could do is attach the documents temporarily to any record and then use action framework to update the parent Id to the new record once saved.
Photo of Aishwarya

Aishwarya

  • 290 Points 250 badge 2x thumb
Hi Pat,

What you mean by Action framework here? I am new to skuid. But I need to implement this solution.

Thanks