public static int InsertPorjectStatus(int projectID, char deliverablesAndResultsStatus, string deliverablesAndResultsComments, char scheduleStatus, string scheduleComment, char capacityResourceStatus, string capacityResourceComment, char scopeStatus, string scopeComment, char clientSatisfactionStatus, string clientSatisfactionComment, char issuesAndRisksStatus, string issuesAndRisksComment, char useOfTestcontrolStatus, string useOfTestcontrolComment, char employeeSatisfactionStatus, string employeeSatisfactionComment, char knownOpportunityStatus, string knownOpportunityComment, char clientContactStatus, string clientContactComment) { List <SqlParameter> paramList = new List <SqlParameter>(); string query = "EXECUTE dbo.InsertProjectStatus @projectID, @deliverablesAndResultsStatus, @deliverablesAndResultsComment, @schedueStatus," + "@scheduleComment, @capacityResourceStatus, @capacityResourceComment, @scopeStatus, @scopeComment, @clientSatisfactionStatus," + "@clientSatisfactionComment, @issuesAndRisksStatus, @issuesAndRisksComment, @useOfTestControlStatus, @useOfTestControlComment," + "@employeeSatisfactionStatus, @employeeSatisfactionComment, @knownOpportunityStatus, @knownOpportunityComment, @clientContactStatus, @clientContactComment"; #region Parameters paramList.Add(new SqlParameter("@projectID", SqlDbType.Int)); paramList[0].Value = projectID; paramList.Add(new SqlParameter("@deliverablesAndResultsStatus", SqlDbType.VarChar, 1)); paramList[1].Value = deliverablesAndResultsStatus; paramList.Add(new SqlParameter("@deliverablesAndResultsComment", SqlDbType.VarChar, -1)); paramList[2].Value = deliverablesAndResultsComments; paramList.Add(new SqlParameter("@schedueStatus", SqlDbType.VarChar, 1)); paramList[3].Value = scheduleStatus; paramList.Add(new SqlParameter("@scheduleComment", SqlDbType.VarChar, -1)); paramList[4].Value = scheduleComment; paramList.Add(new SqlParameter("@capacityResourceStatus", SqlDbType.VarChar, 1)); paramList[5].Value = capacityResourceStatus; paramList.Add(new SqlParameter("@capacityResourceComment", SqlDbType.VarChar, -1)); paramList[6].Value = capacityResourceComment; paramList.Add(new SqlParameter("@scopeStatus", SqlDbType.VarChar, 1)); paramList[7].Value = scopeStatus; paramList.Add(new SqlParameter("@scopeComment", SqlDbType.VarChar, -1)); paramList[8].Value = scopeComment; paramList.Add(new SqlParameter("@clientSatisfactionStatus", SqlDbType.VarChar, 1)); paramList[9].Value = clientSatisfactionStatus; paramList.Add(new SqlParameter("@clientSatisfactionComment", SqlDbType.VarChar, -1)); paramList[10].Value = clientSatisfactionComment; paramList.Add(new SqlParameter("@issuesAndRisksStatus", SqlDbType.VarChar, 1)); paramList[11].Value = issuesAndRisksStatus; paramList.Add(new SqlParameter("@issuesAndRisksComment", SqlDbType.VarChar, -1)); paramList[12].Value = issuesAndRisksComment; paramList.Add(new SqlParameter("@useOfTestControlStatus", SqlDbType.VarChar, 1)); paramList[13].Value = useOfTestcontrolStatus; paramList.Add(new SqlParameter("@useOfTestControlComment", SqlDbType.VarChar, -1)); paramList[14].Value = useOfTestcontrolComment; paramList.Add(new SqlParameter("@employeeSatisfactionStatus", SqlDbType.VarChar, 1)); paramList[15].Value = employeeSatisfactionStatus; paramList.Add(new SqlParameter("@employeeSatisfactionComment", SqlDbType.VarChar, -1)); paramList[16].Value = employeeSatisfactionComment; paramList.Add(new SqlParameter("@knownOpportunityStatus", SqlDbType.VarChar, 1)); paramList[17].Value = knownOpportunityStatus; paramList.Add(new SqlParameter("@knownOpportunityComment", SqlDbType.VarChar, -1)); paramList[18].Value = knownOpportunityComment; paramList.Add(new SqlParameter("@clientContactStatus", SqlDbType.VarChar, 1)); paramList[19].Value = clientContactStatus; paramList.Add(new SqlParameter("@clientContactComment", SqlDbType.VarChar, -1)); paramList[20].Value = clientContactComment; #endregion return(DataBaseGenerics.InsertData(query, paramList, CommandType.Text)); }
public static DataSet GetClientDetails(int clientID) { SqlParameter param = new SqlParameter("@clientID", typeof(System.Int32)); param.Value = clientID; return(DataBaseGenerics.GetData("Execute SelectClient @clientID", param, CommandType.Text)); }
public static DataSet GetBusinessDevelopment(int businessDevelopmentID) { SqlParameter param = new SqlParameter("@businessDevelopmentID", SqlDbType.Int); param.Value = businessDevelopmentID; return(DataBaseGenerics.GetData("EXECUTE SelectBusinessDevelopment @businessDevelopmentID", param, CommandType.Text)); }
public static DataSet GetStatusItem(int statusItemID) { SqlParameter param = new SqlParameter("@statusItemID", SqlDbType.Int); param.Value = statusItemID; return(DataBaseGenerics.GetData("EXECUTE SelectStatusItem @statusItemID", param, CommandType.Text)); }
public static DataSet GetAllStatuses(int projectID) { SqlParameter param = new SqlParameter("@projectID", SqlDbType.Int); param.Value = projectID; return(DataBaseGenerics.GetData("EXECUTE SelectAllProjectStatus @projectID", param, CommandType.Text)); }
public static DataSet GetDeivery(int deliveryID) { SqlParameter param = new SqlParameter("@deliveryID", SqlDbType.Int); param.Value = deliveryID; return(DataBaseGenerics.GetData("EXECUTE SelectDelivery @deliveryID", param, CommandType.Text)); }
public static int InsertPerson(string firstName, string lastName) { List <SqlParameter> paramList = new List <SqlParameter>(); paramList.Add(new SqlParameter("@firstName", SqlDbType.NVarChar, 50)); paramList[0].Value = firstName; paramList.Add(new SqlParameter("@lastName", SqlDbType.NVarChar, 50)); paramList[1].Value = lastName; return(DataBaseGenerics.InsertData("EXECUTE InsertPerson @firstName, @lastName", paramList, CommandType.Text)); }
public static DataSet VerifyUser(string userName, string password) { List <SqlParameter> paramList = new List <SqlParameter>(); paramList.Add(new SqlParameter("@username", SqlDbType.VarChar, 20)); paramList[0].Value = userName; paramList.Add(new SqlParameter("@password", SqlDbType.VarChar, 20)); paramList[1].Value = password; return(DataBaseGenerics.GetData("Execute VerifyLogin @username, @password", paramList, CommandType.Text, QueryType.Select_Statement)); }
public static int InsertClient(string clientName, string clientAddress, string clientContactNumber) { List <SqlParameter> paramList = new List <SqlParameter>(); paramList.Add(new SqlParameter("@clientName", SqlDbType.NVarChar, 50)); paramList[0].Value = clientName; paramList.Add(new SqlParameter("@clientAddress", SqlDbType.NVarChar, 100)); paramList[1].Value = clientAddress; paramList.Add(new SqlParameter("@clientContactNumber", SqlDbType.NVarChar, 30)); paramList[2].Value = clientContactNumber; return(DataBaseGenerics.InsertData("EXECUTE InsertClient @clientName, @clientAddress, @clientContactNumber", paramList, CommandType.Text)); }
public static DataSet GetAllProjects(int clientID, int accountManager, int deliveryManager, int lead, char serviceLine, char commTerms, char reviewFrequency) { List <SqlParameter> paramList = new List <SqlParameter>(); paramList.Add(new SqlParameter("@clientID", SqlDbType.Int)); paramList[0].Value = clientID; paramList.Add(new SqlParameter("@accountManager", SqlDbType.Int)); paramList[1].Value = accountManager; paramList.Add(new SqlParameter("@deliveryManager", SqlDbType.Int)); paramList[2].Value = deliveryManager; paramList.Add(new SqlParameter("@lead", SqlDbType.Int)); paramList[3].Value = lead; paramList.Add(new SqlParameter("@serviceLine", SqlDbType.VarChar, 1)); paramList[4].Value = serviceLine; paramList.Add(new SqlParameter("@commTerms", SqlDbType.VarChar, 1)); paramList[5].Value = commTerms; paramList.Add(new SqlParameter("@reviewFrequency", SqlDbType.VarChar, 1)); paramList[6].Value = reviewFrequency; return(DataBaseGenerics.GetData("Execute SelectAllProjects @clientID, @accountManager, @deliveryManager, @lead, @serviceLine, @commTerms, @reviewFrequency", paramList, CommandType.Text, QueryType.Select_Statement)); }
public static int InsertProject(string projectName, string projectDescription, DateTime startDate, DateTime endDate, DateTime revisedDate, int sogetiPractitionerID, int accountManagerID, int deliveryManagerID, int administratorID, int clientID, int leadID, char commercialTerms, char reviewFrequency, char sogetiServiceLine) { List <SqlParameter> paramList = new List <SqlParameter>(); paramList.Add(new SqlParameter("@projectName", SqlDbType.NVarChar, 50)); paramList[0].Value = projectName; paramList.Add(new SqlParameter("@projectDescription", SqlDbType.NVarChar, 100)); paramList[1].Value = projectDescription; paramList.Add(new SqlParameter("@startDate", SqlDbType.SmallDateTime)); paramList[2].Value = startDate; paramList.Add(new SqlParameter("@endDate", SqlDbType.SmallDateTime)); paramList[3].Value = endDate; paramList.Add(new SqlParameter("@revisedDate", SqlDbType.SmallDateTime)); paramList[4].Value = revisedDate; paramList.Add(new SqlParameter("@sogetiPractitioner", SqlDbType.Int)); paramList[5].Value = sogetiPractitionerID; paramList.Add(new SqlParameter("@accountManager", SqlDbType.Int)); paramList[6].Value = accountManagerID; paramList.Add(new SqlParameter("@deliveryManager", SqlDbType.Int)); paramList[7].Value = deliveryManagerID; paramList.Add(new SqlParameter("@admin", SqlDbType.Int)); paramList[8].Value = administratorID; paramList.Add(new SqlParameter("@clientID", SqlDbType.Int)); paramList[9].Value = clientID; paramList.Add(new SqlParameter("@prjLead", SqlDbType.Int)); paramList[10].Value = leadID; paramList.Add(new SqlParameter("@commTerms", SqlDbType.VarChar, 1)); paramList[11].Value = commercialTerms; paramList.Add(new SqlParameter("@reviewFreq", SqlDbType.VarChar, 1)); paramList[12].Value = reviewFrequency; paramList.Add(new SqlParameter("@sogServiceLine", SqlDbType.VarChar, 1)); paramList[13].Value = sogetiServiceLine; return(DataBaseGenerics.InsertData("InsertProject @projectName, @projectDescription, @startDate, @endDate, @revisedDate, @sogetiPractitioner, @accountManager, @deliveryManager, @admin, @clientID, @prjLead, @commTerms, @reviewFreq, @sogServiceLine", paramList, CommandType.Text)); }
public static DataSet GetAllClients() { return(DataBaseGenerics.GetData("Execute SelectAllClients", CommandType.Text)); }