thiswebshoprules

git clone https://git.tarina.org/thiswebshoprules
Log | Files | Refs

payment.html (691B)


      1 $def with (invoice)
      2 $ qr = '/static/qr/' + invoice['id'] + '.png'
      3 <script>
      4 function copy() {
      5   let textarea = document.getElementById("payreq");
      6   textarea.select();
      7   document.execCommand("copy");
      8 }
      9 </script>
     10 <meta http-equiv="refresh" content="60" />
     11 <br>
     12 <h2>$invoice['description']<br>$invoice['msatoshi'] msat, $invoice['quoted_amount'] $invoice['quoted_currency']</h2>
     13 <br>
     14 <img src="$qr">
     15 <div id='hash'>
     16 <h4>id:</h4>
     17 <textarea id='payid'>
     18 $invoice['id']
     19 </textarea>
     20 <h4>pay req:</h4>
     21 <textarea id='payreq'>
     22 $invoice['payreq']
     23 </textarea>
     24 <br>
     25 <button id="copybutton" onclick="copy()">Copy</button>
     26 <button id="backbutton" autofocus onclick="parent.location='/'">Back</button>
     27 </div>