Difference between revisions of "Examples: Process Handler"

From OpenKM Documentation
Jump to: navigation, search
(Created page with '{{TOCright}} __TOC__ Download and test this process definition: File:Phandler.par. {{Note|The taks will be assigned to an user called "openkm" so you need to create this us…')
(No difference)

Revision as of 17:40, 7 September 2011

Download and test this process definition: File:Phandler.par.


Nota clasica.png The taks will be assigned to an user called "openkm" so you need to create this user and log as him to see the task assignment. Also you can assing this task to another user from the process instance workflow administration.

Process image

Workflow example process handler.png

Process definition

<?xml version="1.0" encoding="UTF-8"?>
<process-definition xmlns="urn:jbpm.org:jpdl-3.2" name="phandler">
   <start-state name="inicio">
      <transition to="entrada de documentos">
         <action class="com.openkm.sample.FechaHandler"></action>
      </transition>
   </start-state>

   <task-node name="entrada de documentos">
      <task name="Recepcion de Documentos">
         <assignment actor-id="openkm"></assignment>
      </task>
      <event type="node-enter">
         <script>
            print(&quot; ent_fecha &quot;)
         </script>
      </event>
      <transition to="enviar notificacion">
         <action class=""></action>
      </transition>
   </task-node>

   <mail-node name="enviar notificacion">
      <transition to="fin"></transition>
   </mail-node>

   <end-state name="fin"></end-state>
</process-definition>

Process handlers

None.

Form definition

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE workflow-forms PUBLIC "-//OpenKM//DTD Workflow Forms 2.0//EN"
                                "http://www.openkm.com/dtd/workflow-forms-2.0.dtd">
<workflow-forms>    
  <workflow-form task="Recepcion de Documentos"> 
    <separator label="REGISTRO DE ENTRADA" name="sep_grp_entrada"/>
    
    <input label="No." name="ent_id"/>
    <input label="Fecha" name="ent_fecha" type="date" data="ent_fecha" readonly="true"/>
    <select label="Medio" name="ent_medio" type="simple">
      <option label="Correo" value="correo" selected="true"/>
      <option label="Email" value="email" />
      <option label="Fax" value="fax" />
      <option label="Mensajeria" value="mensajeria" />
      <option label="Propia Mano" value="propia mano" />
    </select>
    
    <separator label="DOCUMENTO" name="sep_doc"/>      
    
    <input label="No." name="ent_no_doc"/>
    <input label="Fecha" name="ent_fecha_doc" type="date"/>
    <textarea label="Asunto" name="ent_asunto" value=""/>
    
    <separator label="OBSERVACIONES" name="sep_obs"/>
    
    <textarea label="Observaciones" name="ent_obs" value=""/>
    <input label="Capturo" name="ent_capturo"/>
    <button label="Aceptar" name="ent_aceptar"/>
  </workflow-form>
</workflow-forms>