Skip to content
This repository has been archived by the owner on Feb 4, 2021. It is now read-only.

Repeating fields for CKAN: obsoleted by ckanext-scheming 2.1 multiple_text fields

License

Unknown, Unknown licenses found

Licenses found

Unknown
COPYING
Unknown
COPYING.fr
Notifications You must be signed in to change notification settings

open-data/ckanext-repeating

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Note: made obsolete by ckanext-scheming 2.1 multiple_text fields

ckanext-repeating

This extension provides a way to store repeating fields in CKAN datasets, resources, organizations and groups.

Add the repeating plugin to your ckan.plugins configuration settings and use ckanext-scheming or a custom form plugin to use the provided validators to store repeating values in metadata fields.

The easiest way to use repeating fields is with ckanext-scheming. Add ckanext.repeating:presets.json to your scheming.presets configuration settings:

scheming.presets = ckanext.scheming:presets.json
                   ckanext.repeating:presets.json

A repeating field in a scheming schema will look something like:

{
  "field_name": "authors",
  "preset": "repeating_text",
  "label": "Author",
  "form_blanks": 3
}

This new extra field "authors" will appear as multiple fields in the dataset form, with three blank values below existing values. by the form snippet.

Example of repeating form snippet

When displayed, each value for the text entered will appear separately by the display snippet, eg.:

Example of repeating display snippet

When the dataset is accessed from the API each value will appear and are updated as items in a list, eg.:

{
  "...": "...",
  "authors": [
    "Person One",
    "Person Two"
  ],
  "...": "..."
}

About

Repeating fields for CKAN: obsoleted by ckanext-scheming 2.1 multiple_text fields

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
COPYING
Unknown
COPYING.fr

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published