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: get rid o


From: gnunet
Subject: [GNUnet-SVN] [taler-merchant-frontends] branch master updated: get rid of (non-backoffice) JS
Date: Wed, 15 Mar 2017 14:38:17 +0100

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

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

The following commit(s) were added to refs/heads/master by this push:
     new 24430f6  get rid of (non-backoffice) JS
24430f6 is described below

commit 24430f66143576b63663c4d4d100080a2842b11a
Author: Florian Dold <address@hidden>
AuthorDate: Wed Mar 15 14:38:14 2017 +0100

    get rid of (non-backoffice) JS
---
 talerfrontends/donations/static/execute-payment.js | 53 ----------------------
 talerfrontends/donations/static/index.js           | 46 -------------------
 talerfrontends/donations/templates/index.html      |  5 +-
 3 files changed, 4 insertions(+), 100 deletions(-)

diff --git a/talerfrontends/donations/static/execute-payment.js 
b/talerfrontends/donations/static/execute-payment.js
deleted file mode 100644
index d01ee20..0000000
--- a/talerfrontends/donations/static/execute-payment.js
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
-  @licstart  The following is the entire license notice for the
-  JavaScript code in this page.
-
-  Copyright (C) 2015, 2016 INRIA
-
-  The JavaScript code in this page is free software: you can
-  redistribute it and/or modify it under the terms of the GNU
-  Lesser General Public License (GNU LGPL) as published by the Free Software
-  Foundation, either version 2.1 of the License, or (at your option)
-  any later version.  The code is distributed WITHOUT ANY WARRANTY;
-  without even the implied warranty of MERCHANTABILITY or FITNESS
-  FOR A PARTICULAR PURPOSE.  See the GNU LGPL for more details.
-
-  As additional permission under GNU LGPL version 2.1 section 7, you
-  may distribute non-source (e.g., minimized or compacted) forms of
-  that code without the copy of the GNU LGPL normally required by
-  section 4, provided you include this license notice and a URL
-  through which recipients can access the Corresponding Source.
-
-  @licend  The above is the entire license notice
-  for the JavaScript code in this page.
-
-  @author Marcello Stanisci
-*/
-
-"use strict";
-
-// the urls are urlencoded, so that quotation marks can't lead to escaping and 
XSS
-var hash = document.querySelectorAll("[name=contract-hash]")[0];
-var pay_url = document.querySelectorAll("[name=pay-url]")[0];
-var offering_url = document.querySelectorAll("[name=offering-url]")[0];
-
-taler.executePayment(
-    hash.getAttribute("value"),
-    decodeURIComponent(pay_url.getAttribute("value")),
-    decodeURIComponent(offering_url.getAttribute("value")));
-
-var index = 0;
-var dots = ["/",
-            "-",
-            "\\",
-            "|"];
-function print_dots() {
-  var spot = document.getElementById("action-indicator");
-  if (spot)
-    spot.innerHTML = dots[index];
-  index++;
-  index = index % dots.length;
-  window.setTimeout(print_dots, 400);
-}
-
-print_dots();
diff --git a/talerfrontends/donations/static/index.js 
b/talerfrontends/donations/static/index.js
deleted file mode 100644
index 94d9c78..0000000
--- a/talerfrontends/donations/static/index.js
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
-  @licstart  The following is the entire license notice for the
-  JavaScript code in this page.
-
-  Copyright (C) 2015, 2016 INRIA
-
-  The JavaScript code in this page is free software: you can
-  redistribute it and/or modify it under the terms of the GNU
-  Lesser General Public License (GNU LGPL) as published by the Free Software
-  Foundation, either version 2.1 of the License, or (at your option)
-  any later version.  The code is distributed WITHOUT ANY WARRANTY;
-  without even the implied warranty of MERCHANTABILITY or FITNESS
-  FOR A PARTICULAR PURPOSE.  See the GNU LGPL for more details.
-
-  As additional permission under GNU LGPL version 2.1 section 7, you
-  may distribute non-source (e.g., minimized or compacted) forms of
-  that code without the copy of the GNU LGPL normally required by
-  section 4, provided you include this license notice and a URL
-  through which recipients can access the Corresponding Source.
-
-  @licend  The above is the entire license notice
-  for the JavaScript code in this page.
-  
-  @author Marcello Stanisci
-  @author Florian Dold
-*/
-"use strict";
-
-var shop_currency = 
document.querySelectorAll("meta[name=merchant_currency]")[0].getAttribute("value");
-
-function addOption(value, label) {
-  var s = document.getElementById("taler-donation");
-  var e = document.createElement("option");
-  e.textContent = label ? label : ("".concat(value, " ", shop_currency));
-  e.value = value;
-  s.appendChild(e);
-}
-
-function init() {
-  addOption("0.1");
-  addOption("1.0");
-  addOption("6.0", "".concat(5, " ", shop_currency));
-  addOption("10");
-}
-
-document.addEventListener("DOMContentLoaded", init);
diff --git a/talerfrontends/donations/templates/index.html 
b/talerfrontends/donations/templates/index.html
index 226d744..b544ba2 100644
--- a/talerfrontends/donations/templates/index.html
+++ b/talerfrontends/donations/templates/index.html
@@ -40,7 +40,10 @@ You are paying with an imaginary currency ({{ 
env("TALER_CONFIG_CURRENCY", "KUDO
         <!-- options are added dynamically -->
       </select>
       <select id="taler-donation" name="donation_amount">
-        <!-- options are added dynamically -->
+        <option value="0.1">0.1 {{ env("TALER_CONFIG_CURRENCY", "??") 
}}</option>
+        <option value="1">1 {{ env("TALER_CONFIG_CURRENCY", "??") }}</option>
+        <option value="6">5 {{ env("TALER_CONFIG_CURRENCY", "??") }}</option>
+        <option value="10">10 {{ env("TALER_CONFIG_CURRENCY", "??") }}</option>
       </select>
       <input type="submit" class="pure-button pure-button-primary" 
value="Donate!"/>
     </div>

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



reply via email to

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