Exemple #1
0
        void 修改租赁记录ToolStripMenuItemClick(object sender, EventArgs e)
        {
            if (dataGridView1.CurrentRow != null)
            {
                FormLeaseRecord1 tF = new FormLeaseRecord1();
                tF.Text = "租赁记录-修改";

                int i_ProjectID;
                int i_CompanyID;
//				int i_RID;
                i_ProjectID = Convert.ToInt32(comboBoxProject.SelectedValue.ToString());
                i_CompanyID = Convert.ToInt32(comboBoxCompany.SelectedValue.ToString());
                LeaseHT tLeaseHT = BLL.LeaseBLL.GetLeaseHT(i_ProjectID, i_CompanyID);
                tF.i_HTID = tLeaseHT.HTID;
                tF.i_RID  = Convert.ToInt32(dataGridView1.CurrentRow.Cells["RID"].Value);
                tF.ShowDialog();
                //刷新
                RefreshLeaseRecord();
            }
        }
Exemple #2
0
        void 新租赁记录ToolStripMenuItemClick(object sender, EventArgs e)
        {
            FormLeaseRecord1 tF = new FormLeaseRecord1();

            tF.Text = "租赁记录-新增";

            int i_ProjectID;
            int i_CompanyID;

            if (comboBoxProject.SelectedValue == null || comboBoxCompany.SelectedValue == null)
            {
                return;
            }

            i_ProjectID = Convert.ToInt32(comboBoxProject.SelectedValue.ToString());
            i_CompanyID = Convert.ToInt32(comboBoxCompany.SelectedValue.ToString());
            LeaseHT tLeaseHT = BLL.LeaseBLL.GetLeaseHT(i_ProjectID, i_CompanyID);

            tF.i_HTID = tLeaseHT.HTID;
            tF.ShowDialog();
            //刷新
            RefreshLeaseRecord();
        }