On Fri, Feb 11, 2011 at 17:44, slah <[email protected]> wrote:

>
> Ok, I see, I have to set cols before and can't change them after.
>
> Let's forget about Cols now (I've uncommented this line:
> tableModel.setColumns([ "id", "name", "age" ]);).
>
> Could you please tell me how to extract the "values" and set them as data
> for my table.
>

Assuming that you can get your server to stop serving up this:

   {
       "fields": ["id","name","age"],
       "values": [1,"xxx",21,
                       2,"yyy",22,
                       3,"zzz",23]
   }

and start serving up this into 'result' instead:

   {
       "fields": ["id","name","age"],
       "values":
        [
            [1,"xxx",21],
            [2,"yyy",22],
            [3,"zzz",23]
        ]
   }

then you'll set the table data with

  tableModel.setData(result.values);

Derrell
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to