https://github.com/acdh-oeaw/apis-bibsonomy

Plugin for the APIS framework that allows to host references in a bibsonomy instance

https://github.com/acdh-oeaw/apis-bibsonomy

Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.8%) to scientific vocabulary

Keywords

apis-instance
Last synced: 10 months ago · JSON representation

Repository

Plugin for the APIS framework that allows to host references in a bibsonomy instance

Basic Info
  • Host: GitHub
  • Owner: acdh-oeaw
  • License: mit
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 218 KB
Statistics
  • Stars: 2
  • Watchers: 8
  • Forks: 1
  • Open Issues: 15
  • Releases: 18
Topics
apis-instance
Created over 7 years ago · Last pushed about 1 year ago
Metadata Files
Readme Changelog License

README.md

APIS Bibsonomy

APIS Bibsonomy is a small addon to the APIS system. It allows to store references in Bibsonomy instances and use these references in APIS. It is very generic and should work with most Django installations/projects.

Installation

  • Install the package:

pip install apis-bibsonomy

  • Add the package to your installed apps:

INSTALLED_APPS = [ ... 'apis_bibsonomy' ]

  • And migrate your DB:

python manage.py migrate

Some functionality from APIS Bibsonomy uses htmx, so you should include htmx into your web application.

Configuration

APIS Bibsonomy needs an URL of the bibsonomy or zotero instance, a username, a API token and an (optional) collection to search in.

You need to add a configuration section to your APIS settings:

APIS_BIBSONOMY = [{ 'type': 'bibsomomy', #or zotero 'url': 'http://url.at', #url of the bibsonomy instance or zotero.org 'user': 'username', #for zotero use the user id number found in settings 'API key': 'api_key', 'group': 'group' }]

If you want the plugin to add the reference buttons to certain fields you need to add these fields to the config:

APIS_BIBSONOMY_FIELDS = ['name', 'first_name', 'profession']

Restart your server and you are good to go.

htmx

APIS Bibsonomy uses htmx. The delete buttons for references trigger deletion via the API delete route which give an empty response on success. HTMX needs to be configured to swap the content even if the response is empty: document.body.addEventListener('htmx:beforeSwap', function(event) { if (event.detail.xhr.status === 204) { // Swap content even when the response is empty. event.detail.shouldSwap = true; } });

Usage

not needed if you are using standard APIS templates

  • Include the base template somewhere in the header of your template:

{% include 'apis_bibsonomy/apis_bibsonomy_include.html' %}

  • Load the templatetag:

{% load bibsonomy_templatetags %}

  • Include the form somewhere in your template (set hidden=True if you intend to use buttons):

{% bibsonomy_form content_type='person' hidden=True %}

  • And finally add html tags as anker element for the reference forms to your template (dont forget to set "bibsonomy-anker" as class):

<button class="bibsonomy-anker" data-bibs-contenttype="person" data-bibs-object_pk={{instance.pk}} data-bibs-attribute="Attribute name (optional)">Ref</button>

  • If you want to batch add reference forms to attribute fields in a whole form add a hidden anker element. You need to additionally add the names of the form fields you want to have reference forms for to data-bibs-form-elements=""

<button class="bibsonomy-anker-hidden" data-bibs-contenttype="person" data-bibs-object_pk={{instance.pk}} data-bibs-form-elements="first_name|name|gender|start_date_written|lat">Ref</button>

Licenses

The book icon used for the reference link is the SVG from the Import Contacts icon from the material symbols

Owner

  • Name: Austrian Centre for Digital Humanities & Cultural Heritage
  • Login: acdh-oeaw
  • Kind: organization
  • Email: acdh@oeaw.ac.at
  • Location: Vienna, Austria

GitHub Events

Total
  • Create event: 68
  • Issues event: 6
  • Release event: 4
  • Delete event: 57
  • Issue comment event: 47
  • Push event: 45
  • Pull request event: 125
  • Fork event: 1
Last Year
  • Create event: 68
  • Issues event: 6
  • Release event: 4
  • Delete event: 57
  • Issue comment event: 47
  • Push event: 45
  • Pull request event: 125
  • Fork event: 1

Issues and Pull Requests

Last synced: 10 months ago

All Time
  • Total issues: 30
  • Total pull requests: 112
  • Average time to close issues: 5 months
  • Average time to close pull requests: 24 days
  • Total issue authors: 4
  • Total pull request authors: 5
  • Average comments per issue: 0.8
  • Average comments per pull request: 0.6
  • Merged pull requests: 62
  • Bot issues: 0
  • Bot pull requests: 64
Past Year
  • Issues: 5
  • Pull requests: 51
  • Average time to close issues: 2 months
  • Average time to close pull requests: 19 days
  • Issue authors: 2
  • Pull request authors: 3
  • Average comments per issue: 0.2
  • Average comments per pull request: 0.76
  • Merged pull requests: 9
  • Bot issues: 0
  • Bot pull requests: 47
Top Authors
Issue Authors
  • gregorpirgie (10)
  • b1rger (9)
  • sennierer (8)
  • koeaw (4)
  • dependabot[bot] (1)
Pull Request Authors
  • b1rger (76)
  • dependabot[bot] (73)
  • github-actions[bot] (16)
  • sennierer (3)
  • richardhadden (1)
Top Labels
Issue Labels
enhancement (7) usability (6) Documentation (3) question (3) bug (2) dependencies (1)
Pull Request Labels
dependencies (73) python (44) github_actions (15) released (9) autorelease: pending (9) autorelease: tagged (7)

Dependencies

poetry.lock pypi
  • appdirs 1.4.4 develop
  • beautifulsoup4 4.9.3 develop
  • cachecontrol 0.12.6 develop
  • colorama 0.4.4 develop
  • distro 1.6.0 develop
  • feedparser 6.0.8 develop
  • lastversion 1.5.1 develop
  • lockfile 0.12.2 develop
  • msgpack 1.0.2 develop
  • packaging 21.0 develop
  • sgmllib3k 1.0.0 develop
  • soupsieve 2.2.1 develop
  • tqdm 4.62.0 develop
  • anytree 2.8.0
  • apis-core 0.16.32
  • asgiref 3.4.1
  • attrs 21.2.0
  • certifi 2021.5.30
  • charset-normalizer 2.0.4
  • convertdate 2.3.2
  • defusedxml 0.7.1
  • dj-database-url 0.5.0
  • django 3.1.13
  • django-admin-csvexport 1.9
  • django-autocomplete-light 3.8.2
  • django-cors-headers 3.7.0
  • django-crispy-forms 1.12.0
  • django-crum 0.7.9
  • django-filter 2.4.0
  • django-gm2m 1.1.1
  • django-guardian 2.4.0
  • django-leaflet 0.27.1
  • django-model-utils 4.1.1
  • django-reversion 3.0.9
  • django-summernote 0.8.11.6
  • django-tables2 2.4.0
  • djangorestframework 3.12.4
  • djangorestframework-csv 2.1.1
  • djangorestframework-jsonschema 0.1.1
  • djangorestframework-xml 2.0.0
  • drf-spectacular 0.11.1
  • idna 3.2
  • importlib-metadata 4.6.3
  • inflection 0.5.1
  • isodate 0.6.0
  • jmespath 0.10.0
  • jsonschema 3.2.0
  • lxml 4.6.3
  • mysqlclient 2.0.3
  • numpy 1.19.5
  • pandas 0.25.3
  • pymeeus 0.5.11
  • pyparsing 2.4.7
  • pyrsistent 0.18.0
  • python-dateutil 2.8.2
  • pytz 2021.1
  • pyyaml 5.4.1
  • rdflib 5.0.0
  • regex 2020.11.13
  • requests 2.26.0
  • sentry-sdk 0.19.5
  • six 1.16.0
  • sparqlwrapper 1.8.5
  • sqlparse 0.4.1
  • tablib 3.0.0
  • typing-extensions 3.10.0.0
  • unicodecsv 0.14.1
  • uritemplate 3.0.1
  • urllib3 1.26.6
  • zipp 3.5.0
pyproject.toml pypi
  • lastversion ^2.0.1 develop
  • apis-core >=0.16.0
  • python >=3.6, <3.9
setup.py pypi
  • Django >=2.0
  • apis-core >=0.9.22
  • django-autocomplete-light >=3.2.10
  • django-filter >=1.1.0
  • django-reversion >=2.0.13
  • djangorestframework >=3.7.7
  • python-dateutil >=2.7.0
  • requests >=2.18.4
.github/workflows/release-please.yml actions
  • google-github-actions/release-please-action v3 composite