From 2493310b41c4893984b045269e1e1612541fc205 Mon Sep 17 00:00:00 2001
From: lazhen <17772815105@139.com>
Date: 星期五, 25 十月 2024 11:37:49 +0800
Subject: [PATCH] 库存更新添加数量工厂字段
---
_Main/BL/Type_InventoryPointSelection/Function_CalcQuantity.qbl | 16 ++++++++
_Main/BL/Type_InventoryInterfaceData/StaticMethod_Generate.qbl | 5 +-
_Main/UI/MacroPlannerWebApp/Component_FormInventoryPointSelection/Component_ListInventoryPointSelection.def | 2
_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Initialize.qbl | 2
_Main/UI/MacroPlannerWebApp/Component_FormInventoryInterfaceDataDetail/Component_ListInventoryInterfaceDataDetail.def | 2
_Main/UI/MacroPlannerWebApp/Views/InvnetoryUpdate.vw | 30 ++++++++++++++-
_Main/BL/Type_InventoryInterfaceDataDetail/Attribute_Fac.qbl | 8 ++++
_Main/BL/Type_InventoryPointSelection/Attribute_Quantity.qbl | 7 +++
_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Import.qbl | 2
_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory#575.qbl | 2
_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory.qbl | 4 +-
_Main/BL/Type_CCEngineLogisticsCostReport0/StaticMethod_Import.qbl | 2
12 files changed, 70 insertions(+), 12 deletions(-)
diff --git a/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Import.qbl b/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Import.qbl
index be9c992..5cae7b1 100644
--- a/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Import.qbl
+++ b/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Import.qbl
@@ -44,7 +44,7 @@
attricell := selectobject( samerow, GeneralExcelImportAndExportDataCell, attricell, attricell.GeneralExcelImportAndExportDataColumn() = attricolumn );
if( attricell.Value() = '鎬昏垂鐢�' ){
valuecell := selectobject( samerow, GeneralExcelImportAndExportDataCell, valuecell, valuecell.GeneralExcelImportAndExportDataColumn() = excelcolumn );
- if( [Real]valuecell.Value() <> cell.AllCost() ){
+ if( valuecell.Value() <> cell.AllCost().Format( 'N(Dec)' ) ){
cell.AllCost( [Real]valuecell.Value() );
cell.IsUpdate( true );
}
diff --git a/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Initialize.qbl b/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Initialize.qbl
index ed2c859..3dbc8fd 100644
--- a/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Initialize.qbl
+++ b/_Main/BL/Type_CCEngineLogisticsCostReport/StaticMethod_Initialize.qbl
@@ -21,7 +21,7 @@
startofnextyear := startofplanning.StartOfNextYear();
table := owner.CCEngineLogisticsCostReport( relnew, ID := name, Name := name );
- showtable := owner.CCEngineLogisticsCostReport( relnew, ID := name + 'Show', Name := name, IsShow := true );
+ owner.CCEngineLogisticsCostReport( relnew, ID := name + 'Show', Name := name, IsShow := true );
search := owner.CCEngineLogisticsCostSearch( relnew, Generation := allunit, MqbMlb := allunit, Power := allunit );
products := construct( Product_MPs );
diff --git a/_Main/BL/Type_CCEngineLogisticsCostReport0/StaticMethod_Import.qbl b/_Main/BL/Type_CCEngineLogisticsCostReport0/StaticMethod_Import.qbl
index 7761078..ce05c55 100644
--- a/_Main/BL/Type_CCEngineLogisticsCostReport0/StaticMethod_Import.qbl
+++ b/_Main/BL/Type_CCEngineLogisticsCostReport0/StaticMethod_Import.qbl
@@ -43,7 +43,7 @@
attricell := selectobject( samerow, GeneralExcelImportAndExportDataCell, attricell, attricell.GeneralExcelImportAndExportDataColumn() = attricolumn );
if( attricell.Value() = '鎬昏垂鐢�' ){
valuecell := selectobject( samerow, GeneralExcelImportAndExportDataCell, valuecell, valuecell.GeneralExcelImportAndExportDataColumn() = excelcolumn );
- if( [Real]valuecell.Value() <> cell.AllCost() ){
+ if( valuecell.Value() <> cell.AllCost().Format( 'N(Dec)' ) ){
cell.AllCost( [Real]valuecell.Value() );
cell.IsUpdate( true );
}
diff --git a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_Generate.qbl b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_Generate.qbl
index ea304d5..e25faf2 100644
--- a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_Generate.qbl
+++ b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_Generate.qbl
@@ -5,6 +5,7 @@
Date date,
String partno,
String inventory,
+ String fac,
Number quantitiy
)
{
@@ -15,9 +16,9 @@
if( isnull( iid ) ){
iid := interfaceDataset.InventoryInterfaceData( relnew, Date := date, PartNumber := partno );
}
- iidl := selectobject( iid, InventoryInterfaceDataDetail, detail, detail.InventoryPoint() = inventory );
+ iidl := selectobject( iid, InventoryInterfaceDataDetail, detail, detail.InventoryPoint() = inventory and detail.Fac() = fac );
if( isnull( iidl ) ){
- iid.InventoryInterfaceDataDetail( relnew, Date := date, PartNumber := partno, InventoryPoint := inventory, Quantity := quantitiy );
+ iid.InventoryInterfaceDataDetail( relnew, Date := date, PartNumber := partno, InventoryPoint := inventory, Fac := fac, Quantity := quantitiy );
}
*]
}
diff --git "a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory\043575.qbl" "b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory\043575.qbl"
index 2943776..7db9387 100644
--- "a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory\043575.qbl"
+++ "b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory\043575.qbl"
@@ -19,7 +19,7 @@
traverse( inventorys, Elements, inventory ){
product := select( macroplan, Product_MP, product, product.Notes() = inventory.FourCode() );
if( not isnull( product ) ){
- InventoryInterfaceData::Generate( owner, inventory.DDay(), product.ID(), inventory.BIPlace(), [Number]inventory.Total() );
+ InventoryInterfaceData::Generate( owner, inventory.DDay(), product.ID(), inventory.BIPlace(), inventory.Fac(), [Number]inventory.Total() );
}
}
*]
diff --git a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory.qbl b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory.qbl
index 9d17067..c3ba39b 100644
--- a/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory.qbl
+++ b/_Main/BL/Type_InventoryInterfaceData/StaticMethod_SynchronizeInventory.qbl
@@ -22,13 +22,13 @@
if( inventory.Fac() = 'DL' and inventory.Lgort() = 'All' ){
inventoryname := inventory.LineType();
}
- InventoryInterfaceData::Generate( interfaceDataset, inventory.DDay(), inventory.MaterialNo(), inventoryname, [Number]inventory.Total() );
+ InventoryInterfaceData::Generate( interfaceDataset, inventory.DDay(), inventory.MaterialNo(), inventoryname, inventory.Fac(), [Number]inventory.Total() );
}
//鍙戝姩鏈烘垚鍝佸簱瀛�
traverse( loginfo, FinishedEngineInventory, inventory ){
product := select( macroPlan, Product_MP, product, product.Notes() = inventory.FourCode() );
if( not isnull( product ) ){
- InventoryInterfaceData::Generate( interfaceDataset, inventory.DDay(), product.ID(), inventory.BIPlace(), [Number]inventory.Total() );
+ InventoryInterfaceData::Generate( interfaceDataset, inventory.DDay(), product.ID(), inventory.BIPlace(), inventory.Fac(), [Number]inventory.Total() );
}
}
}
diff --git a/_Main/BL/Type_InventoryInterfaceDataDetail/Attribute_Fac.qbl b/_Main/BL/Type_InventoryInterfaceDataDetail/Attribute_Fac.qbl
new file mode 100644
index 0000000..0cb5b77
--- /dev/null
+++ b/_Main/BL/Type_InventoryInterfaceDataDetail/Attribute_Fac.qbl
@@ -0,0 +1,8 @@
+Quintiq file version 2.0
+#parent: #root
+Attribute Fac
+{
+ #keys: '3[415136.0.1243601350][415136.0.1243601349][415136.0.1243601351]'
+ Description: '宸ュ巶鍚嶇О'
+ ValueType: String
+}
diff --git a/_Main/BL/Type_InventoryPointSelection/Attribute_Quantity.qbl b/_Main/BL/Type_InventoryPointSelection/Attribute_Quantity.qbl
new file mode 100644
index 0000000..95e2df0
--- /dev/null
+++ b/_Main/BL/Type_InventoryPointSelection/Attribute_Quantity.qbl
@@ -0,0 +1,7 @@
+Quintiq file version 2.0
+#parent: #root
+Attribute Quantity
+{
+ #keys: '3[415136.0.1243601340][415136.0.1243601339][415136.0.1243601341]'
+ ValueType: Real
+}
diff --git a/_Main/BL/Type_InventoryPointSelection/Function_CalcQuantity.qbl b/_Main/BL/Type_InventoryPointSelection/Function_CalcQuantity.qbl
new file mode 100644
index 0000000..ea6b2c1
--- /dev/null
+++ b/_Main/BL/Type_InventoryPointSelection/Function_CalcQuantity.qbl
@@ -0,0 +1,16 @@
+Quintiq file version 2.0
+#parent: #root
+Function CalcQuantity
+{
+ TextBody:
+ [*
+ // 鐢勫叞楦� Oct-25-2024 (created)
+
+ value := 0.0;
+ if( this.IsIncluded() ){
+ value := sum( this, InventoryInterfaceDataDetail, detail, detail.Quantity() );
+ }
+
+ this.Quantity( value );
+ *]
+}
diff --git a/_Main/UI/MacroPlannerWebApp/Component_FormInventoryInterfaceDataDetail/Component_ListInventoryInterfaceDataDetail.def b/_Main/UI/MacroPlannerWebApp/Component_FormInventoryInterfaceDataDetail/Component_ListInventoryInterfaceDataDetail.def
index 8d8e8c8..a0e6b6b 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_FormInventoryInterfaceDataDetail/Component_ListInventoryInterfaceDataDetail.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_FormInventoryInterfaceDataDetail/Component_ListInventoryInterfaceDataDetail.def
@@ -29,7 +29,7 @@
]
Properties:
[
- Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Date","title":"Date","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Date"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"PartNumber","title":"PartNumber","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"PartNumber"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"InventoryPoint","title":"InventoryPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"InventoryPoint"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Quantity","title":"Quantity","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Quantity"}}]'
+ Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Date","title":"Date","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Date"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"PartNumber","title":"PartNumber","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"PartNumber"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"InventoryPoint","title":"InventoryPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"InventoryPoint"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Fac","title":"Fac","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Fac"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Quantity","title":"Quantity","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Quantity"}}]'
ContextMenu: 'listContextMenuInventoryInterfaceDataDetail'
Taborder: 2
]
diff --git a/_Main/UI/MacroPlannerWebApp/Component_FormInventoryPointSelection/Component_ListInventoryPointSelection.def b/_Main/UI/MacroPlannerWebApp/Component_FormInventoryPointSelection/Component_ListInventoryPointSelection.def
index 72f0b47..34d1f04 100644
--- a/_Main/UI/MacroPlannerWebApp/Component_FormInventoryPointSelection/Component_ListInventoryPointSelection.def
+++ b/_Main/UI/MacroPlannerWebApp/Component_FormInventoryPointSelection/Component_ListInventoryPointSelection.def
@@ -29,7 +29,7 @@
]
Properties:
[
- Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ImgIsIncluded","title":"ImgIsIncluded","subtotals":"","tooltip":"","width":-1,"display":"shown","attribute":"ImgIsIncluded"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ProductID","title":"ProductID","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"ProductID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"InventoryPoint","title":"InventoryPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"InventoryPoint"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"StockpoingPoint","title":"StockpoingPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"StockpoingPoint"}}]'
+ Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ImgIsIncluded","title":"ImgIsIncluded","subtotals":"","tooltip":"","width":-1,"display":"shown","attribute":"ImgIsIncluded"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ProductID","title":"ProductID","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"ProductID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"InventoryPoint","title":"InventoryPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"InventoryPoint"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"StockpoingPoint","title":"StockpoingPoint","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"StockpoingPoint"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Quantity","title":"Quantity","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Quantity"}}]'
ContextMenu: 'listContextMenuInventoryPointSelection'
Taborder: 2
]
diff --git a/_Main/UI/MacroPlannerWebApp/Views/InvnetoryUpdate.vw b/_Main/UI/MacroPlannerWebApp/Views/InvnetoryUpdate.vw
index 1d0a1f8..c6dde50 100644
--- a/_Main/UI/MacroPlannerWebApp/Views/InvnetoryUpdate.vw
+++ b/_Main/UI/MacroPlannerWebApp/Views/InvnetoryUpdate.vw
@@ -25,7 +25,7 @@
FormInventoryInterfaceDataDetail_DataSetLevelInventoryInterfaceDataDetail
{
groupDepth: -1
- sort: 'DESC:Date,DESC:Quantity'
+ sort: 'InventoryPoint'
column_Date
{
columnId: 'Date'
@@ -53,12 +53,21 @@
subtotals: ''
width: 177
}
+ column_Fac
+ {
+ columnId: 'Fac'
+ dataPath: 'Fac'
+ dataType: 'string'
+ index: 3
+ subtotals: ''
+ width: 150
+ }
column_Quantity
{
columnId: 'Quantity'
dataPath: 'Quantity'
dataType: 'real'
- index: 3
+ index: 4
subtotals: ''
width: 155
}
@@ -80,6 +89,14 @@
}
components
{
+ FormInventoryInterfaceData_pHeader
+ {
+ sizeRatio: 1
+ }
+ FormInventoryInterfaceData_pContent
+ {
+ sizeRatio: 1
+ }
FormInventoryInterfaceData_ListInventoryInterfaceData
{
}
@@ -166,6 +183,15 @@
subtotals: ''
width: 150
}
+ column_Quantity
+ {
+ columnId: 'Quantity'
+ dataPath: 'Quantity'
+ dataType: 'real'
+ index: 4
+ subtotals: ''
+ width: 150
+ }
}
}
}
--
Gitblit v1.9.3