"pete.muir(a)jboss.org" wrote : The process isn't created until after the
method completes so during the method the processId isn't available.
Any workaround idea for this? I must to retriew the processid from the db throught a
variable that put in the context like dvd example of seam
| ...
| public String cancelOrder() {
|
| em.refresh(order);
|
| if ( order.getStatus() != Status.OPEN ) {
| return null;
| }
|
| order.setStatus(Status.CANCELLED);
|
| JbpmContext context = ManagedJbpmContext.instance();
|
| ProcessInstance pi = (ProcessInstance) context.getSession()
| .createQuery("select pi from LongInstance si join si.processInstance
pi " +
| "where si.name = 'orderId' and si.value =
:orderId")
| .setLong("orderId", order.getOrderId())
| .uniqueResult();
|
| pi.signal("cancel");
|
| context.save(pi);
|
| return findOrders();
| }
| ...
|
that i found in the ShowOrdersAction class?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4059584#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...