Coder Social home page Coder Social logo

wapone / module-stickers Goto Github PK

View Code? Open in Web Editor NEW
6.0 6.0 6.0 241 KB

Magento 2 extension to provide product image stickers visible everywhere in the store (category page, product page, result page, related/upsell/crossell, widget)

PHP 62.41% HTML 5.44% JavaScript 26.69% CSS 5.47%
magento2 magento2-extension

module-stickers's People

Contributors

wapone avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

module-stickers's Issues

Error with configurable products

I am getting this error: Warning: Division by zero in vendor/wapone/module-stickers/Model/Stickers.php on line 85

After adding configurable product with 3 different prices.

One sticker at a time

This extension only allows one sticker at a time? We would like add stickers for "10% off", "20% off", "30% off", etc.

Is it possible to change it to allow multiples?

Media Base URL is sometimes incorrect

The media base URL will be /media on typical production setups. This will give broken links to images for this plugin

Wrong way to fetch the base URL for media:
$this->getUrl('pub/media')

Correct way:
$this->_storeManager->getStore()->getBaseUrl(\Magento\Framework\UrlInterface::URL_TYPE_MEDIA)

see Block/Discount.php

view/frontend/templates/categoryDiscount.phtml also needs a change

One way of solving this is by adding a new function to Discount.php that returns the full path to the sticker image:

    public function getStickerImageFP()
    {
        return $this->_storeManager->getStore()->getBaseUrl(\Magento\Framework\UrlInterface::URL_TYPE_MEDIA)."wapone/stickers/images/".$this->getStickerImage();
    }

then calling this one instead of getStickerImage()

New Request Please

Add compatibility for magento 2.3.x and Add Free Shipping sticker with logica, if the price is higher than xx you should show the Free Shipping sticker.

Stickers not showing up in new products widget

Magento version : 2.1.7

Steps to reproduce :

  1. Installed WaPoNe/module-stickers manually
  2. enabled the extension
  3. discount calculation : automatic
  4. created a cms page with new products list

Expected result : Discount sticker must be shown anywhere inside the product list block

Actual result : Discount sticker is not showing up

It is working well with category page and product listing widget... Could you please have a look at this issue?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.