Browse Source

[Administration] Exports : ajout colonne poids dans "Totaux produits"

feature/rotating_product
Guillaume Bourgeois 8 months ago
parent
commit
4f210f0d5b
5 changed files with 78 additions and 2161 deletions
  1. +2
    -2
      backend/controllers/DevelopmentController.php
  2. +1
    -1
      common/helpers/Souke.php
  3. +8
    -1
      domain/Distribution/Distribution/Export/DistributionReportTotalProductCsvGenerator.php
  4. +2
    -2
      domain/Producer/Producer/ProducerBuilder.php
  5. +65
    -2155
      producer/web/css/screen.css

+ 2
- 2
backend/controllers/DevelopmentController.php View File

@@ -38,7 +38,7 @@

namespace backend\controllers;

use common\helpers\Opendistrib;
use common\helpers\Souke;
use yii\filters\AccessControl;

/**
@@ -75,7 +75,7 @@ class DevelopmentController extends BackendController
public function actionIndex()
{
$producerModule = $this->getProducerModule();
$versionsArray = Opendistrib::getVersions();
$versionsArray = Souke::getVersions();
$versionsRenderArray = [];
foreach ($versionsArray as $version) {
$versionsRenderArray[$version] = [

common/helpers/Opendistrib.php → common/helpers/Souke.php View File

@@ -38,7 +38,7 @@

namespace common\helpers;

class Opendistrib
class Souke
{
public static function getVersions()
{

+ 8
- 1
domain/Distribution/Distribution/Export/DistributionReportTotalProductCsvGenerator.php View File

@@ -31,10 +31,17 @@ class DistributionReportTotalProductCsvGenerator extends AbstractGenerator imple
$productsArray = $this->productRepository->findProductsByDistribution($distribution, true,'product.order ASC');
$ordersArray = $this->orderRepository->findOrdersByDistribution($distribution);

$datas[] = [
'Produit',
'Quantité (pièces)',
'Poids'
];

foreach($productsArray as $product) {
$datas[] = [
$this->productSolver->getNameExport($product),
$this->orderSolver->getProductQuantityPiecesByOrders($product, $ordersArray)
$this->orderSolver->getProductQuantityPiecesByOrders($product, $ordersArray),
$this->productSolver->getWeightAsString($product)
];
}


+ 2
- 2
domain/Producer/Producer/ProducerBuilder.php View File

@@ -2,7 +2,7 @@

namespace domain\Producer\Producer;

use common\helpers\Opendistrib;
use common\helpers\Souke;
use common\helpers\Password;
use common\helpers\Upload;
use common\helpers\Url;
@@ -78,7 +78,7 @@ class ProducerBuilder extends AbstractBuilder

public function updateOpendistribVersion(Producer $producer): void
{
$versionsArray = Opendistrib::getVersions();
$versionsArray = Souke::getVersions();
$producer->latest_version_opendistrib = reset($versionsArray);

$this->update($producer);

+ 65
- 2155
producer/web/css/screen.css
File diff suppressed because it is too large
View File


Loading…
Cancel
Save