fix: Only refresh plugins on plugin page.
All checks were successful
Build Docker / Build Image (push) Successful in 49s
All checks were successful
Build Docker / Build Image (push) Successful in 49s
Also added link to auction from bids
This commit is contained in:
parent
76dd5a429b
commit
1962c9345e
2
main.py
2
main.py
@ -1298,7 +1298,7 @@ def plugins_index():
|
||||
if not account:
|
||||
return redirect("/logout")
|
||||
|
||||
plugins = render.plugins(plugins_module.listPlugins())
|
||||
plugins = render.plugins(plugins_module.listPlugins(True))
|
||||
|
||||
return render_template("plugins.html", account=account, sync=account_module.getNodeSync(),
|
||||
wallet_status=account_module.getWalletStatus(),
|
||||
|
@ -6,9 +6,8 @@ import hashlib
|
||||
import subprocess
|
||||
|
||||
|
||||
def listPlugins():
|
||||
def listPlugins(update=False):
|
||||
plugins = []
|
||||
customPlugins = []
|
||||
for file in os.listdir("plugins"):
|
||||
if file.endswith(".py"):
|
||||
if file != "main.py":
|
||||
@ -36,7 +35,7 @@ def listPlugins():
|
||||
if not os.path.exists(f"customPlugins/{importPath}"):
|
||||
if os.system(f"git clone {importurl} customPlugins/{importPath}") != 0:
|
||||
continue
|
||||
else:
|
||||
elif update:
|
||||
if os.system(f"cd customPlugins/{importPath} && git pull") != 0:
|
||||
continue
|
||||
|
||||
|
@ -196,7 +196,7 @@ def bidDomains(bids,domains, sortState=False):
|
||||
|
||||
|
||||
html += "<tr>"
|
||||
html += f"<td>{domain['name']}</td>"
|
||||
html += f"<td><a class='text-decoration-none' style='color: var(--bs-table-color-state, var(--bs-table-color-type, var(--bs-table-color)));' href='/auction/{domain['name']}'>{domain['name']}</a></td>"
|
||||
html += f"<td>{domain['state']}</td>"
|
||||
html += f"<td>{bidDisplay}</td>"
|
||||
html += f"<td>{bid['height']}</td>"
|
||||
@ -216,9 +216,10 @@ def bidDomains(bids,domains, sortState=False):
|
||||
|
||||
bidDisplay = f'<b>{bidValue} HNS</b> + {blind} HNS blind'
|
||||
html += "<tr>"
|
||||
html += f"<td>{domain['name']}</td>"
|
||||
html += f"<td><a class='text-decoration-none' style='color: var(--bs-table-color-state, var(--bs-table-color-type, var(--bs-table-color)));' href='/auction/{domain['name']}'>{domain['name']}</a></td>"
|
||||
html += f"<td>{domain['state']}</td>"
|
||||
html += f"<td>{bidDisplay}</td>"
|
||||
html += f"<td>{domain['height']}</td>"
|
||||
html += "</tr>"
|
||||
return html
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user