using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using EAS.Services; using SOH.BLL; namespace SOH.SaleSettings { public partial class frmTuanJianzhiXingQingKuangChaXunJiaXiangMingXi : Form { public frmTuanJianzhiXingQingKuangChaXunJiaXiangMingXi() { InitializeComponent(); } public frmTuanJianzhiXingQingKuangChaXunJiaXiangMingXi(int htbm) { this.htbm = htbm; InitializeComponent(); } int htbm; private void frmTuanJianzhiXingQingKuangChaXunJiaXiangMingXi_Load(object sender, EventArgs e) { var service2 = ServiceContainer.GetService(); DataTable dt = Newtonsoft.Json.JsonConvert.DeserializeObject(service2.GetjjxByhtbm(htbm), typeof(DataTable)) as DataTable; dataGridView1.DataSource = dt; } private void dataGridView1_CellClick(object sender, DataGridViewCellEventArgs e) { if (e.RowIndex < 0) { return; } var service2 = ServiceContainer.GetService(); DataTable dt = Newtonsoft.Json.JsonConvert.DeserializeObject(service2.GetjjxXmBytm(Convert.ToInt32(this.dataGridView1.Rows[e.RowIndex].Cells[1].Value)), typeof(DataTable)) as DataTable; dataGridView2.DataSource = dt; } private void button1_Click(object sender, EventArgs e) { var service2 = ServiceContainer.GetService(); DataTable dt = Newtonsoft.Json.JsonConvert.DeserializeObject(service2.GetDcjjxmxByhtbm(htbm), typeof(DataTable)) as DataTable; if (dt.Rows.Count != 0) { frmDcjjxmLiebiao fdl = new frmDcjjxmLiebiao(); fdl.init(dt); fdl.re.Show(); fdl.ShowDialog(); } else { MessageBox.Show("该合同没有人员加项信息!"); } } } }