Esempio n. 1
0
        public EditPacking(string idw)
        {
            InitializeComponent();
            this.IDW = idw;
            DBPacking dbwp = new DBPacking();

            textBox1.Text = dbwp.Get(this.IDW);
        }
Esempio n. 2
0
        private void button3_Click(object sender, EventArgs e)
        {
            EditPacking ew = new EditPacking(dgWP.SelectedRows[0].Cells["ID"].Value.ToString());

            ew.ShowDialog();
            DBPacking dbwp = new DBPacking();

            dgWP.DataSource = dbwp.GetAll();
        }
Esempio n. 3
0
        private void button2_Click(object sender, EventArgs e)
        {
            NewPacking nwp = new NewPacking();

            nwp.ShowDialog();
            DBPacking dbwp = new DBPacking();

            dgWP.DataSource = dbwp.GetAll();
        }
Esempio n. 4
0
        public Packing()
        {
            InitializeComponent();
            DBPacking dbwp = new DBPacking();

            dgWP.DataSource                  = dbwp.GetAll();
            dgWP.Columns["ID"].Visible       = false;
            dgWP.Columns["PNAME"].HeaderText = "Наименование упаковки";
            dgWP.Columns["PNAME"].Width      = 350;
        }
Esempio n. 5
0
        public NewSummon(IRole uvo)
        {
            InitializeComponent();
            this.UVO = uvo;
            dbs      = new DBSummon();
            // tbIDS.Text = dbs.GetNextNumber();
            tbIDS.Text = "<не определено>";

            IDNEWSUMMON      = dbs.AddNIPSummon();
            dtpCREATED.Value = DateTime.Now;

            cbSISP.SelectedIndex = 0;

            DBCustomer dbc = new DBCustomer();

            cbCustomers.ValueMember   = "ID";
            cbCustomers.DisplayMember = "CNAME";
            cbCustomers.DataSource    = dbc.GetAllCustomers();

            /*DBWPName dbwp = new DBWPName();
             * cbWPNAME.ValueMember = "ID";
             * cbWPNAME.DisplayMember = "WPNAME";
             * cbWPNAME.DataSource = dbwp.GetAllWPNames();*/

            DBAccept dbacc = new DBAccept();

            cbAccept.ValueMember   = "ID";
            cbAccept.DisplayMember = "ANAME";
            cbAccept.DataSource    = dbacc.GetAllAccept();

            DBPacking dbp = new DBPacking();

            cbPacking.ValueMember   = "ID";
            cbPacking.DisplayMember = "PNAME";
            cbPacking.DataSource    = dbp.GetAll();

            //DBEXTCABLE dbec = new DBEXTCABLE();
            //cbExtCable.ValueMember = "ID";
            //cbExtCable.DisplayMember = "EXTCABLENAME";
            //cbExtCable.DataSource = dbec.GetAllEXTCABLENames();

            //DBMountingKit dbmk = new DBMountingKit();
            //cbMountingKit.ValueMember = "ID";
            //cbMountingKit.DisplayMember = "MOUNTINGKITNAME";
            //cbMountingKit.DataSource = dbmk.GetAllDBMountingKitNames();
            //cbMountingKit.SelectedIndex = 0;


            // UIProc ui = new UIProc();
            //ui.LoadExtCables(dgv, this.IDNEWSUMMON.ToString());
            //LoadExtCables();
            pickWPName1.Init(UVO);
            cbCONTRACTTYPE.SelectedIndex = 0;
        }
Esempio n. 6
0
        private void button2_Click(object sender, EventArgs e)
        {
            if (textBox1.Text == "")
            {
                MessageBox.Show("Введите наименование!");
                return;
            }
            DBPacking dbwp = new DBPacking();

            dbwp.Edit(textBox1.Text, this.IDW);
            MessageBox.Show("Наименование успешно изменено!");
            Close();
        }
Esempio n. 7
0
        private void button2_Click(object sender, EventArgs e)
        {
            if (textBox1.Text == "")
            {
                MessageBox.Show("Введите наименование!");
                return;
            }
            DBPacking dbwp = new DBPacking();

            dbwp.AddNew(textBox1.Text);
            MessageBox.Show("Наименование успешно добавлено!");
            Close();
        }