scottmahr - Monday, April 11, 2011 4:35 PM:
Hi all,
I am putting together a purchase request system in Aras and wanted some good ideas out of the group. After a PR is submitted, it goes through a chain of approvers that is dynamically selected based on the project and the dollar amount. I would like to enable any approver to send the PR to someone in the company for comment. To do this I plan to create an activity in the workflow for that PR with paths leading from the current activity to the new activity, then right back to the current activity. I plan on doing this using a method on the purchase request form. My main problem is that I don't want the approvers to be able to edit the PR, and I need some way for them to specify who they want to send the PR to.
Any ideas or thoughts on the topic would be appreciated. It is very possible I am missing a much better way to do this.
Thanks,
Scott
PeterSchroer - Monday, April 11, 2011 10:00 PM:
Hey Scott,
I did something similar for a customer project several years ago. I made a small modification to the HTML of the Workflow voting dialog to add fields that allowed the user to dynamically add additional steps to a running workflow. This modified the workfflow process, adding activities, that loop back to the originating actiity. The idea was "I need help making this decision, dynamically pick 3-4 people to get workflow notifications, and then alert me when they are finished so I can do my original task". Worked great, and was very well accepted.
Here's another way to do it, that does not require modifying the standard client voting dialog html, and doesn't open up editing of the PR to everyone. You can create a relationship from PR to Identity (A tab to list the Approvers). Change the default permission on the relatioship itemtype from Use_Src_Access to having it's own separate permissions. Now users can add rows to the tab, without having Edit rights to the PR. Then your Workflow can look at the list of Approvers dynamically.
Another thought. The Method that is run from your form, you can have the Method change the sesion Identity while it runs (like the Run As on Unix). So even though the user does not have edit rights to the PR, the method he is running has more privilege and can edit the PR.
Also - I recommend you checkout the Meeting Manager community project. there are some excellent examples from Kostja at Freudenberg FDS and Aras's Rob McAveney on how to modify workflow paths and activiies programmatically.
Peter.
scottmahr - Tuesday, April 12, 2011 6:22 PM:
Peter, thanks for all of that, it helps a lot.
I started down the path of placing an html button on my PR form, and asking for the user to enter the name of the user they want to rout the workflow to. I then go check the name to make sure it is valid, (and that the PR is in the correct life cycle phase to allow this action at all). I will look at the meeting manager project and learn how to add activities and paths.
My question then would be if I should programmatically move to that added activity (without the user visiting the voting dialog).
I like the idea of modifying the HTML of the workflow voting dialog instead. It seems like the more natural place for the user to do this sort of action. Where is the html for this "workflow activity completion" form? I looked around the forms, but couldn't seem to find anything. What you implemented before seems almost ideal to me, any chance you have that code laying around that I could look at?
Thanks again,
Scott
scottmahr - Wednesday, April 13, 2011 1:09 PM:
I found InBasket-VoteDialog.html, which seems to hold all the html for the voting dialog. I am now able to edit the voting dialog. Couple questions, I can't get the changes to show up unless I restart my client session of Aras, any better way to get the page to refresh? Changing this html file changes all the voting dialogs (for ECOs for example). I need to make a copy, and have a separate file for the PR voting dialog. I found the form "Workflow Signoffs" which seems to contain the html for the "signoffs" tab. In that tab, the "VOTE NOW" link takes me to the InBasket-VoteDialog.html, but I don't see where this is specified. If I could find this, I would just create an InBasket-VoteDialogPR.html file, and link to it from the PR itemtype.
Obviously I don't quite grasp all the requisite concepts for this design, but with a few pointers I think I will be able to work my way though. Thanks for all your help,
Scott