Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Process definition clarification
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  2 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
emc_lab  
View profile   Translate to Translated (View Original)
 More options May 28 2012, 8:59 pm
From: emc_lab <emclab2...@gmail.com>
Date: Mon, 28 May 2012 17:59:54 -0700 (PDT)
Local: Mon, May 28 2012 8:59 pm
Subject: Process definition clarification
I am a newbie, went through the ruote wiki documentation, but have a
question. If I have the below process definition, I was expecting to
have 2 concurrent participants that approve a given request ('ceo' and
approver), but it looks like there is a 3rd concurrent workflow show
under (ruote process using ruote_kit) as below. Not sure what I make
of this 3rd concurrent workflow. Thanks for any help

3rd Concurrent workflow:
[["participant", {"ceo"=>nil,
"task"=>"approve_business_trip_application_form", "if"=>"2.2 > 0.01"},
[]], ["approver", {"task"=>"approve_business_trip_application_form"},
[]]]

Process Definition:
   PDEF_BUSINESS_TRIP_REQUEST = Ruote.process_definition :name =>
'business_trip_request', :revision => '0.1' do
    cursor do
      requestor :task => 'request_business_trip_application_form'
      concurrence do
        participant 'ceo', :if => '${f:requested_stipend}  > $
{v:amount_supervised}'
        participant approver :task =>
'approve_business_trip_application_form'
      end
      rewind :if => '${forms_not_ok}'
      cancel_process  :if => '${trip_request_denied}'
      cursor do
        requestor :task => 'business_trip_report_form'
        reviewer :task => 'review_business_trip_application_form'
        rewind :if => '${incomplete_report}'
        archiver
      end
    end
  end


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
John Mettraux  
View profile  
 More options May 28 2012, 9:11 pm
From: John Mettraux <jmettr...@gmail.com>
Date: Tue, 29 May 2012 10:11:31 +0900
Local: Mon, May 28 2012 9:11 pm
Subject: Re: [ruote:3560] Process definition clarification

On Mon, May 28, 2012 at 05:59:54PM -0700, emc_lab wrote:
> I am a newbie, went through the ruote wiki documentation, but have a
> question. If I have the below process definition, I was expecting to
> have 2 concurrent participants that approve a given request ('ceo' and
> approver), but it looks like there is a 3rd concurrent workflow show
> under (ruote process using ruote_kit) as below. Not sure what I make
> of this 3rd concurrent workflow. Thanks for any help

Hello Emc,

welcome to the ruote mailing list.

There is no ruote wiki, I guess you're talking about the regular
documentation site ;-)

I was a bit confused when you talked about "3rd concurrent workflow", but I
think you mean "3rd concurrent branch".

I've put your process definition in a standalone script and ran it:

---8<---
require 'pp'
require 'ruote'

pdef = Ruote.process_definition :name => 'business_trip_request', :revision => '0.1' do
  cursor do
    requestor :task => 'request_business_trip_application_form'
    concurrence do
      participant 'ceo', :if => '${f:requested_stipend}  > ${f:amount_supervised}'
      participant approver :task => 'approve_business_trip_application_form'
    end
    rewind :if => '${forms_not_ok}'
    cancel_process  :if => '${trip_request_denied}'
    cursor do
      requestor :task => 'business_trip_report_form'
      reviewer :task => 'review_business_trip_application_form'
      rewind :if => '${incomplete_report}'
      archiver
    end
  end
end

pp pdef
--->8---

And effectively, it's outputting something like:

---8<---
...
    ["concurrence",
     {},
     [["participant",
       {"ceo"=>nil, "if"=>"${f:requested_stipend}  > ${f:amount_supervised}"},
       []],
      ["approver", {"task"=>"approve_business_trip_application_form"}, []],
      ["participant",
       {"[[\"participant\", {\"ceo\"=>nil, \"if\"=>\"${f:requested_stipend}  > ${f:amount_supervised}\"}, []], [\"approver\", {\"task\"=>\"approve_business_trip_application_form\"}, []]]"=>
         nil},
       []]]],
...
--->8---

You can fix that by quoting "approver" in your process definition:

---8<---
#...
    concurrence do
      participant 'ceo', :if => '${f:requested_stipend}  > ${f:amount_supervised}'
      participant 'approver', :task => 'approve_business_trip_application_form'
    end
#...
--->8---

Ruby is very permissive...

Kind regards,

--
John Mettraux - http://lambda.io/jmettraux


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »