paymobile.html (2018B)
1 $def with (lninvoice,invoice,bag,productname,digitalkey,db,getprice,getrate,ordertype,pendinginfo,eur_to_sat) 2 $ qr = '/static/qr/' + invoice['invoice_key'] + '.png' 3 <script> 4 function copy() { 5 let textarea = document.getElementById("payreq"); 6 textarea.select(); 7 document.execCommand("copy"); 8 } 9 </script> 10 11 <div id="container"> 12 <br> 13 ~*~<br> 14 <br> 15 <h2>Waiting for payment</h2> 16 <br> 17 ~*~<br> 18 $if invoice.status != 'paid': 19 <meta http-equiv="refresh" content="30" /> 20 <br> 21 $else: 22 <h3>Payment recieved!</h3> 23 $if digitalkey: 24 <p>link to your digital goodies is in your mail!</p><br> 25 <img src="/static/jamesfrancothanks.gif" style="width:300px"><br> 26 <a href="/">Back to beginning</a> 27 <br> 28 $ totsats=0 29 $ toteuro=0 30 $for i in bag: 31 $ goodies = db.query("SELECT * FROM soundlink WHERE id='" +i.product+"';") 32 $code: 33 price = getprice(i.product) 34 quantity = i.quantity 35 p_totsats=i.quantity*price[0] 36 p_toteuro=i.quantity*price[1] 37 $code: 38 toteuro += p_toteuro 39 40 $if ordertype() == 'digital': 41 ~*~ 42 $else: 43 $ shippinginfo = db.select('shipping', where="country='" + pendinginfo.country + "'", what='price, days')[0] 44 $code: 45 totsats += eur_to_sat(shippinginfo.price) 46 toteuro += shippinginfo.price/100 47 48 $if invoice.status == 'unpaid': 49 <br> 50 Send a payment of total: $(toteuro)€ 51 <br> 52 <br> 53 to Robin Johannes Bäckman 54 <br> 55 with mobilepay app number: 0469507618 56 <br> 57 or send payment here <a href="https://buymeacoffee.com/rbckman">buymecoffee</a> 58 <br> 59 <br> 60 ~<br> 61 <br> 62 it was a pleasure doing business with you and please give me feedback on me@robinbackman.com 63 <br> 64 <br> 65 ~<br> 66 <br> 67 status: unpaid 68 <br> 69 <br> 70 ~*~<br> 71 <br> 72 Order is only reserved once paid. 73 <br> 74 $else: 75 <br> 76 order status: $invoice.status 77 <br> 78 ~*~<br> 79 <br> 80 81 <a href="/checkout"><--- back shopping for moar yes plz</a> 82 83 <br> 84 </div> 85 <br> 86 <br> 87 <br> 88 <br>