| Issue 31: | PATCH Products are not beeing marked with "New" or "Sale" icons | |
| 1 person starred this issue and may be notified of changes. | Back to list |
What steps will reproduce the problem? 1. Create a new product or associate a tag called "On Sale" with one. What is the expected output? What do you see instead? It should have an icon at the upper right corner showing that. But it don't have. What version of the product are you using? On what operating system? trunk. Ubuntu 7.04 Please provide any additional information below. Follows a patch. The view isn't passing these informations to the helper, and if was the product helper method that builds this chunk of code is using a wrong path to the icon.
Apr 8, 2008
(No comment was entered for this change.)
Labels:
-Priority-Medium Priority-Low
May 7, 2008
Nice Patch Thanks!
Jun 14, 2008
Fixed with r86 |
Hi Edmundo, this patch works fine, all products are new if they are less than two weeks old. For those who would prefer control over the tag similar to 'On Sale' just tweek the product.rb model slightly def is_new? @cached_is_new ||= begin #self.date_available >= 2.weeks.ago !self.tags.find_by_name('New').nil? end