In my Lookup it must show only those contacts who have Specific role.
Example:
Contact-1 , Contact-2 are present
Contact-1 Have Role-1 and contact-2 will have Role-2
Lookup must show only Contacts with Role-1 .
If not possible Can we have workaround for this .
In my Example it will show all contacts who are system users.
for these i want to filter collection based on role.
I tried this Please let me know the changes needed.
"lookupListConfig": {
// Array of filters used for the query that forms the lookup field data.
"filters": [
function() {
var filterGroup = Ext.create("Terrasoft.FilterGroup");
// Adding the "IsUser" filter to the resulting filters collection.
// The filter provides for the selection of all records in the Contact core schema
// to which the Id column from the SysAdminUnit schema is connected, for which
// Id is not equal to null.
filterGroup.add("IsUser",
Terrasoft.createColumnIsNotNullFilter("[SysAdminUnit:Contact].Id"));
// Adding the "IsActive" filter to the resultant filters collection.
// The filter provides for the selection of all records from the core schema.
// Contact to which the Id column from the SysAdminUnit schema, for which
// Active=true, is connected.
filterGroup.add("IsActive",
Terrasoft.createColumnFilterWithParameter(
Terrasoft.ComparisonType.EQUAL,
"[SysAdminUnit:Contact].Active",
true));
return filterGroup;
}
]
}
}