@@ -8,6 +8,7 @@ use Lc\ShopBundle\Context\DocumentInterface; | |||
use Lc\ShopBundle\Context\MerchantUtilsInterface; | |||
use Lc\ShopBundle\Context\OrderUtilsInterface; | |||
use Lc\ShopBundle\Services\Utils; | |||
use Lc\ShopBundle\Services\UtilsManager; | |||
use Mailjet\MailjetSwiftMailer\SwiftMailer\MailjetTransport; | |||
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException; | |||
use Symfony\Component\Security\Core\Security; | |||
@@ -17,9 +18,9 @@ class DocumentController extends AdminController | |||
{ | |||
protected $documentRepository ; | |||
public function __construct(Security $security, UserManagerInterface $userManager, EntityManagerInterface $em, Utils $utils, MerchantUtilsInterface $merchantUtils, MailjetTransport $mailjetTransport, OrderUtilsInterface $orderUtils, TranslatorInterface $translator) | |||
public function __construct(Security $security, UserManagerInterface $userManager, EntityManagerInterface $em, MailjetTransport $mailjetTransport, UtilsManager $utilsManager, TranslatorInterface $translator) | |||
{ | |||
parent::__construct($security, $userManager, $em, $utils, $merchantUtils, $mailjetTransport, $orderUtils, $translator); | |||
parent::__construct($security, $userManager, $em, $mailjetTransport, $utilsManager, $translator); | |||
$this->documentRepository = $this->em->getRepository($this->em->getClassMetadata(DocumentInterface::class)->getName()) ; | |||
} | |||
@@ -51,6 +51,7 @@ group: | |||
orderStatus: Changer de status | |||
addRedeliveryOrderProduct: Ajouter une relivraison | |||
payment: Historique des transactions | |||
documents: Documents | |||
Ticket: | |||
listMessages: Liste des messages | |||
None: Aucune valeur | |||
@@ -368,6 +369,13 @@ field: | |||
closed: Fermée | |||
yourAnswer: Votre réponse | |||
closeTicket: Fermer la demande | |||
Document: | |||
typeOptions: | |||
invoice: Facture | |||
quotation: Devis | |||
purchase-order: Bon de commande | |||
delivery-note: Bon de livraison | |||
action: | |||
new: Créer %entity_label% |
@@ -387,7 +387,7 @@ | |||
{% macro box_documents() %} | |||
{% import '@LcShop/backend/default/block/macros.html.twig' as macros %} | |||
{{ macros.card_start("OrderShop.payment", 'primary card-outline') }} | |||
{{ macros.card_start("OrderShop.documents", 'primary card-outline') }} | |||
<table class="table table-striped"> | |||
<tbody> | |||
<thead> | |||
@@ -395,7 +395,6 @@ | |||
<th>Date</th> | |||
<th>Type</th> | |||
<th>Numéro</th> | |||
<th>Envoyé</th> | |||
<th>Actions</th> | |||
</tr> | |||
</thead> | |||
@@ -403,11 +402,10 @@ | |||
<template v-for="(orderDocument, i) in order.orderDocuments"> | |||
<tr> | |||
<td>${orderDocument.date}</td> | |||
<td>${orderDocument.type}</td> | |||
<td>Facture</td> | |||
<td>${orderDocument.reference}</td> | |||
<td>${orderDocument.isSent}</td> | |||
<td> | |||
<a :href="'./?entity=Document&action=downloadInvoice&id='+i" class="btn btn-default">Télécharger</a> | |||
</td> | |||
</tr> | |||
</template> |