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.
129 lines
3.6 KiB
129 lines
3.6 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
|
|
namespace SiaSun.LMS.Implement
|
|
{
|
|
/// <summary>
|
|
/// 消息队列 申请类
|
|
/// </summary>
|
|
public class Apply_0 : Apply_Base
|
|
{
|
|
|
|
public Apply_0(): base()
|
|
{
|
|
}
|
|
|
|
public Apply_0(SiaSun.LMS.Model.IO_CONTROL_APPLY mIO_CONTROL_APPLY): base(mIO_CONTROL_APPLY)
|
|
{
|
|
}
|
|
|
|
public override bool Check(out string sResult)
|
|
{
|
|
bool bResult = true;
|
|
|
|
sResult = string.Empty;
|
|
|
|
bResult=base.Check(out sResult);
|
|
|
|
#region 此处添加该任务类型的特殊校验
|
|
|
|
|
|
#endregion
|
|
|
|
return bResult;
|
|
}
|
|
|
|
public override bool Handel(out string sResult)
|
|
{
|
|
bool bResult = true;
|
|
|
|
sResult = string.Empty;
|
|
|
|
try
|
|
{
|
|
SiaSun.LMS.Model.MANAGE_MAIN mMANAGE_MAIN = this._P_MANAGE_MAIN.GetModelStockBarcode("%" + this.IO_CONTROL_APPLY.STOCK_BARCODE.TrimEnd() + "%");
|
|
|
|
if (mMANAGE_MAIN != null)
|
|
{
|
|
mMANAGE_MAIN.CELL_MODEL = this.IO_CONTROL_APPLY.CONTROL_APPLY_REMARK.TrimEnd();
|
|
|
|
this._P_MANAGE_MAIN.Update(mMANAGE_MAIN);
|
|
|
|
Model.MANAGE_TYPE mMANAGE_TYPE = (Model.MANAGE_TYPE)this.GetModel("MANAGE_TYPE_SELECT_BY_MANAGE_TYPE_CODE", mMANAGE_MAIN.MANAGE_TYPE_CODE).RequestObject;
|
|
|
|
bResult = this.Invoke(mMANAGE_TYPE.MANAGE_TYPE_CLASS.TrimEnd(), "ManageDownLoad", new object[] { mMANAGE_MAIN.MANAGE_ID, this.IO_CONTROL_APPLY.DEVICE_CODE.TrimEnd(), true }, out sResult);
|
|
}
|
|
else
|
|
{
|
|
if (this._S_StorageService.StorageCheck(this.IO_CONTROL_APPLY.STOCK_BARCODE.TrimEnd(), Enum.AREA_TYPE.XuNiKu.ToString(), out sResult))
|
|
{
|
|
mMANAGE_MAIN = new Model.MANAGE_MAIN();
|
|
|
|
mMANAGE_MAIN.MANAGE_TYPE_CODE = "ManageUp";
|
|
|
|
mMANAGE_MAIN.STOCK_BARCODE = this.IO_CONTROL_APPLY.STOCK_BARCODE.TrimEnd();
|
|
|
|
mMANAGE_MAIN.CELL_MODEL = this.IO_CONTROL_APPLY.CONTROL_APPLY_REMARK.TrimEnd();
|
|
|
|
mMANAGE_MAIN.START_CELL_ID = this.WH_CELL.CELL_ID;
|
|
|
|
mMANAGE_MAIN.END_CELL_ID = 0;
|
|
|
|
mMANAGE_MAIN.MANAGE_OPERATOR = "扫码申请";
|
|
|
|
mMANAGE_MAIN.MANAGE_BEGIN_TIME = SiaSun.LMS.Common.StringUtil.GetDateTime();
|
|
|
|
mMANAGE_MAIN.MANAGE_STATUS = SiaSun.LMS.Enum.MANAGE_STATUS.WaitingSend.ToString();
|
|
|
|
mMANAGE_MAIN.MANAGE_LEVEL = string.Empty;
|
|
|
|
mMANAGE_MAIN.MANAGE_REMARK = string.Empty;
|
|
|
|
//bResult = new ManageUp().ManageCreate(mMANAGE_MAIN, true, true, false, out sResult);
|
|
}
|
|
else
|
|
{
|
|
bResult = false;
|
|
|
|
sResult = "未找到托盘信息";
|
|
|
|
return bResult;
|
|
}
|
|
}
|
|
}
|
|
|
|
catch (Exception ex)
|
|
{
|
|
bResult = false;
|
|
|
|
sResult = ex.Message;
|
|
}
|
|
|
|
return bResult;
|
|
}
|
|
|
|
public override void WriteLog(bool bSuccess, string sResult)
|
|
{
|
|
try
|
|
{
|
|
base.WriteLog(bSuccess, sResult);
|
|
|
|
#region 生成异常任务
|
|
|
|
if (!bSuccess)
|
|
{
|
|
|
|
}
|
|
|
|
#endregion
|
|
}
|
|
catch(Exception ex)
|
|
{
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
}
|