public static void SetLists(System.Web.UI.WebControls.ListControl myListControl, ParameterSP parameter) { string sp = "dbo.tcdsb_PLF_ListDDL2New @Operate,@UserID,@UserRole,@SchoolYear"; List <List2Item> myList = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); AssemblingMyList(myListControl, myList); }
public static void SetLists2(System.Web.UI.WebControls.ListControl myListControl, System.Web.UI.WebControls.ListControl myListControl2, object parameter) { string sp = "dbo.tcdsb_LTO_ListSchoolsNew @Operate, @Para0, @Para1, @Para2, @Para3"; List <List2Item> myListData = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); AssemblingSchoolList(myListControl, myListControl2, myListData); }
private void OnShutdown() { if (GeneralDataAccess.Connection.State == System.Data.ConnectionState.Open) { GeneralDataAccess.CloseConnection(); } }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IWebHostEnvironment env, IHostApplicationLifetime applicationLifetime) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } else { app.UseExceptionHandler("/Home/Error"); // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts. app.UseHsts(); } applicationLifetime.ApplicationStopping.Register(OnShutdown); AppContext.Configure(app.ApplicationServices.GetRequiredService <IHttpContextAccessor>()); GeneralDataAccess.SetConfiguration(Configuration); app.UseHttpsRedirection(); app.UseStaticFiles(); app.UseRouting(); app.UseAuthentication(); app.UseAuthorization(); app.UseEndpoints(endpoints => { endpoints.MapControllerRoute( name: "default", pattern: "{controller=Home}/{action=Index}/{id?}"); }); }
public static void AssembleProfilePage(Page myPage, string operate, string userID, string CPNum) { try { Staff parameter = new Staff { Operate = operate, UserID = userID, CPNum = CPNum }; string sp = "dbo.tcdsb_LTO_RosterLTOProfileAction @Operate,@UserID,@CPNum"; var profile = new List <Staff>(); profile = GeneralDataAccess.GetListofTypeT <Staff>(sp, parameter); Label newLable = (Label)myPage.FindControl("LabelSchoolName"); newLable.Text = profile[0].SchoolName; newLable = (Label)myPage.FindControl("LabelTeacherName"); newLable.Text = profile[0].TeacherName; newLable = (Label)myPage.FindControl("LabelCPNum"); newLable.Text = profile[0].CPNum; newLable = (Label)myPage.FindControl("LabelHireDate"); newLable.Text = profile[0].DateOfHire; newLable = (Label)myPage.FindControl("LabelCurrentStatus"); newLable.Text = profile[0].OTType; TextBox newtextbox = (TextBox)myPage.FindControl("LabelOCTQualification"); newtextbox.Text = profile[0].Qualification; } catch (Exception ex) { var exm = ex.Message; throw new Exception(); } }
private static List <Staff> StaffList(Staff parameter) { string sp = "dbo.tcdsb_LTO_RosterTCDSBSeachbyNameAndCPNum @SearchBy,@SearchValue"; List <Staff> staffs = GeneralDataAccess.GetListofTypeT <Staff>(sp, parameter); return(staffs); }
private static List <List2Item> GetListData(object parameter) { string sp = "dbo.tcdsb_LTO_ListDDLNew @Operate,@Para0,@Para1,@Para2,@Para3"; var myListData = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); // var myListData = GeneralExe.DDList(parameter); // GeneralDataAccess.GetListofTypeT<List2Item>(sp, parameter); return(myListData); }
public static void SetLists2(System.Web.UI.WebControls.DropDownList myListControl, System.Web.UI.WebControls.DropDownList myListControl2, ParameterSP parameter) { string sp = "dbo.tcdsb_PLF_ListSchoolsNew @Operate,@UserID,@UserRole,@SchoolYear,@SchoolCode"; List <List2Item> myList = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); AssemblingMyList(myListControl, myList, "myValue", "myValue"); // school Code DDL AssemblingMyList(myListControl2, myList, "myValue", "myText"); // School Name DDL }
public static void SetLists3(System.Web.UI.WebControls.ListControl myListControl1, System.Web.UI.WebControls.ListControl myListControl2, System.Web.UI.WebControls.ListControl myListControl3, object parameter) { string sp = "dbo.tcdsb_LTO_ListSchoolPrincipalsNew @Operate, @Para0, @Para1, @Para2, @Para3"; List <List2Item> myList = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); AssemblingMyList(myListControl1, myList, "myValue", "myText"); // school Code DDL AssemblingMyList(myListControl2, myList, "myValue", "myText"); // school Code DDL AssemblingMyList(myListControl3, myList, "myValue", "myText"); // school Code DDL }
public static string Signature2(string operate, string userID, string schoolYear, string schoolCode, string actionType) { Signature parameter = new Signature { Operate = operate, UserID = userID, SchoolYear = schoolYear, SchoolCode = schoolCode, ActionType = actionType }; return(GeneralDataAccess.TextValue(sp, parameter)); // return SignatureProcess.SignoffResult(operate, userID, userRole, schoolYear, schoolCode, actionType); }
public static string TeamMemberSelect(string operate, string userID, string schoolYear, string schoolCode, string actionType, string employeeID, string selected, string comment) { string sp1 = sp + ",@ActionType,@TeacherID,@Checked,@Comments"; ParameterSP3 parameter = new ParameterSP3 { Operate = operate, UserID = userID, SchoolYear = schoolYear, SchoolCode = schoolCode, ActionType = actionType, TeacherID = employeeID, Checked = selected, Comments = comment }; return(GeneralDataAccess.TextValue(sp1, parameter)); // return PLFSiteTeam.Selected(operate, userID, schoolCode, schoolYear, actionType, employeeID, selected, comment); }
public static void SetSearchList(System.Web.UI.WebControls.ListControl myListControl, string operate, string para0, string para1) { List2Item parameter = new List2Item { Operate = operate, Para0 = para0, Para1 = para1 }; string sp = "dbo.tcdsb_LTO_ListDDL_SearchList @Operate,@Para0,@Para1"; List <List2Item> myListData = GeneralDataAccess.GetListofTypeT <List2Item>(sp, parameter); // myListData = GeneralExe.SearchList(parameter); AssemblingMyList(myListControl, myListData); }
public static void SetLists(System.Web.UI.WebControls.ListControl myListControl, string operate, string userID, string userRole, string schoolYear) { string sp = "dbo.tcdsb_PLF_ListDDL2New @Operate,@UserID,@UserRole,@SchoolYear"; ParameterSP parameter = new ParameterSP { Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear }; List <List2Item> myList = GeneralDataAccess.GetLists(sp, parameter); // List<List2Item> myList = UListItem.GetLists(operate, userID, userRole, schoolYear); /// new List<List2Item>(); AssemblingMyList(myListControl, myList); }
public string Operation(T position, string sp, string action) { try { var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; throw; } }
public IList <T> IGeneralListOfT(string sp, object parameter) { try { var list = GeneralDataAccess.ListofT <T>(sp, parameter); return(list); } catch (Exception ex) { var exm = ex.Message; return(null); } }
public string GeneralValue(string SP, object parameter) { try { var result = GeneralDataAccess.TextValue(SP, parameter); return(result); } catch (Exception ex) { var exm = ex.Message; throw; } }
public static string RePosting(PositionPosting parameter) { try { string parameters = "@Operate,@UserID,@SchoolYear,@PositionID, @PostingCycle,@TakeApplicant"; string sp = "dbo.tcdsb_LTO_PositionDetails_RePosting " + parameters; string result = GeneralDataAccess.TextValue(sp, parameter); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public IList <TeacherListForPrincipalInterview> GetList(ParametersForPosition parameter) { try { string sp = "dbo.tcdsb_LTO_TeacherList_InterviewCandidate @SchoolYear,@PositionID"; var list = GeneralDataAccess.GetListofTypeT <TeacherListForPrincipalInterview>(sp, parameter); return(list); } catch (Exception ex) { var exm = ex.Message; return(null); } }
// get Default position Date public static List <LimitDate> LimitedDate(object parameter) { try { string sp = "dbo.tcdsb_LTO_PositionDetails_DefaultDate @Operate, @AppType, @SchoolYear"; List <LimitDate> limitedate = GeneralDataAccess.GetListofTypeT <LimitDate>(sp, parameter); return(limitedate); } catch (System.Exception ex) { string em = ex.Message; return(null); } }
// get sigal position by ID public static List <PositionPosting> PositionByID(ParameterCL parameter) { try { string sp = "dbo.tcdsb_LTO_PositionDetails_PublishbyID @SchoolYear,@PositionID"; List <PositionPosting> position1 = GeneralDataAccess.GetListofTypeT <PositionPosting>(sp, parameter); return(position1); } catch (System.Exception ex) { string em = ex.Message; return(null); } }
public static string CancelPosting(PositionPosting parameter) { try { string sp = "dbo.tcdsb_LTO_PositionDetails_CancelPosting @Operate,@UserID,@SchoolYear,@PositionID, @Comments"; string result = GeneralDataAccess.TextValue(sp, parameter); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public string RevokeHire(object position, int positionID) { try { string sp = "dbo.tcdsb_LTO_PageHired_Operation @Operate, @UserID, @SchoolYear, @PositionType, @PositionID, @CPNum, @Action"; var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public string UpdatePosting(object position, int positionID) { try { // @Operate ="RePosting" string sp = "dbo.tcdsb_LTO_PageConfirmForHiring_Operation @Operate,@UserID,@SchoolYear,@SchoolCode,@PositionID,@Comments"; var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public static string Content(ParameterSP0 parameter) { try { string sp = "dbo.tcdsb_PLF_FormData_WebAPI @Operate,@UserID,@UserRole,@SchoolYear,@SchoolCode,@ItemCode,@Value"; // ParameterSP0 parameter = new ParameterSP0 { Operate = "Content", SchoolYear = schoolYear, SchoolCode = schoolCode, ItemCode = itemCode, Value = value }; return(GeneralDataAccess.TextValue(sp, parameter)); } catch (Exception ex) { var exm = ex.Message; return(""); } }
public string ConfirmHire4thRound(object position, int positionID) { try { string sp = "dbo.tcdsb_LTO_PageConfirmForHiring4th_Operation @Operate, @UserID, @SchoolYear, @PositionType, @PositionID, @CPNum, @Comments,@Acceptance, @DateConfirm, @DateEffective, @DateEnd, @PrincipalEmail, @OfficerEmail, @Action, @PayStatus,@TeacherName"; var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public string PostingApproveOperation(PositionApprove position, string action) { try { string sp = GetSP(position.Operate); var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public string HiringOperation(ParametersForOperationHire position, string action) { try { string sp = GetSP(action); var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public string RejectRequestPosting(object position, int positionID) { // Exec Rejection try { // Operate = "Reject" string sp = GetSP("Reject"); // "dbo.tcdsb_LTO_PageApprove_Operation @Operate,@UserID,@SchoolYear,@SchoolCode,@PositionID, @Comments,@CPNum"; var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }
public static List <ApplicantNotice> ApplicantsNoticebyID(ApplicantNotice parameter) { try { string sp = "dbo.tcdsb_LTO_PagePublish_NoticeToTeacherList @UserID, @SchoolYear,@PositionID,@Action"; List <ApplicantNotice> noticelist = GeneralDataAccess.GetListofTypeT <ApplicantNotice>(sp, parameter); return(noticelist); } catch (System.Exception ex) { string em = ex.Message; return(null); } }
public string Posting(object position, int positionID) { try { string sp = GetSP("Posting");//"dbo.tcdsb_LTO_PageApprove_Operation @Operate,@UserID,@SchoolYear,@SchoolCode,@PositionID,@Comments,@CPNum,@StartDate,@EndDate,@DatePublish,@DateApplyOpen,@DateApplyClose,@RequestSource"; var result = GeneralDataAccess.TextValue(sp, position); return(result); } catch (Exception ex) { var exm = ex.Message; return("Failed"); } }