Skip to content

Commit 0d6788e

Browse files
committed
improving some GUI stuff
1 parent 3601c29 commit 0d6788e

File tree

3 files changed

+14
-15
lines changed

3 files changed

+14
-15
lines changed

qiita_pet/handlers/api_proxy/user.py

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,27 +11,29 @@
1111

1212

1313
@execute_as_transaction
14-
def user_jobs_get_req(user):
14+
def user_jobs_get_req(user, limit=10):
1515
"""Gets the json of jobs
1616
1717
Parameters
1818
----------
19-
prep_id : int
20-
PrepTemplate id to get info for
21-
user_id : str
22-
User requesting the sample template info
19+
user : User
20+
The user from which you want to return all jobs
21+
limit : int, optional
22+
Maximum jobs to send, negative values will return all
2323
2424
Returns
2525
-------
2626
dict of objects
2727
{'status': status,
2828
'message': message,
29-
'template': {sample: {column: value, ...}, ...}
29+
'template': {{column: value, ...}, ...}
3030
"""
3131

3232
response = []
3333
cmds = {}
34-
for j in user.jobs():
34+
for i, j in enumerate(user.jobs()):
35+
if i == limit:
36+
break
3537
cmd = j.command
3638
if cmd not in cmds:
3739
cmds[cmd] = cmd

qiita_pet/templates/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
{% end %}
44

55
{%block content %}
6-
<div id="jumbotron" class="jumbotron">
6+
<div id="jumbotron" class="jumbotron" style="border-radius: 10px; padding: 30px">
77
<h1>{% raw portal_styling.index_header%}</h1>
88
{% raw portal_styling.index_text%}
99
</div>

qiita_pet/templates/sitebase.html

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@
299299
});
300300

301301
});
302-
302+
303303
</script>
304304
{% block head %}{% end %}
305305
</head>
@@ -318,7 +318,7 @@
318318

319319
<div id="qiita-main" class="qiita-main">
320320
<div id="navigation-bar" class="navbar navbar-inverse navbar-static-top navbar-custom" role="navigation">
321-
<div class="container">
321+
<div class="container-fluid">
322322
<div class="navbar-header">
323323
<!-- button that appears if the window is re-sized to a smaller size -->
324324
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
@@ -411,9 +411,6 @@
411411
</li>
412412
<li class="dropdown">
413413
<a href="#" onClick="show_hide_process_list()" id="dflt-sel-info"><span class="glyphicon glyphicon-tasks"></span></a>
414-
<ul class="dropdown-menu" style="padding: 5px">
415-
<li> <span id="dflt-study-count"></span> Running:</li>
416-
</ul>
417414
</li>
418415
</ul>
419416
<!-- otherwise show the login form -->
@@ -489,7 +486,7 @@ <h6>
489486
{% end %}
490487

491488
<!-- all templates should override this portion to present their main content -->
492-
<div id="template-content" class="container" style="width:99%">
489+
<div id="template-content" class="container-fluid" style="width:98%">
493490
{% block content %}{% end %}
494491
</div>
495492

@@ -517,7 +514,7 @@ <h1>This site only works with the following browsers</h1>
517514
</div>
518515

519516
<div id="qiita-processing" class="pre-scrollable" style="max-height: 100%">
520-
<div id="processing-jobs-table" style="padding: 5px 5px;">
517+
<div id="processing-jobs-table" style="padding: 5px 5px; background-color: #DDD";">
521518
<h3>Processing Jobs</h3>
522519
Search: <input v-model="search">
523520
<hr>

0 commit comments

Comments
 (0)