This function get a table definition either from the server or from the cache and call success or failure function given with jdata if exists.


- tname : the table name to get

- relationship : the name of relation ship to get when reading tdf, skip or set to blank if not needed

- success : the function called if jdata.result=="ok"

- failure : the function called if jdata.result!="ok" or we have another failure situation. 

Function definitions for success and failure is:



- jdata | is the same as it would come from server {'result' : 'ok', 'tdf' :{'fdef' :[]}}

- status | can be null or a value that is returned from the ajax call in jqouery

- xhr | can be null or a value that comes from jquery

- who | will be gettdf

- fromurl | can be null or the url used to call server using ajax

How to use

To call this function you must have a valid deconnect initialized. Then you just call it and add the function to call when result is return as the success parameter.

var tname='Address';
  if (jdata.result=='ok'){
    var tdf = jdata.tdf;
    // do what you want with the tdf

Get the tdf only no relationships for the table Address