diff --git a/source/java/org/alfresco/web/bean/CheckinCheckoutBean.java b/source/java/org/alfresco/web/bean/CheckinCheckoutBean.java index 8e6d736533..5836775611 100644 --- a/source/java/org/alfresco/web/bean/CheckinCheckoutBean.java +++ b/source/java/org/alfresco/web/bean/CheckinCheckoutBean.java @@ -650,26 +650,17 @@ public class CheckinCheckoutBean MimetypeMap.MIMETYPE_TEXT_CSS.equals(mimetype) || MimetypeMap.MIMETYPE_JAVASCRIPT.equals(mimetype)) { - // make content available to the editing screen + // make content available to the text editing screen setEditorOutput(reader.getContentString()); // navigate to appropriate screen FacesContext fc = FacesContext.getCurrentInstance(); this.navigator.setupDispatchContext(node); - String outcome; - if (MimetypeMap.MIMETYPE_XML.equals(mimetype)) - { - outcome = "dialog:editXmlInline"; - } - else - { - outcome = "dialog:editTextInline"; - } - fc.getApplication().getNavigationHandler().handleNavigation(fc, null, outcome); + fc.getApplication().getNavigationHandler().handleNavigation(fc, null, "dialog:editTextInline"); } else { - // make content available to the editing screen + // make content available to the html editing screen setDocumentContent(reader.getContentString()); setEditorOutput(null); diff --git a/source/java/org/alfresco/web/ui/repo/component/template/UITemplate.java b/source/java/org/alfresco/web/ui/repo/component/template/UITemplate.java index 19c0d096b1..81b3b93cff 100644 --- a/source/java/org/alfresco/web/ui/repo/component/template/UITemplate.java +++ b/source/java/org/alfresco/web/ui/repo/component/template/UITemplate.java @@ -247,7 +247,7 @@ public class UITemplate extends SelfRenderingComponent } /** - * Return the custom data model to bind template against. + * Return the custom data model to bind template against. Not cached. * * @return Returns the custom data model to bind template against. */ @@ -258,14 +258,14 @@ public class UITemplate extends SelfRenderingComponent ValueBinding vb = getValueBinding("model"); if (vb != null) { - this.model = vb.getValue(getFacesContext()); + return vb.getValue(getFacesContext()); } } return this.model; } /** - * @param model The model to set. + * @param model The model to set. */ public void setModel(Object model) { diff --git a/source/web/WEB-INF/faces-config-navigation.xml b/source/web/WEB-INF/faces-config-navigation.xml index 040fd19cd4..87a1acf34a 100644 --- a/source/web/WEB-INF/faces-config-navigation.xml +++ b/source/web/WEB-INF/faces-config-navigation.xml @@ -133,10 +133,6 @@ editTextInline /jsp/dialog/edit-text-inline.jsp - - editXmlInline - /jsp/dialog/edit-xml-inline.jsp - diff --git a/source/web/jsp/dialog/edit-xml-inline.jsp b/source/web/jsp/dialog/edit-xml-inline.jsp deleted file mode 100644 index 0cdbe2f238..0000000000 --- a/source/web/jsp/dialog/edit-xml-inline.jsp +++ /dev/null @@ -1,227 +0,0 @@ -<%-- - * Copyright (C) 2005-2007 Alfresco Software Limited. - - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - - * This program 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 General Public License for more details. - - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * As a special exception to the terms and conditions of version 2.0 of - * the GPL, you may redistribute this Program in connection with Free/Libre - * and Open Source Software ("FLOSS") applications as described in Alfresco's - * FLOSS exception. You should have recieved a copy of the text describing - * the FLOSS exception, and it is also available here: - * http://www.alfresco.com/legal/licensing" ---%> -<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %> -<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %> -<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> -<%@ taglib uri="/WEB-INF/alfresco.tld" prefix="a" %> -<%@ taglib uri="/WEB-INF/repo.tld" prefix="r" %> - -<%@ page buffer="32kb" contentType="text/html;charset=UTF-8" %> -<%@ page isELIgnored="false" %> -<%@ page import="org.alfresco.web.ui.common.PanelGenerator" %> -<%@ page import="org.alfresco.web.bean.*, - org.alfresco.service.cmr.repository.*, - org.alfresco.web.bean.content.*, - org.alfresco.web.templating.*" %> -<%@ page import="java.io.*" %> -<%@ page import="org.alfresco.web.app.Application" %> -<%@ page import="org.alfresco.web.templating.*" %> -<%@ page import="org.w3c.dom.Document" %> -<% -final CheckinCheckoutBean ccb = (CheckinCheckoutBean) - session.getAttribute("CheckinCheckoutBean"); -NodeRef nr = ccb.getDocument().getNodeRef(); -String ttName = (String)ccb.getNodeService().getProperty(nr, TemplatingService.TT_QNAME); -final TemplatingService ts = TemplatingService.getInstance(); -final TemplateType tt = ts.getTemplateType(ttName); -TemplateInputMethod tim = tt.getInputMethods().get(0); -final InstanceData instanceData = new InstanceData() { - - public Document getContent() - { - try - { - return ccb.getEditorOutput() != null ? ts.parseXML(ccb.getEditorOutput()) : null; - } - catch (Exception e) - { - e.printStackTrace(); - return null; - } - } - - public void setContent(final Document d) - { - ccb.setEditorOutput(ts.writeXMLToString(d)); - } -}; -%> - - - - - - <%-- load a bundle of properties with I18N strings --%> - - - - - <%-- Main outer table --%> - - - <%-- Title bar --%> - - - - - <%-- Main area --%> - - <%-- Shelf --%> - - - <%-- Work Area --%> - - -
- <%@ include file="../parts/titlebar.jsp" %> -
- <%@ include file="../parts/shelf.jsp" %> - - - <%-- Breadcrumb --%> - <%@ include file="../parts/breadcrumb.jsp" %> - - <%-- Status and Actions --%> - - - - - - - <%-- separator row with gradient shadow --%> - - - - - - - <%-- Details --%> - - - - - - - <%-- Error Messages --%> - - - - - - - <%-- separator row with bottom panel graphics --%> - - - - - - -
- - <%-- Status and Actions inner contents table --%> - <%-- Generally this consists of an icon, textual summary and actions for the current object --%> - - - - - -
- -
''
-
-
- -
- - - - - - - - <%-- Inline editor --%> - - - -
- <%-- Hide the checkout info if this document is already checked out --%> - - <% PanelGenerator.generatePanelStart(out, request.getContextPath(), "yellowInner", "#ffffcc"); %> - - - - - - -
- - - - - -
- -
- <% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "yellowInner"); %> -
-
- <% PanelGenerator.generatePanelStart(out, request.getContextPath(), "greyround", "#F5F5F5"); %> - - - - - - - - -
- -
- -
- <% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "greyround"); %> -
- <% PanelGenerator.generatePanelStart(out, request.getContextPath(), "white", "white"); %> -<% tim.generate(instanceData, tt, out); %> - - <% PanelGenerator.generatePanelEnd(out, request.getContextPath(), "white"); %> -
-
- <%-- messages tag to show messages not handled by other specific message tags --%> - -
-
- -
- -
- - -