Verbesserung der Globalisierung.

git-svn-id: https://svn.libreccm.org/ccm/trunk@2203 8810af33-2d31-482b-a856-94f89814c4df
master
pb 2013-06-12 01:38:42 +00:00
parent ee445f5ddd
commit 780137c5b5
26 changed files with 232 additions and 229 deletions

View File

@ -48,6 +48,12 @@ public class AgendaPropertiesStep extends SimpleEditStep {
/** The name of the editing sheet added to this step */
public static String EDIT_SHEET_NAME = "edit";
/**
* Constructor.
*
* @param itemModel
* @param parent
*/
public AgendaPropertiesStep(ItemSelectionModel itemModel,
AuthoringKitWizard parent ) {
super(itemModel, parent );

View File

@ -75,7 +75,7 @@ public class FileStorageItemPropertiesStep
sheet.add( GlobalizationUtil
.globalize("cms.ui.authoring.title"), FileStorageItem.TITLE );
sheet.add( GlobalizationUtil
.globalize("cms.contenttypes.summary"), FileStorageItem.DESCRIPTION );
.globalize("cms.contenttypes.ui.summary"), FileStorageItem.DESCRIPTION );
return sheet;
}

View File

@ -68,6 +68,7 @@ public class Organization extends ContentPage {
super(type);
}
@Override
public void beforeSave() {
super.beforeSave();
@ -114,6 +115,7 @@ public class Organization extends ContentPage {
}
@Override
public void delete() {
ImageAsset image = getImage();
if (image != null) {

View File

@ -1,6 +1,13 @@
organization.authoring.logo_image.title=Assign Logo Image
organization.authoring.logo_image.description=Assign Logo Image
cms.contenttypes.organization.image_option_null=Image Option was null
cms.contenttypes.organization.chose_image_when_ignoring=You specified an image when choosing to ignore
cms.contenttypes.organization.chose_image_when_deleting=You specified an image when choosing to delete
cms.contenttypes.organization.chose_image_when_uploading=You did not specify an image when choosing to upload
cms.contenttypes.ui.organization.image_option_null=Image Option was null
cms.contenttypes.ui.organization.chose_image_when_ignoring=You specified an image when choosing to ignore
cms.contenttypes.ui.organization.chose_image_when_deleting=You specified an image when choosing to delete
cms.contenttypes.ui.organization.chose_image_when_uploading=You did not specify an image when choosing to upload
cms.contenttypes.ui.organization.link=Link:
cms.contenttypes.ui.organization.contact=Contact:
cms.contenttypes.ui.organization.current_image=Current image:
cms.contenttypes.ui.organization.image=Image:
cms.contenttypes.ui.organization.file_upload=Upload
cms.contenttypes.ui.organization.file_delete=Delete
cms.contenttypes.ui.organization.file_ignore=Ignore

View File

@ -1,6 +1,13 @@
organization.authoring.logo_image.title=Logo zuordnen
organization.authoring.logo_image.description=Zuordnen eines Logos.
cms.contenttypes.organization.image_option_null=Option wae leer.
cms.contenttypes.organization.chose_image_when_ignoring=Ein Bild ist angegeben, obwohl Option Ignorieren gew\u00E4hlt wurde.
cms.contenttypes.organization.chose_image_when_deleting=Ein Bild ist angegeben, obwohl Option L\u00F6schen gew\u00E4hlt wurde.
cms.contenttypes.organization.chose_image_when_uploading=Ein Bild ist angegeben, obwohl Option Hochladen gew\u00E4hlt wurde.
cms.contenttypes.ui.organization.image_option_null=Option wae leerr
cms.contenttypes.ui.organization.chose_image_when_ignoring=Ein Bild ist angegeben, obwohl Option Ignorieren gew\u00e4hlt wurde.
cms.contenttypes.ui.organization.chose_image_when_deleting=Ein Bild ist angegeben, obwohl Option L\u00f6schen gew\u00e4hlt wurde.
cms.contenttypes.ui.organization.chose_image_when_uploading=Ein Bild ist angegeben, obwohl Option Hochladen gew\u00e4hlt wurde.
cms.contenttypes.ui.organization.link=Link:
cms.contenttypes.ui.organization.contact=Kontakt:
cms.contenttypes.ui.organization.current_image=Aktuelles Bild:
cms.contenttypes.ui.organization.image=Bild:
cms.contenttypes.ui.organization.file_upload=Hochladen
cms.contenttypes.ui.organization.file_delete=L\u00f6schen
cms.contenttypes.ui.organization.file_ignore=\u00dcberspringen

View File

@ -19,51 +19,32 @@
package com.arsdigita.cms.contenttypes.ui;
import com.arsdigita.bebop.ColumnPanel;
import com.arsdigita.bebop.FormData;
import com.arsdigita.bebop.event.FormInitListener;
import com.arsdigita.bebop.event.FormProcessListener;
import com.arsdigita.bebop.event.FormValidationListener;
import com.arsdigita.bebop.event.FormSubmissionListener;
import com.arsdigita.bebop.event.FormSectionEvent;
import com.arsdigita.bebop.form.FileUpload;
import com.arsdigita.bebop.form.FormErrorDisplay;
import com.arsdigita.bebop.Form;
import com.arsdigita.bebop.FormData;
import com.arsdigita.bebop.form.Option;
import com.arsdigita.bebop.form.RadioGroup;
import com.arsdigita.bebop.FormProcessException;
import com.arsdigita.bebop.Label;
import com.arsdigita.bebop.PageState;
import com.arsdigita.bebop.SaveCancelSection;
import com.arsdigita.bebop.form.FileUpload;
import com.arsdigita.bebop.form.FormErrorDisplay;
import com.arsdigita.bebop.form.Option;
import com.arsdigita.bebop.form.RadioGroup;
import com.arsdigita.bebop.event.FormInitListener;
import com.arsdigita.bebop.event.FormProcessListener;
import com.arsdigita.bebop.event.FormSectionEvent;
import com.arsdigita.bebop.event.FormSubmissionListener;
import com.arsdigita.bebop.event.FormValidationListener;
import com.arsdigita.bebop.parameters.StringParameter;
import com.arsdigita.cms.ItemSelectionModel;
import com.arsdigita.bebop.SaveCancelSection;
import com.arsdigita.cms.contenttypes.Organization;
import com.arsdigita.cms.contenttypes.util.OrganizationGlobalizationUtil;
import com.arsdigita.cms.ImageAsset;
import com.arsdigita.cms.ItemSelectionModel;
import com.arsdigita.cms.ui.ImageDisplay;
import com.arsdigita.dispatcher.MultipartHttpServletRequest;
import java.io.File;
import java.io.IOException;
import com.arsdigita.cms.ImageAsset;
import com.arsdigita.cms.contenttypes.Organization;
import com.arsdigita.cms.contenttypes.util.OrganizationGlobalizationUtil;
import com.arsdigita.bebop.Form;
import com.arsdigita.bebop.FormData;
import com.arsdigita.bebop.Label;
import com.arsdigita.bebop.PageState;
import com.arsdigita.bebop.ColumnPanel;
import com.arsdigita.bebop.SaveCancelSection;
import com.arsdigita.bebop.FormProcessException;
import com.arsdigita.bebop.event.FormInitListener;
import com.arsdigita.bebop.event.FormProcessListener;
import com.arsdigita.bebop.event.FormValidationListener;
import com.arsdigita.bebop.event.FormSubmissionListener;
import com.arsdigita.bebop.event.FormSectionEvent;
import com.arsdigita.bebop.form.FormErrorDisplay;
import com.arsdigita.bebop.parameters.StringParameter;
import com.arsdigita.cms.ItemSelectionModel;
import org.apache.log4j.Logger;
@ -73,9 +54,9 @@ import org.apache.log4j.Logger;
*
* @version $Id: OrganizationImageForm.java 757 2005-09-02 14:12:21Z sskracic $
*/
public class OrganizationImageForm
extends Form
implements FormInitListener, FormProcessListener, FormValidationListener,
public class OrganizationImageForm extends Form implements FormInitListener,
FormProcessListener,
FormValidationListener,
FormSubmissionListener {
private OrganizationImageStep m_step;
@ -119,7 +100,9 @@ public class OrganizationImageForm
this("OrganizationImageForm", itemModel, null);
}
public OrganizationImageForm(String name, ItemSelectionModel itemModel, OrganizationImageStep step) {
public OrganizationImageForm(String name,
ItemSelectionModel itemModel,
OrganizationImageStep step) {
super(name);
m_itemModel = itemModel;
@ -136,24 +119,39 @@ public class OrganizationImageForm
m_imageDisplay = new ImageDisplay(itemModel) {
protected ImageAsset getImageAsset(PageState state) {
ImageAsset image = (ImageAsset) ((Organization) getImageSelectionModel().getSelectedObject(state)).getImage();
ImageAsset image = (ImageAsset) ((Organization)
getImageSelectionModel()
.getSelectedObject(state))
.getImage();
return image;
}
};
StringParameter imageOptions = new StringParameter(IMAGE + IMAGE_OPTIONS);
m_group = new RadioGroup(imageOptions);
m_group.addOption(new Option(UPLOAD_OPTION, UPLOAD_OPTION));
m_group.addOption(new Option(DELETE_OPTION, DELETE_OPTION));
m_group.addOption(new Option(IGNORE_OPTION, IGNORE_OPTION));
m_group.addOption(new Option(
UPLOAD_OPTION,
new Label(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.ui.organization.file_upload"))
)); //UPLOAD_OPTION));
m_group.addOption(new Option(
DELETE_OPTION,
new Label(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.ui.organization.file_delete"))
)); //DELETE_OPTION));
m_group.addOption(new Option(
IGNORE_OPTION,
new Label(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.ui.organization.file_ignore"))
)); //IGNORE_OPTION));
m_group.setDefaultValue(IGNORE_OPTION);
m_currentLabel = new Label(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.current_image"));
("cms.contenttypes.ui.organization.current_image"));
add(m_currentLabel);
add(m_imageDisplay);
m_label = new Label(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.image"));
("cms.contenttypes.ui.organization.image"));
add(m_label);
m_upload = new FileUpload(IMAGE);
add(m_upload);
@ -177,14 +175,16 @@ public class OrganizationImageForm
/** Form initialisation hook. Fills widgets with data. */
public void init( FormSectionEvent fse ) {
PageState state = fse.getPageState();
Organization item = (Organization) getItemSelectionModel().getSelectedObject(state);
Organization item = (Organization) getItemSelectionModel()
.getSelectedObject(state);
}
/** Form processing hook. Saves Organization object. */
public void process( FormSectionEvent fse ) throws FormProcessException {
PageState state = fse.getPageState();
FormData data = fse.getFormData();
Organization item = (Organization) getItemSelectionModel().getSelectedObject(state);
Organization item = (Organization) getItemSelectionModel()
.getSelectedObject(state);
ImageAsset image = null;
@ -196,7 +196,8 @@ public class OrganizationImageForm
s_log.debug("uploading image");
String fileName = (String)(data.get(IMAGE));
if (fileName != null && fileName.length() > 0) {
File file = ((MultipartHttpServletRequest)state.getRequest()).getFile(IMAGE);
File file = ((MultipartHttpServletRequest)state
.getRequest()).getFile(IMAGE);
s_log.debug("file: " + file);
ImageAsset a = new ImageAsset();
a.setName(fileName);
@ -216,7 +217,7 @@ public class OrganizationImageForm
} else {
throw new FormProcessException
((String)(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.organization.image_option_null")
("cms.contenttypes.ui.organization.image_option_null")
.localize()));
}
} else if (imageOption != null && imageOption.equals(DELETE_OPTION)) {
@ -251,21 +252,24 @@ public class OrganizationImageForm
if (imageOption == null || imageOption.equals(IGNORE_OPTION)) {
if (fileName != null && !fileName.equals("")) {
data.addError(IMAGE,
data.addError(
IMAGE,
(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.organization.chose_image_when_ignoring")));
("cms.contenttypes.ui.organization.chose_image_when_ignoring")));
}
} else if (imageOption.equals(DELETE_OPTION)) {
if (fileName != null && !fileName.equals("")) {
data.addError(IMAGE,
data.addError(
IMAGE,
(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.organization.chose_image_when_deleting")));
("cms.contenttypes.ui.organization.chose_image_when_deleting")));
}
} else {
if (fileName == null || fileName.equals("")) {
data.addError(IMAGE,
data.addError(
IMAGE,
(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.organization.chose_image_when_uploading")));
("cms.contenttypes.ui.organization.chose_image_when_uploading")));
}
}
}

View File

@ -23,14 +23,14 @@ import com.arsdigita.cms.contenttypes.util.OrganizationGlobalizationUtil;
import com.arsdigita.bebop.PageState;
import com.arsdigita.cms.ContentItem;
// import com.arsdigita.cms.dispatcher.Utilities;
import com.arsdigita.cms.ItemSelectionModel;
import com.arsdigita.cms.ui.authoring.AuthoringKitWizard;
import com.arsdigita.cms.ui.authoring.SimpleEditStep;
import com.arsdigita.persistence.DataObject;
import com.arsdigita.domain.DomainObject;
import com.arsdigita.toolbox.ui.DomainObjectPropertySheet;
import com.arsdigita.cms.ui.authoring.WorkflowLockedComponentAccess;
// import com.arsdigita.cms.ui.authoring.WorkflowLockedComponentAccess;
import com.arsdigita.cms.ui.workflow.WorkflowLockedComponentAccess;
import com.arsdigita.cms.ImageAsset;
import com.arsdigita.cms.Service;
@ -43,24 +43,35 @@ import java.math.BigDecimal;
*
* @version $Id: OrganizationImageStep.java 755 2005-09-02 13:42:47Z sskracic $
*/
public class OrganizationImageStep
extends SimpleEditStep {
public class OrganizationImageStep extends SimpleEditStep {
/** The name of the editing sheet added to this step */
public static String IMAGE_SHEET_NAME = "image";
/**
* Constructor.
*
* @param itemModel
* @param parent
*/
public OrganizationImageStep( ItemSelectionModel itemModel,
AuthoringKitWizard parent ) {
super( itemModel, parent, "_image" );
setDefaultEditKey(IMAGE_SHEET_NAME);
add( IMAGE_SHEET_NAME, "Change",
// as soon as SecuityPropertyEditor is refactored to accept a Label or a
// GlobalizedMessage, the Label String has to be globalized!
add( IMAGE_SHEET_NAME,
"Change (OrgImageStep)",
new WorkflowLockedComponentAccess(new OrganizationImageForm(
"OrganizationImageForm", itemModel, this), itemModel));
"OrganizationImageForm", itemModel, this),
itemModel));
DomainObjectPropertySheet sheet = new DomainObjectPropertySheet(itemModel, false);
sheet.add(OrganizationGlobalizationUtil.globalize
("cms.contenttypes.image"), Organization.IMAGE, new ImageFormatter());
sheet.add(OrganizationGlobalizationUtil
.globalize("cms.contenttypes.ui.organization.image"),
Organization.IMAGE,
new ImageFormatter());
setDisplayComponent( sheet );
}
@ -72,7 +83,7 @@ public class OrganizationImageStep
private String m_default;
public ImageFormatter() {
this("<i>no image</i>");
this("no image");
}
public ImageFormatter(String def) {
@ -98,7 +109,7 @@ public class OrganizationImageStep
public static String getHTMLDisplay(ImageAsset image) {
if (image == null)
return ("<i>no image</i>");
return ("no image");
BigDecimal width = image.getWidth();
String widthStr = "";

View File

@ -27,6 +27,7 @@ import com.arsdigita.cms.ui.authoring.AuthoringKitWizard;
import com.arsdigita.cms.ui.authoring.BasicPageForm;
import com.arsdigita.cms.ui.authoring.SimpleEditStep;
import com.arsdigita.cms.ui.authoring.WorkflowLockedComponentAccess;
import com.arsdigita.cms.util.GlobalizationUtil;
import com.arsdigita.toolbox.ui.DomainObjectPropertySheet;
@ -69,9 +70,19 @@ public class OrganizationPropertiesStep
itemModel ) {
DomainObjectPropertySheet sheet = new DomainObjectPropertySheet( itemModel );
sheet.add(GlobalizationUtil
.globalize("cms.contenttypes.ui.title"),
Organization.TITLE);
sheet.add(GlobalizationUtil
.globalize("cms.contenttypes.ui.name"),
Organization.NAME);
sheet.add(OrganizationGlobalizationUtil.globalize("cms.contenttypes.link"), Organization.LINK);
sheet.add(OrganizationGlobalizationUtil.globalize("cms.contenttypes.contact"), Organization.CONTACT);
sheet.add(OrganizationGlobalizationUtil
.globalize("cms.contenttypes.ui.organization.link"),
Organization.LINK);
sheet.add(OrganizationGlobalizationUtil
.globalize("cms.contenttypes.ui.organization.contact"),
Organization.CONTACT);
return sheet;
}

View File

@ -26,7 +26,7 @@ import com.arsdigita.bebop.event.FormProcessListener;
import com.arsdigita.bebop.event.FormSectionEvent;
import com.arsdigita.bebop.event.FormSubmissionListener;
import com.arsdigita.bebop.form.TextField;
import com.arsdigita.bebop.parameters.ParameterModel;
// import com.arsdigita.bebop.parameters.ParameterModel;
import com.arsdigita.cms.ItemSelectionModel;
import com.arsdigita.cms.ui.authoring.BasicPageForm;
import com.arsdigita.cms.contenttypes.util.OrganizationGlobalizationUtil;
@ -68,7 +68,8 @@ public class OrganizationPropertyForm
* Organization to work on
* @param step The OrganizationPropertiesStep which controls this form.
*/
public OrganizationPropertyForm( ItemSelectionModel itemModel, OrganizationPropertiesStep step ) {
public OrganizationPropertyForm( ItemSelectionModel itemModel,
OrganizationPropertiesStep step ) {
super( ID, itemModel );
m_step = step;
addSubmissionListener(this);
@ -81,11 +82,13 @@ public class OrganizationPropertyForm
super.addWidgets();
TextField link = new TextField(LINK);
add(new Label(OrganizationGlobalizationUtil.globalize("cms.contenttypes.link")));
add(new Label(OrganizationGlobalizationUtil.globalize(
"cms.contenttypes.ui.organization.link")));
add(link);
TextField contact = new TextField(CONTACT);
add(new Label(OrganizationGlobalizationUtil.globalize("cms.contenttypes.contact")));
add(new Label(OrganizationGlobalizationUtil.globalize(
"cms.contenttypes.ui.organization.contact")));
add(contact);
}

View File

@ -63,15 +63,18 @@ public class OrganizationCreate extends PageCreate {
super.addWidgets();
TextField link = new TextField(LINK);
add(new Label(OrganizationGlobalizationUtil.globalize("cms.contenttypes.link")));
add(new Label(OrganizationGlobalizationUtil
.globalize("cms.contenttypes.ui.organization.link")));
add(link);
TextField contact = new TextField(CONTACT);
add(new Label(OrganizationGlobalizationUtil.globalize("cms.contenttypes.contact")));
add(new Label(OrganizationGlobalizationUtil
.globalize("cms.contenttypes.ui.organization.contact")));
add(contact);
}
@Override
public void process ( FormSectionEvent e ) throws FormProcessException {
FormData data = e.getFormData();

View File

@ -1,6 +1,6 @@
cms.contenttypes.siteproxy.error_fetching_url=Error fetching URL: {0}
cms.contenttypes.siteproxy.exception_fetching_url=Error fetching URL: {0} with exception of type " {1} " and message " {2} "
cms.contenttypes.siteproxy.empty_page_returned=Empty Page Returned for URL: {0}
cms.contenttypes.dispatcher.siteproxy.error_fetching_url=Error fetching URL: {0}
cms.contenttypes.dispatcher.siteproxy.exception_fetching_url=Error fetching URL: {0} with exception of type " {1} " and message " {2} "
cms.contenttypes.dispatcher.siteproxy.empty_page_returned=Empty Page Returned for URL: {0}
cms.contenttypes.ui.siteproxy.kit.label=Site Proxy
cms.contenttypes.ui.siteproxy.kit.description=A Proxy item for a page on an external site
cms.contenttypes.ui.siteproxy.atozstep.label=Edit AtoZ properties

View File

@ -1,8 +1,8 @@
cms.contenttypes.siteproxy.error_fetching_url=Fehler beim Lesen der URL: {0}
cms.contenttypes.siteproxy.exception_fetching_url=Fehler beim Lesen der URL: {0} mit Ausnahme Typ " {1} " und Nachricht " {2} "
cms.contenttypes.siteproxy.empty_page_returned=URL: {0} ergab eine leere Seite
cms.contenttypes.dispatcher.siteproxy.error_fetching_url=Fehler beim Lesen der URL: {0}
cms.contenttypes.dispatcher.siteproxy.exception_fetching_url=Fehler beim Lesen der URL: {0} mit Ausnahme Typ " {1} " und Nachricht " {2} "
cms.contenttypes.dispatcher.siteproxy.empty_page_returned=URL: {0} ergab eine leere Seite
cms.contenttypes.ui.siteproxy.kit.label=Site Proxy
cms.contenttypes.ui.siteproxy.kit.description=Ein Proxy Dokument Typ f\u00FCr eine Seite auf einem externen Server
cms.contenttypes.ui.siteproxy.kit.description=Ein Proxy Dokument Typ f\u00fcr eine Seite auf einem externen Server
cms.contenttypes.ui.siteproxy.atozstep.label= AtoZ Eigenschaften bearbeiten
cms.contenttypes.ui.siteproxy.atozstep.description= AtoZ Eigenschaften bearbeiten
cms.contenttypes.ui.siteproxy.label.atoztitle=AtoZ Titel

View File

@ -1,6 +1,6 @@
cms.contenttypes.siteproxy.error_fetching_url=Error fetching URL: {0}
cms.contenttypes.siteproxy.exception_fetching_url=Error fetching URL: {0} with exception of type " {1} " and message " {2} "
cms.contenttypes.siteproxy.empty_page_returned=Empty Page Returned for URL: {0}
cms.contenttypes.dispatcher.siteproxy.error_fetching_url=Error fetching URL: {0}
cms.contenttypes.dispatcher.siteproxy.exception_fetching_url=Error fetching URL: {0} with exception of type " {1} " and message " {2} "
cms.contenttypes.dispatcher.siteproxy.empty_page_returned=Empty Page Returned for URL: {0}
cms.contenttypes.ui.siteproxy.kit.label=Site Proxy
cms.contenttypes.ui.siteproxy.kit.description=A Proxy item for a page on an external site
cms.contenttypes.ui.siteproxy.atozstep.label=Edit AtoZ properties

View File

@ -23,6 +23,7 @@ import com.arsdigita.cms.contenttypes.SiteProxy;
import com.arsdigita.bebop.Component;
import com.arsdigita.cms.ui.authoring.BasicPageForm;
import com.arsdigita.cms.ItemSelectionModel;
import com.arsdigita.cms.contenttypes.util.SiteProxyGlobalizationUtil;
import com.arsdigita.cms.ui.authoring.AuthoringKitWizard;
import com.arsdigita.cms.ui.authoring.SimpleEditStep;
import com.arsdigita.toolbox.ui.DomainObjectPropertySheet;
@ -33,12 +34,17 @@ import com.arsdigita.cms.ui.workflow.WorkflowLockedComponentAccess;
* Authoring step to edit the simple attributes of the SiteProxy content
* type (and its subclasses).
*/
public class SiteProxyPropertiesStep
extends SimpleEditStep {
public class SiteProxyPropertiesStep extends SimpleEditStep {
/** The name of the editing sheet added to this step */
public static final String EDIT_SHEET_NAME = "edit";
/**
* Constructor.
*
* @param itemModel
* @param parent
*/
public SiteProxyPropertiesStep( ItemSelectionModel itemModel,
AuthoringKitWizard parent ) {
super( itemModel, parent );
@ -46,7 +52,9 @@ public class SiteProxyPropertiesStep
BasicPageForm editSheet;
editSheet = new SiteProxyPropertyForm( itemModel );
add( EDIT_SHEET_NAME, "Edit",
add( EDIT_SHEET_NAME,
"Edit", // Parent class SecurityPropertyEditor just aceppts
// a String here. Has to be modified after refactoring!
new WorkflowLockedComponentAccess(editSheet, itemModel),
editSheet.getSaveCancelSection().getCancelButton() );
@ -65,9 +73,15 @@ public class SiteProxyPropertiesStep
itemModel ) {
DomainObjectPropertySheet sheet = new DomainObjectPropertySheet( itemModel );
sheet.add( "Name:", SiteProxy.NAME );
sheet.add( "Title:", SiteProxy.TITLE );
sheet.add( "URL:", SiteProxy.URL );
sheet.add( SiteProxyGlobalizationUtil
.globalize("cms.contenttypes.ui.title"),
SiteProxy.TITLE );
sheet.add( SiteProxyGlobalizationUtil
.globalize("cms.contenttypes.ui.name"),
SiteProxy.NAME );
sheet.add( SiteProxyGlobalizationUtil
.globalize("cms.contenttypes.ui.url"),
SiteProxy.URL );
return sheet;
}

View File

@ -36,7 +36,8 @@ import com.arsdigita.cms.ui.authoring.BasicPageForm;
* extended to create forms for SiteProxy subclasses.
*/
public class SiteProxyPropertyForm extends BasicPageForm
implements FormProcessListener, FormInitListener {
implements FormProcessListener,
FormInitListener {
private TextField m_url;

View File

@ -138,6 +138,7 @@ public class SiteProxyPanel extends ContentPanel {
class SiteProxyXMLGenerator extends SimpleXMLGenerator {
@Override
public void generateXML(PageState state, Element parent, String useContext) {
ContentSection section = CMS.getContext().getContentSection();
@ -151,19 +152,19 @@ public class SiteProxyPanel extends ContentPanel {
if (data == null) {
String[] urlArray = {url};
(new Label(SiteProxyGlobalizationUtil.globalize
("cms.contenttypes.siteproxy.error_fetching_url",
("cms.contenttypes.dispatcher.siteproxy.error_fetching_url",
urlArray))).generateXML(state, parent);
} else if (data.getException() != null) {
String[] urlArray =
{url, data.getException().getClass().getName(),
data.getException().getMessage()};
(new Label(SiteProxyGlobalizationUtil.globalize
("cms.contenttypes.siteproxy.exception_fetching_url",
("cms.contenttypes.siteproxy.dispatcher.exception_fetching_url",
urlArray))).generateXML(state, parent);
} else if (data.getContent().length == 0) {
String[] urlArray = {url};
(new Label(SiteProxyGlobalizationUtil.globalize
("cms.contenttypes.siteproxy.empty_page_returned",
("cms.contenttypes.siteproxy.dispatcher.empty_page_returned",
urlArray))).generateXML(state, parent);
}
}

View File

@ -12,32 +12,13 @@ cms.image.not_a_jpeg_file=Not a JPEG file
cms.instantiationexception=Instantiation Exception:
cms.nosuchmethodexception=No-Such-Method Exception:
cms.templates=Templates
cms.title=Title
cms.ui.title=Title
mime_type_jsp=JSP
mime_type_xsl=XSL
cms.contentassets.ui.description=Description
# Package com.arsdigita.cms.contenttypes
# ======================================
cms.contenttypes.contact=Contact:
cms.contenttypes.contact_details=Contact Details:
cms.contenttypes.contact_information=Contact Information:
cms.contenttypes.contactinfo=ContactInfo:
cms.contenttypes.coudlnt_retrieve_text=Coudln't retrieve text
cms.contenttypes.event_type_not_registered=Event type not registered
#used in ccm-cms-types-organization
cms.contenttypes.image=Image:
cms.contenttypes.link=Link:
cms.contenttypes.no_content_section=No content section
cms.contenttypes.no_section=No section
cms.contenttypes.opening_time=Opening Time:
cms.contenttypes.person_specification=Person Specification:
cms.contenttypes.pressrelease_type_not_registered=PressRelease type not registered
cms.contenttypes.service_type_not_registered=Service type not registered
cms.contenttypes.services_provided=Services Provided:
cms.contenttypes.summary=Description:
cms.contenttypes.title=Page Title:
cms.contenttypes.template.body_text.title=Body text
cms.contenttypes.template.body_text.description=Edit the body text
cms.contenttypes.shared.assign_categories.title=Assign Categories
@ -46,35 +27,16 @@ cms.contenttypes.shared.basic_properties.description=Edit Basic Properties
cms.contenttypes.shared.basic_properties.title=Basic Properties
cms.contenttypes.shared.body_text.title=Body Text
cms.contenttypes.shared.body_text.description=Edit the Body Text
cms.contenttypes.ui.address=Address:
cms.contenttypes.ui.contact_info=Contact Info:
cms.contenttypes.ui.contacts=Contacts:
cms.contenttypes.ui.content_group_current_items=Current Items:
cms.contenttypes.ui.content_group_name=Content Group Name:
cms.contenttypes.ui.content_group_new_item=Add new item:
cms.contenttypes.ui.cost=Cost:
cms.contenttypes.ui.creation_date=Creation Date:
cms.contenttypes.ui.date=Date:
cms.contenttypes.ui.description=Description:
cms.contenttypes.ui.description_missing=Please enter a description
cms.contenttypes.ui.end_date=End Date:
cms.contenttypes.ui.end_time=End Time:
cms.contenttypes.ui.homepage=Homepage:
cms.contenttypes.ui.launch_date=Launch Date:
cms.contenttypes.ui.lead=Description:
cms.contenttypes.ui.lead_line=Description:
cms.contenttypes.ui.link_to_map=Link to Map:
cms.contenttypes.ui.location=Location:
cms.contenttypes.ui.main_contributor=Main Contributor:
cms.contenttypes.ui.name=Name (URL stub):
cms.contenttypes.ui.opening_times=Opening Times:
cms.contenttypes.ui.person_specification=Person Specification:
cms.contenttypes.ui.ref_code=Ref. Code:
cms.contenttypes.ui.reference_code=Reference Code:
cms.contenttypes.ui.services_provided=Services Provided:
cms.contenttypes.ui.start_date=Start Date:
cms.contenttypes.ui.start_time=Start Time:
cms.contenttypes.ui.subject_items=Subject Items:
cms.contenttypes.ui.summary=Description:
cms.contenttypes.ui.title=Title:
cms.contenttypes.ui.view_image=view image
@ -880,10 +842,6 @@ Thank you for using {3}.\n
# ===============================================
cms.ui.content_check_alert.subject=Content Check Alert
cms.ui.content_check_alert.body=Dear Author\n\nYou are listed as the Content Owner for the following {0} web page(s). Please check if they need amending or updating in any way:\n\n{1}\nIf you have any amendments or questions please email the appropriate web editor:\n\nsally.editor@aplaws.org (Council & Democracy, Environment, Education)\njohn.editor@aplaws.org (Community & Living, Business, Social Care)\nfrank.editor@aplaws.org (Council & Democracy, Environment, Education)\n\nYou can contact webmanager@aplaws.org with any questions about this email\n
cms.contenttypes.ui.address.email.desc=eMail
cms.contenttypes.ui.address.uri=URL
cms.contenttypes.ui.address.uri.desc=URL
cms.tasks.ui.anyone=Anyone
cms.tasks.ui.assigned_to=Assigned to
cms.tasks.ui.assignment_info=Assignment info

View File

@ -12,32 +12,13 @@ cms.image.not_a_jpeg_file=Keine JPEG Datei
cms.instantiationexception=Ausnahmebedinung bei Instantiierung:
cms.nosuchmethodexception=NoSuchMethodException:
cms.templates=Vorlagen
cms.title=Titel
cms.ui.title=Titel
mime_type_jsp=JSP
mime_type_xsl=XSL
cms.contentassets.ui.description=Beschreibung
# Package com.arsdigita.cms.contenttypes
# ======================================
cms.contenttypes.contact=Kontakt:
cms.contenttypes.contact_details=Kontaktdetails:
cms.contenttypes.contact_information=Kontaktinformation:
cms.contenttypes.contactinfo=Kontaktinformation:
cms.contenttypes.coudlnt_retrieve_text=Text konnte nicht gefunden werden
cms.contenttypes.event_type_not_registered=Veranstaltungs-Typ nicht registriert
#used in ccm-cms-types-organization
cms.contenttypes.image=Bilder:
cms.contenttypes.link=Link:
cms.contenttypes.no_content_section=Kein Inhaltsabschnitt
cms.contenttypes.no_section=Kein Abschnitt
cms.contenttypes.opening_time=\u00d6ffnungszeit\:
cms.contenttypes.person_specification=Person Spezifikation:
cms.contenttypes.pressrelease_type_not_registered=Inhaltstyp PressRelease nicht registriert
cms.contenttypes.service_type_not_registered=Inhaltstyp Service nicht registriert
cms.contenttypes.services_provided=Verf\u00fcgbare Services:
cms.contenttypes.summary=Beschreibung:
cms.contenttypes.title=Titel:
cms.contenttypes.template.body_text.title=Haupttext\:
cms.contenttypes.template.body_text.description=Haupttext bearbeiten
cms.contenttypes.shared.assign_categories.title=Kategorien zuweisen
@ -46,35 +27,16 @@ cms.contenttypes.shared.basic_properties.description=Basiseigenschaften bearbeit
cms.contenttypes.shared.basic_properties.title=Basiseigenschaften
cms.contenttypes.shared.body_text.title=Haupttext
cms.contenttypes.shared.body_text.description=Haupttext bearbeiten
cms.contenttypes.ui.address=Adresse:
cms.contenttypes.ui.contact_info=Kontaktinformation:
cms.contenttypes.ui.contacts=Kontakte:
cms.contenttypes.ui.content_group_current_items=Aktuelle Items:
cms.contenttypes.ui.content_group_name=Inhalt Gruppen Name:
cms.contenttypes.ui.content_group_new_item=Neues Dokument hinzuf\u00fcgen:
cms.contenttypes.ui.cost=Kosten:
cms.contenttypes.ui.creation_date=Erstellungsdatum:
cms.contenttypes.ui.date=Datum:
cms.contenttypes.ui.description=Beschreibung:
cms.contenttypes.ui.description_missing=Bitte eine Beschreibung eingeben
cms.contenttypes.ui.end_date=Enddatum:
cms.contenttypes.ui.end_time=Ende um\:
cms.contenttypes.ui.homepage=Homepage:
cms.contenttypes.ui.launch_date=Ver\u00f6ffentlichungsdatum:
cms.contenttypes.ui.lead=Beschreibung (Lead Text):
cms.contenttypes.ui.lead_line=Beschreibung (Lead Zeile):
cms.contenttypes.ui.link_to_map=Lageplan:
cms.contenttypes.ui.location=Ort:
cms.contenttypes.ui.main_contributor=Hauptredner\:
cms.contenttypes.ui.name=Name (als Teil-URL):
cms.contenttypes.ui.opening_times=\u00d6ffnungszeiten\:
cms.contenttypes.ui.person_specification=Person Specification:
cms.contenttypes.ui.ref_code=Ref. Code:
cms.contenttypes.ui.reference_code=Referenz Code:
cms.contenttypes.ui.services_provided=Verf\u00fcgbarer Service:
cms.contenttypes.ui.start_date=Anfangsdatum:
cms.contenttypes.ui.start_time=Anfangszeit:
cms.contenttypes.ui.subject_items=Thema Items:
cms.contenttypes.ui.summary=Beschreibung:
cms.contenttypes.ui.title=Titel:
cms.contenttypes.ui.view_image=Bild anzeigen
@ -873,10 +835,6 @@ Thank you for using {3}.\n
cms.ui.content_check_alert.subject=Content Check Alert
cms.ui.content_check_alert.body=Dear Author\n\nYou are listed as the Content Owner for the following {0} web page(s). Please check if they need amending or updating in any way:\n\n{1}\nIf you have any amendments or questions please email the appropriate web editor:\n\nsally.editor@aplaws.org (Council & Democracy, Environment, Education)\njohn.editor@aplaws.org (Community & Living, Business, Social Care)\nfrank.editor@aplaws.org (Council & Democracy, Environment, Education)\n\nYou can contact webmanager@aplaws.org with any questions about this email\n
cms.contenttypes.ui.address.email.desc=E-Mail
cms.contenttypes.ui.address.uri=URL
cms.contenttypes.ui.address.uri.desc=URL
cms.tasks.ui.anyone=Jedermann
cms.tasks.ui.assigned_to=Zugewiesen an:
cms.tasks.ui.assignment_info=Informationen \u00fcber die Zuweisung

View File

@ -17,26 +17,11 @@ cms.templates=Gabarits
# Package com.arsdigita.cms.contenttypes
# ======================================
cms.contenttypes.coudlnt_retrieve_text=Impossible d'afficher le texte
cms.contenttypes.no_content_section=Pas de r\u00e9pertoire de contenu
cms.contenttypes.no_section=Pas de repertoire
cms.contenttypes.pressrelease_type_not_registered=Type de PresserRel\u00e2cher non enregistr\u00e9
cms.contenttypes.service_type_not_registered=Type de service non enregistr\u00e9
cms.contenttypes.ui.address=Addresse
cms.contenttypes.ui.contact_info=Contact
cms.contenttypes.ui.contacts=Contacts
cms.contenttypes.ui.cost=Co\u00fbt
cms.contenttypes.ui.date=Date
cms.contenttypes.ui.description=Description
cms.contenttypes.ui.homepage=Accueil
cms.contenttypes.ui.lead=Fil conducteur
cms.contenttypes.ui.lead_line=Ligne de t\u00eate
cms.contenttypes.ui.link_to_map=Lien vers la carte
cms.contenttypes.ui.name=Nom (URL)
cms.contenttypes.ui.opening_times=Heures d'ouverture
cms.contenttypes.ui.person_specification=D\u00e9tails concernant la personne
cms.contenttypes.ui.ref_code=Code de r\u00e9f\u00e9rence
cms.contenttypes.ui.reference_code=Code de r\u00e9ference
cms.contenttypes.ui.services_provided=Services propos\u00e9s
cms.contenttypes.ui.summary=R\u00e9sum\u00e9
cms.contenttypes.ui.summary=R\u00e9sum\u00e9
cms.contenttypes.ui.title=Titre de la page
@ -500,9 +485,6 @@ cms.ui.workflow.you_are_assigned_to_this_item=Vous \u00eates assign\u00e9 \u00e0
cms.ui.workflow.your_active_tasks=Vos t\u00e2ches actives
cms.ui.workflows=Workflows
cms.ui.you_do_not_have_sufficient_privileges_to_access_this_page=Vous n'\u00eates pas autoris\u00e9 \u00e0 voir cette page.
cms.contenttypes.ui.address.uri=URL (TRANSLATE THIS cms.contenttypes.ui.address.uri)
cms.contenttypes.ui.address.email.desc=Means of contacting someone at this address (TRANSLATE THIS cms.contenttypes.ui.address.email.desc)
cms.contenttypes.ui.address.uri.desc=A URL to find more information about this Address (TRANSLATE THIS cms.contenttypes.ui.address.uri.desc)
cms.contenttypes.shared.basic_properties.title=Basic Properties
cms.ui.edit_assoc=
cms.ui.type.permissions=Permissions (Create new items of this type)
@ -565,3 +547,4 @@ cms.ui.authoring.file_upload.no_file=aucun
cms.ui.authoring.no_types_registered=Pas&nbsp;de&nbsp;types&nbsp;enregistr\u00e9
cms.ui.authoring.create_new=Cr\u00e9er&nbsp;un&nbsp;nouveau:
cms.ui.authoring.go=Go
cms.ui.title=Title

View File

@ -91,6 +91,8 @@ cms.contenttypes.ui.genericorgaunit.child.order=Order
cms.contenttypes.ui.genericorgaunit.child.up=Move up
cms.contenttypes.ui.genericorgaunit.confirm_delete=Confirm delete
cms.contenttypes.ui.genericorgaunit.contact.action=Action
#No contacts assoicated yet
#No contacts assoicated yet
cms.contenttypes.ui.genericorgaunit.contacts.none=No contacts
cms.contenttypes.ui.genericorgaunit.contact.title=Contacts
cms.contenttypes.ui.genericorgaunit.contact.type=Type

View File

@ -36,10 +36,19 @@ import com.arsdigita.cms.ui.workflow.WorkflowLockedComponentAccess;
import com.arsdigita.cms.contenttypes.util.ContenttypesGlobalizationUtil;
import java.text.DateFormat;
/**
*
*
*/
public class GenericPersonPropertiesStep extends SimpleEditStep {
public static final String EDIT_SHEET_NAME = "edit";
/**
*
* @param itemModel
* @param parent
*/
public GenericPersonPropertiesStep(ItemSelectionModel itemModel,
AuthoringKitWizard parent) {
super(itemModel, parent);

View File

@ -90,7 +90,6 @@ public class ImageDisplay extends SimpleComponent {
element.addAttribute("name", image.getName());
element.addAttribute("src", URL.getDispatcherPath() +
Service.getImageURL(image));
// Utilities.getImageURL(image));
BigDecimal width = image.getWidth();
if ( width != null ) {

View File

@ -38,7 +38,10 @@ import com.arsdigita.toolbox.ui.ComponentAccess;
public class WorkflowLockedComponentAccess extends ComponentAccess {
ItemSelectionModel m_itemModel;
/**
* Constructor.
*
* @param c The component
*/
public WorkflowLockedComponentAccess(Component c, ItemSelectionModel i) {
@ -47,10 +50,14 @@ public class WorkflowLockedComponentAccess extends ComponentAccess {
}
/**
* Constructor.
*
* @param c The component
* @param check An access check
*/
public WorkflowLockedComponentAccess(Component c, String check, ItemSelectionModel i) {
public WorkflowLockedComponentAccess(Component c,
String check,
ItemSelectionModel i) {
super(c,check);
m_itemModel = i;
}

View File

@ -61,9 +61,12 @@ public class ItemLanguagesTable extends DataTable {
super(new LanguagesBuilder(model));
m_model = model;
addColumn("cms.ui.language.header", ContentPage.LANGUAGE, false,
addColumn("cms.ui.language.header",
ContentPage.LANGUAGE,
false,
new LanguageCellRenderer(m_model));
addColumn("cms.title", ContentPage.TITLE);
addColumn("cms.ui.title",
ContentPage.TITLE);
m_deleteColumn = addColumn("cms.ui.action", new ActionCellRenderer(
m_model));
setResourceBundle(GlobalizationUtil.getBundleName());
@ -241,7 +244,14 @@ public class ItemLanguagesTable extends DataTable {
item.delete();
if (m_model.getSelectedKey(s).equals(id)) {
throw new RedirectSignal(URL.there((new MultilingualItemResolver().generateItemURL(s, bundle.getPrimaryInstance(), bundle.getContentSection(), ContentItem.DRAFT)), null), true);
throw new RedirectSignal(
URL.there((new MultilingualItemResolver()
.generateItemURL(s,
bundle.getPrimaryInstance(),
bundle.getContentSection(),
ContentItem.DRAFT)),
null),
true);
}
} catch (com.arsdigita.domain.DataObjectNotFoundException ex) {
// Object not found is ok, it has probably been deleted already

View File

@ -42,6 +42,8 @@ public class WorkflowLockedComponentAccess extends ComponentAccess {
ItemSelectionModel m_itemModel;
/**
* Constructor.
*
* @param c The component
*/
public WorkflowLockedComponentAccess(Component c, ItemSelectionModel i) {
@ -50,10 +52,14 @@ public class WorkflowLockedComponentAccess extends ComponentAccess {
}
/**
* Constructor.
*
* @param c The component
* @param check An access check
*/
public WorkflowLockedComponentAccess(Component c, String check, ItemSelectionModel i) {
public WorkflowLockedComponentAccess(Component c,
String check,
ItemSelectionModel i) {
super(c, check);
m_itemModel = i;
}
@ -76,11 +82,12 @@ public class WorkflowLockedComponentAccess extends ComponentAccess {
if (isVisible(state) == true) {
if (super.canAccess(state, security)) {
boolean smCheck = sm.canAccess(state.getRequest(), SecurityManager.EDIT_ITEM,
boolean smCheck = sm.canAccess(state.getRequest(),
SecurityManager.EDIT_ITEM,
item);
if (s_log.isDebugEnabled()) {
s_log.debug("Superclass security check passed. SecurityManager check is "
+ smCheck);
s_log.debug("Superclass security check passed. "
+ "SecurityManager check is " + smCheck);
}
return smCheck;
}

View File

@ -191,7 +191,7 @@ public class FormSection extends SimpleComponent implements Container {
try {
listener.submitted(e);
} catch (FormProcessException ex) {
s_log.error(ex);
s_log.debug(ex);
delayedException = ex;
}
}
@ -388,7 +388,7 @@ public class FormSection extends SimpleComponent implements Container {
listener.validate(e);
} catch (FormProcessException fpe) {
s_log.error(fpe);
s_log.debug(fpe);
data.addError(fpe.getMessage());
}
}
@ -503,9 +503,9 @@ public class FormSection extends SimpleComponent implements Container {
}
/**
* Since a form section cannot be processed, always throws an
* error. (Processing of form sections is done by the form in which
* the section is contained.)
* Since a form section cannot be processed, always throws an error.
* (Processing of form sections is done by the form in which the
* section is contained.)
*
* @throws javax.servlet.ServletException because processing a form section is
* not meaningful.