| API / APIs Radiofréquence | |
| Version ACE : 5.0-00 | |
|
Package : Standard Sous-programme Basic : Rec_Allotie Nom de la gnc : gnc_rf_rec_allotie |
Fonctionnalité : Réception |
| Schémas d’entrée et de sortie : | voir en fin de document. |
Cette API permet de déterminer si une réception est de type « Allotie » et, dans ce cas , de calculer le nombre de charges alloties.
API imbriquées : aucune.
Contraintes et limites de fonctionnement (hors périmètre)
| RAS. |
Paramétrage (PPE)
| ALOTIE - |
Prototype de la fonction Basic
| Rec_Allotie (numero_module, typdep, sigdep, numrec, nb_chg) |
Cas d’erreurs
| CODE | DESCRIPTION |
|---|---|
| 0 | Parameter ‘ALOTIE’ is not active. |
| 0 | The reception is not managed with lot |
Processus, contrôles et règles de gestion
| ETAPE | DESCRIPTION DU PROCESSUS |
| Détail : |
If the parameter ‘ALOTIE’ is not active, the API returns the error code 0. For each reception line data (LREL table) read with the input parameters (typdep, sigdep, numrec) ordered ascending by parent stock object ID (idobjpere). For each stock movement (table LMVTSTK ) read with the input parameters (typdep, sigdep) and reception number (lrel.numrec) and reception line number (lrel.numligrec). If the reception line number for the stock movement is different from the reception line number for the reception line (lmvtstk.numligrec != lrel.numligrec). Read the next stock movement. If there is a not validated (lmvtstk.status != 9) entry movement (lmvtstk.typmvt = ‘E’ and lmvtstk.sensmvt = ‘E’). The stock movement is considered as found. If a not validated entry movement is found. Read the EE header (LEAE table) with (lrel.typtie, lrel.sigtie, lrel.numea). If the EE header is not found. It is considered that the reception is not from ‘allotie’ type. Search for a supplier (Read the thirdparty data (table TIE ) with (lrel.typfou and lrel.sigfou).) If the supplier is not found. It is considered that the reception is not a reception managed with lot. Check if the found supplier managed loads with lot. (Read the parameterized field from the thirdparty data (TIE table) referred by the ‘ALOTIE ’ parameter field N1 .) (Compare the value of the parameterized field with the ‘ALOTIE’ parameter field A1.) If the found supplier does not accept managed loads with lot. It is considered that the reception is not managed with lot. If the current reception line parent stock object ID is not presented (lrel.idobjpere is empty). It is considered that the reception is not managed with lot. If current reception line parent stock object ID (LREL.idobjpere) is changed compared to the previous reception line parent stock object ID. The number of the found loads is incremented with one. It the reception is managed with lot, the API returns the error code 0. The API returns the total number of found loads. |
Erreurs possibles
| CAUSE | EFFET |
| Parameter ‘ALOTIE’ is not active. | Code erreur 0 |
| The reception is not managed with lot. | Code erreur 0 |
| NOM DU PARAMÈTRE | TYPE | FORMAT | TAILLE | OBL O/N | REMARQUE |
| typdep | Char(3) | O | Thirdparty type | ||
| sigdep | Char(12) | O | Thirdparty ID | ||
| numrec | Char(10) | O | Reception number |
| NOM DU PARAMÈTRE | TYPE | FORMAT | TAILLE | REMARQUE |
| ParamOut1 | LONG | Total number of found loads |