/**
* NOTE: you take actions away from beans metadata
* and test the contexts with global actions
*/
jbeans = new JBeans(
new JBean(TestBean.class)
.context("nofirstname")
.actions(
new JAction("goToGlobal").ajax(true)
)
.properties(
new JProperty("action.goToGlobal"),
new JProperty("-action.clear"),
new JProperty("-action.global"),
new JProperty("firstName"),
new JProperty("lastName"),
new JProperty("operand1"),
new JProperty("operand2"),
new JProperty("result"),
new JProperty("number")
),
new JBean(TestBean.class)
.context("clearfirstname")
.actions(
new JAction("clear").ajax(true)
)
.properties(
new JProperty("-action.goToGlobal"),
new JProperty("action.clear"),
new JProperty("-action.global"),
new JProperty("firstName").viewOnly(true),
new JProperty("lastName").viewOnly(true),
new JProperty("operand1"),
new JProperty("operand2"),
new JProperty("-result"),
new JProperty("-number")
),
new JBean(TestBean.class)
.context("global")
.properties(
new JProperty("-action.goToGlobal"),
new JProperty("-action.clear"),
new JProperty("firstName"),