update changelog and fix cs

This commit is contained in:
Manuel Raynaud
2014-02-22 19:01:37 +01:00
parent b833b4a5b6
commit a5cfcf91ca
590 changed files with 21397 additions and 24262 deletions

View File

@@ -2,6 +2,13 @@
- Remove container from BaseAction. - Remove container from BaseAction.
- fix sending mail on order creation - fix sending mail on order creation
- less files in default templates are already compile in css. - less files in default templates are already compile in css.
- all validator message are translated
- type argument is now a default argument and used for generating loop cache
- fix total amount without discount in backoffice. Fix #235
- description is not required anymore in coupon form. Fix #233
- Do not allow to cumulate the same coupon many times. Fix #217
- colissimo module is now fully configurable
- test suite are executed on PHP 5.4, 5.5, 5.6 and HHVM. Thelia is not fully compatible with HHVM
#2.0.0-beta4 #2.0.0-beta4
- Tinymce is now a dedicated module. You need to activate it. - Tinymce is now a dedicated module. You need to activate it.

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Action; namespace Thelia\Action;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Propel\Runtime\ActiveQuery\ModelCriteria; use Propel\Runtime\ActiveQuery\ModelCriteria;
use Thelia\Core\Event\UpdatePositionEvent; use Thelia\Core\Event\UpdatePositionEvent;
@@ -64,7 +63,7 @@ class BaseAction
* @param ModelCriteria $query * @param ModelCriteria $query
* @param UpdateSeoEvent $event * @param UpdateSeoEvent $event
* *
* @return mixed an SEOxxx object * @return mixed an SEOxxx object
* @throws FormValidationException if a rewritten URL cannot be created * @throws FormValidationException if a rewritten URL cannot be created
*/ */
protected function genericUpdateSeo(ModelCriteria $query, UpdateSeoEvent $event) protected function genericUpdateSeo(ModelCriteria $query, UpdateSeoEvent $event)
@@ -94,4 +93,4 @@ class BaseAction
return $object; return $object;
} }
} }

View File

@@ -23,7 +23,6 @@
namespace Thelia\Action; namespace Thelia\Action;
use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Thelia\Core\Event\Cart\CartEvent; use Thelia\Core\Event\Cart\CartEvent;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Action; namespace Thelia\Action;
use Propel\Runtime\ServiceContainer\ServiceContainerInterface;
use Symfony\Component\DependencyInjection\Container;
use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Thelia\Condition\ConditionFactory; use Thelia\Condition\ConditionFactory;
use Thelia\Condition\Implementation\ConditionInterface; use Thelia\Condition\Implementation\ConditionInterface;

View File

@@ -155,11 +155,11 @@ class Module extends BaseAction implements EventSubscriberInterface
/** /**
* Call the payment method of the payment module of the given order * Call the payment method of the payment module of the given order
* *
* @param OrderPaymentEvent $event * @param OrderPaymentEvent $event
* @throws \RuntimeException if no payment module can be found. * @throws \RuntimeException if no payment module can be found.
*/ */
public function pay(OrderPaymentEvent $event) { public function pay(OrderPaymentEvent $event)
{
$order = $event->getOrder(); $order = $event->getOrder();
/* call pay method */ /* call pay method */

View File

@@ -26,7 +26,6 @@ namespace Thelia\Action;
use Symfony\Component\EventDispatcher\EventDispatcherInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use Symfony\Component\EventDispatcher\EventSubscriberInterface; use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Thelia\Cart\CartTrait; use Thelia\Cart\CartTrait;
use Thelia\Core\Event\Cart\CartEvent;
use Thelia\Core\Event\Order\OrderAddressEvent; use Thelia\Core\Event\Order\OrderAddressEvent;
use Thelia\Core\Event\Order\OrderEvent; use Thelia\Core\Event\Order\OrderEvent;
use Thelia\Core\Event\Order\OrderManualEvent; use Thelia\Core\Event\Order\OrderManualEvent;
@@ -53,7 +52,6 @@ use Thelia\Model\OrderStatus;
use Thelia\Model\OrderStatusQuery; use Thelia\Model\OrderStatusQuery;
use Thelia\Tools\I18n; use Thelia\Tools\I18n;
/** /**
* *
* Class Order * Class Order
@@ -157,7 +155,6 @@ class Order extends BaseAction implements EventSubscriberInterface
$con->beginTransaction(); $con->beginTransaction();
$placedOrder = $sessionOrder->copy(); $placedOrder = $sessionOrder->copy();
$placedOrder->setDispatcher($dispatcher); $placedOrder->setDispatcher($dispatcher);
@@ -307,8 +304,8 @@ class Order extends BaseAction implements EventSubscriberInterface
/** /**
* Create an order outside of the front-office context, e.g. manually from the back-office. * Create an order outside of the front-office context, e.g. manually from the back-office.
*/ */
public function createManual(OrderManualEvent $event) { public function createManual(OrderManualEvent $event)
{
$placedOrder = $this->createOrder( $placedOrder = $this->createOrder(
$event->getDispatcher(), $event->getDispatcher(),
$event->getOrder(), $event->getOrder(),
@@ -339,7 +336,6 @@ class Order extends BaseAction implements EventSubscriberInterface
$event->getDispatcher()->dispatch(TheliaEvents::ORDER_BEFORE_PAYMENT, new OrderEvent($placedOrder)); $event->getDispatcher()->dispatch(TheliaEvents::ORDER_BEFORE_PAYMENT, new OrderEvent($placedOrder));
/* but memorize placed order */ /* but memorize placed order */
$event->setOrder(new \Thelia\Model\Order()); $event->setOrder(new \Thelia\Model\Order());
$event->setPlacedOrder($placedOrder); $event->setPlacedOrder($placedOrder);

View File

@@ -45,7 +45,7 @@ trait CartTrait
* *
* search if cart already exists in session. If not try to create a new one or duplicate an old one. * search if cart already exists in session. If not try to create a new one or duplicate an old one.
* *
* @param EventDispatcherInterface $dispatcher the event dispatcher * @param EventDispatcherInterface $dispatcher the event dispatcher
* @param \Symfony\Component\HttpFoundation\Request $request * @param \Symfony\Component\HttpFoundation\Request $request
* @return \Thelia\Model\Cart * @return \Thelia\Model\Cart
*/ */

View File

@@ -29,7 +29,6 @@ use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Filesystem\Exception\IOException; use Symfony\Component\Filesystem\Exception\IOException;
use Thelia\Core\Event\Cache\CacheEvent; use Thelia\Core\Event\Cache\CacheEvent;
use Thelia\Core\Event\TheliaEvents; use Thelia\Core\Event\TheliaEvents;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Command; namespace Thelia\Command;
use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Output\OutputInterface;
use Thelia\Core\Event\Image\ImageEvent; use Thelia\Core\Event\Image\ImageEvent;

View File

@@ -27,7 +27,6 @@ use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Output\OutputInterface;
use Thelia\Model\Admin; use Thelia\Model\Admin;
class CreateAdminUser extends ContainerAwareCommand class CreateAdminUser extends ContainerAwareCommand

View File

@@ -27,7 +27,6 @@ use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Output\OutputInterface;
use Thelia\Core\Security\Resource\AdminResources; use Thelia\Core\Security\Resource\AdminResources;
use Thelia\Model\Map\ResourceI18nTableMap; use Thelia\Model\Map\ResourceI18nTableMap;

View File

@@ -248,8 +248,8 @@ class BaseAdminController extends BaseController
* @throws MissingMandatoryParametersException When some parameters are missing that are mandatory for the route * @throws MissingMandatoryParametersException When some parameters are missing that are mandatory for the route
* @throws InvalidParameterException When a parameter value for a placeholder is not correct because * @throws InvalidParameterException When a parameter value for a placeholder is not correct because
* it does not match the requirement * it does not match the requirement
* @throws \InvalidArgumentException When the router doesn't exist * @throws \InvalidArgumentException When the router doesn't exist
* @return string The generated URL * @return string The generated URL
* *
* @see \Thelia\Controller\BaseController::getRouteFromRouter() * @see \Thelia\Controller\BaseController::getRouteFromRouter()
*/ */

View File

@@ -23,7 +23,6 @@
namespace Thelia\Controller\Admin; namespace Thelia\Controller\Admin;
use Thelia\Core\Security\Resource\AdminResources; use Thelia\Core\Security\Resource\AdminResources;
use Thelia\Core\Event\Category\CategoryDeleteEvent; use Thelia\Core\Event\Category\CategoryDeleteEvent;
use Thelia\Core\Event\TheliaEvents; use Thelia\Core\Event\TheliaEvents;

View File

@@ -98,7 +98,6 @@ class CouponController extends BaseAdminController
{ {
$this->checkAuth(AdminResources::COUPON, array(), AccessManager::VIEW); $this->checkAuth(AdminResources::COUPON, array(), AccessManager::VIEW);
$coupon = CouponQuery::create()->findPk($couponId); $coupon = CouponQuery::create()->findPk($couponId);
if ($coupon === null) { if ($coupon === null) {

View File

@@ -32,7 +32,6 @@ use Thelia\Form\CustomerCreateForm;
use Thelia\Form\CustomerUpdateForm; use Thelia\Form\CustomerUpdateForm;
use Thelia\Model\CustomerQuery; use Thelia\Model\CustomerQuery;
/** /**
* Class CustomerController * Class CustomerController
* @package Thelia\Controller\Admin * @package Thelia\Controller\Admin

View File

@@ -841,8 +841,6 @@ class FileController extends BaseAdminController
$model->setPostscriptum($data['postscriptum']); $model->setPostscriptum($data['postscriptum']);
} }
$imageCreateEvent->setModelImage($model); $imageCreateEvent->setModelImage($model);
return $imageCreateEvent; return $imageCreateEvent;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Controller\Admin; namespace Thelia\Controller\Admin;
use Thelia\Core\Security\Resource\AdminResources; use Thelia\Core\Security\Resource\AdminResources;
use Thelia\Core\Event\Order\OrderAddressEvent; use Thelia\Core\Event\Order\OrderAddressEvent;
use Thelia\Core\Event\Order\OrderEvent; use Thelia\Core\Event\Order\OrderEvent;
@@ -46,7 +45,6 @@ class OrderController extends BaseAdminController
public function indexAction() public function indexAction()
{ {
if (null !== $response = $this->checkAuth(AdminResources::ORDER, array(), AccessManager::VIEW)) return $response; if (null !== $response = $this->checkAuth(AdminResources::ORDER, array(), AccessManager::VIEW)) return $response;
return $this->render("orders", array( return $this->render("orders", array(
"display_order" => 20, "display_order" => 20,
"orders_order" => $this->getListOrderFromSession("orders", "orders_order", "create-date-reverse") "orders_order" => $this->getListOrderFromSession("orders", "orders_order", "create-date-reverse")

View File

@@ -32,7 +32,6 @@ use Thelia\Core\Security\Exception\AuthenticationException;
use Thelia\Model\Lang; use Thelia\Model\Lang;
use Thelia\Model\LangQuery; use Thelia\Model\LangQuery;
use Thelia\Core\Event\TheliaEvents; use Thelia\Core\Event\TheliaEvents;
use Thelia\Core\Security\Authentication\AdminTokenAuthenticator; use Thelia\Core\Security\Authentication\AdminTokenAuthenticator;
@@ -75,8 +74,8 @@ class SessionController extends BaseAdminController
return $this->render("login"); return $this->render("login");
} }
protected function applyUserLocale(Admin $user) { protected function applyUserLocale(Admin $user)
{
// Set the current language according to Admin locale preference // Set the current language according to Admin locale preference
$locale = $user->getLocale(); $locale = $user->getLocale();

View File

@@ -51,8 +51,8 @@ class TaxRuleController extends AbstractCrudController
); );
} }
public function defaultAction() { public function defaultAction()
{
// In the tax rule template we use the TaxCreationForm. // In the tax rule template we use the TaxCreationForm.
// //
// The TaxCreationForm require the TaxEngine, but we cannot pass it from the Parser Form plugin, // The TaxCreationForm require the TaxEngine, but we cannot pass it from the Parser Form plugin,

View File

@@ -293,8 +293,8 @@ abstract class BaseController extends ContainerAware
* @throws MissingMandatoryParametersException When some parameters are missing that are mandatory for the route * @throws MissingMandatoryParametersException When some parameters are missing that are mandatory for the route
* @throws InvalidParameterException When a parameter value for a placeholder is not correct because * @throws InvalidParameterException When a parameter value for a placeholder is not correct because
* it does not match the requirement * it does not match the requirement
* @throws \InvalidArgumentException When the router doesn't exist * @throws \InvalidArgumentException When the router doesn't exist
* @return string The generated URL * @return string The generated URL
*/ */
protected function getRouteFromRouter($routerName, $routeId, $parameters = array(), $referenceType = Router::ABSOLUTE_URL) protected function getRouteFromRouter($routerName, $routeId, $parameters = array(), $referenceType = Router::ABSOLUTE_URL)
{ {

View File

@@ -24,7 +24,6 @@
namespace Thelia\Core\Event; namespace Thelia\Core\Event;
use Thelia\Model\Accessory; use Thelia\Model\Accessory;
use Thelia\Core\Event\ActionEvent;
class AccessoryEvent extends ActionEvent class AccessoryEvent extends ActionEvent
{ {

View File

@@ -134,6 +134,7 @@ class AdministratorEvent extends ActionEvent
public function setLocale($locale) public function setLocale($locale)
{ {
$this->locale = $locale; $this->locale = $locale;
return $this; return $this;
} }
@@ -141,4 +142,4 @@ class AdministratorEvent extends ActionEvent
{ {
return $this->locale; return $this->locale;
} }
} }

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeAvEvent;
class AttributeAvCreateEvent extends AttributeAvEvent class AttributeAvCreateEvent extends AttributeAvEvent
{ {
protected $title; protected $title;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeAvEvent;
class AttributeAvDeleteEvent extends AttributeAvEvent class AttributeAvDeleteEvent extends AttributeAvEvent
{ {
protected $attributeAv_id; protected $attributeAv_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeAvCreateEvent;
class AttributeAvUpdateEvent extends AttributeAvCreateEvent class AttributeAvUpdateEvent extends AttributeAvCreateEvent
{ {
protected $attributeAv_id; protected $attributeAv_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeEvent;
class AttributeCreateEvent extends AttributeEvent class AttributeCreateEvent extends AttributeEvent
{ {
protected $title; protected $title;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeEvent;
class AttributeDeleteEvent extends AttributeEvent class AttributeDeleteEvent extends AttributeEvent
{ {
protected $attribute_id; protected $attribute_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Attribute; namespace Thelia\Core\Event\Attribute;
use Thelia\Core\Event\Attribute\AttributeCreateEvent;
class AttributeUpdateEvent extends AttributeCreateEvent class AttributeUpdateEvent extends AttributeCreateEvent
{ {
protected $attribute_id; protected $attribute_id;

View File

@@ -48,6 +48,7 @@ class CartEvent extends ActionEvent
public function setAppend($append) public function setAppend($append)
{ {
$this->append = $append; $this->append = $append;
return $this; return $this;
} }
@@ -65,6 +66,7 @@ class CartEvent extends ActionEvent
public function setCartItem($cartItem) public function setCartItem($cartItem)
{ {
$this->cartItem = $cartItem; $this->cartItem = $cartItem;
return $this; return $this;
} }
@@ -82,6 +84,7 @@ class CartEvent extends ActionEvent
public function setNewness($newness) public function setNewness($newness)
{ {
$this->newness = $newness; $this->newness = $newness;
return $this; return $this;
} }
@@ -99,6 +102,7 @@ class CartEvent extends ActionEvent
public function setProduct($product) public function setProduct($product)
{ {
$this->product = $product; $this->product = $product;
return $this; return $this;
} }
@@ -116,6 +120,7 @@ class CartEvent extends ActionEvent
public function setProductSaleElementsId($productSaleElementsId) public function setProductSaleElementsId($productSaleElementsId)
{ {
$this->productSaleElementsId = $productSaleElementsId; $this->productSaleElementsId = $productSaleElementsId;
return $this; return $this;
} }
@@ -133,6 +138,7 @@ class CartEvent extends ActionEvent
public function setQuantity($quantity) public function setQuantity($quantity)
{ {
$this->quantity = $quantity; $this->quantity = $quantity;
return $this; return $this;
} }
@@ -151,4 +157,4 @@ class CartEvent extends ActionEvent
{ {
return $this->cart; return $this->cart;
} }
} }

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryEvent;
use Thelia\Model\Category; use Thelia\Model\Category;
class CategoryAddContentEvent extends CategoryEvent class CategoryAddContentEvent extends CategoryEvent

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryEvent;
class CategoryCreateEvent extends CategoryEvent class CategoryCreateEvent extends CategoryEvent
{ {
protected $title; protected $title;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryEvent;
use Thelia\Model\Category; use Thelia\Model\Category;
class CategoryDeleteContentEvent extends CategoryEvent class CategoryDeleteContentEvent extends CategoryEvent

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryEvent;
class CategoryDeleteEvent extends CategoryEvent class CategoryDeleteEvent extends CategoryEvent
{ {
public function __construct($category_id) public function __construct($category_id)

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryEvent;
class CategoryToggleVisibilityEvent extends CategoryEvent class CategoryToggleVisibilityEvent extends CategoryEvent
{ {
} }

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Category; namespace Thelia\Core\Event\Category;
use Thelia\Core\Event\Category\CategoryCreateEvent;
class CategoryUpdateEvent extends CategoryCreateEvent class CategoryUpdateEvent extends CategoryCreateEvent
{ {
protected $category_id; protected $category_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Config; namespace Thelia\Core\Event\Config;
use Thelia\Core\Event\Config\ConfigEvent;
class ConfigCreateEvent extends ConfigEvent class ConfigCreateEvent extends ConfigEvent
{ {
protected $event_name; protected $event_name;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Config; namespace Thelia\Core\Event\Config;
use Thelia\Core\Event\Config\ConfigEvent;
class ConfigDeleteEvent extends ConfigEvent class ConfigDeleteEvent extends ConfigEvent
{ {
protected $config_id; protected $config_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Config; namespace Thelia\Core\Event\Config;
use Thelia\Core\Event\Config\ConfigCreateEvent;
class ConfigUpdateEvent extends ConfigCreateEvent class ConfigUpdateEvent extends ConfigCreateEvent
{ {
protected $config_id; protected $config_id;

View File

@@ -87,10 +87,10 @@ class CouponCreateOrUpdateEvent extends ActionEvent
/** /**
* Constructor * Constructor
* *
* @param string $code Coupon Code * @param string $code Coupon Code
* @param string $serviceId Coupon Service id * @param string $serviceId Coupon Service id
* @param string $title Coupon title * @param string $title Coupon title
* @param array $effects Coupon effects ready to be serialized * @param array $effects Coupon effects ready to be serialized
* 'amount' key is mandatory and reflects * 'amount' key is mandatory and reflects
* the amount deduced from the cart * the amount deduced from the cart
* @param string $shortDescription Coupon short description * @param string $shortDescription Coupon short description
@@ -256,9 +256,9 @@ class CouponCreateOrUpdateEvent extends ActionEvent
/** /**
* Set effects ready to be serialized * Set effects ready to be serialized
* *
* @param array $effects Effect ready to be serialized * @param array $effects Effect ready to be serialized
* Needs at least the key 'amount' * Needs at least the key 'amount'
* with the amount removed from the cart * with the amount removed from the cart
* @throws \Thelia\Model\Exception\InvalidArgumentException * @throws \Thelia\Model\Exception\InvalidArgumentException
*/ */
public function setEffects(array $effects) public function setEffects(array $effects)

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Currency; namespace Thelia\Core\Event\Currency;
use Thelia\Core\Event\Currency\CurrencyEvent;
class CurrencyCreateEvent extends CurrencyEvent class CurrencyCreateEvent extends CurrencyEvent
{ {
protected $currency_name; protected $currency_name;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Currency; namespace Thelia\Core\Event\Currency;
use Thelia\Core\Event\Currency\CurrencyEvent;
class CurrencyDeleteEvent extends CurrencyEvent class CurrencyDeleteEvent extends CurrencyEvent
{ {
protected $currency_id; protected $currency_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Currency; namespace Thelia\Core\Event\Currency;
use Thelia\Core\Event\Currency\CurrencyCreateEvent;
class CurrencyUpdateEvent extends CurrencyCreateEvent class CurrencyUpdateEvent extends CurrencyCreateEvent
{ {
protected $currency_id; protected $currency_id;

View File

@@ -68,8 +68,8 @@ class CustomerCreateOrUpdateEvent extends CustomerEvent
* @param string $email * @param string $email
* @param string $password plain password, don't put hash password, it will hashes again * @param string $password plain password, don't put hash password, it will hashes again
* @param $lang * @param $lang
* @param int $reseller if customer is a reseller * @param int $reseller if customer is a reseller
* @param int $sponsor customer's id sponsor * @param int $sponsor customer's id sponsor
* @param float $discount * @param float $discount
* @param string $company * @param string $company
* @param string $ref * @param string $ref

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event; namespace Thelia\Core\Event;
use Thelia\Core\Event\ActionEvent;
class DefaultActionEvent extends ActionEvent class DefaultActionEvent extends ActionEvent
{ {
} }

View File

@@ -66,7 +66,7 @@ class DocumentCreateOrUpdateEvent extends ActionEvent
* *
* @param string $documentType Document type * @param string $documentType Document type
* ex : FileManager::TYPE_CATEGORY * ex : FileManager::TYPE_CATEGORY
* @param int $parentId Document parent id * @param int $parentId Document parent id
*/ */
public function __construct($documentType, $parentId) public function __construct($documentType, $parentId)
{ {

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureAvEvent;
class FeatureAvCreateEvent extends FeatureAvEvent class FeatureAvCreateEvent extends FeatureAvEvent
{ {
protected $title; protected $title;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureAvEvent;
class FeatureAvDeleteEvent extends FeatureAvEvent class FeatureAvDeleteEvent extends FeatureAvEvent
{ {
protected $featureAv_id; protected $featureAv_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureAvCreateEvent;
class FeatureAvUpdateEvent extends FeatureAvCreateEvent class FeatureAvUpdateEvent extends FeatureAvCreateEvent
{ {
protected $featureAv_id; protected $featureAv_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureEvent;
class FeatureCreateEvent extends FeatureEvent class FeatureCreateEvent extends FeatureEvent
{ {
protected $title; protected $title;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureEvent;
class FeatureDeleteEvent extends FeatureEvent class FeatureDeleteEvent extends FeatureEvent
{ {
protected $feature_id; protected $feature_id;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Feature; namespace Thelia\Core\Event\Feature;
use Thelia\Core\Event\Feature\FeatureCreateEvent;
class FeatureUpdateEvent extends FeatureCreateEvent class FeatureUpdateEvent extends FeatureCreateEvent
{ {
protected $feature_id; protected $feature_id;

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\FeatureProduct; namespace Thelia\Core\Event\FeatureProduct;
use Thelia\Core\Event\FeatureProduct\FeatureProductEvent;
use Thelia\Model\FeatureProduct; use Thelia\Model\FeatureProduct;
class FeatureProductDeleteEvent extends FeatureProductEvent class FeatureProductDeleteEvent extends FeatureProductEvent

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\FeatureProduct; namespace Thelia\Core\Event\FeatureProduct;
use Thelia\Core\Event\FeatureProduct\FeatureProductEvent;
use Thelia\Model\FeatureProduct; use Thelia\Model\FeatureProduct;
class FeatureProductUpdateEvent extends FeatureProductEvent class FeatureProductUpdateEvent extends FeatureProductEvent

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\Folder; namespace Thelia\Core\Event\Folder;
use Thelia\Core\Event\Folder\FolderEvent;
/** /**
* Class FolderCreateEvent * Class FolderCreateEvent

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\Folder; namespace Thelia\Core\Event\Folder;
use Thelia\Core\Event\Folder\FolderEvent;
/** /**
* Class FolderDeleteEvent * Class FolderDeleteEvent

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\Folder; namespace Thelia\Core\Event\Folder;
use Thelia\Core\Event\Folder\FolderEvent;
/** /**
* Class FolderToggleVisibilityEvent * Class FolderToggleVisibilityEvent

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\Folder; namespace Thelia\Core\Event\Folder;
use Thelia\Core\Event\Folder\FolderCreateEvent;
/** /**
* Class FolderUpdateEvent * Class FolderUpdateEvent

View File

@@ -63,8 +63,8 @@ class ImageCreateOrUpdateEvent extends ActionEvent
* Constructor * Constructor
* *
* @param string $imageType Image type * @param string $imageType Image type
* ex : FileManager::TYPE_CATEGORY * ex : FileManager::TYPE_CATEGORY
* @param int $parentId Image parent id * @param int $parentId Image parent id
*/ */
public function __construct($imageType, $parentId) public function __construct($imageType, $parentId)
{ {
@@ -90,8 +90,6 @@ class ImageCreateOrUpdateEvent extends ActionEvent
return $this->locale; return $this->locale;
} }
/** /**
* Set Image to save * Set Image to save
* *

View File

@@ -53,7 +53,7 @@ class ImageDeleteEvent extends ActionEvent
* *
* @param CategoryImage|ProductImage|ContentImage|FolderImage $imageToDelete Image about to be deleted * @param CategoryImage|ProductImage|ContentImage|FolderImage $imageToDelete Image about to be deleted
* @param string $imageType Image type * @param string $imageType Image type
* ex : FileManager::TYPE_CATEGORY * ex : FileManager::TYPE_CATEGORY
*/ */
public function __construct($imageToDelete, $imageType) public function __construct($imageToDelete, $imageType)
{ {

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Message; namespace Thelia\Core\Event\Message;
use Thelia\Core\Event\Message\MessageEvent;
class MessageCreateEvent extends MessageEvent class MessageCreateEvent extends MessageEvent
{ {
protected $message_name; protected $message_name;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Message; namespace Thelia\Core\Event\Message;
use Thelia\Core\Event\Message\MessageEvent;
class MessageDeleteEvent extends MessageEvent class MessageDeleteEvent extends MessageEvent
{ {
protected $message_id; protected $message_id;

View File

@@ -22,7 +22,6 @@
/*************************************************************************************/ /*************************************************************************************/
namespace Thelia\Core\Event\Message; namespace Thelia\Core\Event\Message;
use Thelia\Core\Event\Message\MessageCreateEvent;
class MessageUpdateEvent extends MessageCreateEvent class MessageUpdateEvent extends MessageCreateEvent
{ {

View File

@@ -214,7 +214,7 @@ class OrderEvent extends ActionEvent
} }
/** /**
* @param Response $response * @param Response $response
* @return $this * @return $this
*/ */
public function setResponse(Response $response) public function setResponse(Response $response)

View File

@@ -56,6 +56,7 @@ class OrderManualEvent extends OrderEvent
public function setOrder(Order $order) public function setOrder(Order $order)
{ {
$this->order = $order; $this->order = $order;
return $this; return $this;
} }
@@ -65,6 +66,7 @@ class OrderManualEvent extends OrderEvent
public function setPlacedOrder(Order $order) public function setPlacedOrder(Order $order)
{ {
$this->placedOrder = $order; $this->placedOrder = $order;
return $this; return $this;
} }
@@ -74,6 +76,7 @@ class OrderManualEvent extends OrderEvent
public function setInvoiceAddress($address) public function setInvoiceAddress($address)
{ {
$this->invoiceAddress = $address; $this->invoiceAddress = $address;
return $this; return $this;
} }
@@ -83,6 +86,7 @@ class OrderManualEvent extends OrderEvent
public function setDeliveryAddress($address) public function setDeliveryAddress($address)
{ {
$this->deliveryAddress = $address; $this->deliveryAddress = $address;
return $this; return $this;
} }
@@ -92,6 +96,7 @@ class OrderManualEvent extends OrderEvent
public function setDeliveryModule($module) public function setDeliveryModule($module)
{ {
$this->deliveryModule = $module; $this->deliveryModule = $module;
return $this; return $this;
} }
@@ -101,6 +106,7 @@ class OrderManualEvent extends OrderEvent
public function setPaymentModule($module) public function setPaymentModule($module)
{ {
$this->paymentModule = $module; $this->paymentModule = $module;
return $this; return $this;
} }
@@ -110,6 +116,7 @@ class OrderManualEvent extends OrderEvent
public function setPostage($postage) public function setPostage($postage)
{ {
$this->postage = $postage; $this->postage = $postage;
return $this; return $this;
} }
@@ -119,6 +126,7 @@ class OrderManualEvent extends OrderEvent
public function setRef($ref) public function setRef($ref)
{ {
$this->ref = $ref; $this->ref = $ref;
return $this; return $this;
} }
@@ -128,6 +136,7 @@ class OrderManualEvent extends OrderEvent
public function setStatus($status) public function setStatus($status)
{ {
$this->status = $status; $this->status = $status;
return $this; return $this;
} }
@@ -227,6 +236,7 @@ class OrderManualEvent extends OrderEvent
public function setCurrency($currency) public function setCurrency($currency)
{ {
$this->currency = $currency; $this->currency = $currency;
return $this; return $this;
} }
@@ -238,6 +248,7 @@ class OrderManualEvent extends OrderEvent
public function setLang($lang) public function setLang($lang)
{ {
$this->lang = $lang; $this->lang = $lang;
return $this; return $this;
} }
@@ -249,6 +260,7 @@ class OrderManualEvent extends OrderEvent
public function setCart($cart) public function setCart($cart)
{ {
$this->cart = $cart; $this->cart = $cart;
return $this; return $this;
} }
@@ -260,6 +272,7 @@ class OrderManualEvent extends OrderEvent
public function setCustomer($customer) public function setCustomer($customer)
{ {
$this->customer = $customer; $this->customer = $customer;
return $this; return $this;
} }

View File

@@ -44,7 +44,8 @@ class OrderPaymentEvent extends ActionEvent
*/ */
protected $response; protected $response;
public function __construct(Order $order) { public function __construct(Order $order)
{
$this->order = $order; $this->order = $order;
} }
@@ -79,5 +80,4 @@ class OrderPaymentEvent extends ActionEvent
return null !== $this->response; return null !== $this->response;
} }
}
}

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Product; namespace Thelia\Core\Event\Product;
use Thelia\Core\Event\Product\ProductEvent;
class ProductToggleVisibilityEvent extends ProductEvent class ProductToggleVisibilityEvent extends ProductEvent
{ {
} }

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Product; namespace Thelia\Core\Event\Product;
use Thelia\Core\Event\Product\ProductCreateEvent;
class ProductUpdateEvent extends ProductCreateEvent class ProductUpdateEvent extends ProductCreateEvent
{ {
protected $product_id; protected $product_id;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
use Thelia\Model\Template; use Thelia\Model\Template;
class TemplateAddAttributeEvent extends TemplateEvent class TemplateAddAttributeEvent extends TemplateEvent
{ {

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
use Thelia\Model\Template; use Thelia\Model\Template;
class TemplateAddFeatureEvent extends TemplateEvent class TemplateAddFeatureEvent extends TemplateEvent
{ {

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
class TemplateCreateEvent extends TemplateEvent class TemplateCreateEvent extends TemplateEvent
{ {
protected $template_name; protected $template_name;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
use Thelia\Model\Template; use Thelia\Model\Template;
class TemplateDeleteAttributeEvent extends TemplateEvent class TemplateDeleteAttributeEvent extends TemplateEvent

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
class TemplateDeleteEvent extends TemplateEvent class TemplateDeleteEvent extends TemplateEvent
{ {
protected $template_id; protected $template_id;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateEvent;
use Thelia\Model\Template; use Thelia\Model\Template;
class TemplateDeleteFeatureEvent extends TemplateEvent class TemplateDeleteFeatureEvent extends TemplateEvent

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Event\Template; namespace Thelia\Core\Event\Template;
use Thelia\Core\Event\Template\TemplateCreateEvent;
class TemplateUpdateEvent extends TemplateCreateEvent class TemplateUpdateEvent extends TemplateCreateEvent
{ {
protected $template_id; protected $template_id;

View File

@@ -27,7 +27,6 @@ use Symfony\Component\HttpKernel\Event\GetResponseEvent;
use Symfony\Component\HttpKernel\KernelEvents; use Symfony\Component\HttpKernel\KernelEvents;
use Thelia\Core\Translation\Translator; use Thelia\Core\Translation\Translator;
/** /**
* Class RequestListener * Class RequestListener
* @package Thelia\Core\EventListener * @package Thelia\Core\EventListener
@@ -91,4 +90,4 @@ class RequestListener implements EventSubscriberInterface
KernelEvents::REQUEST => array("registerValidatorTranslator", 128) KernelEvents::REQUEST => array("registerValidatorTranslator", 128)
); );
} }
} }

View File

@@ -26,7 +26,6 @@ namespace Thelia\Core\Security\Authentication;
use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Request;
use Thelia\Core\Security\UserProvider\AdminUserProvider; use Thelia\Core\Security\UserProvider\AdminUserProvider;
use Thelia\Form\AdminLogin; use Thelia\Form\AdminLogin;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Security\Authentication; namespace Thelia\Core\Security\Authentication;
use Thelia\Core\Security\UserProvider\TokenUserProvider; use Thelia\Core\Security\UserProvider\TokenUserProvider;
use Thelia\Core\Security\Exception\TokenAuthenticationException; use Thelia\Core\Security\Exception\TokenAuthenticationException;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Security\Authentication; namespace Thelia\Core\Security\Authentication;
use Symfony\Component\HttpFoundation\Request; use Symfony\Component\HttpFoundation\Request;
use Thelia\Core\Security\UserProvider\UserProviderInterface; use Thelia\Core\Security\UserProvider\UserProviderInterface;

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Security\UserProvider; namespace Thelia\Core\Security\UserProvider;
use Thelia\Model\AdminQuery; use Thelia\Model\AdminQuery;
class AdminUserProvider implements UserProviderInterface class AdminUserProvider implements UserProviderInterface

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Security\UserProvider; namespace Thelia\Core\Security\UserProvider;
use Thelia\Model\CustomerQuery; use Thelia\Model\CustomerQuery;
class CustomerUserProvider implements UserProviderInterface class CustomerUserProvider implements UserProviderInterface
{ {

View File

@@ -23,7 +23,6 @@
namespace Thelia\Core\Template\Element; namespace Thelia\Core\Template\Element;
use Thelia\Core\Template\Loop\Argument\Argument; use Thelia\Core\Template\Loop\Argument\Argument;
use Propel\Runtime\ActiveQuery\ModelCriteria; use Propel\Runtime\ActiveQuery\ModelCriteria;
use Thelia\Model\Tools\ModelCriteriaTools; use Thelia\Model\Tools\ModelCriteriaTools;

View File

@@ -337,8 +337,7 @@ abstract class BaseLoop
public function count() public function count()
{ {
$hash = $this->args->getHash(); $hash = $this->args->getHash();
if(false === isset(self::$cacheCount[$hash])) if (false === isset(self::$cacheCount[$hash])) {
{
$count = 0; $count = 0;
if ($this instanceof PropelSearchLoopInterface) { if ($this instanceof PropelSearchLoopInterface) {
$searchModelCriteria = $this->buildModelCriteria(); $searchModelCriteria = $this->buildModelCriteria();
@@ -368,8 +367,7 @@ abstract class BaseLoop
public function exec(&$pagination) public function exec(&$pagination)
{ {
$hash = $this->args->getHash(); $hash = $this->args->getHash();
if(false === isset(self::$cacheLoopResult[$hash])) if (false === isset(self::$cacheLoopResult[$hash])) {
{
if ($this instanceof PropelSearchLoopInterface) { if ($this instanceof PropelSearchLoopInterface) {
$searchModelCriteria = $this->buildModelCriteria(); $searchModelCriteria = $this->buildModelCriteria();
if (null === $searchModelCriteria) { if (null === $searchModelCriteria) {

View File

@@ -26,7 +26,6 @@ namespace Thelia\Core\Template\Element;
use Propel\Runtime\Collection\ObjectCollection; use Propel\Runtime\Collection\ObjectCollection;
use Propel\Runtime\Util\PropelModelPager; use Propel\Runtime\Util\PropelModelPager;
class LoopResult implements \Iterator class LoopResult implements \Iterator
{ {
private $position; private $position;
@@ -152,7 +151,7 @@ class LoopResult implements \Iterator
* Checks if current position is valid * Checks if current position is valid
* @link http://php.net/manual/en/iterator.valid.php * @link http://php.net/manual/en/iterator.valid.php
* @return boolean The return value will be casted to boolean and then evaluated. * @return boolean The return value will be casted to boolean and then evaluated.
* Returns true on success or false on failure. * Returns true on success or false on failure.
*/ */
public function valid() public function valid()
{ {

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Template\Loop; namespace Thelia\Core\Template\Loop;
use Propel\Runtime\ActiveQuery\Criteria; use Propel\Runtime\ActiveQuery\Criteria;
use Thelia\Core\Template\Element\LoopResult; use Thelia\Core\Template\Element\LoopResult;

View File

@@ -127,7 +127,7 @@ class ArgumentCollection implements \Iterator
* Checks if current position is valid * Checks if current position is valid
* @link http://php.net/manual/en/iterator.valid.php * @link http://php.net/manual/en/iterator.valid.php
* @return boolean The return value will be casted to boolean and then evaluated. * @return boolean The return value will be casted to boolean and then evaluated.
* Returns true on success or false on failure. * Returns true on success or false on failure.
*/ */
public function valid() public function valid()
{ {

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Template\Loop; namespace Thelia\Core\Template\Loop;
use Propel\Runtime\ActiveQuery\Criteria; use Propel\Runtime\ActiveQuery\Criteria;
use Thelia\Core\Template\Element\LoopResult; use Thelia\Core\Template\Element\LoopResult;

View File

@@ -194,7 +194,6 @@ class Category extends BaseI18nLoop implements PropelSearchLoopInterface
{ {
foreach ($loopResult->getResultDataCollection() as $category) { foreach ($loopResult->getResultDataCollection() as $category) {
/* /*
* no cause pagination lost : * no cause pagination lost :
* if ($this->getNotEmpty() && $category->countAllProducts() == 0) continue; * if ($this->getNotEmpty() && $category->countAllProducts() == 0) continue;
@@ -254,7 +253,6 @@ class Category extends BaseI18nLoop implements PropelSearchLoopInterface
; ;
} }
$loopResult->addRow($loopResultRow); $loopResult->addRow($loopResultRow);
} }

View File

@@ -30,7 +30,6 @@ use Thelia\Model\CountryQuery;
use Thelia\Module\BaseModule; use Thelia\Module\BaseModule;
use Thelia\Module\DeliveryModuleInterface; use Thelia\Module\DeliveryModuleInterface;
/** /**
* Class Delivery * Class Delivery
* @package Thelia\Core\Template\Loop * @package Thelia\Core\Template\Loop

View File

@@ -87,7 +87,6 @@ class Lang extends BaseLoop implements PropelSearchLoopInterface
$search->filterById($exclude, Criteria::NOT_IN); $search->filterById($exclude, Criteria::NOT_IN);
} }
$orders = $this->getOrder(); $orders = $this->getOrder();
foreach ($orders as $order) { foreach ($orders as $order) {

View File

@@ -46,7 +46,7 @@ abstract class AbstractSmartyPlugin
$array = explode(',', $commaSeparatedValues); $array = explode(',', $commaSeparatedValues);
if (array_walk($array, function(&$item) { if (array_walk($array, function (&$item) {
$item = strtoupper(trim($item)); $item = strtoupper(trim($item));
})) { })) {
return $array; return $array;

View File

@@ -23,8 +23,6 @@
namespace Thelia\Core\Template\Smarty\Assets; namespace Thelia\Core\Template\Smarty\Assets;
use Thelia\Log\Tlog;
use Thelia\Tools\URL; use Thelia\Tools\URL;
use Thelia\Core\Template\Assets\AssetManagerInterface; use Thelia\Core\Template\Assets\AssetManagerInterface;

View File

@@ -109,8 +109,7 @@ class Form extends AbstractSmartyPlugin
if (null != $form) { if (null != $form) {
// Re-use the form // Re-use the form
$instance = $form; $instance = $form;
} } else {
else {
// Create a new one // Create a new one
$class = new \ReflectionClass($formClass); $class = new \ReflectionClass($formClass);

View File

@@ -54,7 +54,7 @@ class Module extends AbstractSmartyPlugin
* AdminIncludes/<location>.html file, and fetch it as a Smarty template. * AdminIncludes/<location>.html file, and fetch it as a Smarty template.
* - countvar : this is the name of a template variable where the number of found modules includes will be assigned. * - countvar : this is the name of a template variable where the number of found modules includes will be assigned.
* *
* @param array $params * @param array $params
* @param \Smarty_Internal_Template $template * @param \Smarty_Internal_Template $template
* @internal param \Thelia\Core\Template\Smarty\Plugins\unknown $smarty * @internal param \Thelia\Core\Template\Smarty\Plugins\unknown $smarty
* *

View File

@@ -7,10 +7,8 @@ use \Symfony\Component\EventDispatcher\EventDispatcherInterface;
use \Smarty; use \Smarty;
use Thelia\Core\Template\ParserInterface; use Thelia\Core\Template\ParserInterface;
use Thelia\Core\Template\Exception\ResourceNotFoundException; use Thelia\Core\Template\Exception\ResourceNotFoundException;
use Thelia\Core\Template\ParserContext; use Thelia\Core\Template\ParserContext;
use Thelia\Core\Template\TemplateDefinition; use Thelia\Core\Template\TemplateDefinition;

View File

@@ -42,7 +42,6 @@ use Symfony\Component\Config\Loader\LoaderInterface;
use Symfony\Component\Yaml\Yaml; use Symfony\Component\Yaml\Yaml;
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; use Symfony\Component\DependencyInjection\ParameterBag\ParameterBag;
use Thelia\Core\Bundle;
use Thelia\Core\Event\TheliaEvents; use Thelia\Core\Event\TheliaEvents;
use Thelia\Config\DatabaseConfiguration; use Thelia\Config\DatabaseConfiguration;
use Thelia\Config\DefinePropel; use Thelia\Config\DefinePropel;

View File

@@ -35,7 +35,7 @@ use Symfony\Component\DependencyInjection\ContainerBuilder;
class TheliaContainerBuilder extends ContainerBuilder class TheliaContainerBuilder extends ContainerBuilder
{ {
public function compile(){} public function compile() {}
public function customCompile() public function customCompile()
{ {

View File

@@ -67,8 +67,8 @@ class TheliaHttpKernel extends HttpKernel
* *
* @param Request $request A Request instance * @param Request $request A Request instance
* @param integer $type The type of the request * @param integer $type The type of the request
* (one of HttpKernelInterface::MASTER_REQUEST or HttpKernelInterface::SUB_REQUEST) * (one of HttpKernelInterface::MASTER_REQUEST or HttpKernelInterface::SUB_REQUEST)
* @param Boolean $catch Whether to catch exceptions or not * @param Boolean $catch Whether to catch exceptions or not
* *
* @return Response A Response instance * @return Response A Response instance
* *

View File

@@ -128,6 +128,7 @@ class BaseFacade implements FacadeInterface
public function getCartTotalTaxPrice() public function getCartTotalTaxPrice()
{ {
$taxCountry = $this->getContainer()->get('thelia.taxEngine')->getDeliveryCountry(); $taxCountry = $this->getContainer()->get('thelia.taxEngine')->getDeliveryCountry();
return $this->getCart()->getTaxedAmount($taxCountry); return $this->getCart()->getTaxedAmount($taxCountry);
} }

View File

@@ -29,7 +29,6 @@ use Thelia\Coupon\FacadeInterface;
use Thelia\Condition\ConditionCollection; use Thelia\Condition\ConditionCollection;
use Thelia\Condition\ConditionOrganizerInterface; use Thelia\Condition\ConditionOrganizerInterface;
/** /**
* Assist in writing a CouponInterface * Assist in writing a CouponInterface
* *
@@ -139,9 +138,9 @@ abstract class CouponAbstract implements CouponInterface
* @param bool $isRemovingPostage If Coupon is removing postage * @param bool $isRemovingPostage If Coupon is removing postage
* @param bool $isAvailableOnSpecialOffers If available on Product already * @param bool $isAvailableOnSpecialOffers If available on Product already
* on special offer price * on special offer price
* @param bool $isEnabled False if Coupon is disabled by admin * @param bool $isEnabled False if Coupon is disabled by admin
* @param int $maxUsage How many usage left * @param int $maxUsage How many usage left
* @param \Datetime $expirationDate When the Code is expiring * @param \Datetime $expirationDate When the Code is expiring
* *
* @return $this * @return $this
*/ */

View File

@@ -76,9 +76,9 @@ interface CouponInterface
* @param bool $isRemovingPostage If Coupon is removing postage * @param bool $isRemovingPostage If Coupon is removing postage
* @param bool $isAvailableOnSpecialOffers If available on Product already * @param bool $isAvailableOnSpecialOffers If available on Product already
* on special offer price * on special offer price
* @param bool $isEnabled False if Coupon is disabled by admin * @param bool $isEnabled False if Coupon is disabled by admin
* @param int $maxUsage How many usage left * @param int $maxUsage How many usage left
* @param \Datetime $expirationDate When the Code is expiring * @param \Datetime $expirationDate When the Code is expiring
*/ */
public function set( public function set(
FacadeInterface $facade, FacadeInterface $facade,

Some files were not shown because too many files have changed in this diff Show More