fkrauthan
09/08/2023, 5:44 PMYou must enter at least one line item for this transaction. anyone has any other idea how to create a vendor payment for vendors that have thousands of open bills?
and obviously calls like findSublistLineWithValue fail to find the line itemalien4u
09/08/2023, 6:27 PMBill Payments and Customer Payments with many lines findSublistLineWithValue is not going to work or find a line buried deep into that huge sublist.
There is a way to use defaultValues when doing the transform to select the required open bills, but I don't remember from the top of my head.alien4u
09/08/2023, 6:35 PMfkrauthan
09/08/2023, 6:37 PMfkrauthan
09/08/2023, 6:37 PMWatz
09/08/2023, 6:38 PMurl.resolveRecord({
recordType: record.Type.VENDOR_PAYMENT,
recordId: '',
isEditMode: true,
params: {
entity: entity,
bill: billId,
subsidiary: subsidiary,
},
});Watz
09/08/2023, 6:39 PMalien4u
09/08/2023, 6:40 PMfkrauthan
09/08/2023, 6:42 PMfkrauthan
09/08/2023, 6:44 PMdisablepaymentfilters work for VENDOR_PAYMENTS as well the doc just says for DEPOSIT. Also it doesn't explain how to select the bill (or bills in some cases in case of batch payment) without using findSublistLineWithValuealien4u
09/08/2023, 6:46 PMfkrauthan
09/08/2023, 6:46 PMfkrauthan
09/08/2023, 6:57 PMYou have entered an invalid default value for this record initialize operation.battk
09/08/2023, 7:50 PMbill or vendorbills default valuesbattk
09/08/2023, 7:50 PMfkrauthan
09/08/2023, 7:51 PMbattk
09/08/2023, 7:51 PMfkrauthan
09/08/2023, 7:52 PMYou must enter at least one line item for this transaction.
(see initial message)fkrauthan
09/08/2023, 7:53 PMfindSublistLineWithValue but they all turned out with return -1battk
09/08/2023, 7:53 PMfkrauthan
09/08/2023, 7:54 PMconst vendorPayment = record.transform({
fromType: record.Type[type],
fromId: billIds[0].billId,
toType: record.Type.VENDOR_PAYMENT,
isDynamic: false,
});
vendorPayment.setValue({
fieldId: "account",
value: sourceAccount,
});
and then
const lineItem = vendorPayment.findSublistLineWithValue({
sublistId: "apply",
fieldId: "internalid",
value: billId,
});
(in case I have more then that single bill id)battk
09/08/2023, 7:55 PMbattk
09/08/2023, 7:55 PMbattk
09/08/2023, 7:55 PMbattk
09/08/2023, 7:55 PMfkrauthan
09/08/2023, 7:55 PMfkrauthan
09/08/2023, 7:56 PMbattk
09/08/2023, 7:56 PMfkrauthan
09/08/2023, 7:56 PMfkrauthan
09/08/2023, 7:56 PMfindSublistLineWithValue involvedbattk
09/08/2023, 7:57 PMbattk
09/08/2023, 7:58 PMfkrauthan
09/08/2023, 7:58 PMfkrauthan
09/08/2023, 7:59 PMbattk
09/08/2023, 7:59 PMbattk
09/08/2023, 7:59 PMbattk
09/08/2023, 7:59 PMfkrauthan
09/08/2023, 8:00 PMfkrauthan
09/08/2023, 8:00 PMbattk
09/08/2023, 8:00 PMvendorbills default value, or settle with code that sometimes workWatz
09/09/2023, 11:40 AMvendorbills defaultValue?battk
09/09/2023, 1:50 PMWatz
09/09/2023, 1:53 PMbattk
09/09/2023, 1:56 PMWatz
09/09/2023, 1:58 PMWatz
09/09/2023, 1:58 PMbattk
09/09/2023, 1:58 PMWatz
09/09/2023, 1:59 PMvendorbills ?Watz
09/09/2023, 2:01 PMWatz
09/09/2023, 2:03 PMvendorbills are shown. Nice to learn new tricks for the future if needed. Thanks!