First files for the publication module (only for backup)
git-svn-id: https://svn.libreccm.org/ccm/trunk@503 8810af33-2d31-482b-a856-94f89814c4dfmaster
parent
f3bfec7592
commit
b10cbd3a76
|
|
@ -0,0 +1,51 @@
|
|||
//
|
||||
// Copyright (C) 2010 Jens Pelzetter, for the Center of Social Politics (ZeS) of
|
||||
// the University of Bremen
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Lesser General Public License
|
||||
// as published by the Free Software Foundation; either version 2.1 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// This library 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
|
||||
// Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public
|
||||
// License along with this library; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
//
|
||||
|
||||
model com.arsdigita.cms.contenttypes;
|
||||
|
||||
import com.arsdigita.cms.ContentPage;
|
||||
|
||||
//PDL definition for the basic attributes of publication.
|
||||
object type Publication extends ContentPage {
|
||||
|
||||
Integer[0..1] yearOfPublication = ct_publications.year INTEGER;
|
||||
String[0..1] abstract = ct_publications.abstract VARCHAR(2048);
|
||||
String[0..1] misc = ct_publications.misc VARCHAR(2048);
|
||||
|
||||
reference key (ct_publications.publication_id);
|
||||
}
|
||||
|
||||
//Assoication for the editors
|
||||
association {
|
||||
|
||||
Publication[0..1] publication = join cms_persons.person_id
|
||||
to ct_publications_authorship.person_id,
|
||||
join ct_publications_authorship.publication_id
|
||||
to ct_publications.publication_id;
|
||||
|
||||
GenericPerson[0..n] persons = join ct_publications.publication_id
|
||||
to ct_publications_authorship.publication_id,
|
||||
join ct_publications_authorship.person_id
|
||||
to cms_persons.person_id;
|
||||
|
||||
// Additional attributes
|
||||
Boolean[0..1] editor = ct_publications_authorship.editor BIT;
|
||||
Integer[0..1] authorOrder = ct_publications_authorship.authorship_order INTEGER;
|
||||
}
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
//
|
||||
// Copyright (C) 2010 Jens Pelzetter, for the Center of Social Politics (ZeS) of
|
||||
// the University of Bremen
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Lesser General Public License
|
||||
// as published by the Free Software Foundation; either version 2.1 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// This library 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
|
||||
// Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public
|
||||
// License along with this library; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
//
|
||||
|
||||
model com.arsdigita.cms.contenttypes;
|
||||
|
||||
import com.arsdigita.cms.ContentPage;
|
||||
|
||||
// PDL definition for a publication with publisher
|
||||
object type PublicationWithPublisher extends Publication {
|
||||
|
||||
String[0..1] isbn = ct_publication_with_publisher.isbn VARCHAR(13);
|
||||
|
||||
reference key (ct_publication_with_publisher.publication_with_publisher_id);
|
||||
|
||||
}
|
||||
|
||||
// Association which links to the publisher (an GenericOrganizationalUnit).
|
||||
association {
|
||||
|
||||
PublicationWithPublisher[0..1] publication = join cms_organizationalunits.organizationalunit_id
|
||||
to ct_publication_publisher.publisher_id,
|
||||
join ct_publication_publisher.publication_with_publisher_id
|
||||
to ct_publication_with_publisher.publication_with_publisher_id;
|
||||
GenericOrganizationalUnit[0..n] publisher = join ct_publication_with_publisher.publication_with_publisher_id
|
||||
to ct_publication_publisher.publication_with_publisher_id,
|
||||
join ct_publication_publisher.publisher_id
|
||||
to cms_organizationalunits.organizationalunit_id;
|
||||
// Additional attributes
|
||||
String[0..1] place = ct_publication_publisher.place VARCHAR(256);
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,65 @@
|
|||
//
|
||||
// Copyright (C) 2010 Jens Pelzetter, for the Center of Social Politics (ZeS) of
|
||||
// the University of Bremen
|
||||
//
|
||||
// This library is free software; you can redistribute it and/or
|
||||
// modify it under the terms of the GNU Lesser General Public License
|
||||
// as published by the Free Software Foundation; either version 2.1 of
|
||||
// the License, or (at your option) any later version.
|
||||
//
|
||||
// This library 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
|
||||
// Lesser General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Lesser General Public
|
||||
// License along with this library; if not, write to the Free Software
|
||||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
//
|
||||
//
|
||||
|
||||
model com.arsdigita.cms.contenttypes;
|
||||
|
||||
import com.arsdigita.cms.ContentPage;
|
||||
|
||||
// The contenttype described in this PDL file represents a series of publications.
|
||||
object types Series extends ContentPage {
|
||||
|
||||
reference key (ct_series.series_id);
|
||||
|
||||
}
|
||||
|
||||
//Assoication for the editship of a series
|
||||
association {
|
||||
|
||||
Series[0..1] series = join cms_persons.persons_id
|
||||
to ct_series_editship.person_id,
|
||||
join ct_series_editship.series_id
|
||||
to ct_series.series_id;
|
||||
|
||||
GenericPerson[0..n] persons = join ct_series.series_id
|
||||
to ct_series_editship.series_id,
|
||||
join ct_series_editship.person_id
|
||||
to cms_persons.person_id;
|
||||
|
||||
// Additional attributes for the editship
|
||||
Date[0..1] from = ct_series_editship.from DATE
|
||||
Date[0..] to = ct_series_editship.to DATE
|
||||
|
||||
}
|
||||
|
||||
//Assoication for the volumes in the series
|
||||
association {
|
||||
|
||||
Series[0..1] series = join ct_publications.publication_id
|
||||
to ct_publications_volume_in_series.publication_id,
|
||||
join ct_publications_volume_in_series.series_id
|
||||
to ct_series.series_id;
|
||||
|
||||
Publication[0..n] publications = join ct_series.series_id
|
||||
to ct_publications_volume_in_series.series_id,
|
||||
join ct_publications_volume_in_series.publication_id
|
||||
to ct_publications.publication_id;
|
||||
// Additional attributes
|
||||
Integer[0..1] volumeOfSeries = ct_publications_volume_in_series.volumeOfSeries INTEGER;
|
||||
}
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
begin;
|
||||
\i ddl/postgres/create.sql
|
||||
end;
|
||||
|
|
@ -22,7 +22,7 @@ model com.arsdigita.cms.contenttypes;
|
|||
|
||||
import com.arsdigita.cms.ContentPage;
|
||||
|
||||
// PDL definition for a commons base type for orgnizations, departments, projects etc.
|
||||
// PDL definition for a commons base type for organizations, departments, projects etc.
|
||||
object type GenericOrganizationalUnit extends ContentPage {
|
||||
//String[0..1] orgaunit_name = cms_organizationalunits.name VARCHAR(256);
|
||||
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ public class GenericOrganizationalUnit extends ContentPage {
|
|||
DataObject link = add(ORGAUNIT_CHILDREN, child);
|
||||
|
||||
link.set(ORGAUNIT_CHILDREN_ORDER, Integer.valueOf((int) getOrgaUnitChildren().
|
||||
size()));
|
||||
size()));
|
||||
}
|
||||
|
||||
public void removeOrgaUnitChildren(GenericOrganizationalUnit child) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue