Esempio n. 1
0
        public static string SignatureOld(string operate, string userID, string userRole, string schoolYear, string schoolCode, string actionType)
        {
            ParameterSP1 parameter = new ParameterSP1 {
                Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear, SchoolCode = schoolCode, ActionType = actionType
            };

            return(GeneralDataAccess.TextValue(sp, parameter));

            // return SignatureProcess.SignoffResult(operate, userID, userRole, schoolYear, schoolCode, actionType);
        }
Esempio n. 2
0
 public static List <School> GetSchoolHistroy(string operate, string userID, string userRole, string schoolYear, string schoolCode)
 {
     using (IDbConnection connection = new SqlConnection(conSTR))
     {
         string       SP        = "dbo.tcdsb_PLF_SchoolHistoryNew @Operate,@UserID,@UserRole,@SchoolYear,@SchoolCode";
         ParameterSP1 parameter = new ParameterSP1 {
             Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear, SchoolCode = schoolCode
         };
         var schoollist = connection.Query <School>(SP, parameter).ToList();
         return(schoollist);
     }
 }
Esempio n. 3
0
 public static string SignoffResult(string operate, string userID, string userRole, string schoolYear, string schoolCode, string actionType, string actionDate)
 {
     using (IDbConnection connection = new SqlConnection(conSTR))
     {
         string       SP        = sp + ",@ActionDate";
         ParameterSP1 parameter = new ParameterSP1 {
             Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear, SchoolCode = schoolCode, ActionType = actionType, ActionDate = actionDate
         };
         var myResult = connection.QuerySingle <SingleString>(SP, parameter);
         //  new { Operate = operate, UserID = userID, SchoolYear = schoolYear, SchoolCode = schoolCode,SchoolArea = schoolArea }).ToList();
         return(myResult.MyText);
     }
 }
Esempio n. 4
0
 public static List <SiteTeams> GetLists(string operate, string userID, string userRole, string schoolYear, string schoolCode)
 {
     using (IDbConnection connection = new SqlConnection(conSTR))
     {
         // connection.Query is a Dapper function
         //var output = connection.Query<Person>($"select * from People where LastName = '{lastName }'").ToList();
         string       SP        = sp;
         ParameterSP1 parameter = new ParameterSP1 {
             Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear, SchoolCode = schoolCode
         };
         var mylist = connection.Query <SiteTeams>(SP, parameter).ToList();
         //  new { Operate = operate, UserID = userID, SchoolYear = schoolYear, SchoolCode = schoolCode,SchoolArea = schoolArea }).ToList();
         return(mylist);
     }
 }
Esempio n. 5
0
 public static string SignatureOld(string operate, string userID, string userRole, string schoolYear, string schoolCode, string actionType, string actionDate)
 {
     try
     {
         ParameterSP1 parameter = new ParameterSP1 {
             Operate = operate, UserID = userID, UserRole = userRole, SchoolYear = schoolYear, SchoolCode = schoolCode, ActionType = actionType, ActionDate = actionDate
         };
         return(GeneralDataAccess.TextValue(sp, parameter));
         //  return SignatureProcess.SignoffResult(operate, userID, userRole, schoolYear, schoolCode, actionType, actionDate);
     }
     catch (Exception ex)
     {
         var exm = ex.Message;
         return("Failed");
     }
 }