Yvonne
10/28/2022, 1:41 AMvar numLines = context.newRecord.getLineCount({
sublistId: 'deposit'
});
Outcome: numLines displays 1
However if I try it off of the loaded record, it doesn't work:
var customerRefund = record.load({
type: record.Type.CUSTOMER_REFUND,
id: context.newRecord.id
});
var numLines = customerRefund.getLineCount({
sublistId: 'deposit'
});
Outcome: numLines displays -1
Furthermore, the following returns a (correctly applied) count of deposit applications, however in the UI, clicking on the link takes you to the customer deposit, NOT the deposit application:
var numLines = customerRefund.getLineCount({
sublistId: 'apply'
});
Just trying to see if anyone can explain why one might work over the other, and maybe if there is a good way to frame decisions around when to use each different option?battk
10/28/2022, 2:08 AMbattk
10/28/2022, 2:09 AMbattk
10/28/2022, 2:10 AMbattk
10/28/2022, 2:12 AMbattk
10/28/2022, 2:12 AMbattk
10/28/2022, 2:14 AMbattk
10/28/2022, 2:15 AMYvonne
10/28/2022, 2:58 AMbattk
10/28/2022, 2:59 AMYvonne
10/28/2022, 2:59 AM