last changes since 6-2023

This commit is contained in:
Kevin Adametz 2023-07-03 10:07:08 +02:00
parent 0341c9c189
commit 04d677d37a
142 changed files with 7895 additions and 2855 deletions

View file

@ -16,7 +16,7 @@ use App\Services\BusinessPlan\SalesPointsVolume;
class Correction
{
private static function userSalesVolume($order){
private static function calcuUserSalesVolume($order){
/*
status
1 => 'hinzugefügt aus Bestellung',
@ -78,9 +78,9 @@ class Correction
$c = 0;
if(true){ //11
if(false){ //11
dump("calculate user_sales_volumes from Orders");
//dd('check function');
dd('check function');
$year = 21;
$months = range(1, 12);
foreach($months as $month){
@ -89,7 +89,7 @@ class Correction
if(UserSalesVolume::whereShoppingOrderId($item->id)->count() === 0){
dump($item->id);
self::userSalesVolume($item);
self::calcuUserSalesVolume($item);
}
$c ++;
}
@ -141,7 +141,7 @@ class Correction
}
if(false){ //9
dump("make homeparty tax_split in shopping_order");
dump("make getOrderPaymentFor in shopping_order");
dd('check function');
$ShoppingOrders = ShoppingOrder::where('payment_for', '=', NULL)->get();
@ -160,6 +160,7 @@ class Correction
if(false){ //8
dump("make homeparty tax_split in shopping_order");
dd('check function');
$ShoppingOrders = ShoppingOrder::where('homeparty_id', '!=', NULL)->get();
//->skip(0)->take(500)->get();
//->skip(500)->take(500)->get();
@ -198,9 +199,10 @@ class Correction
if(false){ //6
dump("make tax_split in shopping_order");
dd('check function');
$ShoppingOrders = ShoppingOrder::where('homeparty_id', '=', NULL)->get();
//->skip(0)->take(500)->get();
//->skip(500)->take(500)->get();
$ShoppingOrders = ShoppingOrder::where('homeparty_id', '=', NULL)//->get();
->skip(0)->take(3000)->get();
//->skip(3000)->take(5000)->get();
foreach($ShoppingOrders as $ShoppingOrder){
$ShoppingOrder->makeTaxSplit();
$c ++;