mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-25 01:03:18 +08:00
Revert "Add office file to task step - reload file option shows plain html page [SCI-7673]"
This commit is contained in:
parent
e020b4a416
commit
dac150f75f
1 changed files with 4 additions and 14 deletions
|
@ -12,8 +12,8 @@
|
|||
:data-gallery-view-id="stepId"
|
||||
:data-preview-url="attachment.attributes.urls.preview"
|
||||
>
|
||||
<span data-toggle="tooltip"
|
||||
data-placement="bottom"
|
||||
<span data-toggle="tooltip"
|
||||
data-placement="bottom"
|
||||
:title="`${ attachment.attributes.file_name }`">
|
||||
{{ attachment.attributes.file_name }}
|
||||
</span>
|
||||
|
@ -44,8 +44,9 @@
|
|||
<div v-else class="empty-office-file">
|
||||
<h2>{{ i18n.t('assets.empty_office_file.description') }}</h2>
|
||||
<a :href="attachment.attributes.urls.load_asset"
|
||||
remote="true"
|
||||
class="btn btn-primary reload-asset"
|
||||
@click.prevent="reloadAsset">
|
||||
:params="{asset: {view_mode: attachment.attributes.view_mode}}">
|
||||
{{ i18n.t('assets.empty_office_file.reload') }}
|
||||
</a>
|
||||
</div>
|
||||
|
@ -89,16 +90,5 @@
|
|||
required: true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
reloadAsset() {
|
||||
$.ajax({
|
||||
method: 'GET',
|
||||
url: this.attachment.attributes.urls.load_asset,
|
||||
data: {
|
||||
asset: { view_mode: this.attachment.attributes.view_mode }
|
||||
}
|
||||
});
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Reference in a new issue