@@ -10,6 +10,7 @@ use FOS\UserBundle\Model\UserManagerInterface; | |||
use Lc\ShopBundle\Context\FilterMultipleMerchantsInterface; | |||
use Lc\ShopBundle\Context\MerchantInterface; | |||
use Lc\ShopBundle\Context\MerchantUtilsInterface; | |||
use Lc\ShopBundle\Context\OrderUtilsInterface; | |||
use Lc\ShopBundle\Context\StatusInterface; | |||
use Lc\ShopBundle\Context\TreeInterface; | |||
use Lc\ShopBundle\Form\AbstractEditPositionType; | |||
@@ -30,9 +31,10 @@ class AdminController extends EasyAdminController | |||
protected $utils; | |||
protected $merchantUtils ; | |||
protected $mailjetTransport ; | |||
protected $orderUtils ; | |||
public function __construct(Security $security, UserManagerInterface $userManager, EntityManagerInterface $em, Utils $utils, | |||
MerchantUtilsInterface $merchantUtils, MailjetTransport $mailjetTransport) | |||
MerchantUtilsInterface $merchantUtils, MailjetTransport $mailjetTransport, OrderUtilsInterface $orderUtils) | |||
{ | |||
$this->security = $security; | |||
$this->userManager = $userManager; | |||
@@ -40,6 +42,7 @@ class AdminController extends EasyAdminController | |||
$this->utils = $utils; | |||
$this->merchantUtils = $merchantUtils ; | |||
$this->mailjetTransport = $mailjetTransport ; | |||
$this->orderUtils = $orderUtils ; | |||
} | |||
/** |
@@ -11,7 +11,7 @@ use Lc\ShopBundle\Context\FilterMerchantInterface; | |||
/** | |||
* @ORM\MappedSuperclass() | |||
*/ | |||
abstract class OrderShop implements FilterMerchantInterface | |||
abstract class OrderShop extends AbstractEntity implements FilterMerchantInterface | |||
{ | |||
/** |
@@ -36,4 +36,16 @@ class OrderShopRepository extends BaseRepository implements DefaultRepositoryInt | |||
return $query->getQuery()->getOneOrNullResult() ; | |||
} | |||
public function findAllByDateStartEnd($dateStart, $dateEnd) | |||
{ | |||
$query = $this->findByMerchantQuery() | |||
->andWhere('e.createdAt >= :dateStart') | |||
->setParameter('dateStart', $dateStart) | |||
->andWhere('e.createdAt <= :dateEnd') | |||
->setParameter('dateEnd', $dateEnd) | |||
; | |||
return $query->getQuery()->getResult() ; | |||
} | |||
} |
@@ -31,9 +31,10 @@ | |||
{% endblock %} | |||
{% block head_custom_stylesheets %} | |||
<link rel="stylesheet" href="{{ asset('bundles/lcshop/css/backend/custom.css') }}"> | |||
{% for asset_css in easyadmin_config('design.assets.css') %} | |||
<link rel="stylesheet" href="{{ asset(asset_css) }}"> | |||
{% endfor %} | |||
{% endblock head_custom_stylesheets %} | |||
{# | |||
@@ -48,7 +49,6 @@ | |||
{% set favicon = easyadmin_config('design.assets.favicon') %} | |||
<link rel="icon" type="{{ favicon.mime_type }}" href="{{ asset(favicon.path) }}"/> | |||
{% endblock %} | |||
</head> | |||
{% block body %} |
@@ -16,7 +16,7 @@ class OrderUtils | |||
protected $security; | |||
protected $userUtils; | |||
protected $merchantUtils; | |||
private $orderShopRepo; | |||
protected $orderShopRepo; | |||
protected $priceUtils ; | |||
protected $productFamilyUtils ; | |||