S
S
Stepan Yudin2015-01-10 14:42:30
Ruby on Rails
Stepan Yudin, 2015-01-10 14:42:30

Implementing a document life cycle (a la IBM Lotus Workflow)?

Good day everyone!
Suppose there is a workflow system written in RoR. But there is no key feature - the implementation of the life cycle of documents (creation - various approvals by various users - the final approval of the document).
Example:

  • User A creates a new document (class object), fills it with data, and saves it. Here he has a choice - to return to editing or send the document for approval to employee B.
  • Employee B, in turn, has access to the document. He can make changes, return it to the initiator for approval, or send it further (for example, to employee B).
  • And so on - from user to user.

It seems to be nothing special ... BUT! Document review routes can be very complex (for example, parallel branches, when a document is cloned and the clone lives separately for some time, until the moment of reunification, the so-called join).
I have experience with IBM Lotus, where there is a Workflow tool that allows you to implement the above. You can draw flowcharts and publish them to the application.
I want the same thing on the rails. Perhaps there is some kind of gem for these purposes?
And a tool that allows you to draw diagrams and export to an open format (XML, JSON, etc.) so that a rails application can process it?
Thank you very much in advance!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
vsuhachev, 2015-01-10
@stepan_sib

Drawing is unlikely, in such cases it is usually customary to write DSL in ruby. Google gems for implementing state machines

A
Alexey P, 2015-01-11
@ruddy22

habr
state machine
aasm

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question