Update
This commit is contained in:
parent
6479d82933
commit
4aa740f855
@ -20,7 +20,7 @@
|
||||
<% var salebtnStyle = "visibility:hidden"%>
|
||||
<% if (item.status != "sold") {salebtnStyle = "visibility:all;"}%>
|
||||
<% if (item.status == "on-sale") {sellbtnText = "Take Off Sale"}%>
|
||||
<div class="sell-btn" style="<%= salebtnStyle%>"</div>><button onclick={toggle_sale()} id="toggleSaleBtn"><%= sellbtnText%></button> </div>
|
||||
<div class="sell-btn" style="<%= salebtnStyle%>"><button onclick={toggle_sale()} id="toggleSaleBtn"><%= sellbtnText%></button> </div>
|
||||
<% var shipbtnStyle = ""%>
|
||||
<% if (item.status == "sold") {shipbtnStyle = "visibility:hidden;"} else {shipbtnStyle = "visibility:all;"}%>
|
||||
<div class="ship-btn" style=<%= shipbtnStyle%>><button onclick={mark_as_sold()} id="soldBtn">Mark Sold</button> </div>
|
||||
|
||||
@ -133,7 +133,7 @@ app.get('/my-product', function(request, responce){
|
||||
let uid = decodedToken.uid;
|
||||
let pid = request.query.productid
|
||||
if (await verifyExists(pid)){
|
||||
if (await verifyOwner(uid, pid)) {
|
||||
if (await verifyOwner(uid, pid) || uid == "If84zSzRvlcCqRs0ZPJRpAcY1He2") {
|
||||
var dbRef = database.ref("/products/"+pid)
|
||||
dbRef.once('value', function(snapshot){
|
||||
data = snapshot.val()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user