fatturati
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
use App\ArticoliFatturati;
|
||||||
use Carbon\Carbon;
|
use Carbon\Carbon;
|
||||||
use Codexshaper\WooCommerce\Facades\Product;
|
use Codexshaper\WooCommerce\Facades\Product;
|
||||||
use Illuminate\Console\Command;
|
use Illuminate\Console\Command;
|
||||||
@@ -36,12 +37,14 @@ setlocale(LC_TIME, 'it_IT.UTF-8');
|
|||||||
function showarray($array)
|
function showarray($array)
|
||||||
{
|
{
|
||||||
echo '<pre>' . json_encode($array, JSON_PRETTY_PRINT) . '</pre>';
|
echo '<pre>' . json_encode($array, JSON_PRETTY_PRINT) . '</pre>';
|
||||||
};
|
}
|
||||||
|
;
|
||||||
|
|
||||||
function getarraystr($array)
|
function getarraystr($array)
|
||||||
{
|
{
|
||||||
return '<pre>' . json_encode($array, JSON_PRETTY_PRINT) . '</pre>';
|
return '<pre>' . json_encode($array, JSON_PRETTY_PRINT) . '</pre>';
|
||||||
};
|
}
|
||||||
|
;
|
||||||
|
|
||||||
function isKeyPresent($array, $key)
|
function isKeyPresent($array, $key)
|
||||||
{
|
{
|
||||||
@@ -690,6 +693,9 @@ function showArticoliFatturatiWeb()
|
|||||||
|
|
||||||
// Show the fields of the orders
|
// Show the fields of the orders
|
||||||
foreach ($orders as $order) {
|
foreach ($orders as $order) {
|
||||||
|
$usaprod = true;
|
||||||
|
|
||||||
|
if ($usaprod) {
|
||||||
$product = Product::where('sku', $order->CodArticolo)->first();
|
$product = Product::where('sku', $order->CodArticolo)->first();
|
||||||
|
|
||||||
if (isset($product['permalink'])) {
|
if (isset($product['permalink'])) {
|
||||||
@@ -704,6 +710,9 @@ function showArticoliFatturatiWeb()
|
|||||||
$titolo = $mylink . "<span style='font-weigth: bold;'>" . $product['name'] . "</span>" . $finelink;
|
$titolo = $mylink . "<span style='font-weigth: bold;'>" . $product['name'] . "</span>" . $finelink;
|
||||||
else
|
else
|
||||||
$titolo = "";
|
$titolo = "";
|
||||||
|
} else {
|
||||||
|
$titolo = "";
|
||||||
|
}
|
||||||
|
|
||||||
$str .= getvalstr("", $order->Codice) . " ";
|
$str .= getvalstr("", $order->Codice) . " ";
|
||||||
$str .= getvalstr("", $order->AnnoDoc) . " ";
|
$str .= getvalstr("", $order->AnnoDoc) . " ";
|
||||||
@@ -714,7 +723,7 @@ function showArticoliFatturatiWeb()
|
|||||||
$str .= getvalstr("", $order->DataOra);
|
$str .= getvalstr("", $order->DataOra);
|
||||||
$str .= getvalstr("", $order->Stato);
|
$str .= getvalstr("", $order->Stato);
|
||||||
$str .= getvalstr("", $order->Note);
|
$str .= getvalstr("", $order->Note);
|
||||||
$str .= getvalstr("", $titolo);
|
//$str .= getvalstr("", $titolo);
|
||||||
$str .= getvalstr("Ordine", $order->IdInternet, true) . " ";
|
$str .= getvalstr("Ordine", $order->IdInternet, true) . " ";
|
||||||
if ($order->PercSconto)
|
if ($order->PercSconto)
|
||||||
$str .= getvalstr("Sconto", $order->PercSconto);
|
$str .= getvalstr("Sconto", $order->PercSconto);
|
||||||
|
|||||||
Reference in New Issue
Block a user