diff --git a/config/admin/services.yml b/config/admin/services.yml index 2c3238b..570ebd7 100644 --- a/config/admin/services.yml +++ b/config/admin/services.yml @@ -53,12 +53,12 @@ services: oksydan.is_imageslider.handler.file_uploader: class: 'Oksydan\IsImageslider\Handler\FileUploader' arguments: - $targetDirectory: '%images_directory%' + $targetDirectory: '%is_imageslider_images_directory%' oksydan.is_imageslider.handler.file_eraser: class: 'Oksydan\IsImageslider\Handler\FileEraser' arguments: - $targetDirectory: '%images_directory%' + $targetDirectory: '%is_imageslider_images_directory%' #creation/edition form @@ -68,7 +68,7 @@ services: - '@oksydan.is_imageslider.repository.image_slider' - '@oksydan.is_imageslider.provider.image_provider' - '@prestashop.core.admin.lang.repository' - - '%placeholder_img%' + - '%is_imageslider_placeholder_img%' - '@prestashop.adapter.shop.context' oksydan.is_imageslider.form.identifiable_object.builder.image_slider_form_builder: @@ -188,4 +188,4 @@ services: class: 'Oksydan\IsImageslider\Provider\ImageProvider' public: true arguments: - - '%images_uri%' + - '%is_imageslider_images_uri%' diff --git a/config/common.yml b/config/common.yml index 37dc1fe..6c1acad 100644 --- a/config/common.yml +++ b/config/common.yml @@ -1,8 +1,8 @@ parameters: - images_directory: '%kernel.project_dir%/modules/is_imageslider/img/' - module_uri: !php/const _MODULE_DIR_ - images_uri: '%module_uri%is_imageslider/img/' - placeholder_img: '/modules/is_imageslider/views/img/placeholder.jpeg' + is_imageslider_images_directory: '%kernel.project_dir%/modules/is_imageslider/img/' + is_imageslider_module_uri: !php/const _MODULE_DIR_ + is_imageslider_images_uri: '%is_imageslider_module_uri%is_imageslider/img/' + is_imageslider_placeholder_img: '/modules/is_imageslider/views/img/placeholder.jpeg' services: _defaults: @@ -33,8 +33,8 @@ services: class: Oksydan\IsImageslider\Presenter\ImageSlidePresenter public: true arguments: - - '%images_uri%' - - '%images_directory%' + - '%is_imageslider_images_uri%' + - '%is_imageslider_images_directory%' - "@=service('prestashop.adapter.legacy.context').getContext()" oksydan.is_imageslider.configuration.slider_configuration: diff --git a/is_imageslider.php b/is_imageslider.php index 93dfe50..dc9234d 100644 --- a/is_imageslider.php +++ b/is_imageslider.php @@ -30,7 +30,7 @@ public function __construct() * https://www.waynet.pl/ */ $this->author = 'Igor Stępień'; - $this->version = '2.3.0'; + $this->version = '2.3.2'; $this->need_instance = 0; $this->bootstrap = true; diff --git a/src/Entity/ImageSlider.php b/src/Entity/ImageSlider.php index 0689354..4003c40 100644 --- a/src/Entity/ImageSlider.php +++ b/src/Entity/ImageSlider.php @@ -44,14 +44,14 @@ class ImageSlider /** * @var \DateTime * - * @ORM\Column(name="display_from", type="datetime") + * @ORM\Column(name="display_from", type="datetime", nullable=true) */ private $display_from; /** * @var \DateTime * - * @ORM\Column(name="display_to", type="datetime") + * @ORM\Column(name="display_to", type="datetime", nullable=true) */ private $display_to; diff --git a/src/Form/ImageSliderType.php b/src/Form/ImageSliderType.php index dfdbd16..7621f53 100644 --- a/src/Form/ImageSliderType.php +++ b/src/Form/ImageSliderType.php @@ -134,6 +134,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void 'widget' => 'single_text', 'html5' => true, 'input' => 'datetime', + 'with_seconds' => true, ]) ->add('display_to', DateTimeType::class, [ 'label' => $this->trans('Display to', TranslationDomains::TRANSLATION_DOMAIN_ADMIN), @@ -141,6 +142,7 @@ public function buildForm(FormBuilderInterface $builder, array $options): void 'widget' => 'single_text', 'html5' => true, 'input' => 'datetime', + 'with_seconds' => true, ]); if ($this->isMultistoreUsed) {