| API / APIs Radiofréquence | |
| Version ACE : 5.0-00 | |
|
Package : Standard Sous-programme Basic : Controle_Centre Nom de la gnc : gnc_rf_controle_liv |
Fonctionnalité :Expédition |
| Schémas d’entrée et de sortie : | voir en fin de document. |
The API controls whether a particular parcel for delivery fulfils the delivery point constraints.
API imbriquées : aucune.
Contraintes et limites de fonctionnement (hors périmètre)
| RAS |
Paramétrage (PPE)
Prototype de la fonction Basic
| Function Controle_Centre(p_sigdep As String, p_idtrn As String, p_sigliv As String, p_idobj As String, p_ordre_charge As String, p_affiche_message As String, p_zone As String) As Integer |
Messages en entrée
| LMAGADR~ p_typdep ~ p_sigdep ~ p_lcodmag ~ p_adremp ~ |
Messages en sortie
| Retour~p_resultat |
Valeurs restituées par l’API
| VALEUR | REMARQUE |
| 1 | La palette est à charger et correspond au tiers à livrer. |
| 10 | La palette n’existe pas, ou alors, l’objet de stock correspondant à la palette n’existe pas. |
| 12 | La palette ne correspond pas à la tournée définie en entrée. |
| 19 | La palette appartient à une vacation trieur non terminée. |
| 11 | La palette ne correspond pas au tiers à livrer. |
| 20 | Le numéro d’ordre de la palette ne correspond pas au numéro d’ordre défini en entrée. |
| 18 | L’objet de stock n’est pas sur le quai de la tournée. |
Processus, contrôles et règles de gestion
| ETAPE | DESCRIPTION DU PROCESSUS |
| 1 | Identification du colis associé à la palette. |
| 2 | Contrôle que la palette correspond à la tournée définie en entrée. |
| 3 | Si le paramètre N3 du paramètre LOGTRI est positionné, identification de la vacation correspondant à la palette, et contrôle qu’il ne s’agit pas d’une vacation trieur non terminée. |
| 4 | Contrôle que la palette correspond au tiers à livrer. |
| 5 | Identification du numéro d’ordre de chargement de la palette suivant le paramètre N1 du paramètre LRFTRN. |
| 6 | Contrôle que le numéro d’ordre de la palette correspond au numéro d’ordre défini en entrée. |
| 7 | Identification de l’objet de stock correspondant à la palette. |
| 8 | Contrôle que l’objet de stock est sur le quai de la tournée. |
| Détail : |
Read the parcel data for the stock object (LCOL table) with the input parameters (sigdep, idobjcol=idobj). If the parcel is not found, the API returns the error code 10. If the parcel does not belong to the expedition tour (lcol.idtrn != idtrn), the API returns the error code 12. Control whether the loading can be done in advance. (If the parameter ‘LDEPOT’ is active and the parameter field N4 is different from ‘0’. Read the depot data (TIE) with (typtie = lcol.typtie, sigtie = lcol.sigtie). If the depot is found. Read the parameterized field from the depot referred by the N4 field of the parameter ‘LDEPOT’. ) If the loading cannot be done in advance. Control whether a dispatcher wave is terminated . If the parameter LOGTRI is active and the parameter field N3 is different from ‘0’. Read the wave header data (LVACE) with (lcol.typtie, lcol.sigtie, lcol.idvac). If the wave header is found. Control whether it is a dispatcher wave. (Read the parameterized field from the wave header referred by the N3 field of the parameter ‘LOGTRI’.) If it is a dispatcher wave (the value of the parameterized field is equal to ‘1’) and the wave is still not terminated (lvace.flgeclat != ‘T’). The API returns the error code 19. Read the delivery order header data (LOLE table) for the parcel with (lcol.typtie, lcol.sigtie, lcol.idol). If the parameter LTRN is active or the input third-party associated with the delivery is presented (sigliv is not empty). If the delivery header’s third-party associated with the delivery is different from the input third-party associated with the delivery (lole.sigliv != sigliv). The API returns the error code 11. Read the parameter LRFTRN. Call the function gnc_rf_num_chargement, as so to retrieve the loading order No for the parcel (lcol.numchg). If the loading order No for the parcel is not equal to the input loading order No ‘num’, the API returns the error code 20. Read the stock object data (LOBJSTK table) with the corresponding parcel data (lcol.typtie, lcol.sigtie, idobj= lcol.idobjcol). If the stock object data is not found, the API returns the error code 10. Read the expedition round data (LTRN table) with the stock object’s third-party (lobjstk.typtie, lobjstk.sigtie) and the input parameter ‘idtrn’. If the input preparation area is not presented (zone is empty). If the expedition round quay (ltrn.quai) is not equal to the stock object’s slot address ( lobjstk.adremp ), the API returns the error code 18. Otherwise: Control whether the stock object is already in the preparation area. (For each preparation area data (lzonppr) read with the stock object’s third-party (lobjstk.typtie, lobjstk.sigtie) and the input parameter ‘zone’. If the preparation area’s logistic store code is different from the store code of the stock object data (lcodmag != lobjstk.lcodmag). Continue with the next preparation area. Otherwise. Stop the reading.) If no such preparation area found. The API returns error code 18. |
Erreurs possibles
| CAUSE | EFFET |
| La palette n’existe pas ou l’objet de stock correspondant à la palette n’existe pas. | Code retour 10, message « Palette inconnue » |
| La palette ne correspond pas au tiers à livrer. | Code retour 11, message « La palette ne correspond pas au centre à charger ». |
| La palette ne correspond pas à la tournée passée en entrée. | Code retour 12, message « La palette ne correspond pas à la tournée à charger ». |
| L’objet de stock n’est pas sur le quai de la tournée. | Code retour 18, message « Adresse palette incorrecte ». |
| La palette appartient à une vacation trieur non terminée. | Code retour 19, message « Vacation trieur non terminée ». |
| Le numéro d’ordre de la palette ne correspond pas à celui passé en entrée. | Code retour 20, message « La palette n'a pas le bon numéro d'ordre ». |
Exemple(s) d’utilisation
| Retour_Controle_Centre = Controle_Centre (p_sigdep, idtrn, p_sigliv, w_idpalette, p_ordre_charge, "O") |
| NOM DU PARAMÈTRE | TYPE | FORMAT | TAILLE | OBL O/N | REMARQUE |
| sigdep | CHAR | 12 | O | Sigle du dépôt | |
| idtrn | CHAR | 10 | O | Identifiant de la tournée | |
| sigliv | CHAR | 12 | O | Sigle du tiers à livrer | |
| idobj | CHAR | 18 | O | Identifiant palette à charger | |
| num | CHAR | 10 | O | Numéro d'ordre de chargement (facultatif). | |
| zone | CHAR | 4 | N | Zone de préparation |
| NOM DU PARAMÈTRE | TYPE | FORMAT | TAILLE | REMARQUE |
| P_résultat | Long | Code retour de l’API |