forked from verdnatura/hedera-web
EDI: Added field RFF+VN(vendorOrderNumber)
This commit is contained in:
parent
9ca2f78103
commit
00c7f9da0d
|
@ -1,4 +1,4 @@
|
||||||
hedera-web (1.408.1) stable; urgency=low
|
hedera-web (1.408.2) stable; urgency=low
|
||||||
|
|
||||||
* Initial Release.
|
* Initial Release.
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "hedera-web",
|
"name": "hedera-web",
|
||||||
"version": "1.408.1",
|
"version": "1.408.2",
|
||||||
"description": "Verdnatura web page",
|
"description": "Verdnatura web page",
|
||||||
"license": "GPL-3.0",
|
"license": "GPL-3.0",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|
|
@ -54,15 +54,6 @@ class Load extends Edi\Method {
|
||||||
else
|
else
|
||||||
$sender = NULL;
|
$sender = NULL;
|
||||||
|
|
||||||
$db->query('CALL mail_new(#messageId, #sender, @mailFk)', [
|
|
||||||
'messageId' => $messageId,
|
|
||||||
'sender' => $sender
|
|
||||||
]);
|
|
||||||
$mailId = $db->getValue("SELECT @mailFk");
|
|
||||||
|
|
||||||
echo "Message from: $sender\n";
|
|
||||||
echo " -> Message id: $messageId\n";
|
|
||||||
|
|
||||||
if ($this->restrictToSenders) {
|
if ($this->restrictToSenders) {
|
||||||
$isAllowed = $db->getValue(
|
$isAllowed = $db->getValue(
|
||||||
"SELECT COUNT(*) > 0 FROM mailSender WHERE mail = #",
|
"SELECT COUNT(*) > 0 FROM mailSender WHERE mail = #",
|
||||||
|
@ -73,6 +64,15 @@ class Load extends Edi\Method {
|
||||||
throw new Exception('Mail processing from unknown senders is disabled');
|
throw new Exception('Mail processing from unknown senders is disabled');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$db->query('CALL mail_new(#messageId, #sender, @mailFk)', [
|
||||||
|
'messageId' => $messageId,
|
||||||
|
'sender' => $sender
|
||||||
|
]);
|
||||||
|
$mailId = $db->getValue("SELECT @mailFk");
|
||||||
|
|
||||||
|
echo "Message from: $sender\n";
|
||||||
|
echo " -> Message id: $messageId\n";
|
||||||
|
|
||||||
// Searches the EDI message on mail parts
|
// Searches the EDI message on mail parts
|
||||||
|
|
||||||
$matchTypes = [TYPEAPPLICATION, TYPETEXT];
|
$matchTypes = [TYPEAPPLICATION, TYPETEXT];
|
||||||
|
@ -98,6 +98,14 @@ class Load extends Edi\Method {
|
||||||
if (!Edi\Message::isEdiString($ediString))
|
if (!Edi\Message::isEdiString($ediString))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
$db->query(
|
||||||
|
'UPDATE ekt
|
||||||
|
SET source = #source
|
||||||
|
WHERE id = #mailId', [
|
||||||
|
'source' => $ediString,
|
||||||
|
'mailId' => $mailId
|
||||||
|
]);
|
||||||
|
|
||||||
// Creates the EDI object and loads its exchanges
|
// Creates the EDI object and loads its exchanges
|
||||||
|
|
||||||
$ediMessage = new Edi\Message();
|
$ediMessage = new Edi\Message();
|
||||||
|
|
|
@ -3,6 +3,7 @@ CALL exchange_new (
|
||||||
#art,
|
#art,
|
||||||
#bgm,
|
#bgm,
|
||||||
#batchNumber,
|
#batchNumber,
|
||||||
|
#vendorOrderNumber,
|
||||||
#aaj,
|
#aaj,
|
||||||
#fec,
|
#fec,
|
||||||
#hor,
|
#hor,
|
||||||
|
|
Loading…
Reference in New Issue