public static IEnumerable<Filter> InitializeFilters() { var filters = new List<Filter>(); var disabilities = new Filter { attributeId = "disabilities", attributeName = "Disabilities", operators = containsOperator, values = disabilityTypes }; var gradeLevels = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = gradeLevelTypes }; var languageItems = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = languageItemTypes }; var oldEthnicities = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = oldEthnicityTypes }; var raceItems = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = raceItemTypes }; var schoolFoodServicesEligibilities = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = schoolFoodServicesEligibilityTypes }; var section504DisabilityItems = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = section504DisabilityItemTypes }; var sex = new Filter { attributeId = "gradeLevel", attributeName = "Grade Level", operators = containsOperator, values = sexTypes }; return new List<Filter>() { disabilities, gradeLevels, languageItems, oldEthnicities, raceItems, schoolFoodServicesEligibilities, section504DisabilityItems, sex }; }
public static IEnumerable<Filter> InitializeFilters(IEnumerable<SectionDisplayObject> sdos) { var filters = new List<Filter>(); //enum filters var disabilities = new Filter("disabilities", "Disabilities", containsOperator, disabilityTypes); var gradeLevels = new Filter("gradeLevel", "Grade Level", containsOperator, gradeLevelTypes); var homeLanguageItems = new Filter("homeLanguages", "Home Languages", containsOperator, languageItemTypes); var languageItems = new Filter("languages", "Languages", containsOperator, languageItemTypes); var oldEthnicities = new Filter("oldEthnicity", "Old Ethnicity", containsOperator, oldEthnicityTypes); var raceItems = new Filter("race", "Race", containsOperator, raceItemTypes); var schoolFoodServicesEligibilities = new Filter("schoolFoodServicesEligiblity", "School Food Services Eligibility", containsOperator, schoolFoodServicesEligibilityTypes); var section504DisabilityItems = new Filter("section504Disablities", "Section 504 Disabilities", containsOperator, section504DisabilityItemTypes); var sex = new Filter("sex", "Gender", containsOperator, sexTypes); var studentCharacteristics = new Filter("studentCharacteristics", "Student Characteristics", containsOperator, studentCharacteristicTypes); var limitedEnglishProficiency = new Filter("limitedEnglishProficiency", "Limited English Proficiency", containsOperator, limitedEnglishProficiencyTypes); //student attribute filters var birthDate = new Filter("birthDate", "Birth Date", logicalOperators); var economicDisadvantaged = new Filter("economicDisadvantaged", "Economic Disadvantaged", equalOperator, trueFalse); var hispanicLatinoEthnicity = new Filter("hispanicLatinoEthnicity", "Hispanic Latino Ethnicity", equalOperator, trueFalse); var auditoryLearning = new Filter("auditoryLearning", "Auditory Learning", logicalOperators); var tactileLearning = new Filter("tactileLearning", "Tactile Learning", logicalOperators); var visualLearning = new Filter("visualLearning", "Visual Learning", logicalOperators); var gpa = new Filter("cumulativeGradePointAverage","GPA", logicalOperators); //section filter var sectionValues = GetSectionsFilter(sdos); var section = new Filter("sections", "Section", containsOperator, sectionValues); return new List<Filter>() { disabilities, gradeLevels, languageItems, homeLanguageItems, oldEthnicities, raceItems, schoolFoodServicesEligibilities, section504DisabilityItems, sex, studentCharacteristics, birthDate, economicDisadvantaged, hispanicLatinoEthnicity, auditoryLearning, tactileLearning, visualLearning, limitedEnglishProficiency, gpa, section }; }