Page 1 of 1

Is it possible to do datamapping with Javascript. I want to bind 500 columns to the screen and it is to slow to do manua

Posted: Wed Jan 07, 2015 7:07 am
by Ahmet

Hi,

I want to map 500 columns from the database to the UI. Manually it is to slow.

Is it possible todo this with Javascript?

Thanks Image


Is it possible to do datamapping with Javascript. I want to bind 500 columns to the screen and it is to slow to do manua

Posted: Thu Jan 08, 2015 3:25 am
by Yurii Orishchuk

Hi Ahmet,

Yes, you can invoke service with JS code and pass there needed request parameters.

Also for you know:

1 "parameters" and "body" you can specify in any service you need.

2 It depends on server part how parameters should be passed.

3 here is correct code for better understanding it:

pre

dogsList2.execute({
//Specify url string parameters. (works in all HTTP methods)
parameters: {"www": "aa"},
//Specify body parameters. (not supports by "GET" or "DELETE" methods, see RFC for details).
body: {"bdf": "123"}
})

/pre

Regards.


Is it possible to do datamapping with Javascript. I want to bind 500 columns to the screen and it is to slow to do manua

Posted: Fri Jan 09, 2015 6:08 am
by Ahmet

Thanks, for the replay,

I have thinking about this isuue, What I need is to select 50 items (max) from a list of 500. And I have seen some examples how to do that.

If I let select 50 Checkbox items from a list of 500 and save this 50 boolean items in a Array then I have only to save this 1 array for each reacord I want to save, Is that correct?

Each record has between 20 and 50 checkbox items (selected from a list of 500) and some other fields, that is what I need. So I think I dont need to map 500 Colums to input fields at all, I think.

I need only to save a max of 50 checkbox Items for each record.

May I know what would your advise for me todo?

Thanks


Is it possible to do datamapping with Javascript. I want to bind 500 columns to the screen and it is to slow to do manua

Posted: Fri Jan 09, 2015 9:58 am
by Ihor Didevych

Hi Ahmet,

I have only to save this 1 array for each record I want to save, Is that correct?
Yes, you should make single request for each array

May I know what would your advise for me todo?
You can check selected fields and save only those