You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
78 lines
2.7 KiB
78 lines
2.7 KiB
using SSWMS.Common;
|
|
using System;
|
|
using System.Windows;
|
|
using System.Windows.Input;
|
|
using System.Data;
|
|
using System.Collections.Generic;
|
|
|
|
namespace SSWMS.Client
|
|
{
|
|
public partial class MANAGE_IN_STATION_STOCK : AvalonDock.DocumentContent
|
|
{
|
|
public MANAGE_IN_STATION_STOCK()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void tbTextBox_KeyDown(object sender, KeyEventArgs e)
|
|
{
|
|
if (e.Key != Key.Enter ||
|
|
string.IsNullOrWhiteSpace(this.tbStockBarcode.Text) ||
|
|
string.IsNullOrWhiteSpace(this.tbQuantity.Text))
|
|
{
|
|
return;
|
|
}
|
|
bInStationStock_Click(null, null);
|
|
}
|
|
|
|
private void bInStationStock_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
try
|
|
{
|
|
string sStockBarcode = this.tbStockBarcode.Text.Trim().ToUpper();
|
|
if (string.IsNullOrWhiteSpace(sStockBarcode))
|
|
{
|
|
MessageDialog.ShowException("请输入托盘条码");
|
|
return;
|
|
}
|
|
if (!StringUtils.StockBarcodeValidate(sStockBarcode))
|
|
{
|
|
MessageDialog.ShowException($"托盘条码 {this.tbStockBarcode.Text} 格式错误");
|
|
return;
|
|
}
|
|
|
|
if (MessageDialog.ShowDialog("确认执行托盘入库"))
|
|
{
|
|
string sResult = string.Empty;
|
|
bool bResult = WCFChannel._I_ManageService.ManageInStation(new STORAGE_MAIN()
|
|
{
|
|
STOCK_BARCODE = sStockBarcode,
|
|
CELL_MODEL = SystemCode.CELL_MODEL.Low,
|
|
CELL_CODE = SystemCode.WH_CELL_CODE.GroupDeviceCode
|
|
}, new List<STORAGE_LIST>()
|
|
{
|
|
new STORAGE_LIST()
|
|
{
|
|
GOODS_ID = SystemCode.GOODS_ID.GetGoodsID(sStockBarcode),
|
|
STORAGE_LIST_QUANTITY = Convert.ToDecimal(this.tbQuantity.Text)
|
|
}
|
|
}, MainApp._USER.USER_NAME, out sResult);
|
|
if (bResult)
|
|
{
|
|
this.bRefresh_Click(null, null);
|
|
}
|
|
MessageDialog.ShowResult(bResult, sResult);
|
|
}
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
MessageDialog.ShowException(ex);
|
|
}
|
|
}
|
|
|
|
private void bRefresh_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
this.tbStockBarcode.Text = string.Empty;
|
|
}
|
|
}
|
|
}
|