Have you set the commandName for
uk.co.arjit.travelbeen.webapp.controller.UrlFormController to "url"? It
seems like you're using a Spring bind tag in urls.jsp that expects a command
name of "url". Hard to tell with the details posted.
On 5/17/07, Aled Rhys Jones <[EMAIL PROTECTED]> wrote:
Thanks for the reply. Still not sure what I'm doing wrong, as its very
similar to the tutorial example.
urls.jsp (list of urls) contains e.g the following:
<display:column property="id" escapeXml="true" sortable="true"
url="/urlForm.html" paramId="id" paramProperty="id"
titleKey="url.id"/>
I have a UrlFormController that is the same as the example
PersonFormController except it uses a Url model and UrlManager.
dispatch-servlet.xml contains the following:
<bean id="urlController"
class="uk.co.arjit.travelbeen.webapp.controller.UrlController">
<property name="urlManager" ref="urlManager"/>
</bean>
<bean id="urlFormController"
class="uk.co.arjit.travelbeen.webapp.controller.UrlFormController">
<property name="validator" ref="beanValidator"/>
<property name="successView" value="redirect:urls.html"/>
<property name="urlManager" ref="urlManager"/>
</bean>
<bean id="companyController"
class="uk.co.arjit.travelbeen.webapp.controller.CompanyController">
<property name="companyManager" ref="companyManager"/>
</bean>
<bean id="companyFormController"
class="uk.co.arjit.travelbeen.webapp.controller.CompanyFormController">
<property name="validator" ref="beanValidator"/>
<property name="successView" value="redirect:companies.html"/>
<property name="companyManager" ref="companyManager"/>
</bean>
As mentioned earlier, company just has generic crud whilst url has an
extra method so requires its own dao and service classes.
All unit tests succeed.
Other web pages are companies.jsp, companyForm.jsp and urlForm.jsp.
Cheers
Aled
Matt Raible wrote:
> The first error is likely because you're navigating to the JSP
> directly, rather than going through a SimpleFormController. As for the
> 2nd issue, what is your Controller named? The
> ControllerClassNameHandlerMapping determines how URLs are created for
> controllers:
>
> http://tinyurl.com/3ce2zn
>
> Matt
>
> On 5/16/07, Aled Rhys Jones <[EMAIL PROTECTED]> wrote:
>> Hi everyone
>>
>> I've started developing with appfuse and so far its been great. I've
>> created two services, url and company, and all the tests pass including
>> the webb ones.
>> I think there's a problem with my jsp's however, as when I click on a
>> url in my url list page (urls.jsp) to go to the urlForm.jsp page, I get
>> the following error:
>> [myapp] ERROR [btpool0-8] HiddenInputTag.doStartTag(84) | Neither
>> BindingRe
>> sult nor plain target object for bean name 'url' available as request
>> attribute
>> java.lang.IllegalStateException: Neither BindingResult nor plain target
>> object f
>> or bean name 'url' available as request attribute
>>
>> My companies page (list of companies) doesn't load either. I get the
>> error:
>> [myapp] WARN [btpool0-9] PageNotFound.noHandlerFound(1003) | No
>> mapping for
>> [/companies.html] in DispatcherServlet with name 'dispatcher'
>>
>> Any ideas?
>>
>> Cheers
>> Aled
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]