48 lines
1.7 KiB
C#
48 lines
1.7 KiB
C#
using System;
|
|
using System.ComponentModel;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using Kingdee.BOS;
|
|
using Kingdee.BOS.Core.Bill.PlugIn;
|
|
using Kingdee.BOS.Core.Bill.PlugIn.Args;
|
|
using Kingdee.BOS.Core.DynamicForm.PlugIn.Args;
|
|
using Kingdee.BOS.Core.Metadata;
|
|
using Kingdee.BOS.Core.Metadata.EntityElement;
|
|
using Kingdee.BOS.Core.SqlBuilder;
|
|
using Kingdee.BOS.Orm.DataEntity;
|
|
using Kingdee.BOS.ServiceHelper;
|
|
using Kingdee.BOS.Util;
|
|
using Kingdee.BOS.Core.DynamicForm;
|
|
using Kingdee.BOS.Core.DynamicForm.PlugIn;
|
|
namespace aoyuPlugIn
|
|
{
|
|
[Description("销售出库单据界面提交")]
|
|
public class jb_xsck_tj : AbstractBillPlugIn
|
|
{
|
|
public override void BarItemClick(BarItemClickEventArgs e)
|
|
{
|
|
base.BarItemClick(e);
|
|
if (e.BarItemKey == "tbSplitSubmit" || e.BarItemKey == "tbSubmit")//提交
|
|
{
|
|
try
|
|
{
|
|
string tsxx = "";
|
|
//e.DynamicObjects[0]["Id"]
|
|
string fid = this.View.Model.DataObject["Id"].ToString();
|
|
var sSql = String.Format("EXEC jb_get_kchz " + fid);
|
|
var dr = DBServiceHelper.ExecuteDynamicObject(this.Context, sSql);
|
|
foreach (var r in dr)
|
|
{
|
|
tsxx = tsxx + "出货单号:" + r[0].ToString() + "|物料编号:" + r[1].ToString() + " |出货数:" + r[2].ToString() + "|差异数:" + r[3].ToString() + "\r\n";
|
|
}
|
|
if(tsxx!="")
|
|
this.View.ShowMessage(tsxx);
|
|
|
|
}
|
|
catch (Exception ex) { this.View.ShowMessage("提交时发生错误为:" + ex.Message); }
|
|
}
|
|
}
|
|
}
|
|
}
|