Author: almaw Date: Sun Jun 17 22:18:50 2007 New Revision: 548221 URL: http://svn.apache.org/viewvc?view=rev&rev=548221 Log: Make authorization look like the rest of it.
Added: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html (with props) incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java (with props) Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.java incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.html incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.java Added: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html?view=auto&rev=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html (added) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html Sun Jun 17 22:18:50 2007 @@ -0,0 +1,10 @@ +<html> +<head> + <title>Wicket Examples - Authorization Roles</title> + <link rel="stylesheet" type="text/css" href="style.css"/> +</head> +<body> + <span wicket:id="mainNavigation"/> + <wicket:child/> +</body> +</html> \ No newline at end of file Propchange: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.html ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java?view=auto&rev=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java (added) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java Sun Jun 17 22:18:50 2007 @@ -0,0 +1,27 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.wicket.examples.authorization; + +import org.apache.wicket.examples.WicketExamplePage; + +/** + * @author almaw + */ +public class BasePage extends WicketExamplePage +{ + +} Propchange: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/BasePage.java ------------------------------------------------------------------------------ svn:eol-style = native Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.html Sun Jun 17 22:18:50 2007 @@ -1,27 +1,4 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> +<wicket:extend> <div> The currently selected user is <strong> @@ -70,5 +47,4 @@ go to panels page, protected with annotations </a> </div> - </body> -</html> +</wicket:extend> \ No newline at end of file Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/Index.java Sun Jun 17 22:18:50 2007 @@ -37,7 +37,7 @@ * * @author Eelco Hillenius */ -public class Index extends WebPage +public class Index extends BasePage { /** * Construct. Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.html Sun Jun 17 22:18:50 2007 @@ -1,27 +1,3 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - Welcome! Seeing this bookmarkable page means that the currently selected user has at least role ADMIN. - </body> -</html> +<wicket:extend> + Welcome! Seeing this bookmarkable page means that the currently selected user has at least role ADMIN. +</wicket:extend> \ No newline at end of file Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsBookmarkablePage.java Sun Jun 17 22:18:50 2007 @@ -17,8 +17,7 @@ package org.apache.wicket.examples.authorization.pages; import org.apache.wicket.authorization.strategies.role.annotations.AuthorizeInstantiation; -import org.apache.wicket.markup.html.WebPage; - +import org.apache.wicket.examples.authorization.BasePage; /** * Bookmarkable page that may only be accessed by users that have role ADMIN. @@ -26,7 +25,7 @@ * @author Eelco Hillenius */ @AuthorizeInstantiation("ADMIN") -public class AdminAnnotationsBookmarkablePage extends WebPage +public class AdminAnnotationsBookmarkablePage extends BasePage { /** * Construct. Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.html Sun Jun 17 22:18:50 2007 @@ -1,27 +1,3 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - Welcome! Seeing this internal page means that the currently selected user has at least role ADMIN. - </body> -</html> +<wicket:extend> + Welcome! Seeing this internal page means that the currently selected user has at least role ADMIN. +</wicket:extend> Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminAnnotationsInternalPage.java Sun Jun 17 22:18:50 2007 @@ -17,8 +17,7 @@ package org.apache.wicket.examples.authorization.pages; import org.apache.wicket.authorization.strategies.role.annotations.AuthorizeInstantiation; -import org.apache.wicket.markup.html.WebPage; - +import org.apache.wicket.examples.authorization.BasePage; /** * Non-bookmarkable page that may only be accessed by users that have role @@ -27,7 +26,7 @@ * @author Eelco Hillenius */ @AuthorizeInstantiation("ADMIN") -public class AdminAnnotationsInternalPage extends WebPage +public class AdminAnnotationsInternalPage extends BasePage { /** * Construct. Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.html Sun Jun 17 22:18:50 2007 @@ -1,27 +1,3 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - Welcome! Seeing this bookmarkable page means that the currently selected user has at least role ADMIN. - </body> -</html> +<wicket:extend> + Welcome! Seeing this bookmarkable page means that the currently selected user has at least role ADMIN. +</wicket:extend> \ No newline at end of file Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminBookmarkablePage.java Sun Jun 17 22:18:50 2007 @@ -16,14 +16,14 @@ */ package org.apache.wicket.examples.authorization.pages; -import org.apache.wicket.markup.html.WebPage; +import org.apache.wicket.examples.authorization.BasePage; /** * Bookmarkable page that may only be accessed by users that have role ADMIN. * * @author Eelco Hillenius */ -public class AdminBookmarkablePage extends WebPage +public class AdminBookmarkablePage extends BasePage { /* * See for configuration of this class the [EMAIL PROTECTED] RolesApplication#init) Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.html Sun Jun 17 22:18:50 2007 @@ -1,27 +1,3 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - Welcome! Seeing this internal page means that the currently selected user has at least role ADMIN. - </body> -</html> +<wicket:extend> + Welcome! Seeing this internal page means that the currently selected user has at least role ADMIN. +</wicket:extend> Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AdminInternalPage.java Sun Jun 17 22:18:50 2007 @@ -16,7 +16,7 @@ */ package org.apache.wicket.examples.authorization.pages; -import org.apache.wicket.markup.html.WebPage; +import org.apache.wicket.examples.authorization.BasePage; /** * Non-bookmarkable page that may only be accessed by users that have role @@ -24,7 +24,7 @@ * * @author Eelco Hillenius */ -public class AdminInternalPage extends WebPage +public class AdminInternalPage extends BasePage { /* * See for configuration of this class the [EMAIL PROTECTED] RolesApplication#init) Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.html Sun Jun 17 22:18:50 2007 @@ -1,29 +1,5 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - This page has three panels. Depending on the roles of the selected user, you either see one, two or three of them. - </body> +<wicket:extend> + This page has three panels. Depending on the roles of the selected user, you either see one, two or three of them. <span wicket:id="forAllUsersPanel"> panel for all users here @@ -41,5 +17,4 @@ <div wicket:id="outer"> <span wicket:id="test">[nothing here yet]</span> </div> - -</html> +</wicket:extend> \ No newline at end of file Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/AnnotationsPanelsPage.java Sun Jun 17 22:18:50 2007 @@ -24,20 +24,19 @@ import org.apache.wicket.authorization.Action; import org.apache.wicket.authorization.strategies.role.Roles; import org.apache.wicket.authorization.strategies.role.annotations.AuthorizeAction; +import org.apache.wicket.examples.authorization.BasePage; import org.apache.wicket.markup.html.WebMarkupContainer; -import org.apache.wicket.markup.html.WebPage; import org.apache.wicket.markup.html.basic.Label; import org.apache.wicket.markup.html.list.ListItem; import org.apache.wicket.markup.html.list.ListView; import org.apache.wicket.markup.html.panel.Panel; - /** * Bookmarkable page that may only be accessed by users that have role ADMIN. * * @author Eelco Hillenius */ -public class AnnotationsPanelsPage extends WebPage +public class AnnotationsPanelsPage extends BasePage { @AuthorizeAction(action = Action.RENDER, roles = Roles.ADMIN) private static class AdminLabel extends Label Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.html URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.html?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.html (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.html Sun Jun 17 22:18:50 2007 @@ -1,29 +1,5 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<html> - <head> - <title> - Wicket Authorization Roles Example - </title> - <link rel="stylesheet" type="text/css" href="style.css" /> - </head> - <body> - This page has three panels. Depending on the roles of the selected user, you either see one, two or three of them. - </body> +<wicket:extend> + This page has three panels. Depending on the roles of the selected user, you either see one, two or three of them. <span wicket:id="forAllUsersPanel"> panel for all users here @@ -36,5 +12,4 @@ <span wicket:id="forAdminsPanel"> panel for only role ADMIN here </span> - -</html> +</wicket:extend> Modified: incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.java URL: http://svn.apache.org/viewvc/incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.java?view=diff&rev=548221&r1=548220&r2=548221 ============================================================================== --- incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.java (original) +++ incubator/wicket/trunk/jdk-1.5/wicket-examples/src/main/java/org/apache/wicket/examples/authorization/pages/PanelsPage.java Sun Jun 17 22:18:50 2007 @@ -17,7 +17,7 @@ package org.apache.wicket.examples.authorization.pages; import org.apache.wicket.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy; -import org.apache.wicket.markup.html.WebPage; +import org.apache.wicket.examples.authorization.BasePage; import org.apache.wicket.markup.html.panel.Panel; @@ -26,7 +26,7 @@ * * @author Eelco Hillenius */ -public class PanelsPage extends WebPage +public class PanelsPage extends BasePage { /** * Construct.