server/migractions.py
changeset 5556 9ab2b4c74baf
parent 5552 11175c77be9c
child 5558 afd1face1faf
equal deleted inserted replaced
5555:a64f48dd5fe4 5556:9ab2b4c74baf
  1155         tr = self._cw.entity_from_eid(treid)
  1155         tr = self._cw.entity_from_eid(treid)
  1156         tr.set_transition_permissions(requiredgroups, conditions, reset)
  1156         tr.set_transition_permissions(requiredgroups, conditions, reset)
  1157         if commit:
  1157         if commit:
  1158             self.commit()
  1158             self.commit()
  1159 
  1159 
  1160     @deprecated('[3.5] use entity.fire_transition("transition") or entity.change_state("state")',
  1160     @deprecated('[3.5] use iworkflowable.fire_transition("transition") or '
  1161                 stacklevel=3)
  1161                 'iworkflowable.change_state("state")', stacklevel=3)
  1162     def cmd_set_state(self, eid, statename, commit=False):
  1162     def cmd_set_state(self, eid, statename, commit=False):
  1163         self._cw.entity_from_eid(eid).change_state(statename)
  1163         self._cw.entity_from_eid(eid).cw_adapt_to('IWorkflowable').change_state(statename)
  1164         if commit:
  1164         if commit:
  1165             self.commit()
  1165             self.commit()
  1166 
  1166 
  1167     # CWProperty handling ######################################################
  1167     # CWProperty handling ######################################################
  1168 
  1168