[jboss-user] [jBPM] - JBPM 3 : EL resolution issue
Ivan Rododendro
do-not-reply at jboss.com
Thu Nov 24 12:18:08 EST 2011
Ivan Rododendro [http://community.jboss.org/people/rododendro.ivan] created the discussion
"JBPM 3 : EL resolution issue"
To view the discussion, visit: http://community.jboss.org/message/638225#638225
--------------------------------------------------------------
Hi all,
I'm quite new to JBPM / Seam, I'm facing a problem of missing resolution of a Seam component in a jpdl transition : in a process definition we use a reference to a seam component called "etatEvenenemt", normally it works. In the transition "ok" of the node "presenter" EL cannot resolve "etatEvenement" and the property is set to "0". I have no other component with the same name. No exception is thrown
Please help, I'm getting crazy...
JBoss 4.2
Seam 2.1.1
this is the process definition :
<process-definition name="gestionEvenement" xmlns="urn:jbpm.org:jpdl-3.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="urn:jbpm.org:jpdl-3.2 http://jbpm.org/xsd/jpdl-3.2.xsd">
<start-state name="start">
<transition to="instruire">
<action
expression="#{evenementHome.changeEtat(etatEvenement.etatEvenementEnCoursDInstruction)}" />
<create-timer name="rappelInstruction" duedate="2 business days">
<action class="fr.vdm.eventsoe.commun.MailJbpmVdm">
<to>
#{evenementList.getEvenementParId(Id).instructeur.email}
</to>
<subject>
EventsOE - Rappel d'instruction pour
l'vnement
F#{evenementList.getEvenementParId(Id).code.code}
</subject>
<text>
<![CDATA[
--- MESSAGE AUTOMATIQUE ---
Le delai de 48h pour l'instruction de l'vnement F#{evenementList.getEvenementParId(Id).code.code} #{evenementList.getEvenementParId(Id).nom} est coul.
--- MESSAGE AUTOMATIQUE ---
PS: Ce mail vous a t envoy de manire
automatique. Il est inutile d'y rpondre.
]]></text>
</action>
</create-timer>
</transition>
</start-state>
<task-node name="instruire">
<event type="node-enter">
<script>
<expression>
viewId = /evenement.seam; objId = Id; objNameId =
evenementId;
</expression>
<variable name='viewId' access='write' mapped-name='viewId' />
<variable name='objId' access='write' mapped-name='objId' />
<variable name='objNameId' access='write' mapped-name='objNameId' />
</script>
</event>
<task name="Instruire un dossier" duedate="2 business days"
description="Evenement #{gestionEvenementCommun.value}">
<assignment
pooled-actors="#{ (not empty evenementHome and not empty evenementHome.instance and not empty evenementHome.instance.instructeur) ? evenementHome.instance.instructeur.username : cIHome.instance.evenement.instructeur.username }" />
</task>
<transition to="valider" name="valider">
<action
expression="#{evenementHome.changeEtat(etatEvenement.etatEvenementValidationInstruction)}" />
<cancel-timer name="rappelInstruction" />
</transition>
<transition to="completer" name="completer">
<action
expression="#{evenementHome.changeEtat(etatEvenement.etatEvenementAttente)}" />
<cancel-timer name="rappelInstruction" />
</transition>
</task-node>
<task-node name="valider">
<event type="node-enter">
<script>
<expression>
viewId = /evenement.seam; objId = Id; objNameId =
evenementId;
</expression>
<variable name='viewId' access='write' mapped-name='viewId' />
<variable name='objId' access='write' mapped-name='objId' />
<variable name='objNameId' access='write' mapped-name='objNameId' />
</script>
</event>
<task name="Valider un dossier" duedate="1 business day"
description="Evenement #{gestionEvenementCommun.value}">
<assignment pooled-actors="#{evenementHome.instance.autorite.username}" />
</task>
<transition to="diffuser" name="diffuser">
<action
expression="#{evenementHome.changeEtat(etatEvenement.etatEvenementDiffusionAuxServices)}" />
</transition>
<transition to="instruire" name="instruire">
<action
expression="#{evenementHome.changeEtat(etatEvenement.etatEvenementEnCoursDInstruction)}" />
</transition>
</task-node>
<task-node name="completer">
<event type="node-enter">
<script>
<expression>
viewId =/ajoutCI.seam; objNameId =cIId;
</expression>
<variable name='viewId' access='write' mapped-name='viewId' />
<variable name='objNameId' access='write' mapped-name='objNameId' />
</script>
</event>
<task name="Completer un dossier" duedate="15 business days"
description="Evenement #{gestionEvenementCommun.value}">
<assignment pooled-actors="#{identity.username}" />
</task>
<transition to="instruire" name="instruire">
<action
expression="#{cIHome.instance.evenement.setEtat(etatEvenement.etatEvenementEnCoursDInstruction)}" />
</transition>
</task-node>
<task-node name="diffuser">
<event type="node-enter">
<create-timer duedate="15 business days" transition="compiler" />
</event>
<task name="Diffusion du dossier" />
<transition to="compiler" name="compiler">
<action
expression="#{avisHome.changeEtat(etatEvenement.etatEvenementAttentePresentation)}" />
</transition>
</task-node>
<task-node name="compiler">
<event type="node-enter">
<script>
<expression>
viewId =/compilerPrescriptions.seam; objNameId
=evenementId; objId = Id;
</expression>
<variable name='viewId' access='write' mapped-name='viewId' />
<variable name='objNameId' access='write' mapped-name='objNameId' />
<variable name='objId' access='write' mapped-name='objId' />
</script>
</event>
<task name="Compiler les prescriptions" duedate="1 business days"
description="Evenement #{gestionEvenementCommun.value}">
<assignment pooled-actors="#{identity.username}" />
</task>
<transition to="presenter" name="presenter">
<action
expression="#{compilationHome.changeEtat(etatEvenement.etatEvenementValidationCabinetMaire)}" />
</transition>
</task-node>
<task-node name="presenter">
<event type="node-enter">
<script>
<expression>
viewId =/saisirDecisionCab.seam; objNameId
=evenementId;
objId = Id;
</expression>
<variable name='viewId' access='write' mapped-name='viewId' />
<variable name='objNameId' access='write' mapped-name='objNameId' />
<variable name='objId' access='write' mapped-name='objId' />
</script>
</event>
<task name="Saisir une decision du cabinet" duedate="5 business days"
description="Evenement #{gestionEvenementCommun.value}">
<assignment pooled-actors="#{identity.username}" />
</task>
<transition to="Ok" name="Ok">
<action
expression="#{saisirDecisionCabHome.instance.setEtat(etatEvenement.etatEvenementAvisFavorable)}" />
</transition>
<transition to="NOk" name="NOk">
<action
expression="#{saisirDecisionCabHome.instance.setEtat(etatEvenement.etatEvenementAvisDefavorable)}" />
</transition>
</task-node>
<task-node name="Ok">
<transition to="termine" />
<transition to="presenter"></transition>
</task-node>
<task-node name="NOk">
<transition to="termine" />
<transition to="presenter"></transition>
</task-node>
<end-state name="termine" />
<event type="process-start">
<action expression="#{evenementHome.processStart}" />
<!-- <action expression="#{evenementHome.processStart}" /> <script name="affecterVars">
<expression> evt = executionContext.getVariable("Evenement"); id = executionContext.getVariable("Id");
ins = executionContext.getVariable("Instructeur"); dat = executionContext.getVariable("DateFin");
</expression> <variable name='Evenement' access='write' mapped-name='evt'
/> <variable name='Instructeur' access='write' mapped-name='ins' /> <variable
name='Id' access='write' mapped-name='id' /> <variable name='DateFin' access='write'
mapped-name='dat' /> </script> -->
</event>
</process-definition>
this is the seam component which (sometimes) is not resolved.
/**
* Utilisé de partout pour les constantes qu'elle contient, on a decidé ivan et moi de la garder et de la renomer.
* @author OYA
* 25/10/2011
*/
@Name("etatEvenement")
@Scope(ScopeType.STATELESS)
public class EtatEvenement implements Serializable {
public static final Integer etatEvenementInitialise = 0;
public static final Integer etatEvenementHorsPerimetre = 1;
public static final Integer etatEvenementHorsDelai = 2;
public static final Integer etatEvenementEnCoursDInstruction = 3;
public static final Integer etatEvenementDiffusionAuxServices = 4;
public static final Integer etatEvenementValidationCabinetMaire = 5;
public static final Integer etatEvenementAvisFavorable = 6;
public static final Integer etatEvenementAvisDefavorable = 7;
public static final Integer etatEvenementAvisReserve = 8;
public static final Integer etatEvenementAnnule = 9;
public static final Integer etatEvenementRefuse = 10;
public static final Integer etatEvenementTermine = 11;
public static final Integer etatEvenementAttente = 12;
public static final Integer etatEvenementValidationInstruction = 13;
public static final Integer etatEvenementAttentePresentation = 14;
public EtatEvenement(){
super();
}
/**
* @return the etatEvenementInitialise
*/
public Integer getEtatEvenementInitialise() {
return etatEvenementInitialise;
}
/**
* @return the etatEvenementHorsPerimetre
*/
public Integer getEtatEvenementHorsPerimetre() {
return etatEvenementHorsPerimetre;
}
/**
* @return the etatEvenementHorsDelai
*/
public Integer getEtatEvenementHorsDelai() {
return etatEvenementHorsDelai;
}
/**
* @return the etatEvenementEnCoursDInstruction
*/
public Integer getEtatEvenementEnCoursDInstruction() {
return etatEvenementEnCoursDInstruction;
}
/**
* @return the etatEvenementDiffusionAuxServices
*/
public Integer getEtatEvenementDiffusionAuxServices() {
return etatEvenementDiffusionAuxServices;
}
/**
* @return the etatEvenementValidationCabinetMaire
*/
public Integer getEtatEvenementValidationCabinetMaire() {
return etatEvenementValidationCabinetMaire;
}
/**
* @return the etatEvenementAvisFavorable
*/
public Integer getEtatEvenementAvisFavorable() {
return etatEvenementAvisFavorable;
}
/**
* @return the etatEvenementAvisDefavorable
*/
public Integer getEtatEvenementAvisDefavorable() {
return etatEvenementAvisDefavorable;
}
/**
* @return the etatEvenementAvisReserve
*/
public Integer getEtatEvenementAvisReserve() {
return etatEvenementAvisReserve;
}
/**
* @return the etatEvenementAnnule
*/
public Integer getEtatEvenementAnnule() {
return etatEvenementAnnule;
}
/**
* @return the etatEvenementRefuse
*/
public Integer getEtatEvenementRefuse() {
return etatEvenementRefuse;
}
/**
* @return the etatEvenementTermine
*/
public Integer getEtatEvenementTermine() {
return etatEvenementTermine;
}
/**
* @return the etatEvenementAttente
*/
public Integer getEtatEvenementAttente() {
return etatEvenementAttente;
}
/**
* @return the etatEvenementValidationInstruction
*/
public Integer getEtatEvenementValidationInstruction() {
return etatEvenementValidationInstruction;
}
public Integer getEtatEvenementAttentePresentation() {
return etatEvenementAttentePresentation;
}
}
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/638225#638225]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20111124/4b2a910d/attachment-0001.html
More information about the jboss-user
mailing list