Save the file locally, decode with:
base64 -d -i q365527.zip.base64 > q365527.zip
Then decompress these files into a force-app/main/default/ directory.
Finally, deploy to your org:
sfdx force:source:deploy -p force-app
<aura:application extends="force:slds"> | |
<c:q317434 /> | |
</aura:application> |
@isTest without sharing class wSharingTest { | |
@isTest static void test() { | |
Account a = new Account(Name='Name'); | |
User u = [SELECT FIELDS(STANDARD) FROM User WHERE Id = :UserInfo.getUserId()].deepClone(false, false, false); | |
u.FederationIdentifier = '12345'; | |
u.Alias = '12345678'; | |
u.UserName += '.brian.fear'; | |
u.CommunityNickname = '12345678'; | |
u.ProfileId = [SELECT Id FROM Profile WHERE Name LIKE 'Standard%' LIMIT 1].Id; | |
System.runAs(new User(Id=UserInfo.getUserId())) { |
Save the file locally, decode with:
base64 -d -i q365527.zip.base64 > q365527.zip
Then decompress these files into a force-app/main/default/ directory.
Finally, deploy to your org:
sfdx force:source:deploy -p force-app
Download this as a ZIP file, move the files so they line up in the proper places, then deploy. | |
force-app/main/default/classes/StockMarketSharesWrapper.cls | |
force-app/main/default/classes/StockMarketSharesWrapper.cls-meta.xml | |
force-app/main/default/lwc/wrapperList/wrapperList.html | |
force-app/main/default/lwc/wrapperList/wrapperList.js | |
force-app/main/default/lwc/wrapperList/wrapperList.js-meta.xml | |
Support for question https://salesforce.stackexchange.com/q/365372/2984 |
// Regexp from https://stackoverflow.com/questions/201323/how-can-i-validate-an-email-address-using-a-regular-expression | |
public class Utils { | |
public static String[] findEmailsInString(String source) { | |
String emailRegex = '(?:[a-z0-9!#$%&\'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&\'*+/=?^_`{|}~-]+)*|"(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21\\x23-\\x5b\\x5d-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\\[(?:(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9]))\\.){3}(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9])|[a-z0-9-]*[a-z0-9]:(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21-\\x5a\\x53-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])+)\\])'; | |
Pattern p = Pattern.compile(emailRegex); | |
Matcher m = p.matcher(source); | |
String[] emails = new String[0]; | |
while(m.find()) { | |
emails.add(m.group(0)); | |
} |
// Randomly select A-Z, a-z, 0-9 | |
String randomStringAllEnhanced(Integer count) { | |
Integer[] chars = new Integer[0], | |
offsets = new Integer[] { 48, 65, 97 }, | |
mods = new Integer[] { 10, 26, 26 }; | |
while(count > chars.size()) { | |
Integer rnd = Math.abs(Crypto.getRandomInteger()), cat = Math.mod(rnd, 3), seed = Math.mod(rnd, mods[cat]); | |
chars.add(seed+offsets[cat]); | |
} | |
return String.fromCharArray(chars); |
<aura:component > | |
<aura:attribute name="currentStep" type="String" /> | |
<aura:attribute name="steps" type="String[]" /> | |
<aura:attribute name="renderInfo" access="private" type="Object[]" /> | |
<aura:registerEvent name="onselect" type="c:valueSelected" /> | |
<aura:handler name="init" value="{!this}" action="{!c.update}" /> | |
<aura:handler name="change" value="{!v.steps}" action="{!c.update}" /> |
public class q341460 { | |
public String property { | |
get; | |
set; | |
} { | |
property = 'Default Property Value'; | |
} | |
public final String finalProperty { | |
get; |