1
0
forked from GitHub/gf-core

minibar/pgf_online.js: pass arguments to the browse function in the same way as the other functions

Also document it in gf-web-api-examples.html.
This commit is contained in:
hallgren
2012-04-10 13:33:12 +00:00
parent 18185aba97
commit 15bf21c091
3 changed files with 15 additions and 4 deletions

View File

@@ -68,8 +68,9 @@ function pgf_online(options) {
translategroup: function(args,cont,err) { // from, input, cat, to
this.pgf_call("translategroup",args,cont,err);
},
browse: function(id,cont,err) {
this.pgf_call("browse",{id:id,format:"json"},cont,err);
browse: function(args,cont,err) { // id, format
if(!args.format) args.format="json"; // sife effect!!
this.pgf_call("browse",args,cont,err);
}
};
for(var o in options) server[o]=options[o];