Hi,
I am working on an extension module for Products which aims to do some administrative tasks such as enabling/disabling products based on some conditions or hold some sales statistics etc. To that end, i need to implement a pseudocron task that will run asynchronously and update various database fields of Products or other modules.
From what i've seen in other posts:
e.g.
http://forum.cmsmadesimple.org/viewtopi ... =4&t=49995
one has to implement the task functionality inside a class that should be put in /lib/tasks directory.
So, what is the best way of achieving this in a typical module installation/removal ? I mean, how can I install this task class file as a part of the installation procedure? Should I copy it explicitly to the root_path/lib/tasks directory or is there another way ?
By the way, i am using cmsms 1.10.3
Adding a new pseudocron task when installing a new module
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: Adding a new pseudocron task when installing a new modul
Take a look at the CGSmartImage module. It has a psuedocron task.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Re: Adding a new pseudocron task when installing a new modul
Oops! I hadn't noticed that task while grep-ing...
Worked like a charm. Thanks.
Worked like a charm. Thanks.