Skip to content

Commit

Permalink
[#56] Display snippets for file size, markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
amercader committed Jun 6, 2024
1 parent 73523d6 commit d456c00
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ckanext/dcat/schemas/dcat_ap_2.1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,13 @@ dataset_fields:
label: Access rights
validators: ignore_missing unicode_safe
form_snippet: markdown.html
display_snippet: markdown.html

- field_name: version_notes
label: Version notes
validators: ignore_missing unicode_safe
form_snippet: markdown.html
display_snippet: markdown.html

- field_name: alternate_identifier
label: Alternate identifier
Expand Down Expand Up @@ -240,6 +242,7 @@ resource_fields:
label: Size
validators: ignore_missing int_validator
form_snippet: number.html
display_snippet: file_size.html

- field_name: hash
label: Hash
Expand All @@ -250,6 +253,7 @@ resource_fields:
- field_name: rights
label: Rights
form_snippet: markdown.html
display_snippet: markdown.html
form_placeholder: Some statement about the rights associated with the resource

- field_name: availability
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{{ h.localised_filesize(data[field.field_name]) }}

0 comments on commit d456c00

Please sign in to comment.