Changing status to rejected is no longer working

Hi,

I’m on RT 4.4.1. I have customized tickets lifecycles and later realized that I am no longer able to change the status from open to rejected. I am not sure whether or not there is a relation with the life cycle changes since I only realized this issue months later after the life cycle changes.

The issue is I get no error messages in the logs and the Web interface says the status was changed but the Status in fact remains the same as before even after refreshing the page.

I upload a screenshot and copy the LifeCycles configuration from my RT_SiteConfig.pmfile in case anyone can help shed light on the issue.

sc1

LifeCycles configuration:

Customize LifeCycles

Set(%Lifecycles,
default => {
initial => [qw(new)], # loc_qw
active => [qw(open pending_data pending_connection pending_information pending_taser pending_closure stalled)], # loc_qw
inactive => [qw(resolved rejected deleted)], # loc_qw

    defaults => {
        on_create => 'new',
        approved  => 'open',
        denied    => 'rejected',
        reminder_on_open     => 'open',
        reminder_on_resolve  => 'resolved',
    },

    transitions => {
        ""       => [qw(new open resolved)],

        # from   => [ to list ],
        new      => [qw(    open pending_data pending_connection pending_information pending_taser pending_closure stalled resolved rejected deleted)],
        open     => [qw(new      pending_data pending_connection pending_information pending_taser pending_closure stalled resolved rejected deleted)],
        pending_data    => [qw(new open     pending_connection pending_information pending_taser pending_closure stalled resolved rejected deleted)],
        pending_connection    => [qw(new open pending_data      pending_information pending_taser pending_closure stalled resolved rejected deleted)],
        pending_information    => [qw(new open pending_data pending_connection      pending_taser pending_closure stalled resolved rejected deleted)],
        pending_taser    => [qw(new open pending_data pending_connection pending_information      pending_closure stalled resolved rejected deleted)],
        pending_closure    => [qw(new open pending_data pending_connection pending_information pending_taser      stalled resolved rejected deleted)],
        stalled  => [qw(new open pending_data pending_connection pending_information pending_taser pending_closure      resolved rejected deleted)],
        resolved => [qw(new open pending_data pending_connection pending_information pending_taser pending_closure stalled      rejected deleted)],
        rejected => [qw(new open pending_data pending_connection pending_information pending_taser pending_closure stalled resolved      deleted)],
        deleted  => [qw(new open pending_data pending_connection pending_information pending_taser pending_closure stalled resolved rejected)],
    },
    rights => {
        '* -> deleted'  => 'DeleteTicket',
        '* -> rejected' => 'ModifyTicket',
        '* -> *'        => 'ModifyTicket',
    },
    actions => [
        'new -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'open -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'stalled -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'pending_connection -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'pending_information -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'pending_taser -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'pending_closure -> pending_data' => { label  => 'Request data access', update => 'Respond' }, # loc{label}
        'new -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'open -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'stalled -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'pending_data -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'pending_information -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'pending_taser -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'pending_closure -> pending_connection' => { label  => 'Request remote access', update => 'Respond' }, # loc{label}
        'new -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'open -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'stalled -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'pending_data -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'pending_connection -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'pending_taser -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'pending_closure -> pending_information' => { label  => 'Request more information', update => 'Respond' }, # loc{label}
        'new -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'open -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'stalled -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'pending_data -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'pending_connection -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'pending_information -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'pending_closure -> pending_taser' => { label  => 'Tasered', update => 'Comment' }, # loc{label}
        'new -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'open -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'stalled -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'pending_data -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'pending_connection -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'pending_information -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'pending_taser -> pending_closure' => { label  => 'Confirm resolution', update => 'Respond' }, # loc{label}
        'new -> open'      => { label  => 'Open It', update => 'Respond' }, # loc{label}
        'new -> resolved'  => { label  => 'Resolve', update => 'Comment' }, # loc{label}
        'new -> rejected'  => { label  => 'Reject',  update => 'Respond' }, # loc{label}
        'new -> deleted'   => { label  => 'Delete',                      }, # loc{label}
        'open -> stalled'  => { label  => 'Stall',   update => 'Comment' }, # loc{label}
        'open -> resolved' => { label  => 'Resolve', update => 'Comment' }, # loc{label}
        'open -> rejected' => { label  => 'Reject',  update => 'Respond' }, # loc{label}
        'stalled -> open'  => { label  => 'Open It',                     }, # loc{label}
        'resolved -> open' => { label  => 'Re-open', update => 'Comment' }, # loc{label}
        'rejected -> open' => { label  => 'Re-open', update => 'Comment' }, # loc{label}
        'deleted -> open'  => { label  => 'Undelete',                    }, # loc{label}
    ],
},
assets => {
    type     => "asset",
    initial  => [
        'new' # loc
    ],
    active   => [
        'allocated', # loc
        'in-use' # loc
    ],
    inactive => [
        'recycled', # loc
        'stolen', # loc
        'deleted' # loc
    ],

    defaults => {
        on_create => 'new',
    },

    transitions => {
        ''        => [qw(new allocated in-use)],
        new       => [qw(allocated in-use stolen deleted)],
        allocated => [qw(in-use recycled stolen deleted)],
        "in-use"  => [qw(allocated recycled stolen deleted)],
        recycled  => [qw(allocated)],
        stolen    => [qw(allocated)],
        deleted   => [qw(allocated)],
    },
    rights => {
        '* -> *'        => 'ModifyAsset',
    },
    actions => {
        '* -> allocated' => {
            label => "Allocate" # loc
        },
        '* -> in-use'    => {
            label => "Now in-use" # loc
        },
        '* -> recycled'  => {
            label => "Recycle" # loc
        },
        '* -> stolen'    => {
            label => "Report stolen" # loc
        },
    },
},

don’t change lifecyle of the approvals, they are not capable to deal with

custom statuses

approvals => {
    initial         => [ 'new' ],
    active          => [ 'open', 'stalled' ],
    inactive        => [ 'resolved', 'rejected', 'deleted' ],

    defaults => {
        on_create => 'new',
        reminder_on_open     => 'open',
        reminder_on_resolve  => 'resolved',
    },

    transitions => {
        ''       => [qw(new open resolved)],

        # from   => [ to list ],
        new      => [qw(open stalled resolved rejected deleted)],
        open     => [qw(new stalled resolved rejected deleted)],
        stalled  => [qw(new open rejected resolved deleted)],
        resolved => [qw(new open stalled rejected deleted)],
        rejected => [qw(new open stalled resolved deleted)],
        deleted  => [qw(new open stalled rejected resolved)],
    },
    rights => {
        '* -> deleted'  => 'DeleteTicket',
        '* -> rejected' => 'ModifyTicket',
        '* -> *'        => 'ModifyTicket',
    },
    actions => [
        'new -> open'      => { label  => 'Open It', update => 'Respond' }, # loc{label}
        'new -> resolved'  => { label  => 'Resolve', update => 'Comment' }, # loc{label}
        'new -> rejected'  => { label  => 'Reject',  update => 'Respond' }, # loc{label}
        'new -> deleted'   => { label  => 'Delete',                      }, # loc{label}
        'open -> stalled'  => { label  => 'Stall',   update => 'Comment' }, # loc{label}
        'open -> resolved' => { label  => 'Resolve', update => 'Comment' }, # loc{label}
        'open -> rejected' => { label  => 'Reject',  update => 'Respond' }, # loc{label}
        'stalled -> open'  => { label  => 'Open It',                     }, # loc{label}
        'resolved -> open' => { label  => 'Re-open', update => 'Comment' }, # loc{label}
        'rejected -> open' => { label  => 'Re-open', update => 'Comment' }, # loc{label}
        'deleted -> open'  => { label  => 'Undelete',                    }, # loc{label}
    ],
},

);

If the status is available in the drop down then I would assume it isn’t the lifecycle, do you have some code maybe setting the value back to the open status?

thanks for the suggestion, it could be a forgotten scrip indeed. I will look into this thanks for the suggestion!

If you go into the ticket history do you see a transaction for the status being set to ‘rejected’?

Very good point - I do indeed !!!

Fri Aug 09 15:07:19 2019 The RT System itself - Status changed from ‘rejected’ to ‘open’

Fri Aug 09 15:07:19 2019 Samuel (Samuel Thoraval) - Status changed from ‘open’ to ‘rejected’

Nice, so this is most likely a scrip then

Found it, and of course the last scrip I created… It is all resolved now.
Thanks a lot for your help!I

1 Like