10 replies [Last post]
finnalden's picture
Offline
Joined: 05/13/2013
Juice: 15
Was this information Helpful?

I am looking for some advice on how to achieve the following:

  1. Create a new order state called Archived.
  2. Make all the orders/invoices that are more than 6 months and completed, automatically be archived.
  3. Hide all orders/invoices from the orders view under store.

I am currently using Drupal 6 and Ubercart 2.x.

The best solution would of course be to use a module, but I am not a drupal programmer and need some help with this task. I do know some PHP, CSS and HTML.

DanZ's picture
Offline
Joined: 08/07/2011
Juice: 1738
Re: Create a new order state, archive, to remove orders from vie

You could just set a filter on the View to only display orders less than six months old, and this would accomplish everything you want. That's a really easy configuration change.

Also, I'm not sure about Ubercart 2, but on Ubercart 3, there's an order state and an order status. If I remember correctly, order states are hard-coded, but you can add a new order status as a simple configuration change. So, you could add an "archived" order status.

You'd use some sort of cron task with Conditional Actions to periodically put stuff into "archive" status. That's an Ubercart 2 thing, so I'm not sure how it works.

finnalden's picture
Offline
Joined: 05/13/2013
Juice: 15
Thanks

I will check out Views tomorrow and see how it works. Conditional actions might be the solution to move it in to an archive mode.

finnalden's picture
Offline
Joined: 05/13/2013
Juice: 15
Solution

The solution was simpler than I thought. Go to View and there are other views listed for Ubercart. I chose to enable orders and added a filter and that took care of the view.

I decided to keep the menu as it is now, but add the new view as a new menu item.

I think it would have been more elegant to archive the old orders, but considering the time and effort, I am happy with this solution.

Fivand420's picture
Offline
Joined: 12/26/2014
Juice: 8
Re: Solution

This article is something that will help me with my class assignment. It helped me to better understand another aspect of this topic. Thanks.
online proxy

Vgicand420's picture
Offline
Joined: 12/25/2014
Juice: 10
Re: Re: Create a new order state, archive, to remove orders from

This is a well written article on this subject. I have been looking at starting a new business and this is valuable information to help me in my decision. Thank you.
find this

commenterman's picture
Offline
Joined: 03/02/2015
Juice: 3
Re: Re: Create a new order state, archive, to remove orders from

with the information on this posting?I have read a few of the articles on your website now, and I really like your style. Thanks a million and please keep up the effective work Website

Logicand420's picture
Offline
Joined: 12/25/2014
Juice: 10
Re: Create a new order state, archive, to remove orders from vie

Your article is very exciting and informational. I am trying to decide on a career move and this has helped me with one aspect. Thank you so much!
Chiropractor Northern Beaches

terrmd's picture
Offline
Joined: 12/29/2014
Juice: 12
Re: Re: Create a new order state, archive, to remove orders from

I like the way you described the topic with such clarity. This is something I have been thinking about for a long time and you really captured the essence of the subject. Ben

weny28's picture
Offline
Joined: 01/08/2015
Juice: 5
Re: Re: Re: Create a new order state, archive, to remove orders

I am in the middle of working on a school report on this topic and your post has helped me with the information I needed to complete it. Thanks ariano reppucci

pete39's picture
Offline
Joined: 12/31/2014
Juice: 6
Re: Re: Re: Re: Create a new order state, archive, to remove ord

I have been searching about this topic and decided to do some research. Your article has some useful information. Do you have any more on this subject? residential locksmith tucson Thanks