mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-03-07 05:03:26 +08:00
Fix markup
This commit is contained in:
parent
a0f11116d2
commit
0f3c138a7e
1 changed files with 2 additions and 3 deletions
|
@ -89,13 +89,12 @@ module RepositoryDatatableHelper
|
||||||
class DisplayCellValue
|
class DisplayCellValue
|
||||||
def self.repository_asset_value(cell, _team)
|
def self.repository_asset_value(cell, _team)
|
||||||
asset = cell.value.asset
|
asset = cell.value.asset
|
||||||
data = {
|
{
|
||||||
id: asset.id,
|
id: asset.id,
|
||||||
url: Rails.application.routes.url_helpers.rails_blob_path(asset.file, disposition: 'attachment'),
|
url: Rails.application.routes.url_helpers.rails_blob_path(asset.file, disposition: 'attachment'),
|
||||||
|
preview_url: Rails.application.routes.url_helpers.asset_file_preview_path(asset),
|
||||||
file_name: asset.file_name
|
file_name: asset.file_name
|
||||||
}
|
}
|
||||||
data[:preview_url] = Rails.application.routes.url_helpers.asset_file_preview_path(asset)
|
|
||||||
data
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue