diff options
author | gnowgi <nagarjun@gnowledge.org> | 2012-09-26 08:46:47 -0700 |
---|---|---|
committer | gnowgi <nagarjun@gnowledge.org> | 2012-09-26 08:46:47 -0700 |
commit | 3ba6b57c6d605262ef9e1f7bba8d62ea20aacc36 (patch) | |
tree | 8d77de86b443495d67360dcd40786f2b8208d334 /objectapp/static/objectapp/js | |
parent | cad11e2f7ed848cdfd7779451bb0f4f931e062c3 (diff) | |
parent | 94535d4adc3a4960795d22e3b229a8375de10b74 (diff) | |
download | gnowsys-3ba6b57c6d605262ef9e1f7bba8d62ea20aacc36.tar.gz |
Merge pull request #85 from supriyasawant/master
All modules, wiki, loom, image, document and video libraries integrated.
Diffstat (limited to 'objectapp/static/objectapp/js')
-rw-r--r--[-rwxr-xr-x] | objectapp/static/objectapp/js/orgitdown/orgitdown/jquery.orgitdown.js | 0 | ||||
-rw-r--r-- | objectapp/static/objectapp/js/orgitdown/orgitdown/sets/savedata.js | 33 |
2 files changed, 32 insertions, 1 deletions
diff --git a/objectapp/static/objectapp/js/orgitdown/orgitdown/jquery.orgitdown.js b/objectapp/static/objectapp/js/orgitdown/orgitdown/jquery.orgitdown.js index c766300..c766300 100755..100644 --- a/objectapp/static/objectapp/js/orgitdown/orgitdown/jquery.orgitdown.js +++ b/objectapp/static/objectapp/js/orgitdown/orgitdown/jquery.orgitdown.js diff --git a/objectapp/static/objectapp/js/orgitdown/orgitdown/sets/savedata.js b/objectapp/static/objectapp/js/orgitdown/orgitdown/sets/savedata.js index eaf728c..2fb78ed 100644 --- a/objectapp/static/objectapp/js/orgitdown/orgitdown/sets/savedata.js +++ b/objectapp/static/objectapp/js/orgitdown/orgitdown/sets/savedata.js @@ -6,8 +6,39 @@ document.getElementById('gnoweditor').style.visibility="visible"; $("#gnoweditor").orgitdown(mySettings); $("#gnoweditor").val(orgdata); + $("#editdata").hide(); + $("#savecontent").show(); }); - + $("#savecontent").one("click",function() { + var org_data = $("#gnoweditor").val(); + var id = document.getElementById("objectid").value + document.getElementById("orgcontent").value = org_data; + var encode_data = encodeURIComponent(org_data); + $("#savecontent").hide(); + $.ajax({ + url: '/nodetypes/ajax/contentorgadd/?id=' + id + '&contentorg=' + encode_data, + success: function(data) { + $.ajax({ + url: '/nodetypes/ajax/ajaxcreatefile/?id=' +id+ '&content_org=' +encode_data, + success: function(data) { + $.ajax({ + url: '/nodetypes/ajax/ajaxcreatehtml/', + success: function(data) { + $.ajax({ + url: '/nodetypes/ajax/contentadd/?id=' +id, + success: function(data) { + // alert("Data Saved"); + location.reload();} + }); + } + }); + } + }); + + } + }); + + }); }); |