Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The RPCManager helper class which the smartclient gem supports can process the request. When the new object of the RPCManager class parses request and model, we need to set the model to the RPCManager object. After the new object of the RPCManager was created, if you call the processRequest, the gem will process the request.

The buildStandardCriteria method of the DataSource helper class is used when the user defines the filter for the front-end.

The complete code for this sample project can be downloaded from github.

...

We don't need to define the controller again.

The add, fetch, remove, update methods of the DataSource helper class of the gem is used for the CRUD through the RPCManager helper class.

The complete code for this sample project can be downloaded from github.

...

We don't need to define the controller again.

The processTransaction method of the RPCManager is used for the transaction.

5)  Adding support for AdvancedCriteria

...

As you can see it is a tree structure, with it's leafs being criterion and the nodes being criteria. If the the criteria member is null, then it is a leaf, otherwise it is a node which has sub-criterias or sub-criterions.

The buildCriterion method is called for this part.

6)  Make it data-driven

This example takes the previous sample and makes it data driven and adds a way for the user to define new DataSource types. It will also be extended to define a new DataSource and change the user interface to allow the user to switch between the two DataSources.

...