UNPKG

@digital-blueprint/sublibrary-app

Version:

[GitHub Repository](https://github.com/digital-blueprint/sublibrary-app) | [npmjs package](https://www.npmjs.com/package/@digital-blueprint/sublibrary-app) | [Unpkg CDN](https://unpkg.com/browse/@digital-blueprint/sublibrary-app/) | [Sublibrary Bundle](ht

23 lines (19 loc) 564 B
import {ResourceSelect} from '@dbp-toolkit/resource-select'; export class LibrarySelect extends ResourceSelect { constructor() { super(); this.resourcePath = 'sublibrary'; } buildUrl(select, url) { url += '/sublibraries'; url += '?' + new URLSearchParams({ libraryManager: encodeURIComponent(select.auth['user-id']), }).toString(); return url; } formatResource(select, resource) { return `${resource['name']} (${resource['code']})`; } }