public DoctorProfile(Options opt) { int lang_id = 1; if (opt.Lang == "ar") { lang_id = 0; } var app = new MainApp(); var doc = new DoctorEndPoint(); /* since the url does not indicate which city or dept */ opt.Department = doc.GetDoctorDept(opt.DocId)[1]; opt.City = doc.GetDocCity(opt.DocId, "en"); opt.Country = "sa"; this.UserId = doc.GetDoctorUserId(opt.DocId); this.comments = GetComments(opt, doc); this.offers = GetDoctorOffers(opt, doc); this.engagment = GetEngagments(opt, doc); this.info = GetDoctorCard(opt, doc); this.ActivePackage = doc.HasActivePackage(opt.DocId); if (!this.ActivePackage) { this.otherdoctors = GetOtherDoctors(opt, doc); } else { this.otherdoctors = new List <DoctorCard>(); } this.cities = app.Set_cities(opt.Lang, opt.Cities); this.DocRatingDetails = doc.GetDoctorGradeDetails(opt.DocId); this.info.City_name = opt.City; this.info.Dept_name = opt.Department; this.info.City_name = doc.GetDocCity(opt.DocId, opt.Lang); this.info.Dept_name = doc.GetDoctorDept(opt.DocId)[lang_id]; this.city = doc.GetDocCity(opt.DocId, "en").ToLower(); this.country = "sa"; opt.City = this.city.ToLower(); opt.Country = this.country.ToLower(); this.departments = app.GetDepartments(opt); if (this.info.ShowMob != "N") { this.ShowMobile = true; this.Call = this.info.Call; } else { this.ShowMobile = false; } this.info.Inst_names = doc.AcceptFormAppointment(this.info.Inst_names); foreach (var i in this.info.Inst_names) { if (i.AccetFormApnt) { this.AcceptApnt = true; } } }
public Home(Options opt) { var app = new MainApp(); var inst = new InstituteEndPoint(); var doc = new DoctorEndPoint(); this.institutes = inst.GetInstitutes(opt, 0, 6); this.doctors = doc.GetDoctors(opt, 0, 6); this.cities = app.Set_cities(opt.Lang, opt.Cities); this.departments = app.GetDepartments(opt); }
public InstitutesHomePage(Options opt) { var app = new MainApp(); var inst = new InstituteEndPoint(); this.offers = GetInstsOffers(opt, inst); this.slides = GetSlides(opt, inst); this.institutes = GetInstituteCards(opt, inst); this.cities = app.Set_cities(opt.Lang, opt.Cities); this.departments = app.GetDepartments(opt); }
public DepartmentProfile(Options opt) { var app = new MainApp(); var doc = new DoctorEndPoint(); this.department_name = doc.GetDeptArabicName(opt.Department); this.icon = opt.Department.Replace(' ', '_') + ".png"; //this.comments = GetComments(opt, doc); this.offers = GetDoctorOffers(opt, doc); this.engagment = GetEngagments(opt, doc); this.otherdoctors = GetOtherDeptDoctors(opt, doc); this.doctors = GetDeptDoctors(opt, doc, this.otherdoctors); this.info = GetDepartmentInfo(opt, app); this.cities = app.Set_cities(opt.Lang, opt.Cities); this.departments = app.GetDepartments(opt); }
public InstituteProfile(Options opt) { var app = new MainApp(); var doc = new DoctorEndPoint(); var inst = new InstituteEndPoint(); this.comments = GetComments(opt, doc); this.offers = GetDoctorOffers(opt, inst); this.engagment = GetEngagments(opt, doc); this.doctors = GetInstDoctors(opt, doc); this.info = GetInstituteCard(opt, inst); this.cities = app.Set_cities(opt.Lang, opt.Cities); this.city = inst.GetInstCity(this.info.Id, "en").ToLower(); this.country = "sa"; opt.City = this.city.ToLower(); opt.Country = this.country.ToLower(); this.departments = app.GetDepartments(opt); this.info.City_name = inst.GetInstCity(this.info.Id, opt.Lang); }
public Department GetDepartmentInfo(Options opt, MainApp ep) { var others = ep.GetDepartments(opt); return(others[0]); }