/// <summary> /// Prepare researcher search model /// </summary> /// <param name="searchModel">Researcher search model</param> /// <returns>Researcher search model</returns> public virtual ResearcherSearchModel PrepareResearcherSearchModel(ResearcherSearchModel searchModel) { if (searchModel == null) { throw new ArgumentNullException(nameof(searchModel)); } //prepare available stores _baseAdminModelFactory.PrepareAgencies(searchModel.AvailableAgencies, true, "--รหัสหน่วยงาน--"); _baseAdminModelFactory.PreparePersonalTypes(searchModel.AvailablePersonTypes, true, "--รหัสประเภทบุคลากร--"); _baseAdminModelFactory.PrepareActiveStatuses(searchModel.AvailableActiveStatues, true, "--รหัสสถานะเข้าใช้งานระบบ--"); //prepare page parameters searchModel.SetGridPageSize(); return(searchModel); }