コード例 #1
0
        private void btn_AddOrder_Click(object sender, EventArgs e)
        {
            if ((this.txtAddOrderNo.Text.Trim().Length > 0) && (this.txtAddProdNo.Text.Trim().Length > 0) && (RegularHelper.isNumericString(this.txtAddOrderCount.Text.Trim())))
            {
                DialogResult diaresult = SpMessageBox.Show("确定要补充该订单吗?", "订单补充", MessageBoxButtons.OKCancel, MessageBoxIcon.Warning);

                if (diaresult == DialogResult.OK)
                {
                    if (OrderInfoBLL.OrderAlreadyExsit(this.txtAddOrderNo.Text.Trim()))
                    {
                        if (OrderInfo.UpdateOrderCount(this.txtAddOrderNo.Text.Trim(), this.txtAddProdNo.Text.Trim(), int.Parse(this.txtAddOrderCount.Text.Trim())))
                        {
                            SpMessageBox.Show("该订单数量补充完成", "订单补充");
                        }
                    }
                    else
                    {
                        SpMessageBox.Show("该订单号不存在,请检查该订单号是否生效", "订单补充");
                    }


                    SystemLogs.WriteSystemLog(Login.UserName, "add order count:" + this.txtAddOrderCount.Text.Trim() + " for order " + this.txtAddOrderNo.Text.Trim() + " at " + Login.CurrentProductionLine, DateTime.Now);
                }
            }
            else
            {
                SpMessageBox.Show("请检查订单号,产品号,和订单数量的输入", "订单补充");
            }
        }
コード例 #2
0
 public static void RemoveOrder(string _orderNo, string _productNo)
 {
     if (!OrderInfoBLL.OrderAlreadyExsit(_orderNo))
     {
         OrderInfoBLL.OrderInfoDelete(_orderNo, _productNo);
     }
 }
コード例 #3
0
 public static void UpdateOrderStatus(string _orderNo, string _productNo, byte _orderStatus)
 {
     if (!OrderInfoBLL.OrderAlreadyExsit(_orderNo))
     {
         OrderInfoBLL.OrderInfoUpdate(_orderNo, _productNo, _orderStatus);
     }
 }
コード例 #4
0
 public static void CheckOrderExsit(string _orderNo, string _productNo, int _orderCount)
 {
     if (!OrderInfoBLL.OrderAlreadyExsit(_orderNo))
     {
         OrderInfoBLL.OrderInfoInsert(_orderNo, _productNo, _orderCount);
     }
     else
     {
         OrderInfoBLL.OrderInfoUpdate(_orderNo, _productNo, _orderCount);
     }
 }