Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#1780 closed defect (fixed)

Copy-transformation icon should be disabled if logged in user doesn't have USE permission

Reported by: Nicklas Nordborg Owned by: olle
Priority: minor Milestone: BASE 3.2.4
Component: web Version:
Keywords: Cc:

Description

Related to #1779, but since no selection of plug-ins is taking place here, the copy will fail with 'permission denied' message. Before placing the 'copy' icon in the GUI it should be checked that user is actually allowed to use the plug-in + config.

Change History (7)

comment:1 Changed 8 years ago by olle

Owner: changed from everyone to olle

comment:2 Changed 8 years ago by olle

Status: newassigned

Ticket accepted.

comment:3 Changed 8 years ago by olle

Example of use case:

  • The copy icon (source:/branches/3.2-stable/www/images/copy.png) in www/images/copy.png is displayed in column "Tools" at the right end of a row of an analysis sub-tree table, e.g. Experiments -> Experiment A, tab "Bioassay sets". If a plug-in has been used to transform the bioassay set, a new leaf is created named after the plug-in, and a child leaf with the result of the transformation. If the copy icon for a transformation is clicked, a configuration pop-up dialog for the transformation should appear. However, if the user doesn't have USE permission for the plug-in or its configuration, the dialog will only contain the 'permission denied' message.
  • In addition, if a transformation link is clicked in the analysis tree to make the transformation properties page appear, a 'copy' button exists in the properties tool bar. Clicking the button activates the same configuration pop-up dialog as discussed above, and the button should therefore also be disabled if the user isn't allowed to use the plug-in or its configuration.
  • A common example of when USE permission exists for a plug-in, but not for its configuration, is BASE 1 plug-ins. In BASE version 2 and up, BASE 1 plug-ins are run as configurations of the BASE 1 plug-in executor, and USE permission is often granted for the latter, but not always for all BASE 1 plug-ins.
Last edited 8 years ago by olle (previous) (diff)

comment:4 Changed 8 years ago by olle

Problem discussion:

  • The 'copy' icon for a transformation is placed in the bioassayset analysis tree GUI by JSP script www/views/experiments/bioassaysets/analysis_tree.jsp, provided a job and an interactive plug-in exist, but no check that the user has permission to use the plug-in or its configuration is performed.
  • The 'copy' button in the properties tool bar for a transformation is created by JSP script www/views/experiments/transformations/view_transformation.jsp, provided WRITE permission for the transformation exists, but no check that the user has permission to use the plug-in or its configuration is performed.

Suggested fix:

  • JSP script www/views/experiments/bioassaysets/analysis_tree.jsp should be updated to only add a 'copy' link, if the user has permission to use the plug-in and its configuration. The user might not have READ permission for a plug-in, which must be considered when trying to obtain the plug-in configuration. A better solution than omitting the 'copy' link, would have been to display an icon for a disabled action, but this is left for a future update.
  • JSP script www/views/experiments/transformations/view_transformation.jsp should be updated to check if the user has permission to use the plug-in and its configuration, and disable the 'copy' button in the properties tool bar for the transformation, if the permissions are insufficient.
Last edited 8 years ago by olle (previous) (diff)

comment:5 Changed 8 years ago by olle

(In [6344]) Refs #1780. Refs #1779. The option to copy a transformation is now disabled, if insufficient permissions exist to perform it:

  1. JSP script www/views/experiments/bioassaysets/analysis_tree.jsp is updated to only add a 'copy' link, if the user has permission to use the plug-in and its configuration. The user might not have READ permission for a plug-in, which is considered when trying to obtain the plug-in configuration. A better solution than omitting the 'copy' link, would have been to display an icon for a disabled action, but this is left for a future update.
  2. JSP script www/views/experiments/transformations/view_transformation.jsp is updated to check if the user has permission to use the plug-in and its configuration, and disable the 'copy' button in the properties tool bar for the transformation, if the permissions are insufficient.

comment:6 Changed 8 years ago by olle

Resolution: fixed
Status: assignedclosed

Ticket closed as the requested functionality has been added.

comment:7 Changed 8 years ago by Nicklas Nordborg

(In [6376]) References #1780: Copy-transformation icon should be disabled if logged in user doesn't have USE permission

The fix was not completely merged to the trunk.

Note: See TracTickets for help on using tickets.