Skip to content

Instantly share code, notes, and snippets.

@arun12209
Created June 19, 2019 18:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arun12209/4491fa99f85a9831bf1b079497a2b3bb to your computer and use it in GitHub Desktop.
Save arun12209/4491fa99f85a9831bf1b079497a2b3bb to your computer and use it in GitHub Desktop.
filesCard
<aura:component controller="FilesController" implements="force:appHostable,flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId,forceCommunity:availableForAllPageTypes,force:lightningQuickAction" access="global" >
<aura:attribute name="recordId" type="string"/>
<aura:attribute name="filesIds" type="list"/>
<aura:handler name="init" value="{!this}" action="{!c.doInit}"/>
<div class="slds">
<div class="slds-page-header">Uploaded Files</div>
<lightning:layout multipleRows="true">
<aura:iteration items="{!v.filesIds}" var="f">
<lightning:layoutItem padding="around-large" size="6" smallDeviceSize="12" mediumDeviceSize="6">
<lightning:fileCard fileId="{!f.ContentDocumentId}" description="{!f.ContentDocument.title}"/>
</lightning:layoutItem>
</aura:iteration>
</lightning:layout>
</div>
</aura:component>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment