|
|
|
@ -39,7 +39,7 @@ namespace BWP.Web.Pages.B3YunKen.ProductTask_ |
|
|
|
protected static DFInfo mGoodsDFInfo = DFInfo.Get(typeof(Goods)); |
|
|
|
protected static DFInfo mPropDFInfo = DFInfo.Get(typeof(GoodsProperty)); |
|
|
|
|
|
|
|
private DFChoiceBox ccbxEmployeeUnit, ccbxDepartment, ccbxProductionUnit; |
|
|
|
private DFChoiceBox ccbxEmployeeUnit, ccbxDepartment, ccbxProductionUnit, ccbxAccountingUnit; |
|
|
|
private DFDateInput cDateInput; |
|
|
|
private DFTextBox ccbxRemark; |
|
|
|
|
|
|
|
@ -72,13 +72,16 @@ namespace BWP.Web.Pages.B3YunKen.ProductTask_ |
|
|
|
var hPanelB = titlePanel.EAdd(new HLayoutPanel()); |
|
|
|
|
|
|
|
hPanelB.Add(new SimpleLabel("生产单位")); |
|
|
|
hPanelB.Add(ccbxProductionUnit = new DFChoiceBox() { Width = 130, EnableTopItem = true, DataKind = B3ProduceUnitedInfosDataSources.生产单位全部 }); |
|
|
|
hPanelB.Add(ccbxProductionUnit = new DFChoiceBox() { Width = 130, EnableTopItem = true, DataKind = B3ProduceUnitedInfosDataSources.生产单位 }); |
|
|
|
|
|
|
|
hPanelB.Add(new SimpleLabel("部门")); |
|
|
|
hPanelB.Add(ccbxDepartment = new DFChoiceBox() { Width = 130, EnableTopItem = true, DataKind = B3FrameworksConsts.DataSources.授权部门全部 }); |
|
|
|
|
|
|
|
hPanelB.Add(new SimpleLabel("会计单位")); |
|
|
|
hPanelB.Add(ccbxAccountingUnit = new DFChoiceBox() { Width = 130, EnableTopItem = true,DataKind = B3FrameworksConsts.DataSources.授权会计单位 }); |
|
|
|
|
|
|
|
hPanelB.Add(new SimpleLabel("经办人")); |
|
|
|
hPanelB.Add(ccbxEmployeeUnit = new DFChoiceBox() { Width = 130, EnableTopItem = true, DataKind = "授权员工" }); |
|
|
|
hPanelB.Add(ccbxEmployeeUnit = new DFChoiceBox() { Width = 130, EnableTopItem = true, EnableInputArgument = true, DataKind = "授权员工" }); |
|
|
|
|
|
|
|
hPanelB.Add(new SimpleLabel("日期")); |
|
|
|
hPanelB.Add(cDateInput = new DFDateInput() { Width = 130, Date = DateTime.Today }); |
|
|
|
@ -99,6 +102,8 @@ namespace BWP.Web.Pages.B3YunKen.ProductTask_ |
|
|
|
throw new Exception("请选择部门"); |
|
|
|
if (string.IsNullOrEmpty(ccbxEmployeeUnit.Value)) |
|
|
|
throw new Exception("请选择经办人"); |
|
|
|
if (string.IsNullOrEmpty(ccbxAccountingUnit.Value)) |
|
|
|
throw new Exception("请选择会计单位"); |
|
|
|
if (!cDateInput.Value.HasValue) |
|
|
|
throw new Exception("请选择日期"); |
|
|
|
if (!mBrowseGrid.GetSelectedItems().Any()) |
|
|
|
@ -162,6 +167,7 @@ namespace BWP.Web.Pages.B3YunKen.ProductTask_ |
|
|
|
var inputDate = cDateInput.Value.Value; |
|
|
|
var remark = ccbxRemark.Text; |
|
|
|
var employeeID = long.Parse(ccbxEmployeeUnit.Value); |
|
|
|
var accounting = ccbxAccountingUnit.Value; |
|
|
|
|
|
|
|
var dmo = new ProductNotice(); |
|
|
|
//dmo.AccountingUnit_ID = accounitingId;
|
|
|
|
@ -171,6 +177,7 @@ namespace BWP.Web.Pages.B3YunKen.ProductTask_ |
|
|
|
dmo.Date = inputDate; |
|
|
|
dmo.Employee_ID = employeeID; |
|
|
|
dmo.Remark = remark; |
|
|
|
dmo.AccountingUnit_ID = long.Parse(accounting); |
|
|
|
foreach (var grouping in list.GroupBy(x => x.GoodsId)) |
|
|
|
{ |
|
|
|
var goodsId = grouping.Key; |
|
|
|
|