Blessed Geek
Blessed Geek

Reputation: 21614

SmartGWT DataSource binding to ListGrid and DynamicForm

First let me warn readers not to pass me off to any links in isomorphic because it is highly probable I have read it and I have scoured the smartgwt showcase running locally here as I ask this question. What I ask is not documented and if it is, I am unable to decipher and need actual explanation here. No, do not tell me about SmartGWT EE. This case is purely Smartclient interacting with my JSP (or perl, php) on the server side, which I use to interact with a SAS backend.

This question has nothing to do with how to operate SAS. I am mentioning SAS to illustrate the point that smartclient has to interact with SAS web service directly and not through SmartGWT server. I asked a similar but different question at smartclient forum which is still unanswered, so this must be a very difficult subject that probably even people at isomorphic does not have an answer.

I have

I need to

This local-server management is what smartclient advertises itself as an advantage. The problems are

  1. my JSP is not registering smartclient sending any parameter to indicate what operation should be performed. It is only receiving the datasource fields=values as parameters for the affected records.
  2. the records are not appended or modified locally for add or edit operations.
  3. to overcome problem (1), I tried providing an extra non-displayed datasource field called operation. But when a dynamic form is bound to that datasource, the dynamicform field would not allow me to programmatically modify the operation field successfully.
  4. I tried appending operation as a DSRequest but my JSP is not receiving it either.

HOW does my JSP know what operation (ADD/REMOVE/EDIT) is being performed?

OK, to cut a long story short - datasource in SmartGWT is a horribly tricky business. I have been advised to use SmartGWT only for its UI but I should avoid using SmartGWT datasource because it is too tricky to deal with. Could some post or link me to examples of how you did your SmartGWT client programming in a configuration similar to mine.

Should I revert to using GWT 2.1M3 cell/page architecture and write my own rpc-table cells-form linking?

Upvotes: 0

Views: 5558

Answers (1)

Gwyn Evans
Gwyn Evans

Reputation: 1521

I think that you do actually need to be looking at the SmartGWT data sources, specifically the RestDataSource and quite possibly, the DataSource.setOperation() method.

Upvotes: 3

Related Questions