Verschiedene kleinere Fehlerkorrekturen.
git-svn-id: https://svn.libreccm.org/ccm/trunk@582 8810af33-2d31-482b-a856-94f89814c4dfmaster
parent
8d7857ade5
commit
fb221bc4c1
|
|
@ -113,3 +113,4 @@ cms.contenttypes.ui.genericorgaunit.select_person=Select person
|
|||
cms.contenttypes.ui.contact.contactEntry.none=No contact information yet
|
||||
cms.contenttypes.ui.genericorgaunit.person.role=Role
|
||||
cms.ui.delete=Remove
|
||||
sciorganization.ui.department.project.confirm_remove=Are you sure to remove this project?
|
||||
|
|
|
|||
|
|
@ -115,3 +115,4 @@ cms.contenttypes.ui.genericorgaunit.addendum=Zusatz
|
|||
cms.contenttypes.ui.genericorgaunit.select_person=Person ausw\u00e4hlen
|
||||
cms.contenttypes.ui.genericorgaunit.person.role=Rolle
|
||||
cms.ui.delete=Entfernen
|
||||
sciorganization.ui.department.project.confirm_remove=Wollen Sie dieses Projekt wirklich entfernen?
|
||||
|
|
|
|||
|
|
@ -177,7 +177,7 @@ public class GenericOrganizationalUnitPersonsTable extends Table implements
|
|||
Object key,
|
||||
int row,
|
||||
int col) {
|
||||
com.arsdigita.cms.SecurityManager securityManager = Utilities.
|
||||
/*com.arsdigita.cms.SecurityManager securityManager = Utilities.
|
||||
getSecurityManager(state);
|
||||
GenericOrganizationalUnit orgaunit = (GenericOrganizationalUnit) m_itemModel.
|
||||
getSelectedObject(
|
||||
|
|
@ -189,9 +189,9 @@ public class GenericOrganizationalUnitPersonsTable extends Table implements
|
|||
if (canEdit) {
|
||||
ControlLink link = new ControlLink(value.toString());
|
||||
return link;
|
||||
} else {
|
||||
} else {*/
|
||||
return new Label(value.toString());
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -158,11 +158,16 @@ public class SciDepartment extends GenericOrganizationalUnit {
|
|||
SciDepartment oldSuperDepartment;
|
||||
|
||||
oldSuperDepartment = getSuperDepartment();
|
||||
remove(SUPER_DEPARTMENT, oldSuperDepartment);
|
||||
if (oldSuperDepartment != null) {
|
||||
remove(SUPER_DEPARTMENT, oldSuperDepartment);
|
||||
}
|
||||
|
||||
if (null != department) {
|
||||
Assert.exists(department, SciDepartment.class);
|
||||
add(SUPER_DEPARTMENT, department);
|
||||
DataObject link = add(SUPER_DEPARTMENT, department);
|
||||
link.set(SUBDEPARTMENT_ORDER,
|
||||
Integer.valueOf((int) department.getSubDepartments().size()));
|
||||
link.save();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -187,11 +192,16 @@ public class SciDepartment extends GenericOrganizationalUnit {
|
|||
SciOrganization oldOrganization;
|
||||
|
||||
oldOrganization = getOrganization();
|
||||
remove(ORGANIZATION, oldOrganization);
|
||||
if (oldOrganization != null) {
|
||||
remove(ORGANIZATION, oldOrganization);
|
||||
}
|
||||
|
||||
if (null != orga) {
|
||||
Assert.exists(orga, SciOrganization.class);
|
||||
add(ORGANIZATION, orga);
|
||||
DataObject link = add(ORGANIZATION, orga);
|
||||
link.set(SciOrganization.DEPARTMENT_ORDER,
|
||||
Integer.valueOf((int) orga.getDepartments().size()));
|
||||
link.save();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -207,6 +217,7 @@ public class SciDepartment extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(SUBDEPARTMENT_ORDER, Integer.valueOf((int) getSubDepartments().
|
||||
size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeSubDepartment(SciDepartment subDepartment) {
|
||||
|
|
@ -231,6 +242,9 @@ public class SciDepartment extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(PROJECT_ORDER,
|
||||
Integer.valueOf((int) getProjects().size()));
|
||||
link.set(SciProject.DEPARTMENTS_ORDER,
|
||||
Integer.valueOf((int) project.getDepartments().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeProject(SciProject project) {
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ import java.math.BigDecimal;
|
|||
public class SciOrganization extends GenericOrganizationalUnit {
|
||||
|
||||
public static final String ORGANIZATION_SHORT_DESCRIPTION =
|
||||
"organizationShortDescription";
|
||||
"organizationShortDescription";
|
||||
public static final String ORGANIZATION_DESCRIPTION =
|
||||
"organizationDescription";
|
||||
public static final String DEPARTMENTS = "departments";
|
||||
|
|
@ -129,6 +129,7 @@ public class SciOrganization extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(DEPARTMENT_ORDER,
|
||||
Integer.valueOf((int) getDepartments().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeDepartment(SciDepartment department) {
|
||||
|
|
@ -150,8 +151,10 @@ public class SciOrganization extends GenericOrganizationalUnit {
|
|||
Assert.exists(project, SciProject.class);
|
||||
|
||||
DataObject link = add(PROJECTS, project);
|
||||
|
||||
link.set(PROJECT_ORDER, Integer.valueOf((int) getProjects().size()));
|
||||
link.set(SciProject.ORGANIZATIONS_ORDER, Integer.valueOf((int) project.
|
||||
getOrganizations().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeProject(SciProject project) {
|
||||
|
|
|
|||
|
|
@ -73,10 +73,10 @@ public class SciProject extends GenericOrganizationalUnit {
|
|||
public static final String SUBPROJECTS = "subProjects";
|
||||
public static final String SUBPROJECT_ORDER = "subProjectOrder";
|
||||
public static final String ORGANIZATIONS = "organization";
|
||||
public static final String ORGANIZATIONS_ORDER = "organization";
|
||||
public static final String ORGANIZATIONS_ORDER = "organizationOrder";
|
||||
public static final String SUPER_PROJECT = "superProject";
|
||||
public static final String DEPARTMENTS = "department";
|
||||
public static final String DEPARTMENTS_ORDER = "department";
|
||||
public static final String DEPARTMENTS_ORDER = "departmentOrder";
|
||||
public static final String BASE_DATA_OBJECT_TYPE =
|
||||
"com.arsdigita.cms.contenttypes.SciProject";
|
||||
private static final SciOrganizationConfig s_config =
|
||||
|
|
@ -163,6 +163,7 @@ public class SciProject extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(SUBPROJECT_ORDER,
|
||||
Integer.valueOf((int) getSubProjects().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeSubProject(SciProject project) {
|
||||
|
|
@ -189,6 +190,9 @@ public class SciProject extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(ORGANIZATIONS_ORDER,
|
||||
Integer.valueOf((int) getOrganizations().size()));
|
||||
link.set(SciOrganization.PROJECT_ORDER,
|
||||
Integer.valueOf((int) orga.getProjects().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeOrganization(SciOrganization orga) {
|
||||
|
|
@ -213,6 +217,7 @@ public class SciProject extends GenericOrganizationalUnit {
|
|||
|
||||
link.set(DEPARTMENTS_ORDER,
|
||||
Integer.valueOf((int) getDepartments().size()));
|
||||
link.save();
|
||||
}
|
||||
|
||||
public void removeDepartment(SciDepartment department) {
|
||||
|
|
|
|||
|
|
@ -108,12 +108,18 @@ public class SciDepartmentOrganizationSheet
|
|||
|
||||
private Table m_table;
|
||||
private SciOrganization m_orga;
|
||||
private boolean m_done;
|
||||
|
||||
public SciDepartmentOrganizationSheetModel(Table table,
|
||||
PageState state,
|
||||
SciDepartment department) {
|
||||
m_table = table;
|
||||
m_orga = department.getOrganization();
|
||||
if (m_orga == null) {
|
||||
m_done = false;
|
||||
} else {
|
||||
m_done = true;
|
||||
}
|
||||
}
|
||||
|
||||
public int getColumnCount() {
|
||||
|
|
@ -123,11 +129,11 @@ public class SciDepartmentOrganizationSheet
|
|||
public boolean nextRow() {
|
||||
boolean ret;
|
||||
|
||||
if (null == m_orga) {
|
||||
ret = false;
|
||||
} else {
|
||||
if (m_done) {
|
||||
ret = true;
|
||||
m_orga = null;
|
||||
m_done = false;
|
||||
} else {
|
||||
ret = false;
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
@ -139,7 +145,8 @@ public class SciDepartmentOrganizationSheet
|
|||
return m_orga.getTitle();
|
||||
case 1:
|
||||
return SciOrganizationGlobalizationUtil.globalize(
|
||||
"sciorganization.ui.department.organization.remove");
|
||||
"sciorganization.ui.department.organization.remove").
|
||||
localize();
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ public class SciDepartmentProjectsTable
|
|||
link.setConfirmation((String) SciOrganizationGlobalizationUtil.
|
||||
globalize(
|
||||
"sciorganization.ui.department.project."
|
||||
+ ".confirm_remove").
|
||||
+ "confirm_remove").
|
||||
localize());
|
||||
return link;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -106,12 +106,18 @@ public class SciDepartmentSuperDepartmentSheet
|
|||
|
||||
private Table m_table;
|
||||
private SciDepartment m_superDepartment;
|
||||
private boolean m_done;
|
||||
|
||||
public SciDepartmentSuperDepartmentSheetModel(Table table,
|
||||
PageState state,
|
||||
SciDepartment department) {
|
||||
m_table = table;
|
||||
m_superDepartment = department.getSuperDepartment();
|
||||
if (m_superDepartment == null) {
|
||||
m_done = false;
|
||||
} else {
|
||||
m_done = true;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -123,11 +129,11 @@ public class SciDepartmentSuperDepartmentSheet
|
|||
public boolean nextRow() {
|
||||
boolean ret;
|
||||
|
||||
if (null == m_superDepartment) {
|
||||
ret = false;
|
||||
} else {
|
||||
if (m_done) {
|
||||
ret = true;
|
||||
m_superDepartment = null;
|
||||
m_done = false;
|
||||
} else {
|
||||
ret = false;
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
@ -140,7 +146,8 @@ public class SciDepartmentSuperDepartmentSheet
|
|||
return m_superDepartment.getTitle();
|
||||
case 1:
|
||||
return SciOrganizationGlobalizationUtil.globalize(
|
||||
"sciorganization.ui.department.superdepartment.remove");
|
||||
"sciorganization.ui.department.superdepartment.remove").
|
||||
localize();
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
|
@ -214,7 +221,6 @@ public class SciDepartmentSuperDepartmentSheet
|
|||
TableColumn column = getColumnModel().get(event.getColumn().intValue());
|
||||
|
||||
if (column.getHeaderKey().toString().equals(TABLE_COL_EDIT)) {
|
||||
|
||||
} else if (column.getHeaderKey().toString().equals(TABLE_COL_DEL)) {
|
||||
department.setSuperDepartment(null);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ public class SciOrganizationDepartmentsTable
|
|||
link.setConfirmation((String) SciOrganizationGlobalizationUtil.
|
||||
globalize(
|
||||
"sciorganization.ui.organization.department."
|
||||
+ ".confirm_remove").
|
||||
+ "confirm_remove").
|
||||
localize());
|
||||
return link;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ public class SciOrganizationProjectsTable
|
|||
link.setConfirmation((String) SciOrganizationGlobalizationUtil.
|
||||
globalize(
|
||||
"sciorganization.ui.organization.project."
|
||||
+ ".confirm_remove").
|
||||
+ "confirm_remove").
|
||||
localize());
|
||||
return link;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ sciorganization.ui.organization.description=Description
|
|||
sciorganization.ui.organization.description.upload=Upload description
|
||||
sciorganization.ui.organization.description.upload.mimetype=Type of file
|
||||
sciorganization.ui.project.select_superproject=Select superior project
|
||||
sciorganization.ui.department.setSuperDepartment=Set superior project
|
||||
sciorganization.ui.department.setSuperDepartment=Set superior department
|
||||
sciorganization.ui.department.superdepartment_none=No superior department found
|
||||
sciorganization.ui.department.superdepartment=Superior department
|
||||
sciorganization.ui.department.superdepartment.remove=Remove superior department
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ sciorganization.ui.organization.description=Beschreibung
|
|||
sciorganization.ui.organization.description.upload=Beschriebung hochladen
|
||||
sciorganization.ui.organization.description.upload.mimetype=Dateityp
|
||||
sciorganization.ui.project.select_superproject=\u00dcbergeordnetes Projekt ausw\u00e4hlen
|
||||
sciorganization.ui.department.setSuperDepartment=\u00dcbergeordnetes Projekt setzen
|
||||
sciorganization.ui.department.setSuperDepartment=\u00dcbergeordnete Abteilung setzen
|
||||
sciorganization.ui.department.superdepartment_none=Keine \u00fcbergeordnete Abteilung gefunden
|
||||
sciorganization.ui.department.superdepartment=\u00dcbergeordnete Abteilung
|
||||
sciorganization.ui.department.superdepartment.remove=\u00dcbergeordnete Abteilung entfernen
|
||||
|
|
|
|||
|
|
@ -294,10 +294,10 @@ public class SciProjectOrganizationsTable
|
|||
|
||||
SciProject project = (SciProject) m_itemModel.getSelectedObject(
|
||||
state);
|
||||
SciProjectSubProjectsCollection subProjects =
|
||||
project.getSubProjects();
|
||||
SciProjectOrganizationsCollection orgas =
|
||||
project.getOrganizations();
|
||||
|
||||
if ((subProjects.size() - 1) == row) {
|
||||
if ((orgas.size() - 1) == row) {
|
||||
Label label = new Label("");
|
||||
return label;
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -133,12 +133,6 @@ public class SciProjectSuperProjectSheet
|
|||
public boolean nextRow() {
|
||||
boolean ret;
|
||||
|
||||
/*if (m_superProject == null) {
|
||||
ret = false;
|
||||
} else {
|
||||
ret = true;
|
||||
m_superProject = null;
|
||||
}*/
|
||||
if (m_done) {
|
||||
logger.debug("Returning true for nextRow()");
|
||||
ret = true;
|
||||
|
|
|
|||
Loading…
Reference in New Issue