示例#1
0
        private void btnDicitemAdd_Click(object sender, EventArgs e)
        {
            string            dicCata = this.cbx_sizeCata.Text;
            ProductSizeDicDlg dlg     = new ProductSizeDicDlg(dicCata, true);

            dlg.ShowDialog();
            presenter.RefreshList(this.cbx_sizeCata.Text);
        }
示例#2
0
        private void OnModifyDic()
        {
            string dicCata = this.cbx_sizeCata.Text;

            string[] dataArray = new string[3] {
                "", "", ""
            };
            if (this.dataGridView1.SelectedRows.Count < 1)
            {
                MessageBox.Show("未选中待修改记录");
                return;
            }
            DataGridViewRow row = this.dataGridView1.SelectedRows[0];

            dataArray[0] = row.Cells[0].Value.ToString();
            dataArray[1] = row.Cells[1].Value.ToString();
            dataArray[2] = row.Cells[2].Value.ToString();

            ProductSizeDicDlg dlg = new ProductSizeDicDlg(dicCata, false);

            dlg.DataArray = dataArray;
            dlg.ShowDialog();
            presenter.RefreshList(this.cbx_sizeCata.Text);
        }