[jboss-jira] [JBoss JIRA] (DROOLS-1838) Referencing condition literals in action columns in Web based decision table

Jozef Marko (Jira) issues at jboss.org
Wed Apr 10 09:15:07 EDT 2019


     [ https://issues.jboss.org/browse/DROOLS-1838?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jozef Marko updated DROOLS-1838:
--------------------------------
    Attachment: Screenshot from 2019-04-10 15-14-50.png


> Referencing condition literals in action columns in Web based decision table
> ----------------------------------------------------------------------------
>
>                 Key: DROOLS-1838
>                 URL: https://issues.jboss.org/browse/DROOLS-1838
>             Project: Drools
>          Issue Type: Feature Request
>          Components: Guided Decision Table Editor
>    Affects Versions: 5.5.0.Final
>            Reporter: Roman Novak
>            Assignee: Michael Anstis
>            Priority: Major
>         Attachments: Screenshot from 2019-04-10 15-14-50.png
>
>
> The use case is to avoid reduncancy in entering data in the web based decision table.
> The redundance occurs, when a "not" condition is used in the LHS of a rule, and exactly the entered condition (in the example rule below it is "demo") should be used/referenced on the RHS of the rule.
> The solution proposal is:
> * it is already possible to reference binding variables in Guvnor decision tables via "=". e.g. set the default value of an action column by "=$p.name" (again with the example below in mind).l
> * it should be possible to reference the actual column content via the mandatory "Column header (description)" field in a way, so that during the generation of the rule code the content of the column in the editor is placed into the action field.
> * suggestion for (de-)referencing the column: ={<column header>}
> Example rule to illustrate the problem:
> declare Address
>    streetName : String
> end
>  
> declare Person
>     name : String
>  end
>  
> rule "Using a declared Type"
> when
>     $p : Person( name == "Bob" )
>      not Address(streetName  == "demo")
> then
>     // if the address does not exist, we create it... (just for example)
>     Address addr = new Address();
>    // how can  the streetName "demo" from above be referenced ? in a normal rule it is not possible! (scope delimiter "not")
>     addr.setStreetName("demo");
>      insert( addr );
> end



--
This message was sent by Atlassian Jira
(v7.12.1#712002)


More information about the jboss-jira mailing list