Following the same principle, one should expect to see only the action
that he's allowed to perform during submission (ie "Submit New
Version" and "Approve Record" but not "Modify Record").
The main reason is that I don't want all users to know what actions
are available! (It should save me some time from explaining why a user
should not be able to modify a record, etc...) :)
Again, the logic is the same: in websubmit_engine's "action" definition:
add
user_info = collect_user_info(req) (in the try except block?)
and
id_action= acc_get_action_id('submit')
mylist= acc_find_possible_actions_user(uid,id_action)
and change:
< if action_details is not None:
---
actionAllowed=False
for mylist_item in mylist:
if (mylist_item[2]==doctype_action[0] and not actionAllowed):
actionAllowed=True
if (action_details is not None) and (actionAllowed or
isUserSuperAdmin(user_info)):
It works for me, but again, I'm not using FireRoles :)