Skip to content

Commit

Permalink
Fixes #82 - with caveats about the need to extend the LWC to support …
Browse files Browse the repository at this point in the history
…all of the fields necessary - by enforcing validation rules for performFullRecalculation method in Rollup
  • Loading branch information
jamessimone committed Apr 22, 2021
1 parent 5689bf8 commit f311cae
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ Create fast, scalable custom rollups driven by Custom Metadata in your Salesforc

### Package deployment options

<a href="https://login.salesforce.com/packaging/installPackage.apexp?p0=04t6g000008GJRnAAO">
<a href="https://login.salesforce.com/packaging/installPackage.apexp?p0=04t6g000008GJSbAAO">
<img alt="Deploy to Salesforce"
src="./media/deploy-package-to-prod.png">
</a>

<a href="https://test.salesforce.com/packaging/installPackage.apexp?p0=04t6g000008GJRnAAO">
<a href="https://test.salesforce.com/packaging/installPackage.apexp?p0=04t6g000008GJSbAAO">
<img alt="Deploy to Salesforce"
src="./media/deploy-package-to-sandbox.png">
</a>
Expand Down
6 changes: 6 additions & 0 deletions rollup/core/classes/Rollup.cls
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,12 @@ global without sharing virtual class Rollup implements Database.Batchable<SObjec
String potentialWhereClause,
String potentialConcatDelimiter
) {
// TODO - need to be able to supply fullRecalculationDefaultStringValue, fullRecalculationDefaultNumberValue, and orderByFirstLast
FlowInput validationRuleWrapper = new FlowInput();
validationRuleWrapper.rollupOperation = operationName.toUpperCase();
validationRuleWrapper.concatDelimiter = potentialConcatDelimiter;
enforceValidationRules(validationRuleWrapper);

QueryWrapper wrapper = new QueryWrapper(lookupSObjectName, lookupFieldOnLookupObject);
wrapper.setQuery(potentialWhereClause);
return performFullRecalculationInner(
Expand Down
3 changes: 2 additions & 1 deletion sfdx-project.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"apex-rollup@1.2.7-0": "04t6g000008GJNqAAO",
"apex-rollup@1.2.8-0": "04t6g000008GJNvAAO",
"apex-rollup@1.2.9-0": "04t6g000008GJQVAA4",
"apex-rollup@1.2.10-0": "04t6g000008GJRnAAO"
"apex-rollup@1.2.10-0": "04t6g000008GJRnAAO",
"apex-rollup@1.2.11-0": "04t6g000008GJSbAAO"
}
}

0 comments on commit f311cae

Please sign in to comment.