Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

shazad maved shazadmaved

🎯
Focusing
View GitHub Profile
@shazadmaved
shazadmaved / gist:8d735d3e3e7bc5c98363670504d6f7c8
Created May 2, 2018
I have created a function to get all possible promotions of a product by considering even the taxons. Its not yet optimised and not well tested. I added the following in the product decorator model
View gist:8d735d3e3e7bc5c98363670504d6f7c8
def get_all_possible_promotions
taxons_of_product_including_parents
end
private
# ids of taxons rules and taxons rules children