@@ -, +, @@ --- Koha/Schema/Result/Virtualshelve.pm | 4 +++- Koha/Virtualshelf.pm | 17 +++++++++++++++++ api/v1/swagger/paths.json | 3 +++ 3 files changed, 23 insertions(+), 1 deletion(-) --- a/Koha/Schema/Result/Virtualshelve.pm +++ a/Koha/Schema/Result/Virtualshelve.pm @@ -210,7 +210,9 @@ sub koha_objects_class { } __PACKAGE__->add_columns( - '+public' => { is_boolean => 1 }, + '+allow_change_from_others' => { is_boolean => 1 }, + '+allow_change_from_owner' => { is_boolean => 1 }, + '+public' => { is_boolean => 1 }, ); 1; --- a/Koha/Virtualshelf.pm +++ a/Koha/Virtualshelf.pm @@ -255,6 +255,23 @@ sub can_biblios_be_removed { # Same answer since bug 18228 } +=head3 to_api_mapping + +This method returns the mapping for representing a Koha::Virtualshelf object +on the API. + +=cut + +sub to_api_mapping { + return { + created_on => 'creation_date', + lastmodified => 'updated_on_date', + owner => 'owner_id', + shelfname => 'name', + shelfnumber => 'list_id', + }; +} + =head2 Internal methods =head3 _type --- a/api/v1/swagger/paths.json +++ a/api/v1/swagger/paths.json @@ -155,6 +155,9 @@ "/import_batch_profiles/{import_batch_profile_id}": { "$ref": "paths/import_batch_profiles.json#/~1import_batch_profiles~1{import_batch_profile_id}" }, + "/lists": { + "$ref": "paths/lists.yaml#/~1lists" + }, "/rotas/{rota_id}/stages/{stage_id}/position": { "$ref": "paths/rotas.json#/~1rotas~1{rota_id}~1stages~1{stage_id}~1position" }, --