Hi, this is my first message to the list. I'm Vagelis Savvas and i'm
evaluating Seaside 2.8 as fetched from SqueakSource repository (Seaside2.8a1-lr.484) on Squeak 3.8 The bug i'm talking about shows up when you have a multiselect form element (WAMultiSelectTag) on a multipart form. Regardless of how many list entries someone selects, after posting the form, the callback block parameter refers to one only of the selected list entries. To see the bug in action just accept the following code in a component: renderContentOn: html html form multipart; with:[ html multiSelect list: (OrderedCollection with: 'first' with: 'second' with: 'third'); callback: [ :value | self halt ]. html button text:'post']. select more than one list entries, post and observe value on halt. The potential fix (i call it potential coz i'm not sure if its right) lies in WAKom>>processMultipartFields: The last line of this method reads like aRequest postFields at: chunk fieldName put: contents and with the fix it reads like: (aRequest postFields at: chunk fieldName ifPresent: [ :c | c add: contents]) ifNil:[ aRequest postFields at: chunk fieldName put: (OrderedCollection with: contents)]] If the fix is wrong what else can be done about it? Greetings, vagy _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
2007/9/19, Vagelis Savvas <[hidden email]>:
> Hi, this is my first message to the list. I'm Vagelis Savvas and i'm > evaluating Seaside 2.8 as fetched from SqueakSource repository > (Seaside2.8a1-lr.484) on Squeak 3.8 > > The bug i'm talking about shows up when you have a multiselect > form element (WAMultiSelectTag) on a multipart form. Regardless of > how many list entries someone selects, after posting the form, the > callback block parameter refers to one only of the selected list entries. > To see the bug in action just accept the following code in a component: > > renderContentOn: html > html form multipart; with:[ > html multiSelect list: (OrderedCollection with: 'first' with: 'second' > with: 'third'); > callback: [ :value | self halt ]. > html button text:'post']. > > select more than one list entries, post and observe value on halt. > > The potential fix (i call it potential coz i'm not sure if its right) > lies in WAKom>>processMultipartFields: The last line of this method reads > like > > aRequest postFields at: chunk fieldName put: contents > > and with the fix it reads like: > > (aRequest postFields at: chunk fieldName ifPresent: [ :c | c add: > contents]) ifNil:[ > aRequest postFields at: chunk fieldName put: (OrderedCollection with: > contents)]] > > > If the fix is wrong what else can be done about it? I can confirm the bug. It seems to be a problem with at least my Swazoo 2 server adapter too. Cheers Philippe > Greetings, > vagy > _______________________________________________ > Seaside mailing list > [hidden email] > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside > _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
2007/9/19, Philippe Marschall <[hidden email]>:
> 2007/9/19, Vagelis Savvas <[hidden email]>: > > Hi, this is my first message to the list. I'm Vagelis Savvas and i'm > > evaluating Seaside 2.8 as fetched from SqueakSource repository > > (Seaside2.8a1-lr.484) on Squeak 3.8 > > > > The bug i'm talking about shows up when you have a multiselect > > form element (WAMultiSelectTag) on a multipart form. Regardless of > > how many list entries someone selects, after posting the form, the > > callback block parameter refers to one only of the selected list entries. > > To see the bug in action just accept the following code in a component: > > > > renderContentOn: html > > html form multipart; with:[ > > html multiSelect list: (OrderedCollection with: 'first' with: 'second' > > with: 'third'); > > callback: [ :value | self halt ]. > > html button text:'post']. > > > > select more than one list entries, post and observe value on halt. > > > > The potential fix (i call it potential coz i'm not sure if its right) > > lies in WAKom>>processMultipartFields: The last line of this method reads > > like > > > > aRequest postFields at: chunk fieldName put: contents > > > > and with the fix it reads like: > > > > (aRequest postFields at: chunk fieldName ifPresent: [ :c | c add: > > contents]) ifNil:[ > > aRequest postFields at: chunk fieldName put: (OrderedCollection with: > > contents)]] > > > > > > If the fix is wrong what else can be done about it? > > I can confirm the bug. It seems to be a problem with at least my > Swazoo 2 server adapter too. Bug is filed: http://bugs.squeak.org/view.php?id=6682 > Cheers > Philippe > > > Greetings, > > vagy > > _______________________________________________ > > Seaside mailing list > > [hidden email] > > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside > > > Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
2007/9/19, Philippe Marschall <[hidden email]>:
> 2007/9/19, Philippe Marschall <[hidden email]>: > > 2007/9/19, Vagelis Savvas <[hidden email]>: > > > Hi, this is my first message to the list. I'm Vagelis Savvas and i'm > > > evaluating Seaside 2.8 as fetched from SqueakSource repository > > > (Seaside2.8a1-lr.484) on Squeak 3.8 > > > > > > The bug i'm talking about shows up when you have a multiselect > > > form element (WAMultiSelectTag) on a multipart form. Regardless of > > > how many list entries someone selects, after posting the form, the > > > callback block parameter refers to one only of the selected list entries. > > > To see the bug in action just accept the following code in a component: > > > > > > renderContentOn: html > > > html form multipart; with:[ > > > html multiSelect list: (OrderedCollection with: 'first' with: 'second' > > > with: 'third'); > > > callback: [ :value | self halt ]. > > > html button text:'post']. > > > > > > select more than one list entries, post and observe value on halt. > > > > > > The potential fix (i call it potential coz i'm not sure if its right) > > > lies in WAKom>>processMultipartFields: The last line of this method reads > > > like > > > > > > aRequest postFields at: chunk fieldName put: contents > > > > > > and with the fix it reads like: > > > > > > (aRequest postFields at: chunk fieldName ifPresent: [ :c | c add: > > > contents]) ifNil:[ > > > aRequest postFields at: chunk fieldName put: (OrderedCollection with: > > > contents)]] > > > > > > > > > If the fix is wrong what else can be done about it? > > > > I can confirm the bug. It seems to be a problem with at least my > > Swazoo 2 server adapter too. > > Bug is filed: > http://bugs.squeak.org/view.php?id=6682 The bug is fixed in Seaside2.8a1-pmm.489. Thanks again for the report and fix. Your fix was almost correct. I had to change a bit more because in its current form it would trigger an inconsistency in the unicode handling that would break unicode handling for post fields. But that's now fixed too. Cheers Philippe > > Cheers > > Philippe > > > > > Greetings, > > > vagy > > > _______________________________________________ > > > Seaside mailing list > > > [hidden email] > > > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside > > > > > > Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Free forum by Nabble | Edit this page |