ChangeStateGQL
RuleRules are designed to be building blocks for workflow logic.
Changed on:
13 Nov 2023
Overview
Change the state of the {event.entityType} to {status} using GraphQL.| Plugin Name | Inventory Reference Module |
|---|---|
| Namespace | [[account.id]].globalinventory |
- Product Catalogue workflow
- Inventory Catalogue workflow
- Control Group workflow
- Virtual Catalogue workflow
UI Description
Change the state of the {event.entityType} to {status} using GraphQL.
Accepts
- CATEGORY
- PRODUCT
- INVENTORY_POSITION
- INVENTORY_QUANTITY
- VIRTUAL_POSITION
- ORDER
- FULFILMENT
- ARTICLE
- CONSIGNMENT
- FULFILMENT_OPTIONS
- FULFILMENT_PLAN
- WAVE
- LOCATION
- CONTROL
Actions
- This rule doesn't produce any output actions.
Rule parameters
| Parameter | Description |
| status | The new state to apply to the entity |
Event attributes
Not Applicable for this rule.
Exceptions
- This rule throws an IllegalArgumentException when:
- the
`entityId`is empty if it's a legacy orchestrated entity - the
`entityRef`is empty if it's a non-legacyOrchestrated entity - the
`retailerId`is empty if it's a RETURN_ORDER/RETURN_FULFILMENT - the
`rootEntityRef`is empty if it's a RETURN_FULFILMENT
- the
- This rule throws a general RubixException with code 422 when the incoming entity is not supported.
Configuration example
1{
2 "name": "FLUENTRETAIL.globalinventory.ChangeStateGQL",
3 "props": {
4 "status": "ACTIVE"
5 }
6}Detailed Technical Description
Based on the type of the incoming entity, this rule either calls GQL or REST API to update the status of the entity to the new
`{status}` given in the input parameters.