This file contains hidden or 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
| <link rel="import" href="../../salesforce/mobile-ui-elements/elements/force-sobject/force-sobject.html"> | |
| <link rel="import" href="../../salesforce/mobile-ui-elements/elements/force-ui-list/force-ui-list.html"> | |
| <polymer-element name="my-element"> | |
| <template> | |
| <style> | |
| :host { | |
| position: absolute; | |
| width: 100%; |
This file contains hidden or 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
| FLOOR((suraj__Actual_End_Date__c - suraj__Actual_Start_Date__c)/7)*5*9 + | |
| MIN(5,FLOOR(MOD((suraj__Actual_End_Date__c - suraj__Actual_Start_Date__c),7)))*9+ | |
| IF((TIMEVALUE(suraj__Actual_End_Date__c)-TIMEVALUE("12:00:00.00"))/(3600*1000)>16,0,MIN(9,(TIMEVALUE(suraj__Actual_End_Date__c)-TIMEVALUE("12:00:00.00"))/(3600*1000))) - IF((TIMEVALUE(suraj__Actual_Start_Date__c)-TIMEVALUE("12:00:00.00"))/(3600*1000)>16,0,MIN(9,(TIMEVALUE(suraj__Actual_Start_Date__c)-TIMEVALUE("12:00:00.00"))/(3600*1000))) |
This file contains hidden or 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
| import {createRecord} from 'lightning/uiRecordApi'; | |
| const fileData={ | |
| Title:'Test File', | |
| PathOnClient:'myfile.txt', | |
| VersionData: window.btoa('Hello,World'), | |
| Description:'test file' | |
| } | |
| const payload={apiName:'ContentVersion',fields:fileData}; | |
| createRecord(payload); |
This file contains hidden or 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
| const colheaders = Object.keys(rows[0]); | |
| const errors=[]; | |
| const regexpArray=[]; | |
| rows.forEach((row,rowindex)=>{ | |
| errors[rowindex]=[]; | |
| Object.values(row).forEach((val,colindex)=>{ | |
| if(regexpArray[colindex] && regexpArray[colindex].test(val)){ | |
| errors[rowindex].push(colheaders[colindex]); | |
| } | |
| }) |
This file contains hidden or 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
| const cleanFunction = arr=>arr.reduce((clean,current)=>{current.replace(/[^(?<!\\)"]/g,"").length%2>0?clean+=current+"\\n":clean+=current+"\n";return clean},"").replace(/\\n$/,'') |
This file contains hidden or 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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <Package xmlns="http://soap.sforce.com/2006/04/metadata"> | |
| <fullName>Standard & Global Picklists</fullName> | |
| <types> | |
| <members>*</members> | |
| </types> | |
| <types> | |
| <members>Industry</members> | |
| <members>AccountContactRole</members> | |
| <members>AccountOwnership</members> |
This file contains hidden or 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
| /** | |
| * This code is untested. | |
| * Assumes references to images in rich text fields is in the form of 'https://<url>/<documentId>' and refers to a document record | |
| */ | |
| public class ImageToBase64{ | |
| public void convertToBase64(Id[] recordIds){ | |
| Account[] accts = new Account[]{}; | |
| Map<Id,Id[]> acctDocMap = new Map<Id,Id[]>(); | |
| Map<Id,Document> docMap = new Map<Id,Document>(); |
This file contains hidden or 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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <Package xmlns="http://soap.sforce.com/2006/04/metadata"> | |
| <fullName>layouts</fullName> | |
| <types> | |
| <members>Account-Account %28Marketing%29 Layout</members> | |
| <members>Account-Account %28Sales%29 Layout</members> | |
| <members>Account-Account %28Support%29 Layout</members> | |
| <members>Case-Case %28Marketing%29 Layout</members> | |
| <members>Case-Case %28Sales%29 Layout</members> | |
| <members>Case-Case %28Support%29 Layout</members> |
This file contains hidden or 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
| const path = require('path'); | |
| module.exports = { | |
| mode: "production", | |
| entry: "./src/index", | |
| output: { | |
| // options related to how webpack emits results | |
| path: path.resolve(__dirname, "dist"), // string | |
| // the target directory for all output files | |
| // must be an absolute path (use the Node.js path module) |
This file contains hidden or 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
| const flatten = (obj,newobj,prefix)=>{ | |
| if(!newobj)newobj={}; | |
| for(let prop in obj){ | |
| if(!prefix)prefix=''; | |
| if(typeof obj[prop]==='object') | |
| flatten(obj[prop],newobj,prefix+prop); | |
| else | |
| newobj[prefix+prop] = obj[prop]; | |
| } | |
| return newobj; |
OlderNewer