hongjli
2023-09-13 afcb84a794314268332e62c0b26c01a7b38c8115
_Main/BL/Type_GlobalDTOTable/Method_ReceivingPanelMaterials.qbl
@@ -8,11 +8,47 @@
  [*
    logfile( "--------------------------------------1------------------------------------------------" );
    nameValue := requestnvt.Root();
    info( nameValue.ToString() );
    bodyHandle := requestnvt.GetHandle( "Body" );
    restHandle := requestnvt.GetHandle( "Rest" );
    restPayloadHandle := requestnvt.GetHandle( "RestPayload" );
    bodyNameValue := nameValue.Child( bodyHandle );
    restNameValue := bodyNameValue.Child( restHandle );
    restPayloadNameValue := restNameValue.Child( restPayloadHandle );
    releaseDateHandle := requestnvt.GetHandle( "releaseDate" );
    businessTypeHandle := requestnvt.GetHandle( "businessType" );
    scenarioNameHandle := requestnvt.GetHandle( "scenarioName" );
    releaseDateNameValue := restPayloadNameValue.Child( releaseDateHandle );
    businessTypeNameValue := restPayloadNameValue.Child( businessTypeHandle );
    scenarioNameNameValue := restPayloadNameValue.Child( scenarioNameHandle );
    info( "发布时间:", releaseDateNameValue.GetValueAsString(), "    事业部:", businessTypeNameValue.GetValueAsString(), "    版本号:", scenarioNameNameValue.GetValueAsString() );
    panelMaterialsHandle := requestnvt.GetHandle( "panelMaterials" );
    panelMaterialsNameValue := restPayloadNameValue.Child( panelMaterialsHandle );
    childPanelMaterialsNameValue := panelMaterialsNameValue.Children();
    productIDHandle := requestnvt.GetHandle( "productID" );
    productDescriptionHandle := requestnvt.GetHandle( "productDescription" );
    startDateHandle := requestnvt.GetHandle( "startDate" );
    quantityHandle := requestnvt.GetHandle( "quantity" );
    traverse ( childPanelMaterialsNameValue, Elements, cpmnv ) {
      info( "产品:", cpmnv.Child( productIDHandle ).GetValueAsString() );
      info( "产品描述:", cpmnv.Child( productDescriptionHandle ).GetValueAsString() );
      info( "开始时间:", cpmnv.Child( startDateHandle ).GetValueAsString() );
      info( "数量:", cpmnv.Child( quantityHandle ).GetValueAsString() );
    }
    // ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    
    replynvt := LibInt_MessageAccessor::CreateEmptyMessage();
    LibInt_MessageAccessor::SetHeaderProperty( replynvt, "Content-Type", "application/json" );
    
    return emit( replynvt );
  *]
}