Questions and discussion about developing processes and programming in PHP, JavaScript, web services & REST API.

Moderator: amosbatto

Forum rules: Please search to see if a question has already asked before creating a new topic. Please don't post the same question in multiple forums.
By HeshanKaru1994
#824802
Lets say we want to add 2 day of SLA to the task.Can it be done by timing controls to give task a duration.And what will happen if the time exceeds.Will it cancel the ongoing case or just show it in red
By HeshanKaru1994
#824807
We have 3 tasks and for each task different SLA days.
Task1 -> 2days
Task2 -> 1days
Task3 -> 3days

How to create a process checking such scenario
User avatar
By amosbatto
#824812
Setting the Due Date for a task only changes its color to red in the case list. If you want to automatically send a notification after a certain amount of time, see this example:
https://www.pmusers.com/index.php/Send_ ... is_overdue

If you want to cancel the case, then you change the trigger in that example to call PMFCancelCase().
If you want to automatically set variables and then route on the case to the next task in the process, then you can use PMFSendVariables() and PMFDerivateCase() in the trigger code.
By HeshanKaru1994
#824818
If we 10 tasks how to create the process workflow(bpmn diagram without dynaforms only with routing)
User avatar
By amosbatto
#824820
HeshanKaru1994 wrote: Tue Jun 11, 2019 12:51 am If we 10 tasks how to create the process workflow(bpmn diagram without dynaforms only with routing)
I don't understand the question. Can you clarify what you want? Is your question related to the previous post or is this a new question?
By HeshanKaru1994
#824827
sla.PNG
sla.PNG (16.26 KiB) Viewed 301 times
Here we have 5 different tasks with different sla days.How to draw the process diagram to current workflow.(Is sla reminder process a separate component or not?)
User avatar
By amosbatto
#824848
You need to create a separate process, which loops forever to check for overdue tasks in another process. If you want to check for five different tasks which are overdue, then follow these instructions:
The script can also be altered to search for multiple tasks. Change the task ID in the database query from:
Code: Select all
$query= "SELECT * FROM APP_CACHE_VIEW WHERE TAS_UID='$taskId' AND
  (APP_STATUS='TO_DO' OR APP_STATUS='DRAFT') AND DEL_THREAD_STATUS='OPEN' AND '$now' > DEL_TASK_DUE_DATE";

To a list of tasks to search for:
Code: Select all
$taskIDs = "'1272003815b8f3547cc9535064264588', '8842091725b7cb77f9d6906015609322', '9139066105b7cf3e6b909a1094180193'";
$query= "SELECT * FROM APP_CACHE_VIEW WHERE TAS_UID in ($taskIDs) AND
  (APP_STATUS='TO_DO' OR APP_STATUS='DRAFT') AND DEL_THREAD_STATUS='OPEN' AND '$now' > DEL_TASK_DUE_DATE";
By HeshanKaru1994
#824897
If we created an infinite loop it will run forever.From the business perspective is it efficient to use an infinite process.And if we created 10 such workflows with SLA reminders will all the infinite loops run in separate threads or will it slow the process
User avatar
By amosbatto
#824919
The example I gave you only creates one case which runs forever and checks if there are overdue tasks. That is the most efficient way to do it with just one case. Having multiple cases looping forever will slow down the cron.php script. You can change the SQL query to check for overdue cases in 10 different processes.

Yeah That will be very helpful :) Thank you

variable in external libs

Ohhh I tried this thing before but didn't work tha[…]

Limit List box

Hello Amos, The following solution is working. $[…]

It looks like jquery.masknumber.js has problems in[…]