internal OneRabotnickForm_Admin(string Code, Worker4Admin W4A)
        {
            InitializeComponent();
            this.Code_Of_Rabotnick_TB.Text = Code;

            DataTable DT = W4A.GetTableFromZapros("select * from ПерсДанныеРаботников where Код_работника = " + Code + ";");
            DataRow   DR = null;

            if (DT.Rows.Count == 0)
            {
                MessageBox.Show("Записей больше нет");
                this.Close();
            }

            DR = DT.Rows[0];

            this.Code_Of_Rabotnick_TB.Text = DR[0].ToString();
            this.Name_TB.Text      = DR[1].ToString();
            this.Family_TB.Text    = DR[2].ToString();
            this.Otchestvo_TB.Text = DR[3].ToString();
            this.Pol_TB.Text       = DR[4].ToString();
            this.Date_TB.Text      = DR[5].ToString();

            this.W4A = W4A;
        }
Exemple #2
0
        internal Pokaz_History_Zachisleniya(Worker4Admin W4A)
        {
            InitializeComponent();
            this.W4A = W4A;

            DataTable DT = W4A.GetTableFromZapros("select top 1 * from ПерсДанныеРаботников");
            DataRow   DR = null;

            if (DT.Rows.Count == 0)
            {
                MessageBox.Show("Записей нет");
                this.Close();
            }

            DR = DT.Rows[0];

            this.Code_Of_Rabotnick_TB.Text = DR[0].ToString();
            this.Name_TB.Text      = DR[1].ToString();
            this.Family_TB.Text    = DR[2].ToString();
            this.Otchestvo_TB.Text = DR[3].ToString();
            this.Pol_TB.Text       = DR[4].ToString();
            this.Date_TB.Text      = DR[5].ToString();

            DataTable DT2 = W4A.GetTableFromZapros("select * from Зачисления_зарплат where Код_работника=" + Code_Of_Rabotnick_TB.Text + ";");

            if (DT2.Rows.Count != 0)
            {
                DGV.DataSource = DT2;
            }
        }
Exemple #3
0
        private void GoButton_Click(object sender, EventArgs e)
        {
            if (Local_RB.Checked)
            {
                if (!File.Exists(Local_Rasp_TB.Text))
                {
                    MessageBox.Show("Указанного файла не существует");
                    return;
                }

                try
                {
                    if (Password_TB.Text == "")
                    {
                        W4A = new Worker4Admin(true, Local_Rasp_TB.Text);
                    }
                    else
                    {
                        W4A = new Worker4Admin(true, Local_Rasp_TB.Text, Password_TB.Text);
                    }
                }
                catch (Exception ex)
                {
                    MessageBox.Show("Не удается подключиться у указанной базе данных");
                    return;
                }

                MessageBox.Show("Вы авторизованы!");

                Form x = new AsAdministrator(W4A);
                x.Show();
            }
            else
            {
                if (!File.Exists(Local_Rasp_TB.Text))
                {
                    MessageBox.Show("Указанного файла не существует");
                    return;
                }

                try
                {
                    W4A = new Worker4Admin(false, Local_Rasp_TB.Text, "qwerty");
                }
                catch (Exception ex)
                {
                    MessageBox.Show("Не удается подключиться у указанной базе данных");
                    return;
                }

                MessageBox.Show("Вы авторизованы!");

                Form x = new AsAdministrator(W4A);
                x.Show();
            }
        }
Exemple #4
0
        internal OnePredpritatiyeForm_Admin(string code, string nazv, string address, string telephone, string colvo, DataTable RabotnikyPredpriyatiya, Worker4Admin W4A)
        {
            InitializeComponent();

            this.W4A = W4A;

            this.Code_Of_Rabotnick_TB.Text = code;
            this.Name_TB.Text      = nazv;
            this.Family_TB.Text    = address;
            this.Otchestvo_TB.Text = telephone;
            this.Pol_TB.Text       = colvo;

            this.DGV_Prin_Uvol_History.DataSource = RabotnikyPredpriyatiya;
        }
Exemple #5
0
        internal Admin_Person_danniye(Worker4Admin W4A)
        {
            InitializeComponent();

            this.W4A = W4A;

            TekZapros_TB.Text = "select * from ПерсДанныеРаботников;";

            GridViewTable.DataSource = W4A.GetFullTableFromZapros("ПерсДанныеРаботников");
            for (int x = 0; x < PokazStolbChB.Items.Count; x++)
            {
                PokazStolbChB.SetItemChecked(x, true);
            }
        }
        internal Admin_Accept_Resumes(Worker4Admin W4A, string CodeOfRabotnick, string name, string family, string otchestvo, string Pol, string date, string JelauemayaZP, string graph, string Specializes, DataTable Table)
        {
            InitializeComponent();
            this.W4A = W4A;

            textBox1.Text            = name;
            textBox2.Text            = family;
            textBox3.Text            = otchestvo;
            textBox4.Text            = date;
            textBox5.Text            = JelauemayaZP;
            textBox6.Text            = graph;
            textBox7.Text            = Pol;
            textBox8.Text            = CodeOfRabotnick;
            richTextBox1.Text        = Specializes;
            dataGridView1.DataSource = Table;
        }
        internal Admin_Prin_U_Rabotnikov(Worker4Admin W4A)
        {
            InitializeComponent();
            this.W4A = W4A;

            try
            {
                GridViewTable.DataSource = W4A.GetFullTableFromZapros("Принятия_и_увольнения_работников");
                TekZapros_TB.Text        = "select * from Принятия_и_увольнения_работников;";
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }

            for (int x = 0; x < PokazStolbChB.Items.Count; x++)
            {
                PokazStolbChB.SetItemChecked(x, true);
            }
        }
Exemple #8
0
        internal Find_Danniye_About_Doljnost(Worker4Admin W4A)
        {
            InitializeComponent();
            this.W4A = W4A;

            DataTable DT = W4A.GetTableFromZapros("select top 1 * from Специальности");
            DataRow   DR = null;

            if (DT.Rows.Count == 0)
            {
                MessageBox.Show("Записей нет");
                this.Close();
            }

            DR = DT.Rows[0];

            this.Code_Of_Rabotnick_TB.Text = DR[0].ToString();
            this.Name_TB.Text   = DR[1].ToString();
            this.Family_TB.Text = DR[2].ToString();
        }
        internal Admin_Zachisleniya_Zarplat(Worker4Admin W4A)
        {
            InitializeComponent();
            this.W4A = W4A;

            try
            {
                GridViewTable.DataSource = W4A.GetFullTableFromZapros("Зачисления_зарплат");
                TekZapros_TB.Text        = "select * from Зачисления_зарплат;";
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }

            for (int x = 0; x < PokazStolbChB.Items.Count; x++)
            {
                PokazStolbChB.SetItemChecked(x, true);
            }
        }
        internal Admin_Predpriyatiya(Worker4Admin W4A)
        {
            InitializeComponent();
            this.W4A = W4A;

            try
            {
                GridViewTable.DataSource = W4A.GetFullTableFromZapros("Предприятия");
                TekZapros_TB.Text        = "select * from Предприятия;";
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
            }

            for (int x = 0; x < PokazStolbChB.Items.Count; x++)
            {
                PokazStolbChB.SetItemChecked(x, true);
            }
        }
Exemple #11
0
        internal Find_Zapis_Predpriyatiya(Worker4Admin W4A, string code)
        {
            InitializeComponent();
            this.W4A = W4A;

            DataTable DT = W4A.GetTableFromZapros("select * from Предприятия where Код_предприятия = " + code + ";");
            DataRow   DR = null;

            if (DT.Rows.Count == 0)
            {
                MessageBox.Show("Запись отсутствует");
                this.Close();
            }

            DR = DT.Rows[0];

            this.Code_Of_Rabotnick_TB.Text = DR[0].ToString();
            this.Name_TB.Text      = DR[1].ToString();
            this.Family_TB.Text    = DR[2].ToString();
            this.Otchestvo_TB.Text = DR[3].ToString();
            this.Pol_TB.Text       = DR[4].ToString();
        }
Exemple #12
0
        internal OneRabotnickForm_Admin(string Code, string Name, string Family, string Otchestvo, string Pol, string Date, DataTable HistOfPrinAndUv, DataTable HistOfZpHistory, Worker4Admin W4A)
        {
            InitializeComponent();
            this.Code_Of_Rabotnick_TB.Text = Code;
            this.Name_TB.Text      = Name;
            this.Family_TB.Text    = Family;
            this.Otchestvo_TB.Text = Otchestvo;
            this.Pol_TB.Text       = Pol;
            this.Date_TB.Text      = Date;
            this.DGV_Prin_Uvol_History.DataSource = HistOfPrinAndUv;
            this.DGV_ZP_History.DataSource        = HistOfZpHistory;
            this.W4A = W4A;

            for (int x = 0; x < Otobr_1_Tabl.Items.Count; x++)
            {
                Otobr_1_Tabl.SetItemChecked(x, true);
            }

            for (int x = 0; x < Otobr_2_Tabl.Items.Count; x++)
            {
                Otobr_2_Tabl.SetItemChecked(x, true);
            }
        }
Exemple #13
0
 internal Dobavit_Vacansy(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal Dobavit_Sotrudnika(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal Dobavit_Zapis_Predpriyatiya(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal OneRabotnickForm_Admin(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal AsAdministrator(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
Exemple #18
0
 internal Dobavit_Danniye_About_Doljnost(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal Find_Resume(Worker4Admin W4A)
 {
     InitializeComponent();
     this.W4A = W4A;
 }
 internal ServerForm(Worker4Admin W4A)
 {
     InitializeComponent();
     DataGridView_Connections.Rows.Add("192.168.0.1", "1234", "DefaultLogin", "21.12.21");
     this.W4A = W4A;
 }