gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-merchant-frontends] branch master updated: Manage no


From: gnunet
Subject: [GNUnet-SVN] [taler-merchant-frontends] branch master updated: Manage no records found in /history by showing proper message
Date: Sun, 23 Apr 2017 00:37:43 +0200

This is an automated email from the git hooks/post-receive script.

marcello pushed a commit to branch master
in repository merchant-frontends.

The following commit(s) were added to refs/heads/master by this push:
     new 636537b  Manage no records found in /history by showing proper message
636537b is described below

commit 636537b1fd53779e2e9a0bc470e67ea5fb48782f
Author: Marcello Stanisci <address@hidden>
AuthorDate: Sun Apr 23 00:36:54 2017 +0200

    Manage no records found in /history by showing
    proper message
---
 talerfrontends/blog/static/backoffice.js      | 13 ++++++++++++-
 talerfrontends/blog/static/web-common         |  2 +-
 talerfrontends/blog/templates/backoffice.html |  3 +++
 talerfrontends/donations/static/web-common    |  2 +-
 4 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/talerfrontends/blog/static/backoffice.js 
b/talerfrontends/blog/static/backoffice.js
index fd491b7..2e63857 100644
--- a/talerfrontends/blog/static/backoffice.js
+++ b/talerfrontends/blog/static/backoffice.js
@@ -195,6 +195,15 @@ function xpath_get(xpath, ctx){
 function fill_table(history, execution_time){
   var table = document.getElementById("history");
   var tbody = xpath_get("tbody", table).snapshotItem(0);
+  
+  if(0 == history.length){
+    window.setTimeout(remove_loader, 900);
+    return;
+  }
+
+  /* Remove the "no results" message */
+  tbody.removeChild(xpath_get("tr[1]", tbody).snapshotItem(0));
+
   for (var i=0; i<history.length; i++){
     var entry = history[i];
     var row = document.createElement("tr");
@@ -249,8 +258,10 @@ function get_history(scroll){
           console.log("Got invalid JSON");
           return;
         }
-        if(0 < history.length)
+        if(0 < history.length){
+          console.log(req.respnseText);
           LAST = history[history.length - 1].row_id;
+        }
         fill_table(history);
       }
       else{
diff --git a/talerfrontends/blog/static/web-common 
b/talerfrontends/blog/static/web-common
index 0be9ac9..d7e0135 160000
--- a/talerfrontends/blog/static/web-common
+++ b/talerfrontends/blog/static/web-common
@@ -1 +1 @@
-Subproject commit 0be9ac9264a3bd9f495c37abf1ac864562e8c598
+Subproject commit d7e013594d15388b1a7342a44a0e9c8d4ecca82d
diff --git a/talerfrontends/blog/templates/backoffice.html 
b/talerfrontends/blog/templates/backoffice.html
index 74e9494..1578989 100644
--- a/talerfrontends/blog/templates/backoffice.html
+++ b/talerfrontends/blog/templates/backoffice.html
@@ -8,6 +8,9 @@
     <table id="history" width="60%" style="visibility: hidden;">
       <tbody>
         <tr>
+          <th colspan="3">No records found</th>
+        </tr>
+        <tr style="visibility: hidden">
           <th class="order-id">Order ID</th>
           <th class="amount">Amount</th>
           <th class="date">Date</th>
diff --git a/talerfrontends/donations/static/web-common 
b/talerfrontends/donations/static/web-common
index 0be9ac9..d7e0135 160000
--- a/talerfrontends/donations/static/web-common
+++ b/talerfrontends/donations/static/web-common
@@ -1 +1 @@
-Subproject commit 0be9ac9264a3bd9f495c37abf1ac864562e8c598
+Subproject commit d7e013594d15388b1a7342a44a0e9c8d4ecca82d

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]