lastCollections instead of collections, to be more precise.
This commit is contained in:
parent
d0fd052f26
commit
b55ad15014
|
@ -12,22 +12,11 @@ Class {
|
|||
#category : #Zotero
|
||||
}
|
||||
|
||||
{ #category : #querying }
|
||||
ZoteroLibrary >> collections [
|
||||
"I return all the public collections for a particular group or user"
|
||||
^ NeoJSONReader fromString: (ZnEasy get: self collectionsURL) contents
|
||||
|
||||
|
||||
]
|
||||
|
||||
{ #category : #utility }
|
||||
ZoteroLibrary >> collectionsURL [
|
||||
"I provide the common part of the collections URL for the Zotero API"
|
||||
|
||||
groupID ifNotNil: [ ^ ZoteroAPI baseURL,'groups/',groupID,'/collections/' ].
|
||||
userID
|
||||
ifNotNil: [ ^ ZoteroAPI baseURL,'groups/',userID,'/collections/' ]
|
||||
ifNil: [ self emptyValuesWarning ]
|
||||
^ self groupURL, '/collections/'
|
||||
]
|
||||
|
||||
{ #category : #utility }
|
||||
|
@ -63,6 +52,14 @@ ZoteroLibrary >> groupURL [
|
|||
ifNil: [ self emptyValuesWarning ]
|
||||
]
|
||||
|
||||
{ #category : #querying }
|
||||
ZoteroLibrary >> lastCollections [
|
||||
"I return all the public collections for a particular group or user"
|
||||
^ NeoJSONReader fromString: (ZnEasy get: self collectionsURL) contents
|
||||
|
||||
|
||||
]
|
||||
|
||||
{ #category : #querying }
|
||||
ZoteroLibrary >> lastItems [
|
||||
"I return the last 25 items of the public collections for a particular group or user"
|
||||
|
|
Loading…
Reference in New Issue