You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@beehive.apache.org by anil kumar <ma...@gmail.com> on 2008/01/15 14:17:44 UTC

need small help....

Hi
        In http://beehive.apache.org/docs/1.0.2/netui/tags/datagrid.html,
The following example builds a custom pager that provides "jump to page"
functionality via an HTML select box, for example:

<netui-data:dataGrid dataSource="pageScope.pets" name="pets">
    <netui-data:configurePager defaultPageSize="2"
pagerFormat="firstPrevNextLast" disableDefaultPager="true"/>
    <netui-data:header>
        <netui-data:headerCell headerText="Name"/>
        <netui-data:headerCell headerText="Description"/>
        <netui-data:headerCell headerText="Price"/>
    </netui-data:header>
    <netui-data:rows>
        <netui-data:spanCell value="${container.item.name}"/>
        <netui-data:spanCell value="${container.item.description}"/>
        <netui-data:spanCell value="${container.item.price}"/>
    </netui-data:rows>
    <netui-data:footer>
        <td colspan="2" align="left">
          <netui-data:renderPager/>
        </td>
        <td colspan="1" align="right">
            <c:if test="${dataGrid.dataSet.size > 0}">
                <form name="pageForm" action="*simple-pager-jumptopage.jsp*
">
                Jump to Page:
                <script type="text/javascript">
                    function doPagerSubmit(comp)
                    {
                      var form = document.forms["pageForm"];
                      form.method="GET";
                      form.submit();
                    }
                </script>
                <select name="${dataGrid.urlBuilder.pagerRowQueryParamKey}"
onchange="doPagerSubmit(this); return true;">
                    <netui-data:repeater dataSource="
dataGrid.urlBuilder.pagerParamValues">
                        <c:choose>
                            <c:when test="${container.index ==
dataGrid.state.pagerModel.page}">
                                <option value="${container.item}"
selected="true">${container.index+1}</option>
                            </c:when>
                            <c:otherwise>
                                <option value="${container.item}">${
container.index+1}</option>
                            </c:otherwise>
                        </c:choose>
                    </netui-data:repeater>
                </select>
            </c:if>
        </td>
    </netui-data:footer>
</netui-data:dataGrid>


But in this code there is nothing mentioned abt "*
simple-pager-jumptopage.jsp*", while i'm trying to implement this code, but
it is not working... Can you please help me what is *
simple-pager-jumptopage.jsp. *why we need to use that...?


Thanks & Regards
Anil Kumar

Re: Error while doing a build

Posted by Eddie O'Neil <ek...@gmail.com>.
Sreera--

  It appears that you have the netui-compiler.jar file in your
classpath while you're trying to build Page Flows.  The error you're
seeing occurs because the NetUI annotation processor requires a value
for the web.content.root, which must be passed as a -A option to the
annotation processor.

  There are two ways to avoid this problem:

1) Remove the netui-compiler.jar file from your classpath entirely and
build Page Flows and Controls separately using the <build-controls>
and <build-pageflows> Ant macros.  For example:

  http://svn.apache.org/repos/asf/beehive/tags/v1.0.2/samples/netui-blank/build.xml

2) Avoid using the <build-*> Ant macros and instead use the <apt> task
directly.  Note, this passes a value for the "web.content.root"
annotation processor option.  For example:

  http://svn.apache.org/repos/asf/beehive/tags/v1.0.2/samples/netui-samples/build.xml

  HTH.

Eddie



On Jan 17, 2008 9:19 AM, Jayanti, Sreeramam
<Sr...@corp.aol.com> wrote:
> Hi,
>
> Iam trying to convert an application from WebLogic 8.1.5 to Apache
> Tomcat. I used the weblogic workshop 9.0 to convert the application. Iam
> using beehive 1.0.2. Iam able to convert it with some minor changes and
> compile it.
>
> In current application I have about 8 directories which have .java
> files. I was thinking of putting them into a directory by name utilities
> (this directory was not existing earlier). I copied them and changed all
> the references of these in the entire application. When I try to build
> the application I get below given error.
>
> I tried copying all the files to one existing directory by the name
> Utils and still got the same error.
>
> Iam not sure what Iam doing wrong. Appreciate if I could get some help
> in resolving this issue.
>
> Output from the ant build command in a command window
> ------------------------------------------------------
> C:\cvs\adsystems_web\cprApache>ant -version
> Apache Ant version 1.6.2 compiled on July 16 2004
> C:\cvs\adsystems_web\cprApache>ant build
> Buildfile: build.xml
>
> deploy-beehive:
>      [echo] Deploy NetUI to webapp C:\cvs\adsystems_web\cprApache\build
>
> deploy.beehive.webapp.runtime:
>      [echo] Deploy NetUI to webapp rooted at:
> C:\cvs\adsystems_web\cprApache\bui
> ld
>
> build:
>      [copy] Copying 23 files to C:\cvs\adsystems_web\cprApache\build
>      [echo] Building Controls
>       [apt] Compiling 103 source files to
> C:\cvs\adsystems_web\cprApache\build\W
> EB-INF\classes
>       [apt] error: The "-Aweb.content.root" option is required.  It is
> specified
>  by passing "-Aweb.content.root=<value>" as an option to apt.
>       [apt] Note: Some input files use or override a deprecated API.
>       [apt] Note: Recompile with -Xlint:deprecation for details.
>       [apt] 1 error
>
> BUILD FAILED
> C:\cvs\adsystems_web\cprApache\build.xml:84: The following error
> occurred while
> executing this line:
> C:\apache-beehive-1.0.2\ant\beehive-tools.xml:75: Compile failed; see
> the compil
> er error output for details.
>
> Total time: 41 seconds
> C:\cvs\adsystems_web\cprApache>
>
> Thanks
> Sreera,
>

Error while doing a build

Posted by "Jayanti, Sreeramam" <Sr...@corp.aol.com>.
Hi,

Iam trying to convert an application from WebLogic 8.1.5 to Apache
Tomcat. I used the weblogic workshop 9.0 to convert the application. Iam
using beehive 1.0.2. Iam able to convert it with some minor changes and
compile it.

In current application I have about 8 directories which have .java
files. I was thinking of putting them into a directory by name utilities
(this directory was not existing earlier). I copied them and changed all
the references of these in the entire application. When I try to build
the application I get below given error. 

I tried copying all the files to one existing directory by the name
Utils and still got the same error.

Iam not sure what Iam doing wrong. Appreciate if I could get some help
in resolving this issue.

Output from the ant build command in a command window
------------------------------------------------------
C:\cvs\adsystems_web\cprApache>ant -version
Apache Ant version 1.6.2 compiled on July 16 2004
C:\cvs\adsystems_web\cprApache>ant build
Buildfile: build.xml

deploy-beehive:
     [echo] Deploy NetUI to webapp C:\cvs\adsystems_web\cprApache\build

deploy.beehive.webapp.runtime:
     [echo] Deploy NetUI to webapp rooted at:
C:\cvs\adsystems_web\cprApache\bui
ld

build:
     [copy] Copying 23 files to C:\cvs\adsystems_web\cprApache\build
     [echo] Building Controls
      [apt] Compiling 103 source files to
C:\cvs\adsystems_web\cprApache\build\W
EB-INF\classes
      [apt] error: The "-Aweb.content.root" option is required.  It is
specified
 by passing "-Aweb.content.root=<value>" as an option to apt.
      [apt] Note: Some input files use or override a deprecated API.
      [apt] Note: Recompile with -Xlint:deprecation for details.
      [apt] 1 error

BUILD FAILED
C:\cvs\adsystems_web\cprApache\build.xml:84: The following error
occurred while
executing this line:
C:\apache-beehive-1.0.2\ant\beehive-tools.xml:75: Compile failed; see
the compil
er error output for details.

Total time: 41 seconds
C:\cvs\adsystems_web\cprApache>

Thanks
Sreera,

Re: need small help....

Posted by Eddie O'Neil <ek...@gmail.com>.
Anil--

  You're right that the documentation isn't very clear about this --
the "simple-pager-jumptopage.jsp" is the destination for the form
submit that handles changing the page.  In a simple case, it should
just be the name of the JSP that has the data grid.  In a more complex
case, it might be a Page Flow action.

  For example, if your page with the data grid is called "foo.jsp",
just set that to action="foo.jsp" to send the request back to that
page.

  Hope that helps.

Eddie




On Jan 15, 2008 6:17 AM, anil kumar <ma...@gmail.com> wrote:
> Hi
>         In http://beehive.apache.org/docs/1.0.2/netui/tags/datagrid.html,
> The following example builds a custom pager that provides "jump to page"
> functionality via an HTML select box, for example:
>
> <netui-data:dataGrid dataSource="pageScope.pets" name="pets">
>     <netui-data:configurePager defaultPageSize="2"
> pagerFormat="firstPrevNextLast" disableDefaultPager="true"/>
>     <netui-data:header>
>         <netui-data:headerCell headerText="Name"/>
>         <netui-data:headerCell headerText="Description"/>
>         <netui-data:headerCell headerText="Price"/>
>     </netui-data:header>
>     <netui-data:rows>
>         <netui-data:spanCell value="${container.item.name}"/>
>         <netui-data:spanCell value="${container.item.description}"/>
>         <netui-data:spanCell value="${container.item.price}"/>
>     </netui-data:rows>
>     <netui-data:footer>
>         <td colspan="2" align="left">
>           <netui-data:renderPager/>
>         </td>
>         <td colspan="1" align="right">
>             <c:if test="${dataGrid.dataSet.size > 0}">
>                 <form name="pageForm" action="*simple-pager-jumptopage.jsp*
> ">
>                 Jump to Page:
>                 <script type="text/javascript">
>                     function doPagerSubmit(comp)
>                     {
>                       var form = document.forms["pageForm"];
>                       form.method="GET";
>                       form.submit();
>                     }
>                 </script>
>                 <select name="${dataGrid.urlBuilder.pagerRowQueryParamKey}"
> onchange="doPagerSubmit(this); return true;">
>                     <netui-data:repeater dataSource="
> dataGrid.urlBuilder.pagerParamValues">
>                         <c:choose>
>                             <c:when test="${container.index ==
> dataGrid.state.pagerModel.page}">
>                                 <option value="${container.item}"
> selected="true">${container.index+1}</option>
>                             </c:when>
>                             <c:otherwise>
>                                 <option value="${container.item}">${
> container.index+1}</option>
>                             </c:otherwise>
>                         </c:choose>
>                     </netui-data:repeater>
>                 </select>
>             </c:if>
>         </td>
>     </netui-data:footer>
> </netui-data:dataGrid>
>
>
> But in this code there is nothing mentioned abt "*
> simple-pager-jumptopage.jsp*", while i'm trying to implement this code, but
> it is not working... Can you please help me what is *
> simple-pager-jumptopage.jsp. *why we need to use that...?
>
>
> Thanks & Regards
> Anil Kumar
>