Asset for RT 1.0.2 and rt-crontool

Hi,

I’ve installed RT 4.2.9 and Asset 1.0.2 and now try to configure it for tech support.

Is it possible to use rt-crontool to change a status of an asset depend on it’s custom field?
I’d like to create “Expiration data” custom field to change status of assets if data expired.

How to do this?

Thanks, Andrey
.

Is it possible to use rt-crontool to change a status of an asset depend on it’s custom field?
I’d like to create “Expiration data” custom field to change status of assets if data expired.

Assets doesn’t have support for triggered actions (scrips) yet. You
can override the AddCustomFieldValue method on RT::Asset to accomplish
this manually.

  • Alex

So, is it impossible to act on assets like tickets from rt-crontool?

So, is it impossible to act on assets like tickets from rt-crontool?

As of now, yes. rt-crontool is still ticket-centric, in that its
search predicates only return tickets, and its actions are still
Scrips’ actions, which assume they act on tickets.

Writing a small amount of code to iterate over assets and modify them
is fairly simple, however.

  • Alex

I don’t understand how to do this task if I try to override AddCustomFieldValue method…

Each my asset record have custom field “Expiration date”. This field is mandatory and fill in at the moment of creation.

I thought if I run each night some tool like rt-crontool I can check this custom field and compare it with current date. If it’s expired the status of asset should be changed.