portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From raph...@apache.org
Subject cvs commit: jakarta-jetspeed/src/java/org/apache/jetspeed/modules/pages JetspeedTemplatePage.java
Date Mon, 04 Jun 2001 17:21:10 GMT
raphael     01/06/04 10:21:10

  Modified:    src/java/org/apache/jetspeed/modules/pages
                        JetspeedTemplatePage.java
  Log:
  - fix default page search path
  - reenable message logging at debug level
  
  Revision  Changes    Path
  1.12      +15 -6     jakarta-jetspeed/src/java/org/apache/jetspeed/modules/pages/JetspeedTemplatePage.java
  
  Index: JetspeedTemplatePage.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/pages/JetspeedTemplatePage.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- JetspeedTemplatePage.java	2001/06/04 08:27:27	1.11
  +++ JetspeedTemplatePage.java	2001/06/04 17:21:07	1.12
  @@ -125,7 +125,7 @@
    *
    * @author <a href="mailto:john.mcnally@clearink.com">John D. McNally</a>
    * @author <a href="mailto:mbryson@mont.mindspring.com">Dave Bryson</a>
  - * @version $Id: JetspeedTemplatePage.java,v 1.11 2001/06/04 08:27:27 taylor Exp $
  + * @version $Id: JetspeedTemplatePage.java,v 1.12 2001/06/04 17:21:07 raphael Exp $
    */
   public class JetspeedTemplatePage extends DefaultPage
   {
  @@ -146,11 +146,20 @@
   
           // if only a screen but no template is specified, then we need to display
           // a legacy ecs screen --> screenTemplate = ECS
  -        if ( data.hasScreen() && (data.getTemplateInfo().getScreenTemplate() ==
null) )
  -            data.setScreenTemplate( "Ecs" );
  +        if ( data.getTemplateInfo().getScreenTemplate() == null )
  +        {
  +            String screen = TurbineTemplate.getDefaultScreen();
  +            String ext = TurbineTemplate.getDefaultExtension();
  +            
  +            if (!screen.endsWith(ext))
  +            {
  +                screen=screen+ext;
  +            }
  +            data.setScreenTemplate(screen);
  +        }
   
           String template = data.getTemplateInfo().getScreenTemplate();
  -        //Log.note("JetspeedTemplatePage: requested template = " + template);
  +        Log.debug("JetspeedTemplatePage: requested template = " + template);
   
           // get real path now - this is a fix to get us thru 1.3a2
           // when the TurbineTemplateService can locate resources by NLS and mediatype,
  @@ -158,7 +167,7 @@
   
           String locatedScreen = Profiler.locateScreenTemplate(data, template);
           data.setScreenTemplate( locatedScreen );
  -        Log.note("JetspeedTemplatePage: calculated template = " + locatedScreen);
  +        Log.debug("JetspeedTemplatePage: calculated template = " + locatedScreen);
   
           // -----------------------------------------------------------
           // Get screen and layout template (first screen then layout!!) 
  @@ -171,7 +180,7 @@
   
           String layout = Profiler.locateLayoutTemplate(data, template);
           data.setLayoutTemplate(layout);
  -        Log.note("JetspeedTemplatePage: layoutTemplate is finally " + layout);
  +        Log.debug("JetspeedTemplatePage: layoutTemplate is finally " + layout);
   
           if ( !data.hasScreen() )
           {
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message