public DeleteProjectForm(DatabaseTools databaseTools, Exchange.ProjectInfo projectInfo, SettingClass settingClass) { InitializeComponent(); m_DatabaseTools = databaseTools; m_ProjectInfo = projectInfo; m_SettingClass = settingClass; textBoxName.Text = m_ProjectInfo.Name; }
public TimesForm(DatabaseTools databaseTools, SettingClass settingClass, Exchange.ProjectInfo projectInfo) { m_LockChangeSettings = true; InitializeComponent(); m_DatabaseTools = databaseTools; m_ProjectInfo = projectInfo; m_SettingClass = settingClass; labelCaption.Text = "Выбранный проект:\r\n" + projectInfo.Name; }
public EditProjectForm(DatabaseTools databaseTools, SettingClass settingClass, Exchange.ProjectInfo projectInfo) { InitializeComponent(); m_SettingClass = settingClass; m_DatabaseTools = databaseTools; m_ProjectInfo = projectInfo; textBoxName.Text = m_ProjectInfo.Name; textBoxPay.Text = m_ProjectInfo.Pay.ToString(); textBoxInfo.Text = m_ProjectInfo.Info; }
/// <summary> /// Get all rows from Project table /// </summary> /// <returns></returns> public Exchange.ProjectInfo[] GetProjectRows() { DataTable productTable = m_DataSet.Tables[TableNames.Project.ToString()]; var resRows = new Exchange.ProjectInfo[productTable.Rows.Count]; DataRow[] allRows = productTable.Select("", "name"); for (int i = 0; i < allRows.Length; i++) { resRows[i].ID = (int)allRows[i]["id"]; resRows[i].Name = (string)allRows[i]["name"]; resRows[i].Pay = (int)allRows[i]["pay"]; resRows[i].Info = (string)allRows[i]["info"]; } return(resRows); }