Thumbnail View - Display infos
Relevant information can be displayed on image thumbnails in SharinPix albums. The options that can be displayed are:
- Filename
- Tags
- Title
- Date
- Custom label
Abiltity | Value | Description |
---|---|---|
Filename | Boolean | Displays the filename of the image. |
Tags | Boolean | Displays the tags applied on the image. To see how to tag images, click here. |
Title | Boolean | Displays the image's title. This value can be set either by making use of the image_caption ability or on the SharinPix mobile app. |
Date | String | Displays the date on which the image has been created. Date formats can be found here. For example, date: 'L'
|
Custom label | String | This parameter allows the display of a custom label. The value of the custom label should be stored in a Salesforce field on the sObject SharinPixImage__c. The Salesforce field API name should then be used as the value for the parameter custom_label, for example: custom_label: 'CustomFilename__c' , where CustomFilename__c refers to the API name of the Salesforce field storing the value for the custom label. |
SharinPix Permission
SharinPix Permissions can be used to activate the abilities corresponding to the above mentioned options.
Apex Class & VF Page Implementations
The display parameters can be used as shown in the following code snippets.
public class ThumbnailInfos {
private Map<String, Object> params;
public test(ApexPages.StandardController stdCtrl) {
String albumId = (Id)stdCtrl.getId();
params = new Map<String, Object>{
'path' => '/pagelayout/' + albumId,
'abilities' => new Map<String, Object> {
albumId => New Map<String, Object> {
'Access' => new Map<String, Object> {
'see' => true,
'image_list' => true,
'image_upload' => true
},
'Display' => new Map<String, Object> {
'tags' => true,
'title' => true,
'date' => 'L'
}
}
},
'download' => true,
'custom_label' => 'sharinpix__FileName__c'
};
}
public String getParameters() {
return JSON.serialize(params);
}
}
Click to copy
<apex:page docType="html-5.0" cache="false"
showHeader="false"
sidebar="false"
standardStylesheets="false"
standardController="Account"
extensions="ThumbnailInfos"
applyHtmlTag="false"
applyBodyTag="false">
<sharinpix:sharinpix id="iframe" parameters="{!parameters}" ></sharinpix:sharinpix>
<sharinpix:CustomData componentId="iframe"></sharinpix:CustomData>
</apex:page>
Click to copy
Tip:
SharinPix also provides download parameters that can be used to personalize the download filenames. For more information about these parameters and how to configure them, refer to the following article:
Multiple Image download (ZIP) - How to personalize the download filenames
0 Comments
Add your comment