From 73f067cfafeee646a9410fbd02a22b964bc0fcef Mon Sep 17 00:00:00 2001 From: Christoph Reiter <reiter.christoph@gmail.com> Date: Wed, 27 Oct 2021 10:57:35 +0200 Subject: [PATCH] /people -> /base/people --- packages/organization-select/README.md | 4 ++-- packages/person-profile/README.md | 2 +- packages/person-profile/src/person-profile.js | 2 +- packages/person-select/README.md | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/organization-select/README.md b/packages/organization-select/README.md index bb61bdee..d56de9cb 100644 --- a/packages/organization-select/README.md +++ b/packages/organization-select/README.md @@ -27,14 +27,14 @@ Or directly via CDN: - `entry-point-url` (optional, default is the TU Graz entry point url): entry point url to access the api - example `<dbp-organization-select entry-point-url="http://127.0.0.1:8000"></dbp-organization-select>` - `value` (optional): api path of organization to preload the selector with - - example `<dbp-organization-select value="/people/testuser"></dbp-organization-select>` + - example `<dbp-organization-select value="/base/people/testuser"></dbp-organization-select>` - the `value` will also be set automatically when an organization is chosen in the selector - `context` (optional): the context of the returned organizations - example `<dbp-organization-select context="libray-manager"></dbp-organization-select>` returns all organizations where the current user is library manager - if no `context` is set all organizations are returned that are in a relation with the current user - `data-object` (read-only): when an organization is selected the organization object will be set as json string - - example `<dbp-organization-select data-object="{"@id":"/organizations/1190-F2050","@type":"http://schema.org/Organization","identifier":"1190-F2050","name":"Institut f�r Stahlbau","url":"https://online.tugraz.at/tug_online/wborg.display?pOrgNr=1190","alternateName":"F2050"}"></dbp-organization-select>` + - example `<dbp-organization-select data-object="{"@id":"/organizations/1190-F2050","@type":"http://schema.org/Organization","identifier":"1190-F2050","name":"Institut für Stahlbau","url":"https://online.tugraz.at/tug_online/wborg.display?pOrgNr=1190","alternateName":"F2050"}"></dbp-organization-select>` - `auth` object: you need to set that object property for the auth token - example auth property: `{token: "THE_BEARER_TOKEN"}` - note: most often this should be an attribute that is not set directly, but subscribed at a provider diff --git a/packages/person-profile/README.md b/packages/person-profile/README.md index 2fd1e25d..6a7e27b7 100644 --- a/packages/person-profile/README.md +++ b/packages/person-profile/README.md @@ -27,7 +27,7 @@ Or directly via CDN: - `entry-point-url` (optional, default is the TU Graz entry point url): entry point url to access the api - example `<dbp-person-profile entry-point-url="http://127.0.0.1:8000"></dbp-person-profile>` - `value` (optional): api path of person to preload the selector with - - example `<dbp-person-profile value="/people/testuser"></dbp-person-profile>` + - example `<dbp-person-profile value="/base/people/testuser"></dbp-person-profile>` - `auth` object: you need to set that object property for the auth token - example auth property: `{token: "THE_BEARER_TOKEN"}` - note: most often this should be an attribute that is not set directly, but subscribed at a provider diff --git a/packages/person-profile/src/person-profile.js b/packages/person-profile/src/person-profile.js index c78a0b9b..649b8df3 100644 --- a/packages/person-profile/src/person-profile.js +++ b/packages/person-profile/src/person-profile.js @@ -46,7 +46,7 @@ export class PersonProfile extends DBPLitElement { } case 'value': if (this.value !== '') { - const apiUrl = this.entryPointUrl + '/people/' + this.value; + const apiUrl = this.entryPointUrl + '/base/people/' + this.value; // load person fetch(apiUrl, { diff --git a/packages/person-select/README.md b/packages/person-select/README.md index f2d1d40c..6bb84d46 100644 --- a/packages/person-select/README.md +++ b/packages/person-select/README.md @@ -27,10 +27,10 @@ Or directly via CDN: - `entry-point-url` (optional, default is the TU Graz entry point url): entry point url to access the api - example `<dbp-person-select entry-point-url="http://127.0.0.1:8000"></dbp-person-select>` - `value` (optional): api path of person to preload the selector with - - example `<dbp-person-select value="/people/testuser"></dbp-person-select>` + - example `<dbp-person-select value="/base/people/testuser"></dbp-person-select>` - the `value` will also be set automatically when a person is chosen in the selector - `data-object` (read-only): when a person is selected the person object will be set as json string - - example `<dbp-person-select data-object="{"@id":"/people/testuser", "@type":"http://schema.org/Person", "identifier":"testuser", "givenName":"Hans", "familyName":"Tester", "honorificSuffix":"Ing.", "telephone":"+43 (876) 123-4567", "phoneExtension":"4567", "email":"hans.tester@email.com", "name":"Hans Tester"}"></dbp-person-select>` + - example `<dbp-person-select data-object="{"@id":"/base/people/testuser", "@type":"http://schema.org/Person", "identifier":"testuser", "givenName":"Hans", "familyName":"Tester", "honorificSuffix":"Ing.", "telephone":"+43 (876) 123-4567", "phoneExtension":"4567", "email":"hans.tester@email.com", "name":"Hans Tester"}"></dbp-person-select>` - `show-details` (optional): also shows the email address of the persons to distinguish people with the same name - the currently logged in user needs to have permissions to show the email address of people - example `<dbp-person-select show-details></dbp-person-select>` -- GitLab