Syncing Foundry files
git-svn-id: https://svn.libreccm.org/ccm/trunk@2875 8810af33-2d31-482b-a856-94f89814c4dfmaster
parent
b18536aa4f
commit
e8a69ca7fb
|
|
@ -15,7 +15,6 @@
|
||||||
* License along with this library; if not, write to the Free Software
|
* License along with this library; if not, write to the Free Software
|
||||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package com.arsdigita.portalworkspace.ui;
|
package com.arsdigita.portalworkspace.ui;
|
||||||
|
|
||||||
import com.arsdigita.bebop.Page;
|
import com.arsdigita.bebop.Page;
|
||||||
|
|
@ -42,9 +41,8 @@ public abstract class AbstractWorkspaceComponent extends SimpleContainer {
|
||||||
private PersistentPortal m_portalDisplay;
|
private PersistentPortal m_portalDisplay;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default constructor creates a new, empty
|
* Default constructor creates a new, empty <code>AbstractWorkspaceComponent</code> using
|
||||||
* <code>AbstractWorkspaceComponent</code> using parents
|
* parents (SimpleContainer) default constructor.
|
||||||
* (SimpleContainer) default constructor.
|
|
||||||
*/
|
*/
|
||||||
public AbstractWorkspaceComponent() {
|
public AbstractWorkspaceComponent() {
|
||||||
this(null);
|
this(null);
|
||||||
|
|
@ -63,7 +61,7 @@ public abstract class AbstractWorkspaceComponent extends SimpleContainer {
|
||||||
m_workspace = workspace;
|
m_workspace = workspace;
|
||||||
m_details = new WorkspaceDetails(m_workspace);
|
m_details = new WorkspaceDetails(m_workspace);
|
||||||
m_portal = new DefaultPortalSelectionModel(new BigDecimalParameter(
|
m_portal = new DefaultPortalSelectionModel(new BigDecimalParameter(
|
||||||
"portal"));
|
"portal"));
|
||||||
m_portalList = createPortalList(m_portal);
|
m_portalList = createPortalList(m_portal);
|
||||||
m_portalDisplay = createPortalDisplay(m_portal);
|
m_portalDisplay = createPortalDisplay(m_portal);
|
||||||
|
|
||||||
|
|
@ -101,7 +99,7 @@ public abstract class AbstractWorkspaceComponent extends SimpleContainer {
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
protected abstract PersistentPortal createPortalDisplay(
|
protected abstract PersistentPortal createPortalDisplay(
|
||||||
PortalSelectionModel portal);
|
PortalSelectionModel portal);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -1,36 +1,36 @@
|
||||||
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
|
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
|
||||||
xmlns:define="/WEB-INF/bebop-define.tld"
|
xmlns:define="/WEB-INF/bebop-define.tld"
|
||||||
xmlns:show="/WEB-INF/bebop-show.tld"
|
xmlns:show="/WEB-INF/bebop-show.tld"
|
||||||
version="1.2">
|
version="1.2">
|
||||||
|
|
||||||
<jsp:directive.page import="com.arsdigita.dispatcher.DispatcherHelper"/>
|
<jsp:directive.page import="com.arsdigita.dispatcher.DispatcherHelper"/>
|
||||||
<jsp:directive.page import="com.arsdigita.kernel.permissions.PrivilegeDescriptor"/>
|
<jsp:directive.page import="com.arsdigita.kernel.permissions.PrivilegeDescriptor"/>
|
||||||
<jsp:directive.page import="com.arsdigita.portalworkspace.Workspace"/>
|
<jsp:directive.page import="com.arsdigita.portalworkspace.Workspace"/>
|
||||||
<jsp:directive.page import="com.arsdigita.portalworkspace.ui.AbstractWorkspaceComponent"/>
|
<jsp:directive.page import="com.arsdigita.portalworkspace.ui.AbstractWorkspaceComponent"/>
|
||||||
<jsp:directive.page import="com.arsdigita.portalworkspace.ui.WorkspaceSelectionDefaultModel"/>
|
<jsp:directive.page import="com.arsdigita.portalworkspace.ui.WorkspaceSelectionDefaultModel"/>
|
||||||
<jsp:directive.page import="com.arsdigita.toolbox.ui.ApplicationAuthenticationListener"/>
|
<jsp:directive.page import="com.arsdigita.toolbox.ui.ApplicationAuthenticationListener"/>
|
||||||
|
|
||||||
<jsp:scriptlet>
|
|
||||||
DispatcherHelper.cacheDisable(response);
|
|
||||||
</jsp:scriptlet>
|
|
||||||
|
|
||||||
<define:page name="viewWorkspace" application="portal"
|
|
||||||
title="Workspace" cache="true">
|
|
||||||
<jsp:scriptlet>
|
<jsp:scriptlet>
|
||||||
|
DispatcherHelper.cacheDisable(response);
|
||||||
|
</jsp:scriptlet>
|
||||||
|
|
||||||
|
<define:page name="viewWorkspace" application="portal"
|
||||||
|
title="Workspace" cache="true">
|
||||||
|
<jsp:scriptlet>
|
||||||
if (Workspace.getConfig().getCheckWorkspaceReadPermissions()) {
|
if (Workspace.getConfig().getCheckWorkspaceReadPermissions()) {
|
||||||
viewWorkspace.addRequestListener(
|
viewWorkspace.addRequestListener(
|
||||||
new ApplicationAuthenticationListener(PrivilegeDescriptor.READ));
|
new ApplicationAuthenticationListener(PrivilegeDescriptor.READ));
|
||||||
}
|
}
|
||||||
</jsp:scriptlet>
|
</jsp:scriptlet>
|
||||||
|
|
||||||
<define:component name="view"
|
<define:component name="view"
|
||||||
classname="com.arsdigita.portalworkspace.ui.WorkspaceViewer" />
|
classname="com.arsdigita.portalworkspace.ui.WorkspaceViewer" />
|
||||||
<jsp:scriptlet>
|
<jsp:scriptlet>
|
||||||
((AbstractWorkspaceComponent) view).setWorkspaceModel(
|
((AbstractWorkspaceComponent) view).setWorkspaceModel(
|
||||||
new WorkspaceSelectionDefaultModel());
|
new WorkspaceSelectionDefaultModel());
|
||||||
</jsp:scriptlet>
|
</jsp:scriptlet>
|
||||||
</define:page>
|
</define:page>
|
||||||
|
|
||||||
<show:all/>
|
<show:all/>
|
||||||
|
|
||||||
</jsp:root>
|
</jsp:root>
|
||||||
|
|
|
||||||
|
|
@ -29,13 +29,40 @@
|
||||||
|
|
||||||
<foundry:doc>
|
<foundry:doc>
|
||||||
<foundry:doc-desc>
|
<foundry:doc-desc>
|
||||||
Generates a HTML <code>a</code> element.
|
<p>
|
||||||
|
Generates a HTML <code>a</code> element. There are some differences to the
|
||||||
|
<code>a</code> element in HTML. First, there two attribute for the URL:
|
||||||
|
</p>
|
||||||
|
<dl>
|
||||||
|
<dt>
|
||||||
|
<code>href-property</code>
|
||||||
|
</dt>
|
||||||
|
<dd>
|
||||||
|
The name of a property of the current object which contains the URL for the
|
||||||
|
link.
|
||||||
|
</dd>
|
||||||
|
<dt>
|
||||||
|
<dt>
|
||||||
|
<code>href-static</code>
|
||||||
|
</dt>
|
||||||
|
<dd>
|
||||||
|
A static URL.
|
||||||
|
</dd>
|
||||||
|
</dt>
|
||||||
|
</dl>
|
||||||
|
<p>
|
||||||
|
The third variant for providing an URL is to call the template with a href
|
||||||
|
parameter in the XSL.
|
||||||
|
</p>
|
||||||
</foundry:doc-desc>
|
</foundry:doc-desc>
|
||||||
<foundry:doc-see-also>
|
<foundry:doc-see-also>
|
||||||
<foundry:doc-link href="http://www.w3.org/TR/html5/text-level-semantics.html#the-a-element"/>
|
<foundry:doc-link href="http://www.w3.org/TR/html5/text-level-semantics.html#the-a-element"/>
|
||||||
</foundry:doc-see-also>
|
</foundry:doc-see-also>
|
||||||
</foundry:doc>
|
</foundry:doc>
|
||||||
<xsl:template match="a">
|
<xsl:template match="a">
|
||||||
|
<xsl:with-param name="href" select="''"/>
|
||||||
|
<xsl:with-param name="title" select="''"/>
|
||||||
|
|
||||||
<a>
|
<a>
|
||||||
<xsl:if test="./@download">
|
<xsl:if test="./@download">
|
||||||
<xsl:attribute name="download">
|
<xsl:attribute name="download">
|
||||||
|
|
@ -52,6 +79,11 @@
|
||||||
<xsl:value-of select="./@href-static"/>
|
<xsl:value-of select="./@href-static"/>
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
|
<xsl:if test="$href != ''">
|
||||||
|
<xsl:attribute name="href">
|
||||||
|
<xsl:value-of select="$href"/>
|
||||||
|
</xsl:attribute>
|
||||||
|
</xsl:if>
|
||||||
<xsl:if test="./@href-lang">
|
<xsl:if test="./@href-lang">
|
||||||
<xsl:attribute name="hreflang">
|
<xsl:attribute name="hreflang">
|
||||||
<xsl:value-of select="./@href-lang"/>
|
<xsl:value-of select="./@href-lang"/>
|
||||||
|
|
@ -62,6 +94,16 @@
|
||||||
<xsl:value-of select="./@rel"/>
|
<xsl:value-of select="./@rel"/>
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
|
<xsl:if test="./title-static">
|
||||||
|
<xsl:attribute name="title">
|
||||||
|
<xsl:value-of select="foundry:get-static-text('', ./@static-title)"/>
|
||||||
|
</xsl:attribute>
|
||||||
|
</xsl:if>
|
||||||
|
<xsl:if test="$title != ''">
|
||||||
|
<xsl:attribute name="title">
|
||||||
|
<xsl:value-of select="$title"/>
|
||||||
|
</xsl:attribute>
|
||||||
|
</xsl:if>
|
||||||
<xsl:if test="./@type">
|
<xsl:if test="./@type">
|
||||||
<xsl:attribute name="type">
|
<xsl:attribute name="type">
|
||||||
<xsl:value-of select="./@type"/>
|
<xsl:value-of select="./@type"/>
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,65 @@
|
||||||
exclude-result-prefixes="xsl bebop foundry nav"
|
exclude-result-prefixes="xsl bebop foundry nav"
|
||||||
version="1.0">
|
version="1.0">
|
||||||
|
|
||||||
|
<foundry:doc>
|
||||||
|
<foundry:doc-attribute name="navigation-id">
|
||||||
|
The id of the navigation/category system from which URL should be retrieved. Default
|
||||||
|
value is <code>categoryMenu</code>, which is suitable in most cases.
|
||||||
|
</foundry:doc-attribute>
|
||||||
|
<foundry:doc-attribute name="show-description-text">
|
||||||
|
If set to <code>true</code> (true) the description text for the category system from the
|
||||||
|
data tree XML will be used as value of the title attribute.
|
||||||
|
If set to <code>false</code>, the translated name of the category system will be used.
|
||||||
|
</foundry:doc-attribute>
|
||||||
|
<foundry:doc-attribute name="use-static-title">
|
||||||
|
if set the to <code>true</code> (default) Foundry will try to translate the title of the
|
||||||
|
navigation/category system using the language file <code>lang/navigation.xml</code>.
|
||||||
|
If set to <code>false</code> the title is retrieved from the data tree XML.
|
||||||
|
</foundry:doc-attribute>
|
||||||
|
<foundry:doc-desc>
|
||||||
|
Environment for outputting the home link for a navigation/category system. This tag
|
||||||
|
only intializes the context. The link itself has to be rendered using the <code>a</code>
|
||||||
|
HTML tag. The title of the navigation is printed using the <code>navigation-title</code>
|
||||||
|
tag.
|
||||||
|
</foundry:doc-desc>
|
||||||
|
<foundry:doc-see-also>#a</foundry:doc-see-also>
|
||||||
|
<foundry:doc-see-also>#navigation-title</foundry:doc-see-also>
|
||||||
|
</foundry:doc>
|
||||||
|
<xsl:template match="navigation-home-link">
|
||||||
|
<xsl:variable name="navigation-id"
|
||||||
|
select="foundry:get-attribute-value('navigation-id', 'categoryMenu')"/>
|
||||||
|
|
||||||
|
<xsl:apply-templates>
|
||||||
|
<xsl:with-param name="href"
|
||||||
|
select="$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@url"/>
|
||||||
|
<xsl:with-param name="navigation-id" select="$navigation-id"/>
|
||||||
|
<xsl:with-param name="title">
|
||||||
|
<xsl:choose>
|
||||||
|
<xsl:when test="./@show-description-text = 'false'">
|
||||||
|
<xsl:choose>
|
||||||
|
<xsl:when test="./@use-static-title = 'false'">
|
||||||
|
<xsl:value-of select="$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@title"/>
|
||||||
|
</xsl:when>
|
||||||
|
<xsl:otherwise>
|
||||||
|
<xsl:value-of select="foundry:get-static-text('navigation',
|
||||||
|
$data-tree//nav:categoryMenu[@id=$navigation-id]/@navigation-id,
|
||||||
|
'false')"/>
|
||||||
|
</xsl:otherwise>
|
||||||
|
</xsl:choose>
|
||||||
|
</xsl:when>
|
||||||
|
<xsl:otherwise>
|
||||||
|
<xsl:value-of select="$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@description"/>
|
||||||
|
</xsl:otherwise>
|
||||||
|
</xsl:choose>
|
||||||
|
</xsl:with-param>
|
||||||
|
</xsl:apply-templates>
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
|
<xsl:template match="navigation-home-link//navigation-title">
|
||||||
|
<xsl:param name="navigation-id"/>
|
||||||
|
<xsl:value-of select="foundry:shying($data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@title)"/>
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
<xsl:template match="navigation-layout">
|
<xsl:template match="navigation-layout">
|
||||||
<xsl:apply-templates>
|
<xsl:apply-templates>
|
||||||
<xsl:with-param name="navigation-id"
|
<xsl:with-param name="navigation-id"
|
||||||
|
|
@ -26,33 +85,7 @@
|
||||||
</xsl:apply-templates>
|
</xsl:apply-templates>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
<xsl:template match="navigation-layout//navigation-home-link">
|
|
||||||
<xsl:param name="navigation-id"/>
|
|
||||||
<xsl:param name="show-description-text"/>
|
|
||||||
|
|
||||||
<a href="{$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@url}">
|
|
||||||
<xsl:attribute name="title">
|
|
||||||
<xsl:choose>
|
|
||||||
<xsl:when test="./@show-description-text = 'false'">
|
|
||||||
<xsl:choose>
|
|
||||||
<xsl:when test="./@use-static-title = 'false'">
|
|
||||||
<xsl:value-of select="$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@title"/>
|
|
||||||
</xsl:when>
|
|
||||||
<xsl:otherwise>
|
|
||||||
<xsl:value-of select="foundry:get-static-text('navigation',
|
|
||||||
$data-tree//nav:categoryMenu[@id=$navigation-id]/@navigation-id,
|
|
||||||
'false')"/>
|
|
||||||
</xsl:otherwise>
|
|
||||||
</xsl:choose>
|
|
||||||
</xsl:when>
|
|
||||||
<xsl:otherwise>
|
|
||||||
<xsl:value-of select="$data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@description"/>
|
|
||||||
</xsl:otherwise>
|
|
||||||
</xsl:choose>
|
|
||||||
</xsl:attribute>
|
|
||||||
<xsl:value-of select="foundry:shying($data-tree//nav:categoryMenu[@id=$navigation-id]/nav:category/@title)"/>
|
|
||||||
</a>
|
|
||||||
</xsl:template>
|
|
||||||
|
|
||||||
<xsl:template match="navigation-layout//navigation-link-list"
|
<xsl:template match="navigation-layout//navigation-link-list"
|
||||||
name="navigation-link-list">
|
name="navigation-link-list">
|
||||||
|
|
@ -95,13 +128,21 @@
|
||||||
<h1>applied navigation-link-list with these values:</h1>
|
<h1>applied navigation-link-list with these values:</h1>
|
||||||
<dl>
|
<dl>
|
||||||
<dt>navigation-id</dt>
|
<dt>navigation-id</dt>
|
||||||
<dd><xsl:value-of select="$navigation-id"/></dd>
|
<dd>
|
||||||
|
<xsl:value-of select="$navigation-id"/>
|
||||||
|
</dd>
|
||||||
<dt>min-level</dt>
|
<dt>min-level</dt>
|
||||||
<dd><xsl:value-of select="$min-level"/></dd>
|
<dd>
|
||||||
|
<xsl:value-of select="$min-level"/>
|
||||||
|
</dd>
|
||||||
<dt>max-level</dt>
|
<dt>max-level</dt>
|
||||||
<dd><xsl:value-of select="$max-level"/></dd>
|
<dd>
|
||||||
|
<xsl:value-of select="$max-level"/>
|
||||||
|
</dd>
|
||||||
<dt>current-level</dt>
|
<dt>current-level</dt>
|
||||||
<dd><xsl:value-of select="$current-level"/></dd>
|
<dd>
|
||||||
|
<xsl:value-of select="$current-level"/>
|
||||||
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
<xsl:if test="$current-level >= min-level">
|
<xsl:if test="$current-level >= min-level">
|
||||||
|
|
|
||||||
|
|
@ -44,56 +44,56 @@ public class SciProjectCSVExporter extends Program {
|
||||||
super("SciProjectCSVExporter", "1.0.0", "");
|
super("SciProjectCSVExporter", "1.0.0", "");
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(true)
|
.hasArg(true)
|
||||||
.withLongOpt(START_BEFORE)
|
.withLongOpt(START_BEFORE)
|
||||||
.withDescription(
|
.withDescription(
|
||||||
"Include only projects started before a data. Date is in ISO format (yyyy-mm-dd)")
|
"Include only projects started before a data. Date is in ISO format (yyyy-mm-dd)").
|
||||||
.create());
|
create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(true)
|
.hasArg(true)
|
||||||
.withLongOpt(START_AFTER)
|
.withLongOpt(START_AFTER)
|
||||||
.withDescription(
|
.withDescription(
|
||||||
"Include only projects started after a data. Date is in ISO format (yyyy-mm-dd)")
|
"Include only projects started after a data. Date is in ISO format (yyyy-mm-dd)").
|
||||||
.create());
|
create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(true)
|
.hasArg(true)
|
||||||
.withLongOpt(END_BEFORE)
|
.withLongOpt(END_BEFORE)
|
||||||
.withDescription(
|
.withDescription(
|
||||||
"Include only projects finished before a data. Date is in ISO format (yyyy-mm-dd)")
|
"Include only projects finished before a data. Date is in ISO format (yyyy-mm-dd)").
|
||||||
.create());
|
create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(true)
|
.hasArg(true)
|
||||||
.withLongOpt(END_AFTER)
|
.withLongOpt(END_AFTER)
|
||||||
.withDescription(
|
.withDescription(
|
||||||
"Include only projects finished after a data. Date is in ISO format (yyyy-mm-dd)")
|
"Include only projects finished after a data. Date is in ISO format (yyyy-mm-dd)").
|
||||||
.create());
|
create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(false)
|
.hasArg(false)
|
||||||
.withLongOpt(OMIT_FUNDING_VOLUME)
|
.withLongOpt(OMIT_FUNDING_VOLUME)
|
||||||
.withDescription("Omit funding volume")
|
.withDescription("Omit funding volume")
|
||||||
.create());
|
.create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(false)
|
.hasArg(false)
|
||||||
.withLongOpt(OMIT_FUNDING_CODE)
|
.withLongOpt(OMIT_FUNDING_CODE)
|
||||||
.withDescription("Omit funding code")
|
.withDescription("Omit funding code")
|
||||||
.create());
|
.create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(false)
|
.hasArg(false)
|
||||||
.withLongOpt(OMIT_ROLES)
|
.withLongOpt(OMIT_ROLES)
|
||||||
.withDescription("Omit roles")
|
.withDescription("Omit roles")
|
||||||
.create());
|
.create());
|
||||||
|
|
||||||
getOptions().addOption(OptionBuilder
|
getOptions().addOption(OptionBuilder
|
||||||
.hasArg(false)
|
.hasArg(false)
|
||||||
.withLongOpt(WITH_DESC)
|
.withLongOpt(WITH_DESC)
|
||||||
.withDescription("Add description to CSV")
|
.withDescription("Add description to CSV")
|
||||||
.create());
|
.create());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -141,10 +141,28 @@ public class SciProjectCSVExporter extends Program {
|
||||||
withDesc = true;
|
withDesc = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//First line with column labels
|
||||||
|
createColumn("Name", buffer);
|
||||||
|
createColumn("Begin", buffer);
|
||||||
|
createColumn("End", buffer);
|
||||||
|
createColumn("Members", buffer);
|
||||||
|
createColumn("Short description", buffer);
|
||||||
|
if (withDesc) {
|
||||||
|
createColumn("Description", buffer);
|
||||||
|
}
|
||||||
|
|
||||||
|
createColumn("Sponsors", buffer);
|
||||||
|
|
||||||
|
if (withFundingVolume) {
|
||||||
|
createColumn("Funding volme", buffer);
|
||||||
|
}
|
||||||
|
|
||||||
|
buffer.append(LINE_SEPARATOR);
|
||||||
|
|
||||||
while (projects.next()) {
|
while (projects.next()) {
|
||||||
|
|
||||||
final SciProject project = (SciProject) DomainObjectFactory.newInstance(projects
|
final SciProject project = (SciProject) DomainObjectFactory.newInstance(projects
|
||||||
.getDataObject());
|
.getDataObject());
|
||||||
|
|
||||||
createLine(project, buffer);
|
createLine(project, buffer);
|
||||||
|
|
||||||
|
|
@ -208,16 +226,16 @@ public class SciProjectCSVExporter extends Program {
|
||||||
|
|
||||||
while (members.next()) {
|
while (members.next()) {
|
||||||
buffer
|
buffer
|
||||||
.append(members.getSurname())
|
.append(members.getSurname())
|
||||||
.append(", ")
|
.append(", ")
|
||||||
.append(members.getGivenName());
|
.append(members.getGivenName());
|
||||||
|
|
||||||
if (withRoles) {
|
if (withRoles) {
|
||||||
final String roleName = members.getRoleName();
|
final String roleName = members.getRoleName();
|
||||||
final String roleLabel;
|
final String roleLabel;
|
||||||
|
|
||||||
final RelationAttributeCollection roles = new RelationAttributeCollection(
|
final RelationAttributeCollection roles = new RelationAttributeCollection(
|
||||||
SciProject.ROLE_ENUM_NAME, roleName);
|
SciProject.ROLE_ENUM_NAME, roleName);
|
||||||
roles.addLanguageFilter(Kernel.getConfig().getDefaultLanguage());
|
roles.addLanguageFilter(Kernel.getConfig().getDefaultLanguage());
|
||||||
|
|
||||||
if (roles.isEmpty()) {
|
if (roles.isEmpty()) {
|
||||||
|
|
@ -229,9 +247,9 @@ public class SciProjectCSVExporter extends Program {
|
||||||
}
|
}
|
||||||
|
|
||||||
buffer
|
buffer
|
||||||
.append(" (")
|
.append(" (")
|
||||||
.append(roleLabel)
|
.append(roleLabel)
|
||||||
.append(')');
|
.append(')');
|
||||||
}
|
}
|
||||||
|
|
||||||
buffer.append("; ");
|
buffer.append("; ");
|
||||||
|
|
@ -246,14 +264,14 @@ public class SciProjectCSVExporter extends Program {
|
||||||
while (sponsors.next()) {
|
while (sponsors.next()) {
|
||||||
if (withFundingCode && sponsors.getFundingCode() != null) {
|
if (withFundingCode && sponsors.getFundingCode() != null) {
|
||||||
buffer
|
buffer
|
||||||
.append(sponsors.getSponsor().getTitle())
|
.append(sponsors.getSponsor().getTitle())
|
||||||
.append(" (")
|
.append(" (")
|
||||||
.append(sponsors.getFundingCode())
|
.append(sponsors.getFundingCode())
|
||||||
.append(");");
|
.append(");");
|
||||||
} else {
|
} else {
|
||||||
buffer
|
buffer
|
||||||
.append(sponsors.getSponsor().getTitle())
|
.append(sponsors.getSponsor().getTitle())
|
||||||
.append("; ");
|
.append("; ");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue