| API / APIs Radiofréquence | |
| Version ACE : 1.4 | |
|
Package : Standard Sous-programme Basic : gnc_rf_creation_lot_egx |
Fonctionnalité :SCE Mobile |
| Schémas d’entrée et de sortie : | voir en fin de document. |
Cette API permet de créer un lot de préparation. Toutes les informations nécessaires à la préparation sont transmises via les champs du schéma d'entrée.
Les champs de type « date » sont renseignés sous cette forme : « JJMMAAAA ».
API imbriquées : aucune.
Contraintes et limites de fonctionnement (hors périmètre)
| RAS. |
Paramétrage (PPE)
Détail de l'API
Read the product code data (pro) with the input product code (codpro).
If the product’s stock tracking is lot/slot stock tracking (suistk = ‘L’ or suistk = ‘X’).
If the parameter ‘PRXLOT’ is active and the parameter field N1 is different from 0.
Call the function gnc_zone_gere, as so to read the data from a given customized field which number is taken from N1 field of parameter ‘PRXLOT’. This information indicates whether the product is managed per lot or not.
Call the function gnc_gesost_batch_calc_numlot to receive a new lot number.
If the function succeeds.
Create a new stock’s lot object (lsk) with (codpro = input product code, sigdep = the input third party ID (sigtie), numlot = the lot number generated by the gnc_gesost_batch_calc_numlot function).
If the stock’s lot object is created.
Call the functions gnc_gesost_batch_init and gnc_gesost_batch_creat_ost to create a new lot (ost) with (numlot = the lot number generated by the gnc_gesost_batch_calc_numlot function,
reflot = if the parameter ‘PRXLOT’ is active
the lot number generated by the gnc_gesost_batch_calc_numlot.
else if the input lot reference is presented (reflot != “”)
the input lot reference
else the lot number generated by the gnc_gesost_batch_calc_numlot,
codpro = input product code).
If the function gnc_gesost_batch_creat_ost is successfully executed.
Update the fields of the new lot object (OST) (datlc, datfab, durvie, datlv, datdluo) with the corresponding input parameters.
If the product is managed per lot.
Call the function gnc_zone_gere, as so to update the customized field which number is taken from N2 field of the parameter ‘PRXLOT’ of the new lot object (OST) with the input lot reference (reflot).
If the parameter ‘PRXLOT’ is active .
Call the function gnc_zone_gere, as so to update the customized field 8 of the new lot object (ost) with agrement.
If the parameter ‘LRECQ’ is active and the parameter field N3 is different from 0.
Call the function gnc_zone_gere, as so to update the customized field which number is taken from N3 field of the parameter ‘LRECQ’ of the new lot object (ost) with agrement.
Return the code 1.
| NOM DU PARAMÈTRE | FORMAT | REMARQUE |
| sigtie | Char(12) | Third party ID. |
| codpro | Char(16) | Product code. |
| datfab | Char(8) | Manufacturing date. |
| datdlc | Char(8) | Use-by-date. |
| durvie | Number | Lifetime. |
| datlv | Char(8) | Sell-by-date. |
| datdluo | Char(8) | Deadline of the optimum use. |
| reflot | Char(30) | Lot reference. |
| NOM DU PARAMÈTRE | FORMAT | OBL O/N | REMARQUE |
| sigtie | Char(12) | O | Third party ID. |
| codpro | Char(16) | O | Product code. |
| numlot | Char(7) | O | Number of the created lot. |