Skip to main content

I need to display data in LWC like the below order

 

Custom Object Rec1.field

Custom Object Rec2.Document Link (Download Link for Doc uploaded to ContentVersion)

 

Custom Object Rec2.field

Custom Object Rec2.Document Link (Download Link for Doc uploaded to ContentVersion)

 

I am using the below scenario:

on connectedcallback(), i am calling Apex function which returns the Custom Object Record in Map structure Map<Custom_Object_Rec_ID, Custom_Object_Rec>. But i am not able to add Document Record to this Map. 

 

Could anyone please suggest me the better way to send Custom Object and Content Document record in one Data structure?  Thanks

 

Also, i am sending all the contentdocument in another separate array. But in LWC html as there is not able to compare the Custom Object Id and Attachment Parent Id, displays all attachments with all rows.

 

Thanks

Syam

3 respuestas
0/9000