Sage: begin order processing (StartGenOrderAssignedMasterData)
Sage: begin order processing (StartGenOrderAssignedMasterData)
Before new order-related master data can be created or existing order-related master data modified, this function for initializing the generation must be called. It checks if a tax rate is already present for the order number/position. If that is not the case, a tax rate is created. If, however, a tax rate is already present, then it is a case of reconfiguration. In this instance, all order-related BOMs and routings for the order/position are deleted.
The function has the following mandatory fields: order number (aufnr), order position (aufpos), identification number (identnr), account (konto), and rate type (satzart). The rate type is always 1 for customers.After calling the function, it returns the reconfiguration parameter without input data. This specifies if new order-related master data is to be created (0) or reconfigured (1).
Otherwise, the service delivers a corresponding error message on the parameter Message.
After ending the function for manipulating order-related master data, the function ’FinishGenOrderAssignedMasterData’ must be called.
Syntax: Status = f$SageService ( Service , 'StartGenOrderAssignedMasterData' , InputPG , OutputPG ) | |||
| Argument | Type | Meaning |
| Service | String | URL of the web service |
| 'StartGenOrderAssignedMasterData' | String | Command constant |
| 'PGINPUT' | String | Name of the ePOS parameter group with the input data. |
| 'PGOUTPUT' | String | Name of the ePOS parameter group with the result data. |
Result: | Integer | Status of the function: 1 : the service function was successfully called -1 : the component eposvbcomexe could not be found -2 : function URL not entered -4 : general error | |
Example: | B7Service = 'http://b7demo.sagebaeurer.de/br71/callin/epos_soap' Auftrag_bearbeiten.aufnr = eposcall_ret.aufnr Auftrag_bearbeiten.aufpos = eposcall_ret.aufpos Auftrag_bearbeiten.identnr = eposcall_ret.identnr Auftrag_bearbeiten.var = eposcall_ret.var Auftrag_bearbeiten.satzart = 1 auftrag_such.aufnr = eposcall_ret.aufnr Status = f$SageService ( B7Service , 'ReadOrder' , 'auftrag_such' , 'auftrag_kopf,auftrag_pos' ) Auftrag_bearbeiten.konto = auftrag_kopf.konto Status = f$SageService ( B7Service , 'StartGenOrderAssignedMasterData' , 'process_order' , 'process_order' ) | ||