Daniel_SDaniel_S MitgliedKommentare: 9 Danke erhalten: 0 Mitglied seit: Dezember 2017

Hello everyone,

I am trying to set the vertical orientation for ".last-seen-products" but didn't have luck finding a doc about it. If I'm not wrong, the .last-seen-products slider is initialized in jquery.last-seen-products.js file at line 181: me.productSlider.initSlider();

/**
         * Creates a list of all collected articles and calls
         * the product slider plugin.
         *
         * @public
         * @method createProductList
         */
        createProductList: function () {
            var me = this,
                opts = me.opts,
                itemKey = 'lastSeenProducts-' + opts.shopId + '-' + opts.baseUrl,
                productsJson = me.storage.getItem(itemKey),
                products = productsJson ? JSON.parse(productsJson) : [],
                len = Math.min(opts.productLimit, products.length);

            if (len > 1) {
                me.$el.removeClass('is--hidden');
            }

            $.each(products, function(i, product) {
                if (product.articleId === opts.currentArticle.articleId) {
                    return;
                }

                me.$container.append(me.createTemplate(product));
            });

            me.productSlider.initSlider();

            $.publish('plugin/swLastSeenProducts/onCreateProductList', [ me ]);
        }

That piece of code, is calling the Product slider plugin, so how can I pass the orientation vertical option into me.productSlider.initSlider() ??? I was expecting something like me.productSlider.initSlider({orientation: "vertical"}) or is it a different way to do it?

Any help would be appreciated.

Thanks.

Anmelden oder Registrieren, um zu kommentieren.