]> lifelog.hopto.org Git - LifeLog.git/commitdiff
minor.
authorMetabox <redacted>
Sat, 20 Jul 2019 23:27:58 +0000 (09:27 +1000)
committerMetabox <redacted>
Sat, 20 Jul 2019 23:27:58 +0000 (09:27 +1000)
htdocs/cgi-bin/json.cgi
htdocs/cgi-bin/main.cgi
htdocs/cgi-bin/wsrc/main.js

index f35224137c572c30ecfa419b17f79d912b0b11f2..9219cf28defa19ac579252fd64d5d66bb70d3b14 100755 (executable)
@@ -44,6 +44,8 @@ my $sid      = $session->id();
 my $dbname   = "";#$session->param('database');
 my $userid   = $session->param('alias');
 my $password = $session->param('passw');
+my $action   = $session->param('action');
+my $lid      = $session->param('id');
 
 if ($AUTHORITY) {
     $userid = $password = $AUTHORITY;
@@ -75,7 +77,9 @@ $today->set_time_zone($TIME_ZONE);
 my $json = JSON->new->utf8->space_after->pretty->allow_blessed->encode
      ({date => DateTime::Format::SQLite->format_datetime($today), 
        origin => "LifeLog.".$RELEASE_VER,
-       response => "Feature Under Development!"
+       response => "Feature Under Development!",
+       alias => $userid,
+       log_id => $lid,
     });
 
 
index f4dcf167f0e2b9d3547b525ccd1729c6c77808b8..68fe14e127a3e49135c6d75998fe43899dbc9220 100755 (executable)
@@ -1081,7 +1081,7 @@ return qq{
   </div>
   <div id="editor-container"></div>
   <div class="save_button">
-  <button id="btn_save_doc" onclick="saveRTF($log_id, 'store'); return false;">Save</button>
+  <input type="button" id="btn_save_doc" onclick="saveRTF(0, 'store'); return false;" value="Save"/>
   </div>
   </td></tr></table>
 
index fbf27cb3943ff53c502812e0bd8c1f3f4ad17690..35b14da72e99a10279a62f09c6be6595b00a8d23 100644 (file)
@@ -471,10 +471,10 @@ function dateDiffSelected() {
 
 function saveRTF(id, action) {
     // alert(JSON.stringify(QUILL.getContents()));
-    //Dissabled on new log entry. Save and edit, obtains id. For now. @2019-07-20
-    if (id > 0) {
-        $.post('json.cgi?action=' + action + '&id=' + id, { doc: JSON.stringify(QUILL.getContents()) }, saveRTFResult);
-    }
+    //Disabled on new log entry. Save and edit, obtains id. For now. @2019-07-20
+    //if (id > 0) {
+    $.post('json.cgi?action=' + action + '&id=' + id, { doc: JSON.stringify(QUILL.getContents()) }, saveRTFResult);
+    //}
 }
 
 function saveRTFResult(result) {