this might be a simple question but when editing t...
# general
a
this might be a simple question but when editing the freemarker template for payment file templates, how do you reference information on the original bill? is it {transaction.X}?
hi - i'm still kind of stuck on this. i know you can reference company bank details, payment details etc., but how can you add a new custom field to the payment file template? for example, if you want a memo on the check - where would you store that field?
j
@automation_nation10 use the internal ID of the field. So memo would be transaction.memo If you need to add a brand new field, add a custom field and use the internal ID you defined there. If you're not sure about the internal ID of a native field, use the SuiteScript Records Browser in SuiteAnswers.
a
thanks. do you first have to add a custom EBP page and add the custom field there, then add it to the payment file template?
j
just add it to the template
a
ok thank you. and payment… refers to the aggregate of the payments and transaction.. is the individual bill payments?
j
not sure I'm fully tracking, but like for example ${transaction.tranid} would pull in the vendor bill document number and ${payment.tranid} would pull in the bill payment document number. Is that what you're asking?
a
yes i think so. Basically there is a memo field on the xml template so I’m trying to figure out where to source it from. It sounds like transaction.memo would take it from the vendor bill document
j
yep, that's correct
a
ok thanks! that seemed to work. I’m trying to pull in the reference number for the vendor bill but for some reason {transaction.tranid} doesn’t work. Any idea why?
j
As in it’s pulling something else or nothing at all? tranid is the internal ID for Document Number not the Reference Number. Use the SuiteScript Records Browser to find the record type and look up the internal ID of the field you want. Don’t recall it offhand but I think Reference Number is something like refno or refnum.
a
its just showing {transaction.tranid}. it seems like that is the ID for reference number in the records browswer
nevermind, i forgot the $ in front