Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Limit Orders Amount Shown Rate Topic   - - - - -

 
  • Darius
  • Douchebag
  • Members
  • Join Date: 20-Apr 08
  • 3176 posts

Posted 22 May 2018 - 12:48 PM #1

Hello

 

demo.cs-cart.com/stores/orders/

 

how do I limit shown orders to for example only from 2018 or last 5 ?



 
  • Darius
  • Douchebag
  • Members
  • Join Date: 20-Apr 08
  • 3176 posts

Posted 31 May 2018 - 06:11 AM #2

If someone needs then here it is how
 
need to edit

responsive / templates / views / orders / search.tpl

 

add  (you can change 2 o any number)

{$params = $smarty.request}
{$params.user_id = $auth.user_id}
{$_orders = $params|fn_get_orders:2}

before

<table class="ty-table ty-orders-search">

then change

{foreach from=$_orders item="o"}

to

{foreach from=$_orders.0 item="o"}

If someone know how can I load orders not by needed number but to year, say current year or last 6 months ?