Attribute Names for use in coding custom S-Drive Lightning Components

If you are creating your own custom Lightning Component for S-Drive, you can use these same attributes found when configuration the out-of-the-box component on a Lightning page. The attributes are shown here with their description, attribute name, and default value if applicable.

 

Attribute/Description (release where first available)

Attribute Name

Default Value

Attribute/Description (release where first available)

Attribute Name

Default Value

Title

This is the title of the page block inside the object page. You can set it to "Account Files" (or Case Files, Contact Files, etc) or whatever title you like. This field is optional and if you don't provide a value for this field, it will be set to "S-Drive Files".

title

 

Use Custom Logo on Header

Checking this box will enable inserting a custom logo. In order to enable this checkbox, add your logo image to Static Resource with the name 'SCustomLogo' first. Note that Static Resource should be public.

logo

false

Use Compact View

Checking this box will enable a compact view of S-Drive which will help users to fit S-Drive into narrow spaces. In compact view, toolbar operations will be limited to the following: navigate to Home, upload files, download files and folders, create folders, navigate to recycle bin.

enableCompactView

false

Parent object name

The name of the object that the files will be attached to.

customObjectName

 

Parent object prefix

The object's namespace prefix, if it has one.

objectNamespacePrefix

 

File object name

The name of the S-Drive file object you are configuring. This object holds the information regarding the attached files. For our example, "My_Example_Object_File__c".

customObjectFileName

 

File object prefix

The file object's namespace prefix. Since you created the file object and it’s not part of a managed package, this should be left blank.

fileNamespacePrefix

 

Relationship field name

Master-detail or lookup relation used for selected standard/custom object. This should be set to 'Parent__r'. The name of your lookup field on your file object should be Parent__c.

relationshipName

The lookup field on your file object should be named Parent__r

Component Id

If multiple S-Drive components are used in a page, this attribute should be set to a unique key for each component. For example: '1', 'a', etc.

componentId

1

Enable copy URL

This option is used to enable/disable "Copy URL" link in the page. If the checkbox is checked, you will be able to see the "Copy URL" link for each asset. The default value for this checkbox is checked.

enableCopyUrl

true

Enable delete

This option is used to enable/disable "Delete" option for all attachments in the page. If the checkbox is checked, you will be able to see the "Delete" link for each asset. The default value for this checkbox is checked.

enableDelete

true

Enable download

This option is used to enable/disable "Download" option for all attachments in the page. If the checkbox is checked, you will be able to see the "Download" link for each asset. The default value for this checkbox is checked.

enableDownload

true

Enable edit

This option is used to enable/disable "Edit" option for all attachments in the page. If the checkbox is checked, you will be able to see the "Edit" link for each asset. The default value for this checkbox is checked.

enableEdit

true

Enable e-mail

This option is used to enable/disable "E-Mail" option for all attachments in the page. If the checkbox is checked, you will be able to see the "E-Mail" link for each asset. The default value for this checkbox is checked.

enableEmail

true

Default email address

You can use this option, if you want to set a default "Additional To" email address for sending emails from your S-Drive Attachments. For example, if you select an Account S-Drive Attachment for an account and click "Email" button, "Email Files" screen will be opened and "Additional To" field will be filled with the email address you have provided here.

defaultEmailAddress

 

Enable upload

This option is used to enable/disable "Upload" option for all attachments in the page. If the checkbox is checked, you will be able to see the "Upload File(s)" link for each asset. The default value for this checkbox is checked.

enableUpload

true

Enable Drop Zone

This option is used to configure drop zone in S-Drive components. Select/deselect the checkbox to enable or disable the drop zone.

isDropzoneEnabled

true

Allowed file extensions

You can use this option if you want to limit the file types to be uploaded into selected object's S-Drive attachments. Semicolon separated list of file extensions that are allowed to be uploaded can be written here. This attribute is optional and leaving this empty will allow all kind of files to be uploaded. For example, "*.jpg, *.txt" will limit the files to be uploaded to jpg and txt files.

allowedFileExtensions

 

Enable folders

This option is used to enable/disable folder support for S-Drive attachments in the page. If the checkbox is checked, you will be able to see the "New Folder" button. The default value for this checkbox is checked. If the box is not checked, the "New Folder" button will be removed from the toolbar section.

enableFolders

true

Enable private files

This option is used for enabling public/private file access to the S-Drive attachments and commonly used to limit the customer portal users' access to individual files. The ability for users to configure this is determined by the main configuration settings in S-Drive Configuration Tab. If the checkbox is checked, you will see the public/private flag. Set this attribute to true by checking the checkbox, if you want to enable private/public flag. Setting the private flag on a file hides the file from customer portal users. The default value for this checkbox is unchecked.

privateEnabled

false

Enable Public Share

This option is used to configure public share in S-Drive components. Select the checkbox to see Public Share option in Actions Menu. Deselect the checkbox to disable Public Share in Actions Menu.

isPublicShareEnabled

false

Enable Chatter

This option is used for enabling/disabling Chatter for Account files. If you enable this option, you will be able to use functions such as 'Post to Chatter' and will be able to view the Chatter feed of each Account file.

enableChatter

true

Disable Cut Copy Paste

This option is used for enabling/disabling cut/copy-paste options. Set this attribute to true by checking the checkbox if you want to disable cut/copy-paste operations.

disableCutCopyPaste

false

Enable Shortcut Creation

This option is used to configure Shortcut Creation in S-Drive components. Select the checkbox to see Create Shortcut button on toolbar. Deselect the checkbox to disable Create Shortcut button on toolbar.

isShortcutEnabled

false

Enable Open Original File

Causes “Open Original File” action to show on shortcuts if checked. The action takes the user to the file record of the file underlying the shortcut.

enableOpenOriginalFile

false

Default sort field name

This option is used to order/sort S-Drive documents based on a field. Specify the name of the field that should be used to order the list of files. For example, "File_Name__c". If you are creating a custom Lightning Component for a file object included in the S-Drive managed package, add the namespace prefix: cg__File_Name__c

sortField

cg__File_Name__c

Default sort order

This option is used to set the sort order direction of the S-Drive documents. There are two possible values for this attribute: "asc" for ascending or "desc" for descending.

sortOrder

asc

Files Count for A Page

This option is to set the number of files to be shown per page in the S-drive component. If this value is set to '30' and object has 91 total items, the files will be displayed in 4 pages.

pageSize

100

Default view type

This option is to set the default view type of the file list table. There are 3 options you can choose: List, Thumbnail and Grid.

viewType

list

Show Folder Tree

This option sets the default behavior (show or hide) of the folder tree component located on the left-hand side of the S-Drive attachments page.

showFolderTree

true

Show Breadcrumb

This option sets the default behavior of the breadcrumbs located on the left-hand side of the S-Drive attachments page, above the folder tree component. You can choose to hide or show the breadcrumbs.

showBreadcrumb

true

Open File After Clicking on It

This option is used to configure the behavior when clicking on a file. Set to true to open the file when it is clicked on. Select false to go to the Details view of the file.

openWhenClickedOnFile

false

Enable Field

This option is used to show or hide the Fields button on toolbar which is used to select and display fields in columns next to the file name. Set to true to enable the button on toolbar and false to hide it.

enableField

true

Enable Manual Sharing (2.8)

This option determines whether manual sharing is allowed on files. It is only used on customer file objects that have a lookup relationship to the parent.

enableManualSharing

true

Enable Inherit Sharing Checkbox (2.8)

This option controls whether the Inherit Sharing checkbox is shown or hidden when creating subfolders and uploading files. If true, it is shown. This is only used on file objects that have a lookup relationship to the parent.

enableInheritSharingCheckbox

true

Enable Inherit Sharing by Default (2.8)

This option controls whether the Inherit Sharing checkbox is checked or unchecked by default. If you hide the Inherit Sharing checkbox, you still need to use this setting to determine whether Inherit Sharing is true or false when subfolders are created and files are uploaded. This is only used on file objects that have a lookup relationship to the parent.

defaultInheritSharingValue

true

Show Audit Tab (2.7.14)

This option determines whether or not the Audit Tab is shown when clicking on file details

isAuditTabEnabled

true

Enable Online Editing (2.14)

If Online Editing is configured in the org, this attribute determines whether it is enabled on this S-Drive component. If Online Editing is not configured for the org, this attribute is ignored.

enableOnlineEditing

false

Show Recycle Bin Button (2.17)

This option shows the green Recycle Bin button in the Folder Tree pane if checked.

enableRecycleBin

true

Show Checked Out Files Button (2.17)

This option shows the blue Checked Out Files button in the Folder Tree pane if checked.

enableCheckedOutFiles

true

Show Legal Hold Files Button (2.17)

This option shows the blue Legal Hold Files button in the Folder Tree pane if checked.

enableLegalHoldFiles

true