// ---------------------------------------------------------------------------------- // Confidentiality // ---------------------------------------------------------------------------------- #region Confidentiality public static bool IsAffectedByConfidentiality(FacilitySearchFilter filter) { DataClassesFacilityDataContext db = getDataContext(); ParameterExpression param = Expression.Parameter(typeof(FACILITYSEARCH_ALL), "s"); Expression exp = LinqExpressionBuilder.GetLinqExpressionFacilitySearchConfidential(filter, param); // create lambda according to filters Expression <Func <FACILITYSEARCH_ALL, bool> > lambda = Expression.Lambda <Func <FACILITYSEARCH_ALL, bool> >(exp, param); // return true if found any return(getDistinctFacilityReportIds(db, lambda).Any()); }