Created
May 22, 2015 10:12
-
-
Save jeznag/836b3963f4398531e99f to your computer and use it in GitHub Desktop.
Mass update lookups in Zoho CRM using custom function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void update_vendor_lookup (int finance_equity_id) | |
finance_equity_obj = zoho.crm.getRecordById("CustomModule4", finance_equity_id); | |
lender_string = finance_equity_obj.get("Lender"); | |
lender_id = 0; | |
if (lender_string.contains("Adelaide")){ | |
//figure out appropriate lookup value based on picklist | |
lender_id = 1002375000002270019; | |
} | |
//update lookup | |
if (lender_id != 0){ | |
finance_equity_obj.put("Lender Name_ID", lender_id); | |
finance_equity_id_str = toString(finance_equity_id); | |
updateResp = zoho.crm.updateRecord("CustomModule4", finance_equity_id_str, finance_equity_obj); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment