Exemplo n.º 1
0
 private void button2_Click(object sender, EventArgs e)
 {
     DBUtility.ExecuteSQL($"update stock_out set stock_out_checked = 1,stock_out_pay = {double.Parse(textBox3.Text) * double.Parse(textBox4.Text)} where stock_in_id2 = '{comboBox2.SelectedItem.ToString()}'");
     MessageBox.Show("确认成功");
     UpdateInfo();
 }
Exemplo n.º 2
0
 /// <summary>
 /// Add
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void button1_Click(object sender, EventArgs e)
 {
     DBUtility.ExecuteSQL($"insert into STAFF_TYPE select  right('0'+cast(max([Staff_type_id])+1 as varchar),2),'{textBox1.Text}' from STAFF_TYPE ");
     ShowData();
 }
Exemplo n.º 3
0
 public Product()
 {
     InitializeComponent();
     data = DBUtility.GetData("SELECT Product_ID 编号,Product_Name 名称,Product_tally 单位 , Product_Weight 重量 , Product_Long 长度 ,Product_Hgih 高度 , Product_Wide 宽度 , Product_Temperature 保存温度 , Product_humidity 保存湿度 FROM[WMS].[dbo].[Product]");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 4
0
 /// <summary>
 /// select data
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void button1_Click(object sender, EventArgs e)
 {
     data = DBUtility.GetData($"SELECT Product_ID 编号,Product_Name 名称,Product_tally 单位 , Product_Weight 重量 , Product_Long 长度 ,Product_Hgih 高度 , Product_Wide 宽度 , Product_Temperature 保存温度 , Product_humidity 保存湿度 FROM [WMS].[dbo].[Product] where Product_ID like '%{textBox1.Text}%' and Product_Name like '%{textBox2.Text}%' and Product_tally like '%{textBox3.Text}%' and Product_Weight like '%{textBox4.Text}%' and Product_Long like '%{textBox5.Text}%' and Product_Hgih like '%{textBox6.Text}%' and  Product_Wide like '%{textBox7.Text}%'  ");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 5
0
 private void ShowData()
 {
     data = DBUtility.GetData("SELECT [WareType_ID] 种类编号 ,[Waretype_Name] 种类名称 ,[Waretype_Tem_controlable] 可控温 ,[Waretype_Hum_controlable] 可控湿 ,[Waretype_Max_tem] 最高温度 ,[Waretype_Min_tem] 最低温度 ,[Waretype_Max_hum] 最高湿度 ,[Waretype_Min_hum] 最低湿度  FROM [WMS].[dbo].[WareAreaType]");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 6
0
 private void ShowData()
 {
     data = DBUtility.GetData("SELECT [WareArea_ID] 区域编号,[Warehouse_Name] 主仓库名称 ,[Waretype_Name] 仓库类别 ,[WareArea_Floor] 层数 ,[WareArea_High] 高度 ,[WareArea_Wide] 宽度 ,[WareArea_Long] 长度 ,[WareArea_MaxWeight] 最大承重 ,[WareArea_Cost] 花费 ,[WareArea_NowTem] 当前温度 ,[WareArea_NowHum] 当前湿度 ,[Last_check_date] 最后检查时间 FROM [WMS].[dbo].[WareArea] a, WareAreaType b, WareHouse c  where a.Warehouse_ID = c.Warehouse_ID and a.WareType_ID = b.WareType_ID");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 7
0
 public CustomerMain(string email)
 {
     ID    = DBUtility.GetData($"select customer_id from customer where customer_email = '{email}'").Rows[0][0].ToString();
     Email = email;
     InitializeComponent();
 }
Exemplo n.º 8
0
 private void button1_Click(object sender, EventArgs e)
 {
     DBUtility.ExecuteSQL($"Update warearea set last_check_date = getdate() where wareArea_id ='{comboBox1.SelectedItem.ToString()}' ");
     MessageBox.Show("巡检成功");
 }
Exemplo n.º 9
0
 private void ShowData()
 {
     data = DBUtility.GetData("SELECT [Warehouse_ID] 仓库编号 ,[Warehouse_Name] 仓库名 FROM [WMS].[dbo].[WareHouse]");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 10
0
 /// <summary>
 /// update
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void button2_Click(object sender, EventArgs e)
 {
     DBUtility.ExecuteSQL($"update [WMS].[dbo].[WareHouse] set Warehouse_Name = '{textBox2.Text}'  where Warehouse_ID = '{textBox1.Text}'  ");
     ShowData();
 }
Exemplo n.º 11
0
 /// <summary>
 /// insert
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void button1_Click(object sender, EventArgs e)
 {
     DBUtility.ExecuteSQL($"insert into  [WMS].[dbo].[WareHouse] select  right('0000000000'+cast(max(Warehouse_ID)+1 as varchar),10),'{textBox2.Text}' from [WMS].[dbo].[WareHouse] ");
     ShowData();
 }
Exemplo n.º 12
0
 private void button1_Click(object sender, EventArgs e)
 {
     data = DBUtility.GetData($"  select WareArea_ID 仓储区域号,a.Ware_detail_owner 货主,a.Product_ID 商品编号 ,b.Product_Name 商品名,a.Ware_detail_number 数量 from Ware_Detail a , Product b where a.Product_ID = b.Product_ID  and b.Product_Name like '%{textBox1.Text}%' and a.Ware_detail_owner like '%{textBox2.Text}%' and WareArea_ID like '%{textBox3.Text}%'");
     dataGridView1.DataSource = data;
 }
Exemplo n.º 13
0
 public StockStaff()
 {
     InitializeComponent();
     data = DBUtility.GetData("  select WareArea_ID 仓储区域号,a.Ware_detail_owner 货主,a.Product_ID 商品编号 ,b.Product_Name 商品名,a.Ware_detail_number 数量 from Ware_Detail a , Product b where a.Product_ID = b.Product_ID ");
     dataGridView1.DataSource = data;
 }