X-Git-Url: https://git.mdrn.pl/librarian.git/blobdiff_plain/215503e15ca9d6d1e8a053f7bfa359af1af102f3..f517a747988a667aafec9475ef106007481edcf7:/librarian/dcparser.py?ds=inline diff --git a/librarian/dcparser.py b/librarian/dcparser.py old mode 100755 new mode 100644 index d3547f0..cca9c6f --- a/librarian/dcparser.py +++ b/librarian/dcparser.py @@ -1,23 +1,7 @@ # -*- coding: utf-8 -*- # -# This file is part of Librarian. -# -# Copyright © 2008,2009,2010 Fundacja Nowoczesna Polska -# -# For full list of contributors see AUTHORS file. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . +# This file is part of Librarian, licensed under GNU Affero GPLv3 or later. +# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information. # from xml.parsers.expat import ExpatError from datetime import date @@ -151,6 +135,10 @@ class BookInfo(object): Field( DCNS('rights.license'), 'license', required=False), Field( DCNS('rights'), 'license_description'), ) + + @property + def slug(self): + return self.url.rsplit('/', 1)[1] @classmethod def from_string(cls, xml):