[Seasar-user:8248] Re: [S2JSF]DTOによるフォームデータの受け渡し

[E-MAIL ADDRESS DELETED] [E-MAIL ADDRESS DELETED]
2007年 6月 12日 (火) 16:23:23 JST


米林様

conpotaです。
できました。ありがとうございました。


07/06/12 に [E-MAIL ADDRESS DELETED] <[E-MAIL ADDRESS DELETED]> さんは書きました:
>
> 米林です。
>
> 回避策としては以下が考えられます。
> ------------------------------------
> test1Dtoのinstance属性をsessionにする
> ------------------------------------
> tesDtoのinstanceがrequestスコープであれば
> リクエスト毎に、testDtoのインスタンスが生成されます。
>
> よろしくお願いします。
>
> ----- Original Message -----
> From: <[E-MAIL ADDRESS DELETED]>
> Sent: Tuesday, June 12, 2007 2:12 PM
>
>
> > conpotaです。
> > exampleを試して自分で以下のように作ったのですが、うまくいかなかったので質問し
> ました。
> >
> > ■test1.html
> > <html xmlns:m="http://www.seasar.org/maya">
> > <head>
> > <meta http-equiv="Content-Type" content="text/html;
> charset=Windows-31j"/>
> > <title>test1</title>
> > </head>
> > <body>
> >     <form>
> >         <input type="text" id="message" m:value="#{test1Dto.message}"/>
> >         <input type="submit" value="calculate" m:action="#{
> > test1Action.calculate}"/>
> >     </form>
> > </body>
> > </html>
> >
> > ■Test1ActionImpl
> > public class Test1ActionImpl implements Test1Action {
> >
> >     private Test1Dto test1Dto;
> >
> >     public String calculate() {
> >         return "test1_next";
> >     }
> >     public void setTest1Dto(Test1Dto test1Dto) {
> >         this.test1Dto = test1Dto;
> >     }
> > }
> >
> > ■test1_next.html
> > <html xmlns:m="http://www.seasar.org/maya">
> > <head>
> > <meta http-equiv="Content-Type" content="text/html;
> charset=Windows-31j"/>
> > <title>test1_next</title>
> > </head>
> > <body>
> >     <span m:value="#{test1_nextDto.message}"/>
> > </body>
> > </html>
> >
> > ■Test1_nextActionImpl
> > public class Test1_nextActionImpl implements Test1_nextAction {
> >
> >     private Test1Dto test1Dto;
> >
> >     public void setTest1Dto(Test1Dto test1Dto) {
> >         this.test1Dto = test1Dto;
> >     }
> > }
> >
> > ■Test1Dto
> > public class Test1Dto implements Serializable {
> >
> >     private String message;
> >
> >     public String getMessage() {
> >         return message;
> >     }
> >     public void setMessage(String message) {
> >         this.message = message;
> >     }
> > }
> >
> > test1.htmlのインプットボックスに値を入力しサブミットすると、
> > test1_next.htmlは表示されますが、test1_nextDto.messageが表示されません。。
>
> ---
> 米林 正明
> [E-MAIL ADDRESS DELETED]
>
> _______________________________________________
> Seasar-user mailing list
> [E-MAIL ADDRESS DELETED]
> https://ml.seasar.org/mailman/listinfo/seasar-user
>



-- 
conpota <[E-MAIL ADDRESS DELETED]>
-------------- next part --------------
HTMLの添付ファイルを保管しました...
URL: http://ml.seasar.org/archives/seasar-user/attachments/20070612/f3313a4e/attachment.html 


Seasar-user メーリングリストの案内