Files
crm.twinpol.com/modules/EcmInvoiceOuts/bimit_sendInvoiceToAllegro.php

27 lines
640 B
PHP
Raw Normal View History

2025-05-12 15:44:39 +00:00
<?php
// https://crm.twinpol.com/index.php?module=EcmInvoiceOuts&action=bimit_sendInvoiceToAllegro&record=a1a26133-6111-ce47-7c12-660fcc41e492
$invoice = new EcmInvoiceOut();
$invoice->retrieve($_REQUEST['record']);
$sale = new EcmSale();
$sale->retrieve($invoice->so_id.'1');
if ($sale->order_source != 'allegro') {
echo "Faktura nie dotyczy zamówienia Allegro!";
return;
}
var_dump($sale->order_source);
return;
/*
getBlob() {
$EcmInvoiceOut = new EcmInvoiceOut();
$file_location = $EcmInvoiceOut->get_PDF_file_path($_REQUEST['pdf_type']);
$blob= file_get_contents($file_location);
var_dump($pdfData);
}
*/