This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface Executable { | |
void execute(String method); | |
} | |
public class DoAwesomeStuff implements Executable { | |
public override void execute(String method) { | |
if (method == 'method1') method1(); | |
else if (method == 'method2') method2(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT Id,PermissionsDelete,Parent.Profile.Name,SobjectType | |
FROM ObjectPermissions | |
WHERE Parent.IsOwnedByProfile = TRUE | |
AND PermissionsDelete = TRUE | |
ORDER BY Parent.Profile.Name, SObjectType | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var field = arguments[0], | |
value = arguments[1]; | |
if (field.mode == 'read') { | |
skuid.ui.fieldRenderers.DOUBLE.read(field,value); | |
} else { | |
skuid.ui.fieldRenderers.DOUBLE.edit(field,value); | |
skuid.utils.delayInputCallback( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var field = arguments[0], | |
value = arguments[1], | |
metadata = field.metadata, | |
dt = metadata.displaytype; | |
// For currency, double, and percent fields, | |
// manually override the field's metadata | |
// related to how many decimal points to display | |
if (dt == 'CURRENCY' || dt == 'DOUBLE' || dt == 'PERCENT') { | |
metadata.scale = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// jQuery | |
$('input[type="checkbox"]').prop('checked',true); | |
// DOM | |
Array.prototype.slice.call(document.querySelectorAll('input[type="checkbox"]')).forEach(function(e){e.setAttribute("checked","checked");}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// If your Visualforce Page currently looks like this: | |
<apex:page action="{!redirect}&objecttype=Account&actiontype=View" standardController="Account"/> | |
// Change it to look like this: | |
<apex:page standardController="Account" readonly="true" doctype="html-5.0"> | |
<skuid:page objectType="Account" actionType="View"/> | |
</apex:page> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// SETTINGS | |
// | |
var POSSIBLE_PICKLIST_VALUES = [ | |
'Education', | |
'College Counseling', | |
'Job Club', | |
'Full Medical & Dental Care', | |
'Mental Health', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Row Action snippet | |
skuid.snippet.registerSnippet('SyncPermSets_RowAction',function(){ | |
skuid.snippet.getSnippet('UpdatePermissionSetAssignmentsForUsers')({ | |
rows:[arguments[0].item.row] | |
}); | |
}); | |
// Mass Action snippet | |
skuid.snippet.registerSnippet('SyncPermSets_MassAction',function(){ | |
var rows = []; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<skuidpage showsidebar="true" showheader="true" tabtooverride="Case"> | |
<models> | |
<model id="Case" limit="1" query="false" createrowifnonefound="true" sobject="Case"> | |
<fields> | |
<field id="Subject"/> | |
<field id="Status"/> | |
<field id="Priority"/> | |
<field id="Latitude__c"/> | |
<field id="Longitude__c"/> | |
</fields> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<skuidpage showsidebar="true" showheader="true" tabtooverride="Case"> | |
<models> | |
<model id="CasePhoto" limit="1" query="false" createrowifnonefound="true" sobject="skuid__Image__c"> | |
<fields/> | |
<conditions/> | |
</model> | |
<model id="Case" limit="1" query="false" createrowifnonefound="true" sobject="Case"> | |
<fields> | |
<field id="Subject"/> | |
<field id="Description"/> |
OlderNewer