How to configure ViewFlow, many functionality

945 Views Asked by At

How to configure ViewFlow on Django project?

I am new to Django community and I'm trying to install and test the functionality that have ViewFlow in Django

I've see the demo online but I would like to install it in my computer and test all the functionality and play with the code.

Specifically, I'd like know:

  • how to create and configure a new form
  • how to create a new flow, and assign a user specific, (because in demo, just assign a My User)
  • I've see in documentation a user interface graph to model flow but in demo I can't see any.

link demo: http://demo.viewflow.io/

1

There are 1 best solutions below

0
On

It sounds like you somehow been confused. Viewflow is the code-based workflow library, instead of clunky UI, you can construct workflow directly in code. So, it opens a way to unlimited customization and things that are common in the standard development practice like code review, code versioning, unit-testing and etc.

The best way to start with viewflow is to follow Quick Start tutorial.

Viewflow is the library for the Django Web Framework, so the django tutorial could also be helpful.

To create a new form - https://docs.djangoproject.com/en/1.10/topics/forms/

To auto-assign, a user you need to provide a callable that would return a user instance on task activation.

mytask = flow.View(
       UpdateProcessView,
       fields=['first_field', 'second_field']
   ).Assign(
        lambda activation: .. return a user here ...
   ).Next(this.next_task)

Viewflow PRO version could provide a flow visualization - http://demo.viewflow.io/workflow/shipment/shipment/chart.svg/