So if the lookup code in the Title contact is "XYZ". Then they would be able to view folder "ABC".
Visibilty Conditions Examples
You may need to modify it to loop through the contacts you are concerned with. Ultimately, return true if you find a match; false otherwise.
# Only show this folder/document if there is a Lender with a code that has "abc" (code used for ___ bank).
# and if the file is a CD file type
# Code can be typed in any case combination
# If there is No Lender selected on the file or Lookup Code of selected Lender is blank, Hide Folder/file
for Lender in Order.Lenders(0):
if (Lender(0).LookupCode == None or not Lender.LookupCode):
# Not added to collection yet.
elif Lender.LookupCode.lower() == 'abc' and hasattr(Order,'SettlementType') and str(Order.SettlementType)=='CDF':
Code: Select all
# Only show this folder/document if there is a Lender with the specified lookup code # and if the file is a CD file type. # Enter Lender's code below. Can be typed in any case combination. lenderLookupCode = 'abc' # SettlementType values are defined below so logic can use any settlement type. SettlementType_CDF = 0 SettlementType_HUD1 = 1 SettlementType_CSS = 2 # Don't display folder/document unless order is CDF. if int(Order.SettlementType) != SettlementType_CDF: return False # Force all lookup code comparisons to lowercase to so we don't have to # worry about mixed case later. lenderLookupCode = lenderLookupCode.lower() # We will check each lender, one at a time, to see if we can find the valid # lookup code. If so, display folder/document. for lender in Order.Lenders: if lender.LookupCode and lender.LookupCode.lower() == lenderLookupCode: # Found our lookup code - make items visible. return True # We didn't find the lender. Don't display the folder/document. return False