Hi Isomorphic,
we are using a BatchUploader to import Data. I would like to check the data according to our business logic before the data gets shown in the BatchUploaders ListGrid, and mark rows, that match a specific needing without having a vaidation error. What I was thinking about is either
I was able to add a ClickHandler to the upload button via
That works, but what is the best practice then to get the data, before it arrives in the grid?
2.
I was not able to add a DataArrivedHandler to the ListGrid, what i tried is:
The data is shown in the grid without hitting the Handler. According to the docs https://www.smartclient.com/smartgwt...roperties.html
it says it should be possible. Please let me know if I did not use this right.
What I generally wanna do is check each row, if it meets some criteria. so when I´m in the Handler I need to make a fetch for this row and either mark it or not. Could You please give some advice, how to establish that in a good way.
Thanks in Advance,
Kind Regards
we are using a BatchUploader to import Data. I would like to check the data according to our business logic before the data gets shown in the BatchUploaders ListGrid, and mark rows, that match a specific needing without having a vaidation error. What I was thinking about is either
- add a ClickHandler on the uploadButton and then check the data or
- add a DataArrivedHandler on the ListGrid or
- make it as a validator, but as far as I know there is nothing like a "warning" validator, that would allow to commit the data anyway, right?
I was able to add a ClickHandler to the upload button via
Code:
ButtonItem uploadButtonTemplate = new ButtonItem(); uploadButtonTemplate.addClickHandler(new com.smartgwt.client.widgets.form.fields.events.ClickHandler() { @Override public void onClick(com.smartgwt.client.widgets.form.fields.events.ClickEvent event) { // TODO Auto-generated method stub } }); BatchUploader.changeAutoChildDefaults("uploadButton", uploadButtonTemplate);
2.
I was not able to add a DataArrivedHandler to the ListGrid, what i tried is:
Code:
ListGrid grid = new ListGrid() { { addDataArrivedHandler(new DataArrivedHandler() { @Override public void onDataArrived(DataArrivedEvent event) { } }); } }; BatchUploader.changeAutoChildDefaults("grid", grid);
it says it should be possible. Please let me know if I did not use this right.
What I generally wanna do is check each row, if it meets some criteria. so when I´m in the Handler I need to make a fetch for this row and either mark it or not. Could You please give some advice, how to establish that in a good way.
Thanks in Advance,
Kind Regards
Comment