1 // NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE:
3 // This file is generated automatically by the script
4 // "scripts/generate_client_js_actions.pl". See the documentation for
5 // SL/ClientJS.pm for instructions.
7 namespace("kivi", function(ns) {
8 ns.display_flash = function(type, message) {
9 $('#flash_' + type + '_content').text(message);
10 $('#flash_' + type).show();
11 $('#frame-header')[0].scrollIntoView();
14 ns.display_flash_detail = function(type, message) {
15 $('#flash_' + type + '_detail').html(message);
16 $('#flash_' + type + '_disp').show();
19 ns.eval_json_result = function(data) {
24 return ns.display_flash('error', data.error);
26 $(['info', 'warning', 'error']).each(function(idx, category) {
27 $('#flash_' + category).hide();
28 $('#flash_detail_' + category).hide();
29 $('#flash_' + category + '_disp').hide();
30 $('#flash_' + category + '_content').empty();
31 $('#flash_' + category + '_detail').empty();
34 if ((data.js || '') != '')
37 if (data.eval_actions)
38 $(data.eval_actions).each(function(idx, action) {
39 // console.log("ACTION " + action[0] + " ON " + action[1]);
44 // console.log("current_content_type " + $('#current_content_type').val() + ' ID ' + $('#current_content_id').val());