X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=SL%2FClientJS.pm;h=96132cfb387fa816e95d1dd6cc803cb4a6207e1a;hb=64b49f6c38c2c5763f21df00c7b4580ff70893be;hp=a04702eb34932dbb95a2ca7580bf6ce1ee92c2f2;hpb=39bbd478869bbcd482226d68f7fadcd6bc4da0eb;p=kivitendo-erp.git diff --git a/SL/ClientJS.pm b/SL/ClientJS.pm index a04702eb3..96132cfb3 100644 --- a/SL/ClientJS.pm +++ b/SL/ClientJS.pm @@ -14,7 +14,7 @@ use Rose::Object::MakeMethods::Generic my %supported_methods = ( # ## Non-jQuery methods ## - flash => 2, # display_flash(, ) + flash => 2, # kivi.display_flash(, ) # ## jQuery basics ## @@ -217,12 +217,12 @@ with jQuery First some JavaScript code: // In the client generate an AJAX request whose 'success' handler - // calls "eval_json_response(data)": + // calls "eval_json_result(data)": var data = { action: "SomeController/the_action", id: $('#some_input_field').val() }; - $.post("controller.pl", data, eval_json_response); + $.post("controller.pl", data, eval_json_result); Now some Perl code: @@ -278,7 +278,7 @@ There are three things that need to be done for this to work: =item 1. The "client_js.js" has to be loaded before the AJAX request is started. -=item 2. The client code needs to call C with the result returned from the server. +=item 2. The client code needs to call C with the result returned from the server. =item 3. The server must use this module.