Merge lp:~cjohnston/ubuntu-ci-services-itself/1286168 into lp:ubuntu-ci-services-itself

Proposed by Chris Johnston
Status: Merged
Approved by: Chris Johnston
Approved revision: 393
Merged at revision: 393
Proposed branch: lp:~cjohnston/ubuntu-ci-services-itself/1286168
Merge into: lp:ubuntu-ci-services-itself
Diff against target: 148 lines (+87/-8)
6 files modified
webui/complete.html (+35/-0)
webui/index.html (+3/-2)
webui/packages.html (+3/-2)
webui/status.html (+3/-2)
webui/ticket.html (+3/-2)
webui/webui_complete.js (+40/-0)
To merge this branch: bzr merge lp:~cjohnston/ubuntu-ci-services-itself/1286168
Reviewer Review Type Date Requested Status
Evan (community) Approve
Andy Doan (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+211126@code.launchpad.net

Commit message

Adds a 'completed' ticket page

Description of the change

After a ticket has completed, it has no place to go. This will give it a home.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

PASSED: Continuous integration, rev:393
http://s-jenkins.ubuntu-ci:8080/job/uci-engine-ci/429/
Executed test runs:

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/uci-engine-ci/429/rebuild

review: Approve (continuous-integration)
Revision history for this message
Andy Doan (doanac) wrote :

25 + <li><a href="/" class="first">Ticket list</a></li>
26 + <li><a href="/complete.html">Completed tickets</a></li>
27 + <li><a href="/packages.html">Published packages</a></li>
28 + <li><a href="/status.html">Engine health</a></li>

I think L26 should have the "class=first" option and not L25?

Revision history for this message
Andy Doan (doanac) wrote :

ignore my comment

review: Approve
Revision history for this message
Evan (ev) wrote :

+ <li><a href="/" class="first">Ticket list</a></li>

Maybe that should become "Unfinished tickets"? When I read it I always think that it's the entire list of tickets, which it is not.

144 + console.log("failure: ", tx, r, e);

I'd suggest Y.webui.main_table.showMessage(json_error_msg); in addition to logging on the console.

Don't let me block merging though. +1

Revision history for this message
Chris Johnston (cjohnston) wrote :

Ev, currently, Ticket list still holds failed tickets too.. so yes, it sounds wrong, but also Unfinished tickets (or open tickets) would be just as wrong... I hope to get a failed tickets page in as well, which would open this up for changes..

Thinking about it now... Maybe keep Ticket list as the main nav, then under that 'Open' 'Completed' 'Failed'?

Revision history for this message
Evan (ev) :
review: Approve
Revision history for this message
Vincent Ladeuil (vila) wrote :

Tickets in flight ?

Flying tickets ? ;)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file 'webui/complete.html'
2--- webui/complete.html 1970-01-01 00:00:00 +0000
3+++ webui/complete.html 2014-03-14 19:21:12 +0000
4@@ -0,0 +1,35 @@
5+<html>
6+ <head>
7+ <link href='https://fonts.googleapis.com/css?family=Ubuntu:400,300,300italic,400italic,700,700italic|Ubuntu+Mono' rel='stylesheet' type='text/css' />
8+ <script type="text/javascript" src="http://yui.yahooapis.com/3.14.0/build/yui/yui.js"></script>
9+ <script type="text/javascript" src="webui.js"></script>
10+ <script type="text/javascript" src="webui_complete.js"></script>
11+ <link rel="stylesheet" type="text/css" media="screen" href="ubuntu-styles.css" />
12+ <link rel="stylesheet" href="webui.css">
13+ <title>Ubuntu CI Engine - Completed tickets</title>
14+ </head>
15+ <body>
16+ <header class="banner global" role="banner">
17+ <nav role="navigation" class="nav-primary nav-right">
18+ <div class="logo">
19+ <a class="logo-ubuntu" href="/">
20+ <img width="118" height="27" src="logo-ubuntu-orange.png" alt="Ubuntu logo for print" />
21+ <span>CI Engine</span>
22+ </a>
23+ </div>
24+ <ul>
25+ <li><a href="/" class="first">Ticket list</a></li>
26+ <li><a href="/complete.html">Completed tickets</a></li>
27+ <li><a href="/packages.html">Published packages</a></li>
28+ <li><a href="/status.html">Engine health</a></li>
29+ </ul>
30+ </nav>
31+ </header><!-- /#header -->
32+
33+ <div class='container_15 clearfix'>
34+ <div class="wrapper">
35+ <div id="main-content" class="inner-wrapper">
36+ <table id='table' class='yui3-skin-sam'></table>
37+ </div></div></div>
38+ </body>
39+</html>
40
41=== modified file 'webui/index.html'
42--- webui/index.html 2014-03-14 10:37:28 +0000
43+++ webui/index.html 2014-03-14 19:21:12 +0000
44@@ -19,8 +19,9 @@
45 </a>
46 </div>
47 <ul>
48- <li><a href="/" class="first ">Ticket list</a></li>
49- <li><a href="/packages.html" class="first ">Published packages</a></li>
50+ <li><a href="/" class="first">Ticket list</a></li>
51+ <li><a href="/complete.html">Completed tickets</a></li>
52+ <li><a href="/packages.html">Published packages</a></li>
53 <li><a href="/status.html">Engine health</a></li>
54 </ul>
55 </nav>
56
57=== modified file 'webui/packages.html'
58--- webui/packages.html 2014-03-11 20:01:52 +0000
59+++ webui/packages.html 2014-03-14 19:21:12 +0000
60@@ -18,8 +18,9 @@
61 </a>
62 </div>
63 <ul>
64- <li><a href="/" class="first ">Ticket list</a></li>
65- <li><a href="/packages.html" class="first ">Published packages</a></li>
66+ <li><a href="/" class="first">Ticket list</a></li>
67+ <li><a href="/complete.html">Completed tickets</a></li>
68+ <li><a href="/packages.html">Published packages</a></li>
69 <li><a href="/status.html">Engine health</a></li>
70 </ul>
71 </nav>
72
73=== modified file 'webui/status.html'
74--- webui/status.html 2014-03-14 10:37:28 +0000
75+++ webui/status.html 2014-03-14 19:21:12 +0000
76@@ -18,8 +18,9 @@
77 </a>
78 </div>
79 <ul>
80- <li><a href="/" class="first ">Ticket list</a></li>
81- <li><a href="/packages.html" class="first ">Published packages</a></li>
82+ <li><a href="/" class="first">Ticket list</a></li>
83+ <li><a href="/complete.html">Completed tickets</a></li>
84+ <li><a href="/packages.html">Published packages</a></li>
85 <li><a href="/status.html">Engine health</a></li>
86 </ul>
87 </nav>
88
89=== modified file 'webui/ticket.html'
90--- webui/ticket.html 2014-03-14 18:27:36 +0000
91+++ webui/ticket.html 2014-03-14 19:21:12 +0000
92@@ -18,8 +18,9 @@
93 </a>
94 </div>
95 <ul>
96- <li><a href="/" class="first ">Ticket list</a></li>
97- <li><a href="/packages.html" class="first ">Published packages</a></li>
98+ <li><a href="/" class="first">Ticket list</a></li>
99+ <li><a href="/complete.html">Completed tickets</a></li>
100+ <li><a href="/packages.html">Published packages</a></li>
101 <li><a href="/status.html">Engine health</a></li>
102 </ul>
103 </nav>
104
105=== added file 'webui/webui_complete.js'
106--- webui/webui_complete.js 1970-01-01 00:00:00 +0000
107+++ webui/webui_complete.js 2014-03-14 19:21:12 +0000
108@@ -0,0 +1,40 @@
109+YUI().use('io', 'jsonp', 'webui', 'datatable-mutable', function(Y) {
110+
111+ var table = new Y.webui.make_main_table('#table');
112+ if (Y.webui.main_table) {
113+ Y.webui.main_table.showMessage("loading data...");
114+ }
115+
116+ Y.io(Y.webui.url_prefix + "ticketstatus/?current_workflow_step=1000", {
117+ on: {
118+ success: function (tx, r) {
119+ var data,
120+ i;
121+ console.log("success");
122+
123+ try {
124+ data = Y.JSON.parse(r.responseText);
125+ } catch (e) {
126+ Y.webui.main_table.showMessage(json_error_msg);
127+ return;
128+ }
129+
130+ if (data.objects && data.objects.length !== 0) {
131+ for (i = 0; i < data.objects.length; i += 1) {
132+ if (data.objects[i]) {
133+ Y.webui.add_item(data.objects[i]);
134+ }
135+ }
136+ Y.webui.check_statuses();
137+ }
138+ if (Y.webui.main_table.data.size() === 0) {
139+ Y.webui.main_table.showMessage("No results found");
140+ }
141+ Y.webui.done_loading = true;
142+ },
143+ failure: function (tx, r, e) {
144+ console.log("failure: ", tx, r, e);
145+ }
146+ }
147+ });
148+});

Subscribers

People subscribed via source and target branches