[JBoss Seam] - @DataModelSelection always outjects first value in list
by paulharrington
I have a class which acts as a backing bean for a page with a datatable. A second class acts as a backing bean for a form, which alows a selected value from the table to be edited.
In the first class I use the @Datamodel component to outject the list, and the @DataModelSelection to outject the selected item.
The second class uses the @In annotation to pick up the selected value.
The problem is that Regardless of which value I click on my list in the xhtml page, the first entry in the list is always outjected, and hence picked up by the second component.
I am using seam 1.2.1
Can anyone help?
thanks
Paul
(below is the code for how I use the @DataModel, and @DataModelSelection annotations:
-----------------------------------------------
@SerializedConcurrentAccess @Synchronized @Name("appUserListAction")
@Stateful
public class AppUserListActionImpl
{
....
@DataModelSelection
@Out(required = false)
private AppUser appUser;
@DataModel(scope = ScopeType.PAGE)
private List myCurrentPage;
@Factory("myCurrentPage")
@Begin
public void initCurrentPage()
{
myCurrentPage = getService().getCurrentPage();
}
}
@Name("appUserAction")
@Scope(ScopeType.CONVERSATION)
public class AppUserActionImpl {
....
@In(required = false, create = true)
private AppUser appUser;
....
}
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4044095#4044095
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4044095
19 years, 1 month
[JBoss Seam] - Re: CRUD screen
by damianharvey
If you mean an all-on-one-page CRUD, I'm doing this using a Seam Gen'd application and using the EntityHome objects.
On the left of the screen is my input form. No real difference to the ones created by Seam Gen but the page.xml returns the view to itself. On the right is the DataTable. This has a column with links for Edit and Delete as per below:
| <rich:column>
| <f:facet name="header">Action</f:facet>
| <s:link action="#{objectHome.find}"
| title="Click here to edit this record">
| <f:param name="objectId" value="#{tableVar.objectId}"/>
| <h:graphicImage url="/img/edit.png" border="0"/>
| </s:link>
| <s:link action="#{objectHome.remove}"
| onclick="return confirm('Are you sure you want to delete this row?');"
| title="Click here to delete this record">
| <f:param name="objectId" value="#{tableVar.objectId}"/>
| <h:graphicImage url="/img/cross.png" border="0"/>
| </s:link>
| </rich:column>
|
The page.xml has the param like this:
| <param name="objectId" value="#{objectHome.objectId}"/>
|
And in the objectHome after an Update or Persist I remove it from the all contexts:
| Contexts.removeFromAllContexts("objectHome");
|
This is working quite well for me at the moment, but the downside is that it exposes the IDs. Would welcome any improvements.
Cheers,
Damian.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4044091#4044091
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4044091
19 years, 1 month
[JBoss Messaging] - Re: AccessControlException
by colomb
Now upgraded to v1.2.0GA and we are still receiving an AccessControlException. I checked and the messaging-service.xml is configured to use the bisocket. Any help would be greatly appreciated.
| java.security.AccessControlException: access denied (java.net.SocketPermission 10.100.1.40:514 connect,resolve)
| at java.security.AccessControlContext.checkPermission(Unknown Source)
| at java.security.AccessController.checkPermission(Unknown Source)
| at java.lang.SecurityManager.checkPermission(Unknown Source)
| at java.lang.SecurityManager.checkConnect(Unknown Source)
| at java.net.DatagramSocket.send(Unknown Source)
| at org.apache.log4j.helpers.SyslogWriter.write(SyslogWriter.java:69)
| at org.apache.log4j.helpers.QuietWriter.write(QuietWriter.java:39)
| at org.apache.log4j.helpers.SyslogQuietWriter.write(SyslogQuietWriter.java:45)
| at org.apache.log4j.net.SyslogAppender.append(SyslogAppender.java:245)
| at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:221)
| at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:57)
| at org.apache.log4j.Category.callAppenders(Category.java:187)
| at org.apache.log4j.Category.forcedLog(Category.java:372)
| at org.apache.log4j.Category.log(Category.java:864)
| at org.jboss.logging.log4j.Log4jLoggerPlugin.error(Log4jLoggerPlugin.java:222)
| at org.jboss.logging.Logger.error(Logger.java:279)
| at org.jboss.jms.client.delegate.DelegateSupport.handleThrowable(DelegateSupport.java:224)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.org$jboss$jms$client$delegate$ClientConnectionFactoryDelegate$createConnectionDelegate$aop(ClientConnectionFactoryDelegate.java:179)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.java)
| at org.jboss.jms.client.container.StateCreationAspect.handleCreateConnectionDelegate(StateCreationAspect.java:83)
| at org.jboss.aop.advice.org.jboss.jms.client.container.StateCreationAspect0.invoke(StateCreationAspect0.java)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.java)
| at org.jboss.jms.client.container.ExceptionInterceptor.invoke(ExceptionInterceptor.java:71)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.java)
| at org.jboss.jms.client.container.ClientLogInterceptor.invoke(ClientLogInterceptor.java:107)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.invokeNext(ClientConnectionFactoryDelegate$createConnectionDelegate_4579211046834694258.java)
| at org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate.createConnectionDelegate(ClientConnectionFactoryDelegate.java)
| at org.jboss.jms.client.JBossConnectionFactory.createConnectionInternal(JBossConnectionFactory.java:212)
| at org.jboss.jms.client.JBossConnectionFactory.createQueueConnection(JBossConnectionFactory.java:102)
| at org.jboss.jms.client.JBossConnectionFactory.createQueueConnection(JBossConnectionFactory.java:96)
| at com.css.util.jms.jboss.JBossQueueFactoryImpl.connectQueues(JBossQueueFactoryImpl.java:31)
| at com.css.util.jms.CssJmsFactory.connectQueues(CssJmsFactory.java:52)
| at com.css.graphs.messages.client.ApplicationMessageClient.<init>(ApplicationMessageClient.java:34)
| at com.css.graphs.bonds.ApplicationMessageHandler.<init>(ApplicationMessageHandler.java:23)
| at com.css.graphs.bonds.Bond.<init>(Bond.java:152)
| at com.css.graphs.bonds.Bond.main(Bond.java:576)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
| at java.lang.reflect.Method.invoke(Unknown Source)
| at com.sun.javaws.Launcher.executeApplication(Unknown Source)
| at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
| at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
| at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
| at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
| at com.sun.javaws.Launcher.run(Unknown Source)
| at java.lang.Thread.run(Unknown Source)
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4044090#4044090
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4044090
19 years, 1 month