LemonStand Forum: Recently viewed products - LemonStand Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Recently viewed products

#1 User is offline   Urvi 

  • Member
  • Group: Members
  • Posts: 22
  • Joined: 05-November 11

Posted 14 January 2012 - 09:55 AM

Is there any way for recently viewed products list?
0

#2 User is offline   Eric 

  • Developer
  • PipPipPip
  • Group: Members
  • Posts: 1,290
  • Joined: 04-August 10
  • LocationVancouver, Canada

Posted 16 January 2012 - 10:19 AM

Yes, by creating a custom module which keeps track of the customer and the X recently viewed products. You would need to extend the customer model with a list of products. On the product page, push the current $product to the front of the list, and slice off the extra products after the total desired.

http://lemonstandapp...nstand_modules/
http://lemonstandapp...onstand_events/
0

#3 User is offline   Urvi 

  • Member
  • Group: Members
  • Posts: 22
  • Joined: 05-November 11

Posted 17 January 2012 - 03:31 AM

View PostEric, on 16 January 2012 - 10:19 AM, said:

Yes, by creating a custom module which keeps track of the customer and the X recently viewed products. You would need to extend the customer model with a list of products. On the product page, push the current $product to the front of the list, and slice off the extra products after the total desired.

http://lemonstandapp...nstand_modules/
http://lemonstandapp...onstand_events/


Thanks for the some suggestions but still I am not so clear,
Yes I know that I have to create a custom module for it but I dont know which event should be more proper for it?
its valid - shop:onDisplayProductList event...?
we required the product detail page load event with current customer Id ... how can I achieve this?

Thanks in Advance
0

#4 User is offline   manic 

  • Member
  • Group: Members
  • Posts: 27
  • Joined: 22-October 11

Posted 19 January 2012 - 03:55 AM

not the solution looking for but a simple option is to do it client side and save lemonstand the overheads.

Make use of HTML5's localstorage and incorporate it into your templates so that a javascript storage method is executed on each product detail page.. .. create a function to retrieve the list... job done. Not all browsers support localstorage but you can detect with Modernizr and use cookies as backup or leave it as a feature for those priveliged enough to have a recent enough browser.
0

#5 User is offline   Eric 

  • Developer
  • PipPipPip
  • Group: Members
  • Posts: 1,290
  • Joined: 04-August 10
  • LocationVancouver, Canada

Posted 19 January 2012 - 10:15 AM

View PostUrvi, on 17 January 2012 - 03:31 AM, said:

Thanks for the some suggestions but still I am not so clear,
Yes I know that I have to create a custom module for it but I dont know which event should be more proper for it?
its valid - shop:onDisplayProductList event...?
we required the product detail page load event with current customer Id ... how can I achieve this?

Thanks in Advance


Well, definitely these two:

  • shop:onExtendCustomerModel event - allows to extend customer model. You can add new fields to the customer model in the event handler.
  • shop:onExtendCustomerForm event - allows to add new fields to the Create/Edit Customer form in the Administration Area.


You can see here how a customer model is extended with wish lists. In your case it would be customer model and product lists.
0

Share this topic:


Page 1 of 1

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users