12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455 |
- 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 UAS_MES_NEW.DataOperate;
- using UAS_MES_NEW.Entity;
- namespace UAS_MES_NEW.Packing
- {
- public partial class Packing_PalletWeightRecord : Form
- {
- DataHelper dh = SystemInf.dh;
- public Packing_PalletWeightRecord()
- {
- InitializeComponent();
- }
- private void SaveWeight_Click(object sender, EventArgs e)
- {
- //验证栈板号存在
- if (dh.CheckExist("package", "pa_outboxcode='" + pa_outboxcode.Text + "' and pa_type=3"))
- {
- float PalletWeight;
- try
- {
- PalletWeight = float.Parse(weight.Text);
- }
- catch (Exception)
- {
- OperateResult.AppendText(">>请输入正确的重量\n");
- return;
- }
- dh.UpdateByCondition("package", "PA_WEIGHT='" + PalletWeight + "',pa_length='" + length.Text + "',pa_width='" + width.Text + "',pa_heigth='" + height.Text + "'", "pa_outboxcode='" + pa_outboxcode.Text + "'");
- OperateResult.AppendText(">>栈板号" + pa_outboxcode.Text + "记录重量" + weight.Text + "kg成功\n", Color.Green, pa_outboxcode);
- weight.Clear();
- }
- else OperateResult.AppendText(">>栈板号" + pa_outboxcode.Text + "不存在\n", Color.Red, pa_outboxcode);
- }
- private void Clean_Click(object sender, EventArgs e)
- {
- OperateResult.Clear();
- }
- private void Packing_PalletWeightRecord_Load(object sender, EventArgs e)
- {
- }
- }
- }
|