I've got a client that makes a lot of payments to ...
# suitescript
k
I've got a client that makes a lot of payments to their customers. Because of this each customer has a corresponding vendor record for the vendor payment to cut a check. This is how their implementation partner set them up, not my solution. To do this they use the Other Relationships field on the customer record to create a Vendor record that is tied to the Customer. Other customers are then the "Payor" which make customer payments that get deposited to be paid to the vendors who are the customers who actually get paid by the client. Yeah, it's complicated! I'm working on a suitelet "report" that outputs a list of vendor payments and deposits and their end customer which has all the end customer's account information. My question is, how do you find the "Other Relationships" field via search, SuiteQL, or worst case record.load() so it can be pulled by SuiteScript and displayed in the suitelet? Attached is a screenshot of the field and its help on the Customer record.
b
do an entity query with a filter on the type column
💯 1
k
like literally right when you posted haha
their answer isn't quite the same but it got me to what you're saying
Thank you!
g
With other relationships internal ids are the same between the entities so if you prefer suiteql you can just do a join on id between vendor and customer.
👍 2