initialer Upload

This commit is contained in:
2024-06-17 16:49:41 +02:00
parent 5ccc4188a2
commit f427ef5537
9 changed files with 3391 additions and 0 deletions

View File

@@ -0,0 +1,52 @@
////////////////////////////////////////////////////////////////////////////////
// Hook for dbs | invoice
// => ERP-Functions (Communication with ERP)
// File-Encoding: UTF-8 without BOM( Test: ü,ä,ö )
//------------------------------------------------------------------------------
// Created/Edited | Description
//------------------------------------------------------------------------------
// 08.2017 | dbs | invoice workflow 1.1.0
////////////////////////////////////////////////////////////////////////////////
vars lGMF_ERP_SYSTEMS[2] = { "XML", "WCS2" } // init array for erp system types
//---------------------------------------------------------------------------------------------------------------------------------------------------
// general ERP Configurations
//---------------------------------------------------------------------------------------------------------------------------------------------------
global gGMF_ERP_SYSTEM = lGMF_ERP_SYSTEMS[1] // XML: 1, WCS2: 2 configure the erp type
//---------------------------------------------------------------------------------------------------------------------------------------------------
// getMetaDataFromERP
//---------------------------------------------------------------------------------------------------------------------------------------------------
proc getMetaDataFromERP()
{
vars lReturnValue = 0
if( gGMF_GET_ERP_META_DATA_HOOK == "1" )
{
}
return lReturnValue
} // end of getMetaDataFromERP
//---------------------------------------------------------------------------------------------------------------------------------------------------
// createRecordInERP
//---------------------------------------------------------------------------------------------------------------------------------------------------
proc createRecordInERP( pDocId )
{
vars lReturnValue = 0
vars lStorage
lReturnValue = api_function( "attribute_get_single", gDDF_STORAGE, 0, pDocId, "Master" )
if ( lReturnValue == 0 && api_single_info != "" )
{
lStorage = api_single_info
}
if( gGMF_ERP_SYSTEM == lGMF_ERP_SYSTEMS[2] && lStorage == gSTORAGE_WORKFLOW )
{
// do WCS2 function create record and start workflow
return createRecordInWCS2( pDocId, gGMF_WEB_SERVICE_URL )
}
return lReturnValue
} // end of createRecordInERP