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
// Asking for extra CPU time and heap for those really "heavy" orgs | |
@isTest class GetExtraLimitsForYourUnitTest implements Queueable { | |
@testSetup static void testSetup() { | |
Test.startTest(); // TIP: this avoids governor limits for your @isTest methods | |
System.enqueueJob(new GetExtraLimitsForYourUnitTest()); // We'll get async limits! | |
// P.S. Did you know that the end of a unit test method triggers async code, | |
// just as if you called Test.stopTest()? | |
} | |
public void execute(QueueableContext context) { | |
// I now have 60000ms to do my setup, instead of just 10000ms. |
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
#!/usr/bin/env python3 | |
# Author: SAVITHRU LOKANATH | |
# Login to Telegram on web browser https://web.telegram.org | |
# Create an API key here: https://core.telegram.org/api | |
# Install tesseract-ocr: apt-get install tesseract-ocr && pip install pytesseract | |
# Install Telethon lib: pip install telethon | |
# Install Text-to-Speech lib if using Windows: pip install pyttsx3 | |
# To run, increase speaker volume to 100% & in your cmd prompt: python3 listener_visa_slots.py |
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
#!/bin/bash | |
TARGET_ORG=$1 | |
if ["$TARGET_ORG" == ""]; then | |
echo Please specify a target username | |
echo For a list of available usernames use: sfdx force:org:list | |
exit 1 | |
fi |
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
<template> | |
<div> | |
<template if:true={ranger} > | |
<lightning-record-view-form | |
record-id={ranger} | |
object-api-name="Contact"> | |
<div class="potato slds-box" style={boxClass}> | |
<lightning-output-field field-name="Name"> | |
</lightning-output-field> | |
<lightning-output-field field-name="Email"> |
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
/** | |
* Selector for the `Account` entity | |
*/ | |
public class AccountSelector { | |
public static final AccountSelector INSTANCE = new AccountSelector(); | |
/** | |
* Finds all accounts that are child accounts of | |
* the given opportunity's account. |
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
// Help report errors to parent/child object on failed DML update | |
// For use in Trigger contexts only. | |
// This version is for demonstration purposes only, and should not | |
// be considered production ready without additional modifications. | |
// | |
// Example trigger: | |
// | |
// trigger updateContactPhone on Account(after update) { | |
// Id[] updates = new Id[0]; | |
// for(Account record: Trigger.new) { |
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 class TreeNodeDataProvider { | |
@AuraEnabled public static User[] getUsers() { | |
return [SELECT Name, ManagerId, SmallPhotoUrl FROM User]; | |
} | |
} |
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
<aura:application extends="force:slds" controller="AccountListFilterByCity"> | |
<aura:attribute name="cities" type="List" default="[]" /> | |
<aura:attribute name="allAccounts" type="List" default="[]" /> | |
<aura:attribute name="filterAccounts" type="List" default="[]" /> | |
<aura:handler name="init" value="{!this}" action="{!c.init}" /> | |
<lightning:layout> | |
<lightning:layoutItem size="3"> | |
<aura:iteration items="{!v.cities}" var="cityValue"> |
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 class PageController { | |
// Transient so we don't exceed view state limits | |
public transient String fileType { get; set; } | |
public transient Blob fileBody { get; set; } | |
ApexPages.StandardController controller; | |
public PageController(ApexPages.StandardController controller) { | |
this.controller = controller; | |
} |
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
<macrodef name="snapshot" description="Snapshots all metadata in an organization - Revision 22"> | |
<attribute name="username" /> | |
<attribute name="password" /> | |
<attribute name="serverurl" default="https://login.salesforce.com" /> | |
<attribute name="outPath" default="temp/snapshot" description="Directory to write snapshot." /> | |
<sequential> | |
<!-- prompt user to confirm --> |
NewerOlder