Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronald Krist committed Nov 7, 2023
1 parent 2634feb commit 5705aac
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,26 @@
# OARepo requests
# OARepo communities

## Installation

To init custom fields, add them under COMMUNITIES_CUSTOM_FIELDS key to invenio.cfg,
for example


``` python
from oarepo_communities.cf.permissions import PermissionsCF
from oarepo_communities.cf.aai import AAIMappingCF

COMMUNITIES_CUSTOM_FIELDS = [PermissionsCF("permissions"), AAIMappingCF("aai")]
COMMUNITIES_CUSTOM_FIELDS_UI = [{
"section": "settings",
"fields": [{
"field": "permissions",
"ui_widget": "Input",
"props": {
"label":"permissions dict",
}
}]
}]
```
and the init cli command:
invenio communities custom-fields init

0 comments on commit 5705aac

Please sign in to comment.