You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@continuum.apache.org by oc...@apache.org on 2008/07/20 06:54:59 UTC

svn commit: r678249 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ProjectGroupAction.java resources/localization/Continuum.properties webapp/WEB-INF/jsp/projectGroupSummary.jsp

Author: oching
Date: Sat Jul 19 21:54:59 2008
New Revision: 678249

URL: http://svn.apache.org/viewvc?rev=678249&view=rev
Log:
[CONTINUUM-801]
-show the project's homepage url in the project group summary

Modified:
    continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
    continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
    continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp

Modified: continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=678249&r1=678248&r2=678249&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java (original)
+++ continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java Sat Jul 19 21:54:59 2008
@@ -111,6 +111,8 @@
     private int buildDefinitionId;
 
     private String preferredExecutor = "maven2";
+    
+    private String url;
 
     public String summary()
         throws ContinuumException
@@ -177,6 +179,11 @@
                     {
                         nbShellProjects += 1;
                     }
+                    
+                    if( p.getId() == 1 )
+                    {
+                    	url = p.getUrl();
+                    }
                 }
 
                 int nbActualPreferredProject = nbMaven2Projects;
@@ -847,4 +854,14 @@
     {
         return preferredExecutor;
     }
+
+	public String getUrl() 
+	{
+		return url;
+	}
+
+	public void setUrl(String url) 
+	{
+		this.url = url;
+	}
 }

Modified: continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties?rev=678249&r1=678248&r2=678249&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties (original)
+++ continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties Sat Jul 19 21:54:59 2008
@@ -153,6 +153,7 @@
 projectGroup.name.label = Project Group Name
 projectGroup.groupId.label = Project Group Id
 projectGroup.description.label = Description
+projectGroup.url.label = Homepage Url
 projectGroup.projects.title = Member Projects
 projectGroup.tab.summary = Project Group Summary
 projectGroup.tab.members = Members

Modified: continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp?rev=678249&r1=678248&r2=678249&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp (original)
+++ continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp Sat Jul 19 21:54:59 2008
@@ -88,6 +88,10 @@
         <c1:data label="%{getText('projectGroup.name.label')}" name="projectGroup.name"/>
         <c1:data label="%{getText('projectGroup.groupId.label')}" name="projectGroup.groupId"/>
         <c1:data label="%{getText('projectGroup.description.label')}" name="projectGroup.description"/>
+        <c:if test="${url != null}">
+            <ww:url id="projectHomepageUrl" value="${url}" includeContext="false" includeParams="none"/>
+        	<c1:data label="%{getText('projectGroup.url.label')}" name="url" valueLink="%{'${projectHomepageUrl}'}"/>  
+        </c:if>
       </table>
     </div>
 



Re: svn commit: r678249 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ProjectGroupAction.java resources/localization/Continuum.properties webapp/WEB-INF/jsp/projectGroupSummary.jsp

Posted by Maria Odea Ching <oc...@apache.org>.
Ok, I guess I can put a check in there to only get the url for m1 & m2
projects and get the url from the parent pom instead of from the first
project.
Thanks Emm! :)

-Deng

On Tue, Jul 22, 2008 at 5:23 PM, Emmanuel Venisse <
emmanuel.venisse@gmail.com> wrote:

> You can let it at the group level but don't use the project id 1.
> In the group, you can find the parent pom, get the id of this project then
> you get the url.
>
> This feature will work only for maven (1 and 2) projects.
> We'll can add a new field in the db for url of shell/ant projects, but I'd
> prefer to not modify the db schema for 1.2
>
> Emmanuel
>
> On Tue, Jul 22, 2008 at 11:17 AM, Maria Odea Ching <oc...@apache.org>
> wrote:
>
> > Hi Emm,
> >
> > Do you think I should move this to the project level (project info page)?
> >
> > That's what I originally did, but the problem was that if it's a
> > multi-module project.. the module name just gets appended to the url
> > specified at the root pom and when you click the url, the page does not
> > exist. The sample project I used for testing this was archiva. Since the
> > url
> > set in the root pom is http://archiva.apache.org, in the modules.. the
> url
> > becomes http://archiva.apache.org/archiva-jetty,
> > http://archiva.apache.org/archiva-cli and so on, which doesn't
> necessarily
> > exist in the website :)
> >
> > Because of this, I moved the url to the group level and just got the
> first
> > project since that would represent the root project. But as you've
> pointed
> > out, if there are other projects (not specifically a module of the root
> > project) added to the group, then their urls wouldn't be captured. I
> > figured
> > a group should only contain projects that belong to or is related to that
> > group, so I only checked for the url of the first project in the group..
> :)
> >
> >
> > Thanks,
> > Deng
> >
> > On Tue, Jul 22, 2008 at 4:44 PM, Emmanuel Venisse <
> > emmanuel.venisse@gmail.com> wrote:
> >
> > > On Sun, Jul 20, 2008 at 6:54 AM, <oc...@apache.org> wrote:
> > >
> > > > Author: oching
> > > > Date: Sat Jul 19 21:54:59 2008
> > > > New Revision: 678249
> > > >
> > > > URL: http://svn.apache.org/viewvc?rev=678249&view=rev
> > > > Log:
> > > > [CONTINUUM-801]
> > > > -show the project's homepage url in the project group summary
> > > >
> > > > Modified:
> > > >
> > > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > >
> > > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > >
> > > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > >
> > > > Modified:
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > > URL:
> > > >
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=678249&r1=678248&r2=678249&view=diff
> > > >
> > > >
> > >
> >
> ==============================================================================
> > > > ---
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > > (original)
> > > > +++
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > > Sat Jul 19 21:54:59 2008
> > > > @@ -111,6 +111,8 @@
> > > >     private int buildDefinitionId;
> > > >
> > > >     private String preferredExecutor = "maven2";
> > > > +
> > > > +    private String url;
> > > >
> > > >     public String summary()
> > > >         throws ContinuumException
> > > > @@ -177,6 +179,11 @@
> > > >                     {
> > > >                         nbShellProjects += 1;
> > > >                     }
> > > > +
> > > > +                    if( p.getId() == 1 )
> > > > +                    {
> > > > +                       url = p.getUrl();
> > > > +                    }
> > >
> > >
> > > I don't think this test is correct.
> > > It will work only for the first project added in Continuum ;)
> > >
> > > Emmanuel
> > >
> > >
> > >
> > > >
> > > >                 }
> > > >
> > > >                 int nbActualPreferredProject = nbMaven2Projects;
> > > > @@ -847,4 +854,14 @@
> > > >     {
> > > >         return preferredExecutor;
> > > >     }
> > > > +
> > > > +       public String getUrl()
> > > > +       {
> > > > +               return url;
> > > > +       }
> > > > +
> > > > +       public void setUrl(String url)
> > > > +       {
> > > > +               this.url = url;
> > > > +       }
> > > >  }
> > > >
> > > > Modified:
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > > URL:
> > > >
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties?rev=678249&r1=678248&r2=678249&view=diff
> > > >
> > > >
> > >
> >
> ==============================================================================
> > > > ---
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > > (original)
> > > > +++
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > > Sat Jul 19 21:54:59 2008
> > > > @@ -153,6 +153,7 @@
> > > >  projectGroup.name.label = Project Group Name
> > > >  projectGroup.groupId.label = Project Group Id
> > > >  projectGroup.description.label = Description
> > > > +projectGroup.url.label = Homepage Url
> > > >  projectGroup.projects.title = Member Projects
> > > >  projectGroup.tab.summary = Project Group Summary
> > > >  projectGroup.tab.members = Members
> > > >
> > > > Modified:
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > > URL:
> > > >
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp?rev=678249&r1=678248&r2=678249&view=diff
> > > >
> > > >
> > >
> >
> ==============================================================================
> > > > ---
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > > (original)
> > > > +++
> > > >
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > > Sat Jul 19 21:54:59 2008
> > > > @@ -88,6 +88,10 @@
> > > >         <c1:data label="%{getText('projectGroup.name.label')}"
> > > > name="projectGroup.name"/>
> > > >         <c1:data label="%{getText('projectGroup.groupId.label')}"
> > > > name="projectGroup.groupId"/>
> > > >         <c1:data label="%{getText('projectGroup.description.label')}"
> > > > name="projectGroup.description"/>
> > > > +        <c:if test="${url != null}">
> > > > +            <ww:url id="projectHomepageUrl" value="${url}"
> > > > includeContext="false" includeParams="none"/>
> > > > +               <c1:data label="%{getText('projectGroup.url.label')}"
> > > > name="url" valueLink="%{'${projectHomepageUrl}'}"/>
> > > > +        </c:if>
> > > >       </table>
> > > >     </div>
> > > >
> > > >
> > > >
> > > >
> > >
> >
>

Re: svn commit: r678249 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ProjectGroupAction.java resources/localization/Continuum.properties webapp/WEB-INF/jsp/projectGroupSummary.jsp

Posted by Emmanuel Venisse <em...@gmail.com>.
You can let it at the group level but don't use the project id 1.
In the group, you can find the parent pom, get the id of this project then
you get the url.

This feature will work only for maven (1 and 2) projects.
We'll can add a new field in the db for url of shell/ant projects, but I'd
prefer to not modify the db schema for 1.2

Emmanuel

On Tue, Jul 22, 2008 at 11:17 AM, Maria Odea Ching <oc...@apache.org>
wrote:

> Hi Emm,
>
> Do you think I should move this to the project level (project info page)?
>
> That's what I originally did, but the problem was that if it's a
> multi-module project.. the module name just gets appended to the url
> specified at the root pom and when you click the url, the page does not
> exist. The sample project I used for testing this was archiva. Since the
> url
> set in the root pom is http://archiva.apache.org, in the modules.. the url
> becomes http://archiva.apache.org/archiva-jetty,
> http://archiva.apache.org/archiva-cli and so on, which doesn't necessarily
> exist in the website :)
>
> Because of this, I moved the url to the group level and just got the first
> project since that would represent the root project. But as you've pointed
> out, if there are other projects (not specifically a module of the root
> project) added to the group, then their urls wouldn't be captured. I
> figured
> a group should only contain projects that belong to or is related to that
> group, so I only checked for the url of the first project in the group.. :)
>
>
> Thanks,
> Deng
>
> On Tue, Jul 22, 2008 at 4:44 PM, Emmanuel Venisse <
> emmanuel.venisse@gmail.com> wrote:
>
> > On Sun, Jul 20, 2008 at 6:54 AM, <oc...@apache.org> wrote:
> >
> > > Author: oching
> > > Date: Sat Jul 19 21:54:59 2008
> > > New Revision: 678249
> > >
> > > URL: http://svn.apache.org/viewvc?rev=678249&view=rev
> > > Log:
> > > [CONTINUUM-801]
> > > -show the project's homepage url in the project group summary
> > >
> > > Modified:
> > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > >
> > >
> >
>  continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > >
> > > Modified:
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > URL:
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=678249&r1=678248&r2=678249&view=diff
> > >
> > >
> >
> ==============================================================================
> > > ---
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > (original)
> > > +++
> > >
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > > Sat Jul 19 21:54:59 2008
> > > @@ -111,6 +111,8 @@
> > >     private int buildDefinitionId;
> > >
> > >     private String preferredExecutor = "maven2";
> > > +
> > > +    private String url;
> > >
> > >     public String summary()
> > >         throws ContinuumException
> > > @@ -177,6 +179,11 @@
> > >                     {
> > >                         nbShellProjects += 1;
> > >                     }
> > > +
> > > +                    if( p.getId() == 1 )
> > > +                    {
> > > +                       url = p.getUrl();
> > > +                    }
> >
> >
> > I don't think this test is correct.
> > It will work only for the first project added in Continuum ;)
> >
> > Emmanuel
> >
> >
> >
> > >
> > >                 }
> > >
> > >                 int nbActualPreferredProject = nbMaven2Projects;
> > > @@ -847,4 +854,14 @@
> > >     {
> > >         return preferredExecutor;
> > >     }
> > > +
> > > +       public String getUrl()
> > > +       {
> > > +               return url;
> > > +       }
> > > +
> > > +       public void setUrl(String url)
> > > +       {
> > > +               this.url = url;
> > > +       }
> > >  }
> > >
> > > Modified:
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > URL:
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties?rev=678249&r1=678248&r2=678249&view=diff
> > >
> > >
> >
> ==============================================================================
> > > ---
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > (original)
> > > +++
> > >
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > > Sat Jul 19 21:54:59 2008
> > > @@ -153,6 +153,7 @@
> > >  projectGroup.name.label = Project Group Name
> > >  projectGroup.groupId.label = Project Group Id
> > >  projectGroup.description.label = Description
> > > +projectGroup.url.label = Homepage Url
> > >  projectGroup.projects.title = Member Projects
> > >  projectGroup.tab.summary = Project Group Summary
> > >  projectGroup.tab.members = Members
> > >
> > > Modified:
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > URL:
> > >
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp?rev=678249&r1=678248&r2=678249&view=diff
> > >
> > >
> >
> ==============================================================================
> > > ---
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > (original)
> > > +++
> > >
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > > Sat Jul 19 21:54:59 2008
> > > @@ -88,6 +88,10 @@
> > >         <c1:data label="%{getText('projectGroup.name.label')}"
> > > name="projectGroup.name"/>
> > >         <c1:data label="%{getText('projectGroup.groupId.label')}"
> > > name="projectGroup.groupId"/>
> > >         <c1:data label="%{getText('projectGroup.description.label')}"
> > > name="projectGroup.description"/>
> > > +        <c:if test="${url != null}">
> > > +            <ww:url id="projectHomepageUrl" value="${url}"
> > > includeContext="false" includeParams="none"/>
> > > +               <c1:data label="%{getText('projectGroup.url.label')}"
> > > name="url" valueLink="%{'${projectHomepageUrl}'}"/>
> > > +        </c:if>
> > >       </table>
> > >     </div>
> > >
> > >
> > >
> > >
> >
>

Re: svn commit: r678249 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ProjectGroupAction.java resources/localization/Continuum.properties webapp/WEB-INF/jsp/projectGroupSummary.jsp

Posted by Maria Odea Ching <oc...@apache.org>.
Hi Emm,

Do you think I should move this to the project level (project info page)?

That's what I originally did, but the problem was that if it's a
multi-module project.. the module name just gets appended to the url
specified at the root pom and when you click the url, the page does not
exist. The sample project I used for testing this was archiva. Since the url
set in the root pom is http://archiva.apache.org, in the modules.. the url
becomes http://archiva.apache.org/archiva-jetty,
http://archiva.apache.org/archiva-cli and so on, which doesn't necessarily
exist in the website :)

Because of this, I moved the url to the group level and just got the first
project since that would represent the root project. But as you've pointed
out, if there are other projects (not specifically a module of the root
project) added to the group, then their urls wouldn't be captured. I figured
a group should only contain projects that belong to or is related to that
group, so I only checked for the url of the first project in the group.. :)


Thanks,
Deng

On Tue, Jul 22, 2008 at 4:44 PM, Emmanuel Venisse <
emmanuel.venisse@gmail.com> wrote:

> On Sun, Jul 20, 2008 at 6:54 AM, <oc...@apache.org> wrote:
>
> > Author: oching
> > Date: Sat Jul 19 21:54:59 2008
> > New Revision: 678249
> >
> > URL: http://svn.apache.org/viewvc?rev=678249&view=rev
> > Log:
> > [CONTINUUM-801]
> > -show the project's homepage url in the project group summary
> >
> > Modified:
> >
> >
>  continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> >
> >
>  continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> >
> >
>  continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> >
> > Modified:
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > URL:
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=678249&r1=678248&r2=678249&view=diff
> >
> >
> ==============================================================================
> > ---
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > (original)
> > +++
> >
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> > Sat Jul 19 21:54:59 2008
> > @@ -111,6 +111,8 @@
> >     private int buildDefinitionId;
> >
> >     private String preferredExecutor = "maven2";
> > +
> > +    private String url;
> >
> >     public String summary()
> >         throws ContinuumException
> > @@ -177,6 +179,11 @@
> >                     {
> >                         nbShellProjects += 1;
> >                     }
> > +
> > +                    if( p.getId() == 1 )
> > +                    {
> > +                       url = p.getUrl();
> > +                    }
>
>
> I don't think this test is correct.
> It will work only for the first project added in Continuum ;)
>
> Emmanuel
>
>
>
> >
> >                 }
> >
> >                 int nbActualPreferredProject = nbMaven2Projects;
> > @@ -847,4 +854,14 @@
> >     {
> >         return preferredExecutor;
> >     }
> > +
> > +       public String getUrl()
> > +       {
> > +               return url;
> > +       }
> > +
> > +       public void setUrl(String url)
> > +       {
> > +               this.url = url;
> > +       }
> >  }
> >
> > Modified:
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > URL:
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties?rev=678249&r1=678248&r2=678249&view=diff
> >
> >
> ==============================================================================
> > ---
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > (original)
> > +++
> >
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> > Sat Jul 19 21:54:59 2008
> > @@ -153,6 +153,7 @@
> >  projectGroup.name.label = Project Group Name
> >  projectGroup.groupId.label = Project Group Id
> >  projectGroup.description.label = Description
> > +projectGroup.url.label = Homepage Url
> >  projectGroup.projects.title = Member Projects
> >  projectGroup.tab.summary = Project Group Summary
> >  projectGroup.tab.members = Members
> >
> > Modified:
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > URL:
> >
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp?rev=678249&r1=678248&r2=678249&view=diff
> >
> >
> ==============================================================================
> > ---
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > (original)
> > +++
> >
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> > Sat Jul 19 21:54:59 2008
> > @@ -88,6 +88,10 @@
> >         <c1:data label="%{getText('projectGroup.name.label')}"
> > name="projectGroup.name"/>
> >         <c1:data label="%{getText('projectGroup.groupId.label')}"
> > name="projectGroup.groupId"/>
> >         <c1:data label="%{getText('projectGroup.description.label')}"
> > name="projectGroup.description"/>
> > +        <c:if test="${url != null}">
> > +            <ww:url id="projectHomepageUrl" value="${url}"
> > includeContext="false" includeParams="none"/>
> > +               <c1:data label="%{getText('projectGroup.url.label')}"
> > name="url" valueLink="%{'${projectHomepageUrl}'}"/>
> > +        </c:if>
> >       </table>
> >     </div>
> >
> >
> >
> >
>

Re: svn commit: r678249 - in /continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ProjectGroupAction.java resources/localization/Continuum.properties webapp/WEB-INF/jsp/projectGroupSummary.jsp

Posted by Emmanuel Venisse <em...@gmail.com>.
On Sun, Jul 20, 2008 at 6:54 AM, <oc...@apache.org> wrote:

> Author: oching
> Date: Sat Jul 19 21:54:59 2008
> New Revision: 678249
>
> URL: http://svn.apache.org/viewvc?rev=678249&view=rev
> Log:
> [CONTINUUM-801]
> -show the project's homepage url in the project group summary
>
> Modified:
>
>  continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
>
>  continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
>
>  continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
>
> Modified:
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> URL:
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=678249&r1=678248&r2=678249&view=diff
>
> ==============================================================================
> ---
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> (original)
> +++
> continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java
> Sat Jul 19 21:54:59 2008
> @@ -111,6 +111,8 @@
>     private int buildDefinitionId;
>
>     private String preferredExecutor = "maven2";
> +
> +    private String url;
>
>     public String summary()
>         throws ContinuumException
> @@ -177,6 +179,11 @@
>                     {
>                         nbShellProjects += 1;
>                     }
> +
> +                    if( p.getId() == 1 )
> +                    {
> +                       url = p.getUrl();
> +                    }


I don't think this test is correct.
It will work only for the first project added in Continuum ;)

Emmanuel



>
>                 }
>
>                 int nbActualPreferredProject = nbMaven2Projects;
> @@ -847,4 +854,14 @@
>     {
>         return preferredExecutor;
>     }
> +
> +       public String getUrl()
> +       {
> +               return url;
> +       }
> +
> +       public void setUrl(String url)
> +       {
> +               this.url = url;
> +       }
>  }
>
> Modified:
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> URL:
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties?rev=678249&r1=678248&r2=678249&view=diff
>
> ==============================================================================
> ---
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> (original)
> +++
> continuum/trunk/continuum-webapp/src/main/resources/localization/Continuum.properties
> Sat Jul 19 21:54:59 2008
> @@ -153,6 +153,7 @@
>  projectGroup.name.label = Project Group Name
>  projectGroup.groupId.label = Project Group Id
>  projectGroup.description.label = Description
> +projectGroup.url.label = Homepage Url
>  projectGroup.projects.title = Member Projects
>  projectGroup.tab.summary = Project Group Summary
>  projectGroup.tab.members = Members
>
> Modified:
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> URL:
> http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp?rev=678249&r1=678248&r2=678249&view=diff
>
> ==============================================================================
> ---
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> (original)
> +++
> continuum/trunk/continuum-webapp/src/main/webapp/WEB-INF/jsp/projectGroupSummary.jsp
> Sat Jul 19 21:54:59 2008
> @@ -88,6 +88,10 @@
>         <c1:data label="%{getText('projectGroup.name.label')}"
> name="projectGroup.name"/>
>         <c1:data label="%{getText('projectGroup.groupId.label')}"
> name="projectGroup.groupId"/>
>         <c1:data label="%{getText('projectGroup.description.label')}"
> name="projectGroup.description"/>
> +        <c:if test="${url != null}">
> +            <ww:url id="projectHomepageUrl" value="${url}"
> includeContext="false" includeParams="none"/>
> +               <c1:data label="%{getText('projectGroup.url.label')}"
> name="url" valueLink="%{'${projectHomepageUrl}'}"/>
> +        </c:if>
>       </table>
>     </div>
>
>
>
>