Kevin Kok Khah Whey
2023-09-27 56c0e837d2caae5f6a9ecda085715d6e29757ece
Kevin: Added test method and modified GlobalOTDTable.SetIsLinkedWithFinishedGoodAttributes method.
已修改3个文件
已添加3个文件
56 ■■■■■ 文件已修改
_Main/BL/Type_GlobalDTOTable/Method_SetIsLinkedWithFinishedGoodAttributes.qbl 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_GlobalDTOTable/Method_Test.qbl 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_Global_MappingProduct_MP/Attribute_BOMCount.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_Global_MappingProduct_MP/Method_SetIsLinkedWithFinishedGoodAttributes_Recursive.qbl 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlanner/Component_ApplicationLibMacroPlanner/Component_mbMainMenu.def 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlanner/Component_ApplicationLibMacroPlanner/Response_TIANMA_JITUAN_mbMainMenu_MenuGlobalOTDTableTest_OnClick.def 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_GlobalDTOTable/Method_SetIsLinkedWithFinishedGoodAttributes.qbl
@@ -30,12 +30,16 @@
    traverse( this, Global_MappingProduct_MP, product,
              product.ProductMajorType() = "鎴愬搧" )
    {
      uniquebomids := construct( Strings );
      product.IsLinkedWithFinishedGood( false );
      product.SetIsLinkedWithFinishedGoodAttributes_Recursive( 0, // depth
                                                               100, // maxdepth
                                                               productspool,
                                                               operationspool,
                                                               operationbomspool );
                                                               operationbomspool,
                                                               uniquebomids );
      uniquebomids := uniquebomids.Unique();
      product.BOMCount( uniquebomids.Size() );
    }
  *]
}
_Main/BL/Type_GlobalDTOTable/Method_Test.qbl
对比新文件
@@ -0,0 +1,9 @@
Quintiq file version 2.0
#parent: #root
Method Test
{
  TextBody:
  [*
    // KKO2 Sep-27-2023 (created)
  *]
}
_Main/BL/Type_Global_MappingProduct_MP/Attribute_BOMCount.qbl
对比新文件
@@ -0,0 +1,8 @@
Quintiq file version 2.0
#parent: #root
Attribute BOMCount
{
  #keys: '3[157968.0.1161166085][157968.0.1161166084][157968.0.1161166086]'
  Description: 'Number of unique BOM used to produce this finished good.'
  ValueType: Number
}
_Main/BL/Type_Global_MappingProduct_MP/Method_SetIsLinkedWithFinishedGoodAttributes_Recursive.qbl
@@ -5,7 +5,8 @@
  Number maxdepth,
  Global_MappingProduct_MPs productspool,
  Global_MappingOperations operationspool,
  Global_MappingOperationBOMs operationbomspool
  Global_MappingOperationBOMs operationbomspool,
  output Strings uniquebomids_o
)
{
  Description: 'Method to traverse the supply chain recursively to determine if there are any products that are not used to produce finished goods.'
@@ -13,6 +14,11 @@
  [*
    if( not this.IsLinkedWithFinishedGood() )
    {
      if( this.ProductMajorType() <> "鎴愬搧" )
      {
        uniquebomids_o.Add( this.ID() );
      }
      depth := depth + 1;
      this.IsLinkedWithFinishedGood( true );
      
@@ -50,7 +56,8 @@
                                                                                maxdepth,
                                                                                productspool,
                                                                                operationspool,
                                                                                operationbomspool );
                                                                                operationbomspool,
                                                                                uniquebomids_o );
            }
            
            if( operationbom.AlternativeMaterialCode() <> ""
@@ -66,7 +73,8 @@
                                                                                    maxdepth,
                                                                                    productspool,
                                                                                    operationspool,
                                                                                    operationbomspool );
                                                                                    operationbomspool,
                                                                                    uniquebomids_o );
              }
            }
          }
_Main/UI/MacroPlanner/Component_ApplicationLibMacroPlanner/Component_mbMainMenu.def
@@ -13,6 +13,10 @@
          [
            Component MenuSpecial #extension
            {
              Children:
              [
                Component MenuGlobalOTDTableTest { #keys: '[157968.0.1170224128]' BaseType: 'Menu' Properties: [ Image: 'DUDE2' Text: 'GlobalOTDTable Test' ] }
              ]
              Properties:
              [
                ModeledStringList ChildOrdering
@@ -30,6 +34,7 @@
                  c: MenuTest
                  c: MenuScenarioManagerTest
                  c: MenuMPDomainHandlerTest
                  c: MenuGlobalOTDTableTest
                  c: MenuRemoveHistory
                  c: Menu46
                  c: MenuRefresh
_Main/UI/MacroPlanner/Component_ApplicationLibMacroPlanner/Response_TIANMA_JITUAN_mbMainMenu_MenuGlobalOTDTableTest_OnClick.def
对比新文件
@@ -0,0 +1,12 @@
Quintiq file version 2.0
#parent: mbMainMenu/MenuGlobalOTDTableTest
Response OnClick () id:Response_TIANMA_JITUAN_mbMainMenu_MenuGlobalOTDTableTest_OnClick
{
  #keys: '[157968.0.1170224134]'
  Body:
  [*
    // Run GlobalOTDTable test method
    GlobalOTDTable.Test();
  *]
  DefinitionID: 'Responsedef_Menu_OnClick'
}