Changeset a3227e7 in flexoentity
- Timestamp:
- 10/27/25 10:56:45 (3 months ago)
- Branches:
- master
- Children:
- 52ccac6
- Parents:
- 3bad43e
- File:
-
- 1 edited
-
flexoentity/flexo_entity.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
flexoentity/flexo_entity.py
r3bad43e ra3227e7 307 307 def publish(self): 308 308 """ 309 Movefrom APPROVED or APPROVED_AND_SIGNED to PUBLISHED.309 Move from APPROVED or APPROVED_AND_SIGNED to PUBLISHED. 310 310 311 311 Uses allowed_transitions() to verify legality, … … 375 375 case _: 376 376 return [] 377 378 def apply_state_change(self, new_state): 379 """ 380 High-level dispatcher used by GUI actions. 381 Safely applies the requested state transition by invoking 382 the corresponding FlexoEntity method if available. 383 """ 384 385 if self.state == new_state: 386 return 387 if new_state == EntityState.APPROVED: 388 self.approve() 389 elif new_state == EntityState.SIGNED: 390 self.sign() 391 elif new_state == EntityState.PUBLISHED: 392 self.publish() 393 elif new_state == EntityState.OBSOLETE: 394 self.obsolete() 395 else: 396 raise RuntimeError(f"No handler for state transition to {new_state.name}")
Note:
See TracChangeset
for help on using the changeset viewer.
