Exemplo n.º 1
0
 def retract_item(item):
     schedule_feature = feature.get_feature(item, "schedule")
     if schedule_feature is None:
         return
     
     # take back to schedule pending
     wfc = IWorkflowController(item)
     for state in schedule_feature.get_param("schedulable_states"):
         transitions = wfc.getFireableTransitionIdsToward(state)
         if transitions:
             wfc.fireTransition(transitions[0])
             break
Exemplo n.º 2
0
    def retract_item(item):
        schedule_feature = feature.get_feature(item, "schedule")
        if schedule_feature is None:
            return

        # take back to schedule pending
        wfc = IWorkflowController(item)
        for state in schedule_feature.get_param("schedulable_states"):
            transitions = wfc.getFireableTransitionIdsToward(state)
            if transitions:
                wfc.fireTransition(transitions[0])
                break
Exemplo n.º 3
0
 def values(self):
     param_audit_actions = feature.get_feature(self.context,
                                               "audit").p.audit_actions
     return domain.get_changes(self.context, *param_audit_action)
Exemplo n.º 4
0
def get_scheduled_states(type_key):
    schedule_feature = feature.get_feature(type_key, "schedule")
    if schedule_feature:
        return schedule_feature.get_param("scheduled_states")
    return []
Exemplo n.º 5
0
 def values(self):
     param_audit_actions = feature.get_feature(self.context, "audit").p.audit_actions
     return domain.get_changes(self.context, *param_audit_action)
Exemplo n.º 6
0
def get_scheduled_states(type_key):
    schedule_feature = feature.get_feature(type_key, "schedule")
    if schedule_feature:
        return schedule_feature.get_param("scheduled_states")
    return []