16
Guided tour of a work flow solution in Joomla! 1.7 and ChronoForms v4 Russell Searle Principal Consultant, Psicom Melbourne Joomla! User Group 25 Jan 2012

ChronoForms work flow application

Embed Size (px)

DESCRIPTION

Guided tour of a work flow application built with ChronoForms v4 on Joomla! 1.7. Presentation for Melbourne Joomla! User Group on 25 Jan 2012.

Citation preview

Page 1: ChronoForms work flow application

Guided tour of a work flow solution

in Joomla! 1.7 and ChronoForms v4

Russell SearlePrincipal Consultant, Psicom

Melbourne Joomla! User Group

25 Jan 2012

Page 2: ChronoForms work flow application

Agenda

• Initial business requirement and preliminary solution• Flying tour of ChronoForms• Building a simple form in ChronoForms• Complete business requirements and solution design• Final HR Leave Application product and code

Page 3: ChronoForms work flow application

Initial business requirement

• Provide on-line forms for registered users to enter applications for annual, sick and long service leave• For each type of leave, users can select one or more of a

few payment options• Mail notifications of new leave applications:• Acknowledgement to the applicant• Notify the Payroll Administrator, who will extract and maintain

leave details on an Excel worksheet

Page 4: ChronoForms work flow application

Preliminary solution

• Single RSForm! Pro form:• Slick, comprehensive form-mail builder• Easy, fast development• Good enough reporting, through back-end access• Optionally maps to custom database tables

… but …• Could not retrieve/update a record• Could not support a business process work flow

Page 5: ChronoForms work flow application

What is a work flow application?

• Process that can be drawn on a flow diagram• Often modelled in BPM tools• Two major features:• State variables• System-produced email messages

• User interfaces:• Email client• Active views• Dashboards

Page 6: ChronoForms work flow application

Work flow patterns

• Business process automation• Forums / Discussion• Authoring / publication• Document library / Q&A• Team room• Project collaboration• Wiki• e-Learning• Mail-in databases

Page 7: ChronoForms work flow application

ChronoForms v4

• Drag and drop form builder• Wizards for basic and complex forms• Basic set of configurable input elements, plus custom element• Extensive set of configurable form actions• Custom callable events• Pluggable architecture• Extremely customisable and programmable• Best for back-end developers: HTML, PHP, JavaScript, CSS, AJAX• Developed by Max (ChronoMan), supported by Max and Bob Janes

(author of Packt book)

Page 8: ChronoForms work flow application

Two types of forms CCK

• “Vertical” data storage• Multiple physical records per logical record• Fixed table and column names, fixed key and indexes

Form builder RSForm! ProTable #__reform_submission_values

SubmissionValueId FormId SubmissionId FieldName FieldValue1 1 1 name Joe Blow2 1 1 email joe@[email protected] 1 1 address1 1 Fred Street4 1 1 address2 5 1 1 suburb Carlton6 1 1 state Vic7 1 1 postcode 30848 1 1 country AU9 1 1 phone 03 5555 1234

Page 9: ChronoForms work flow application

Two types of forms CCK

• “Horizontal” data storage• One physical record per logical record• Custom table and column names, custom key and indexes

Form builder ChronoFormsTable #__chronoforms_data_mailusers

name email address1 address2 suburb state postcode country phoneJoe Blow joe@[email protected] 1 Fred Street Carlton Vic 3084 AU 03 5555 1234

Page 10: ChronoForms work flow application

Two types of forms CCK

Feature “Vertical” storage “Horizontal” storage

Flexibility Very flexible Rigid structure

Adaptability Highly adaptable Slow to adapt

Extensibility Easy, fast extension Painstaking extension

Efficiency, performance ? OK for small-medium DBs High performance

Scalability Limited, constrained Practically unlimited

Joins and views Hopeless Practically unlimited

Report production Poor reporting support Strong reporting features

Processing complexity Limited to simple apps Highly complex DBs/apps

Data typing Weak typing Strong typing

Page 11: ChronoForms work flow application

Building a simple form

Demonstration

Page 12: ChronoForms work flow application

Complete business requirementsThe new online leave application process works as follows:•You must log in to the intranet to gain access to online Leave Application facilities.•Begin the leave application process by clicking the Apply for Leave link in any one of:

• The Business Systems module• The Leave Applications - Apply for Leave option in the HR drop-down menu from the top menu bar• The Leave Applications - Apply for Leave option in the blue HR section menu in the left sidebar

•First you will be asked which type of leave you are applying for: Annual, Sick, Long Service or Bereavement leave.•If you are a manager who has the authority to submit leave applications on behalf of your staff, you will also be asked whether you are submitting the leave application for yourself, or on behalf of one of your staff members.•Fill out and submit the Leave Application form. Required values have labels marked with *. There are pop-up calendars for the starting and ending leave dates. Please be sure to enter the correct number of working days off. You must apply for a minimum of one day's leave.•For sick leave applications, please upload a scanned copy of your doctor’s certificate. For bereavement applications, please identify your relationship to your deceased relative.•When you submit the form, three e-mails are sent:

• You receive an acknowledgement e-mail at your registered e-mail address.• The Payroll Administrator will receive a request to check and confirm your available balance of the type of leave you have requested.• The manager who approves your leave applications will receive a copy of your application, for planning purposes.

•When the Payroll Administrator checks your leave balance, another e-mail is sent to the manager who approves your leave applications:• Your manager will be asked to review and approve your leave application. The manager may refuse your application, but if so, he or she must

record a reason.• If your manager is unable to review your leave application for some reason, the Payroll Administrator can review and update your application on

behalf of your manager.•When your manager reviews and updates your leave application, two more e-mails are sent:

• You receive an e-mail advising the manager's decision. If your leave application is refused, please discuss the matter with your manager.• If your application is for Long Service leave, the Managing Director will also receive a copy of your manager's decision on your leave application.• The e-mail to you is also copied to the Payroll Administrator, for management purposes.

Page 13: ChronoForms work flow application

Final solution design

• Actors• Applicant• Approver• Delegate• PayrollAdmin• ManagingDirector

• Entities = Tables• LeaveDefinition• LeaveRule• LeaveApplication

• Relations• LeaveApplication -> LeaveDefinition• LeaveApplication -> LeaveRule

• Major Attributes• LeaveDefinition

• name, value, description• LeaveRule

• rule, factors x 4, results x 2• LeaveApplication

• applicantType• leaveType

• leaveOption

• stage• checkBalance• approved• All actors• etc …

Page 14: ChronoForms work flow application

Final solution design

Leave Application Forms List

Stage Process Seq Name Type Use Case Next Seq

Control 1 LeaveDefinition Form Defines entity-level parameters for Leave Application forms 2, 3

2 LeaveDefinitionList View List Leave Definitions for add or update 3

Control 3 LeaveRule Form Defines combination rules to populate LeaveApplication forms 4, 5

4 LeaveRuleList View List Leave Rules for add or update 5

Apply 5 LeaveApplicationMaster Switch Present Approver options or Applicant Leave Type option 6 or 7

6 LeaveApproverOptions Form Approver chooses Leave Type and either LeaveApplicationSelf or LeaveApplicationProxy 8 or 9

7 LeaveApplicantOptions Form Applicant chooses Leave Type 9

9 LeaveApplicationSelf Form Leave Application for Self 10

8 LeaveApplicationProxy Form Leave Application for Employee 10

CheckBalance 10 LeaveCheckBalance Form Payroll Administrator approves available Leave Balance 11, 12

11 LeaveCheckBalanceList View Payroll Administrator reviews and updates all Leave Applications awaiting Leave Balance approval 12

ApproveLeave 12 LeaveApproval Form Approver approves Leave Application 13, 14

13 LeaveApprovalList View Approver reviews and updates all Applications awaiting his/her Leave approval 14

Control 14 LeaveApplicationAll Form Payroll Administrator updates any Leave Application 15

15 LeaveList View Payroll Administrator reviews and updates all Leave Applications end

Page 15: ChronoForms work flow application

Final HR Leave Application product

Demonstration

Page 16: ChronoForms work flow application

References

• ChronoForms product site:• http://www.chronoengine.com/

• Bob Janes’ support site:• http://greyhead.net/

• Bob Janes’ ChronoForms 3.1 Cookbook:• http://www.packtpub.com/chronoforms-31-joomla-site-cookbook/book

• MooTools:• http://mootools.net/

• FormCheck class:• http://mootools.floor.ch/docs/formcheck/files/formcheck-js.html