Back
includedInObject()
Used as a shortcut to check if the specified IDs are a part of the main form object.
This method should only be used for hasMany
associations.
// Check to see if the customer is subscribed to the Swimsuit Edition. Note that the order of the `keys` argument should match the order of the `customerid` and `publicationid` columns in the `subscriptions` join table if(!includedInObject(objectName="customer", association="subscriptions", keys="#customer.key()#,#swimsuitEdition.id#")){ assignSalesman(customer); }
Copied!