You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
INSERT_UPDATE Employee;UID[unique=true];$writableCatalogVersions;$readableCatalogVersions;description;name;groups(uid);password
;productmanager_wf1;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 1. Can access workflow actions and workflows;Workflow Product Manager Demouser 1;productmanagergroup;1234
;productmanager_wf2;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 2. Can access workflow actions and workflows;Workflow Product Manager Demouser 2;productmanagergroup;1234
;productmanager_wf3;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 3. Can access workflow actions and workflows;Workflow Product Manager Demouser 3;productmanagergroup;1234
INSERT_UPDATE WorkflowTemplate;code[unique=true];name[lang=en];owner(uid);description[lang=en];activationscript
;SampleWorkflow;Product Workflow;admin;This is an exemplary workflow template which is started when a product has been changed in the platform i.e. added or edited. Adding or editing a new product is usually followed by further steps to take. These steps are associated with this workflow template exemplarily. The
newly added or edited product will be assigned to the respective workflow instance as an attachment.;*// this script will create a new workflow when a product is created or saved and its approval status is check
(
// create new item
(action.equals(""create"") &&
// initialValues must be set
initialValues != null &&
// approvalStatus must be set
initialValues.get(""approvalstatus"") != null &&
// approvalStatus must be set to ""check""
initialValues.get(""approvalstatus"").getCode().equals(""check"")
) ||
// save item
(action.equals(""save"") &&
// currentValues must be set
currentValues != null &&
// approvalStatus must be set
currentValues.get(""approvalstatus"") != null &&
// approvalStatus must be set to ""check""
currentValues.get(""approvalstatus"").getCode().equals(""check""))) &&
// created or saved item is a product
typeService.isAssignableFrom(""Product"", itemType.getCode())"
INSERT_UPDATE WorkflowActionTemplate;code[unique=true];name[lang=en];description[lang=en];principalAssigned(uid);workflow(code)[unique=true];sendEmail;emailAddress;renderTemplate(code);actionType(code)
;SampleActionl;Categorization;Please assign the attached product to the category structure.;productmanager_wfl;SampleWorkflow;false;wf1@hybris.de;;start
;SampleAction2;Pricing;Please price the attached product.;productmanager_wf2;SampleWorkflow;false;w2@hybris.de;;start
;SampleAction3;Translation;Please translate the existing product description to all available languages.;productmanager_wf3;SampleWorkflow;false;w3@hybris.de;;start
;SampleAction4;Validation of Categorization;Please validate the result of the categorization.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction5;Validation of Pricing;Please validate the result of the pricing.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction6;Validation of Translation;Please validate the result of the translation.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction7;End;Here the workflow ends.;productmanagergroup;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;end
INSERT_UPDATE WorkflowDecisionTemplate;code[unique=true];name[lang=en];actionTemplate(code);description[allownull=true]
;SampleDecisionl;finished Categorization;SampleActionl
;SampleDecision2;finished Pricing;SampleAction2
;SampleDecision3;finished Translation;SampleAction3
;SampleDecision4;Validation of Categorization successful;SampleAction4
;SampleDecision5;Validation of Pricing successful;SampleAction5
;SampleDecision6;Validation of Translation successful;SampleAction6
;SampleDecision7;reject Categorization;SampleAction4
;SampleDecision8;reject Pricing;SampleAction5
;SampleDecision9;reject Translation;SampleAction6
Set catalog read / write access for users and describe the users
$writableCatalogVersions=writableCatalogVersions(catalog(id),version)
$readableCatalogVersions=readableCatalogVersions(catalog(id),version)
INSERT_UPDATE Employee;UID[unique=true];$writableCatalogVersions;$readableCatalogVersions;description;name;groups(uid);password
;productmanager_wf1;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 1. Can access workflow actions and workflows;Workflow Product Manager Demouser 1;productmanagergroup;1234
;productmanager_wf2;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 2. Can access workflow actions and workflows;Workflow Product Manager Demouser 2;productmanagergroup;1234
;productmanager_wf3;electronicsProductCatalog:Staged;electronicsProductCatalog:Staged;Workflow Product manager demouser 3. Can access workflow actions and workflows;Workflow Product Manager Demouser 3;productmanagergroup;1234
INSERT_UPDATE WorkflowTemplate;code[unique=true];name[lang=en];owner(uid);description[lang=en];activationscript
;SampleWorkflow;Product Workflow;admin;This is an exemplary workflow template which is started when a product has been changed in the platform i.e. added or edited. Adding or editing a new product is usually followed by further steps to take. These steps are associated with this workflow template exemplarily. The
newly added or edited product will be assigned to the respective workflow instance as an attachment.;*// this script will create a new workflow when a product is created or saved and its approval status is check
(
// create new item
(action.equals(""create"") &&
// initialValues must be set
initialValues != null &&
// approvalStatus must be set
initialValues.get(""approvalstatus"") != null &&
// approvalStatus must be set to ""check""
initialValues.get(""approvalstatus"").getCode().equals(""check"")
) ||
// save item
(action.equals(""save"") &&
// currentValues must be set
currentValues != null &&
// approvalStatus must be set
currentValues.get(""approvalstatus"") != null &&
// approvalStatus must be set to ""check""
currentValues.get(""approvalstatus"").getCode().equals(""check""))) &&
// created or saved item is a product
typeService.isAssignableFrom(""Product"", itemType.getCode())"
INSERT_UPDATE WorkflowActionTemplate;code[unique=true];name[lang=en];description[lang=en];principalAssigned(uid);workflow(code)[unique=true];sendEmail;emailAddress;renderTemplate(code);actionType(code)
;SampleActionl;Categorization;Please assign the attached product to the category structure.;productmanager_wfl;SampleWorkflow;false;wf1@hybris.de;;start
;SampleAction2;Pricing;Please price the attached product.;productmanager_wf2;SampleWorkflow;false;w2@hybris.de;;start
;SampleAction3;Translation;Please translate the existing product description to all available languages.;productmanager_wf3;SampleWorkflow;false;w3@hybris.de;;start
;SampleAction4;Validation of Categorization;Please validate the result of the categorization.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction5;Validation of Pricing;Please validate the result of the pricing.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction6;Validation of Translation;Please validate the result of the translation.;productmanager;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;normal
;SampleAction7;End;Here the workflow ends.;productmanagergroup;SampleWorkflow;true;productmanagergroup@hybris.de;productValidation;end
INSERT_UPDATE WorkflowDecisionTemplate;code[unique=true];name[lang=en];actionTemplate(code);description[allownull=true]
;SampleDecisionl;finished Categorization;SampleActionl
;SampleDecision2;finished Pricing;SampleAction2
;SampleDecision3;finished Translation;SampleAction3
;SampleDecision4;Validation of Categorization successful;SampleAction4
;SampleDecision5;Validation of Pricing successful;SampleAction5
;SampleDecision6;Validation of Translation successful;SampleAction6
;SampleDecision7;reject Categorization;SampleAction4
;SampleDecision8;reject Pricing;SampleAction5
;SampleDecision9;reject Translation;SampleAction6
new Workflow Model
insert_update WorkflowActionTemplateLinkTemplateRelation;source(code)[unique=true];target(code)[unique=true];andConnectionTemplate;qualifier
;SampleDecisionl;SampleAction4;false;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision2;SampleAction5;false;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision3;SampleAction6;false;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision4;SampleAction7;true;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision5;SampleAction7;true;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision6;SampleAction7;true;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision7;SampleActionl;false;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision8;SampleAction2;false;WorkflowActionTemplateLinkTemplateRelation
;SampleDecision9;SampleAction3;false;WorkflowActionTemplateLinkTemplateRelation
The text was updated successfully, but these errors were encountered: