mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-02-06 06:56:54 +08:00
Merge pull request #1019 from okriuchykhin/ok_SCI_2134
Remove extra permission checks from WOPI buttons [SCI-2134][SCI-2133]
This commit is contained in:
commit
c0cfa6e7fe
1 changed files with 2 additions and 4 deletions
|
@ -28,8 +28,7 @@ module WopiHelper
|
|||
end
|
||||
|
||||
def wopi_asset_view_button(asset)
|
||||
if can_read_experiment?(result.my_module.experiment) &&
|
||||
asset.can_perform_action('view')
|
||||
if asset.can_perform_action('view')
|
||||
link_to view_asset_url(id: asset),
|
||||
class: 'btn btn-default btn-sm',
|
||||
target: '_blank',
|
||||
|
@ -41,8 +40,7 @@ module WopiHelper
|
|||
end
|
||||
|
||||
def wopi_asset_edit_button(asset)
|
||||
if can_manage_module?(result.my_module) &&
|
||||
asset.can_perform_action('edit')
|
||||
if asset.can_perform_action('edit')
|
||||
link_to edit_asset_url(id: asset),
|
||||
class: 'btn btn-default btn-sm',
|
||||
target: '_blank',
|
||||
|
|
Loading…
Reference in a new issue