Showing results for 
Search instead for 
Did you mean: 

May Mission - Universal task form

Hi all,

I'll provide an example how I evolved to design task approval form.

it's an ordinary requirement, that approver needs (at least) to see what's the content of an item he/she should to response the task for, and the best from within task approval form itself.

the requirement is of course very valid from end users point of view, but from developer's point of view is a nightmare.

typically, one need to develop as many forms as there are decision steps/levels + 1 entry/view/edit form (despite there are usually very slight differences  among the forms).

yeah, we can reuse form design through export/import or to share form for copied/pasted workflow actions. but that I see (just) as a good start point.

the more decision steps/levels are there in place and the later in development/maintenance process a change (or a bug) arise, the (exponentially) more effort it means for developer to implement it. that's the nightmare I meant above.

so, I decided to develop and use kind of 'universal' task approval form.

my form looks like this:

- upper part relates to task itself. usually 4 controls are enough to response the task

               - outcome/decision

               - delegate

               - approver's comments

               - link to item's edit form

- lower part relates to the item ('Request overview'  on picture below), the task is for. it's based on 'Page Viewer' control which point to item's view form link.

I just had to play a bit with how to hide ribbon and all the navigation bars/links within page view control.

Update 05.09.2016:

finally I came up with following piece of code that needs to be added into the form being shown in PageViewer control. Note PageViewer control on task form has to have assigned EmbededPageViewer class.

Update 06.10.2016:

code updated to hide submit/cancel buttons in embeeded PageViewer control

/* ***************************************************************

   following code has to be included in New/Edit form to disable inner ribbon & navigation bar                   
   if form is to be shown in Embeeded page viewer
   **************************************************************** */

NWF$(document).ready(function() {   

       /* disable navigation toolbars&links if embeeded in PgaeViewer */
       if (parent.document.getElementsByClassName("EmbededPageViewer").length > 0 ){      

Note, if you follow the same item field's and variable's namings (outcome, comments,...) no change is needed on the form design, so it's easily reusable over and over.

that way I as well managed to get around usual problem of giving approver access to item's attachments from within task form. the attachment links are simply OOTB rendered within embedded item's view form.

of course there are cases when end users insist on some really specific feature to be implemented on task form (in my example below it's 'Notify approver about..." checkbox). I just reused my 'universal' form and added one another control. still I saved plenty of work designing and maintaining a separate form with all the item's fields, rules, JS code, user permissions ...

I just wish

- this kind of functionality becomes once native somehow (I mean to design form once and re-use where needed or some OOTB control on task form that would show item's view/edit form)

- the approach is once somehow achieve-able on nintex mobile (eg link/reference mobile entry form within mobile task form???)

Version history
Revision #:
1 of 1
Last update:
‎05-30-2016 04:52 PM
Updated by: