Join us on May 14-15, 2019 at Forrester Digital Transformation & Innovation 2019 in Chicago, USA.

Versions Compared

Key

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

Table of Contents
indent30px
stylecircle

AssignmentManager

  • URL : /jw/js/json/util.js
  • Auto included in all userview pages.
  • Used to deal with assignment of a logged in user.

...

Code Block
languagejs
AssignmentManager.withdrawAssignment('http://localhost/jw', '1_1_activity');

ConnectionManager

  • URL : /jw/js/json/util.js
  • Auto included in all userview pages.
  • Convenient method to do AJAX call.

...

Code Block
languagejs
var callback = {
    success : function(response){
        //do something
    }
};
ConnectionManager.post('http://localhost/test', callback, 'id=6&name=test');

FormUtil

  • URL : /jw/js/json/formUtil.js
  • Auto included in page using form.
  • Convenient method to interact with form field.

...

Code Block
languagejs
var values = FormUtil.getValues("field1");
for (var i = 0; i < values.length; i++) {
    console.log(values[i]); 
}

JPopup

  • URL : /jw/js/json/ui_ext.js
  • Auto included in all userview pages.
  • Convenient method to create/show/hide a popup dialog to display a page.

...

Code Block
languagejs
var params = {
    id : "1",
    name : "test"
};
 
JPopup.show("testPopup", "http://www.joget.org", params);

UI

  • URL : /jw/js/json/ui.js
  • Auto included in all userview pages.
  • Convenient method to retrieve value for UI usages.

...

Code Block
languagejs
var url = "http://localhost/jw/form/embed?" + UI.userviewThemeParams();

UrlUtil

  • URL : /jw/js/json/util.js
  • Auto included in all userview pages.
  • Convenient method to deal with URL.

...

Code Block
languagejs
var q1 = "name=joget&email=info@jogte.org&email=test@joget.org";
var q2 = "name=joget team&phone=012345678";
 
var queryString = UrlUtil.mergeRequestQueryString(q1, q2);
console.log(queryString); // name=joget%20team&email=info%40joget%2Eorg&email=test%40joget%2Eorg&phone=012345678