Kleinere Fehlerkorrekturen:
- Link.java und LinkPropertyForm.java: Hier fehlte an zwei Stellen eine Prüfung auf null, was unter bestimmten Bedingungen zu einer NullPointerException führte - CompoundContentPanel, SciOrganizationPanel und SciProjectPanel: Fehler im Paginator sowie einige Formatierungen git-svn-id: https://svn.libreccm.org/ccm/trunk@641 8810af33-2d31-482b-a856-94f89814c4dfmaster
parent
8539b1852b
commit
1ab5e0f6cc
|
|
@ -316,7 +316,7 @@ public class Link extends ACSObject {
|
||||||
String url = resolver.generateItemURL(
|
String url = resolver.generateItemURL(
|
||||||
state, item, section, item.getVersion());
|
state, item, section, item.getVersion());
|
||||||
|
|
||||||
if (getTargetURI().startsWith("&")) {
|
if ((getTargetURI() != null) && getTargetURI().startsWith("&")) {
|
||||||
ParameterMap parameters;
|
ParameterMap parameters;
|
||||||
StringTokenizer tokenizer;
|
StringTokenizer tokenizer;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -234,9 +234,9 @@ public abstract class CompoundContentItemPanel
|
||||||
paginator.addAttribute("pageNumber", Long.toString(pageNumber));
|
paginator.addAttribute("pageNumber", Long.toString(pageNumber));
|
||||||
paginator.addAttribute("pageCount", Long.toString(pageCount));
|
paginator.addAttribute("pageCount", Long.toString(pageCount));
|
||||||
paginator.addAttribute("pageSize", Long.toString(m_pageSize));
|
paginator.addAttribute("pageSize", Long.toString(m_pageSize));
|
||||||
paginator.addAttribute("objectBegin", Long.toString(begin));
|
paginator.addAttribute("objectBegin", Long.toString(begin + 1));
|
||||||
paginator.addAttribute("objectEnd", Long.toString(end));
|
paginator.addAttribute("objectEnd", Long.toString(end));
|
||||||
paginator.addAttribute("objectCount", Long.toString(count));
|
paginator.addAttribute("objectCount", Long.toString(count + 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -313,6 +313,8 @@ public abstract class CompoundContentItemPanel
|
||||||
|
|
||||||
exportAttributes(content);
|
exportAttributes(content);
|
||||||
|
|
||||||
|
content.addAttribute("showing", getShowParam(state));
|
||||||
|
|
||||||
return content;
|
return content;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -409,7 +409,8 @@ public class LinkPropertyForm extends FormSection
|
||||||
try {
|
try {
|
||||||
m_title.setValue(state, link.getTitle());
|
m_title.setValue(state, link.getTitle());
|
||||||
m_description.setValue(state, link.getDescription());
|
m_description.setValue(state, link.getDescription());
|
||||||
if (link.getTargetURI().startsWith("&")) {
|
if ((link.getTargetURI() != null)
|
||||||
|
&& link.getTargetURI().startsWith("&")) {
|
||||||
m_itemParams.setValue(state,
|
m_itemParams.setValue(state,
|
||||||
link.getTargetURI().substring(1));
|
link.getTargetURI().substring(1));
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -502,7 +502,7 @@ public class SciOrganizationPanel extends SciOrganizationBasePanel {
|
||||||
Element element,
|
Element element,
|
||||||
PageState state) {
|
PageState state) {
|
||||||
Element content = generateBaseXML(item, element, state);
|
Element content = generateBaseXML(item, element, state);
|
||||||
|
|
||||||
Element availableData = content.newChildElement("availableData");
|
Element availableData = content.newChildElement("availableData");
|
||||||
|
|
||||||
SciOrganization orga = (SciOrganization) item;
|
SciOrganization orga = (SciOrganization) item;
|
||||||
|
|
@ -578,8 +578,7 @@ public class SciOrganizationPanel extends SciOrganizationBasePanel {
|
||||||
} else if (SHOW_PROJECTS_ONGOING.equals(show)) {
|
} else if (SHOW_PROJECTS_ONGOING.equals(show)) {
|
||||||
generateProjectsXML(
|
generateProjectsXML(
|
||||||
orga, content, state, getFiltersForOngoingProjects());
|
orga, content, state, getFiltersForOngoingProjects());
|
||||||
} else if (SHOW_PROJECTS_FINISHED.equals(show)) {
|
} else if (SHOW_PROJECTS_FINISHED.equals(show)) {
|
||||||
Calendar today = new GregorianCalendar();
|
|
||||||
generateProjectsXML(
|
generateProjectsXML(
|
||||||
orga, content, state, getFiltersForFinishedProjects());
|
orga, content, state, getFiltersForFinishedProjects());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -235,12 +235,12 @@ public class SciProjectPanel extends SciOrganizationBasePanel {
|
||||||
|
|
||||||
String show = getShowParam(state);
|
String show = getShowParam(state);
|
||||||
|
|
||||||
if (SHOW_DESCRIPTION.equals(show)) {
|
if (SHOW_DESCRIPTION.equals(show)) {
|
||||||
String desc;
|
|
||||||
desc = project.getProjectDescription();
|
|
||||||
|
|
||||||
Element description = content.newChildElement("description");
|
Element description = content.newChildElement("description");
|
||||||
description.setText(desc);
|
description.setText(project.getProjectDescription());
|
||||||
|
|
||||||
|
Element funding = content.newChildElement("funding");
|
||||||
|
funding.setText(project.getFunding());
|
||||||
} else if (SHOW_CONTACTS.equals(show)) {
|
} else if (SHOW_CONTACTS.equals(show)) {
|
||||||
generateContactsXML(project, content, state);
|
generateContactsXML(project, content, state);
|
||||||
} else if (SHOW_SUBPROJECTS.equals(show)) {
|
} else if (SHOW_SUBPROJECTS.equals(show)) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue