forked from Dniel97/artemis
frontend: fixes to searching
This commit is contained in:
parent
aa17f99252
commit
1497bf4a95
@ -343,9 +343,8 @@ class FE_System(FE_Base):
|
|||||||
|
|
||||||
if ac_id_search is not None:
|
if ac_id_search is not None:
|
||||||
u = self.data.arcade.get_arcade(ac_id_search[0])
|
u = self.data.arcade.get_arcade(ac_id_search[0])
|
||||||
if ul is not None:
|
if u is not None:
|
||||||
if u is not None:
|
aclist.append(u._asdict())
|
||||||
aclist.append(u._asdict())
|
|
||||||
|
|
||||||
elif ac_name_search is not None:
|
elif ac_name_search is not None:
|
||||||
ul = self.data.arcade.get_arcade_by_name(ac_name_search[0])
|
ul = self.data.arcade.get_arcade_by_name(ac_name_search[0])
|
||||||
|
@ -8,8 +8,8 @@
|
|||||||
<form id="usrLookup" name="usrLookup" action="/sys/lookup.user" class="form-inline">
|
<form id="usrLookup" name="usrLookup" action="/sys/lookup.user" class="form-inline">
|
||||||
<h3>User Search</h3>
|
<h3>User Search</h3>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="usrEmail">Email address</label>
|
<label for="usrId">User ID</label>
|
||||||
<input type="email" class="form-control" id="usrEmail" name="usrEmail" aria-describedby="emailHelp">
|
<input type="number" class="form-control" id="usrId" name="usrId">
|
||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
@ -18,8 +18,8 @@
|
|||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="usrId">User ID</label>
|
<label for="usrEmail">Email address</label>
|
||||||
<input type="number" class="form-control" id="usrId" name="usrId">
|
<input type="email" class="form-control" id="usrEmail" name="usrEmail" aria-describedby="emailHelp">
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<button type="submit" class="btn btn-primary">Search</button>
|
<button type="submit" class="btn btn-primary">Search</button>
|
||||||
@ -31,13 +31,13 @@
|
|||||||
<form id="arcadeLookup" name="arcadeLookup" action="/sys/lookup.arcade" class="form-inline" >
|
<form id="arcadeLookup" name="arcadeLookup" action="/sys/lookup.arcade" class="form-inline" >
|
||||||
<h3>Arcade Search</h3>
|
<h3>Arcade Search</h3>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="arcadeName">Arcade Name</label>
|
<label for="arcadeId">Arcade ID</label>
|
||||||
<input type="text" class="form-control" id="arcadeName" name="arcadeName">
|
<input type="number" class="form-control" id="arcadeId" name="arcadeId">
|
||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="arcadeId">Arcade ID</label>
|
<label for="arcadeName">Arcade Name</label>
|
||||||
<input type="number" class="form-control" id="arcadeId" name="arcadeId">
|
<input type="text" class="form-control" id="arcadeName" name="arcadeName">
|
||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
@ -57,13 +57,13 @@
|
|||||||
<form id="cabLookup" name="cabLookup" action="/sys/lookup.cab" class="form-inline" >
|
<form id="cabLookup" name="cabLookup" action="/sys/lookup.cab" class="form-inline" >
|
||||||
<h3>Machine Search</h3>
|
<h3>Machine Search</h3>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="cabSerial">Machine Serial</label>
|
<label for="cabId">Machine ID</label>
|
||||||
<input type="text" class="form-control" id="cabSerial" name="cabSerial">
|
<input type="number" class="form-control" id="cabId" name="cabId">
|
||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="cabId">Machine ID</label>
|
<label for="cabSerial">Machine Serial</label>
|
||||||
<input type="number" class="form-control" id="cabId" name="cabId">
|
<input type="text" class="form-control" id="cabSerial" name="cabSerial">
|
||||||
</div>
|
</div>
|
||||||
OR
|
OR
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
@ -80,19 +80,19 @@
|
|||||||
{% if sesh.permissions >= 2 %}
|
{% if sesh.permissions >= 2 %}
|
||||||
<div id="userSearchResult" class="col-sm-6" style="max-width: 25%;">
|
<div id="userSearchResult" class="col-sm-6" style="max-width: 25%;">
|
||||||
{% for usr in usrlist %}
|
{% for usr in usrlist %}
|
||||||
<a href=/user/{{ usr.id }}><pre>{{ usr.id }} | {{ usr.username if usr.username is defined else "<i>No Name Set</i>"}}</pre></a>
|
<a href=/user/{{ usr.id }}><pre>{{ usr.id }} | {{ usr.username if usr.username != None else "<i>No Name Set</i>"}}</pre></a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if sesh.permissions >= 4 %}
|
{% if sesh.permissions >= 4 %}
|
||||||
<div id="arcadeSearchResult" class="col-sm-6" style="max-width: 25%;">
|
<div id="arcadeSearchResult" class="col-sm-6" style="max-width: 25%;">
|
||||||
{% for ac in aclist %}
|
{% for ac in aclist %}
|
||||||
<pre><a href=/arcade/{{ ac.id }}>{{ ac.id }} | {{ ac.name if ac.name is defined else "<i>No Name Set</i>" }} | {{ ac.ip if ac.ip is defined else "<i>No IP Assigned</i>"}}</pre></a>
|
<pre><a href=/arcade/{{ ac.id }}>{{ ac.id }} | {{ ac.name if ac.name != None else "<i>No Name Set</i>" }} | {{ ac.ip if ac.ip != None else "<i>No IP Assigned</i>"}}</pre></a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div
|
</div
|
||||||
><div id="cabSearchResult" class="col-sm-6" style="max-width: 25%;">
|
><div id="cabSearchResult" class="col-sm-6" style="max-width: 25%;">
|
||||||
{% for cab in cablist %}
|
{% for cab in cablist %}
|
||||||
<a href=/cab/{{ cab.id }}><pre>{{ cab.id }} | {{ cab.game if cab.game is defined else "<i>No Game Assigned</i>" }} | {{ cab.serial }}</pre></a>
|
<a href=/cab/{{ cab.id }}><pre>{{ cab.id }} | {{ cab.game if cab.game != None else "<i>ANY </i>" }} | {{ cab.serial }}</pre></a>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
Loading…
Reference in New Issue
Block a user