diff options
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates/mrb_section.html')
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/mrb_section.html | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/mrb_section.html b/bitbake/lib/toaster/toastergui/templates/mrb_section.html index 3d17ac62e4..586c47bfae 100644 --- a/bitbake/lib/toaster/toastergui/templates/mrb_section.html +++ b/bitbake/lib/toaster/toastergui/templates/mrb_section.html | |||
@@ -44,7 +44,7 @@ | |||
44 | Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a> | 44 | Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a> |
45 | </span> | 45 | </span> |
46 | {% if build.project %} | 46 | {% if build.project %} |
47 | <a class="btn {%if build.outcome == build.SUCCEEDED%}btn-success{%elif build.outcome == build.FAILED%}btn-danger{%else%}btn-info{%endif%} pull-right" onclick="scheduleBuild({%url 'xhr_projectbuild' build.project.id as myurl %}{{myurl|json}}, {{build.project.name|json}}, {{build.get_sorted_target_list|mapselect:'target'|json}})">Run again</a> | 47 | <a class="btn {%if build.outcome == build.SUCCEEDED%}btn-success{%elif build.outcome == build.FAILED%}btn-danger{%else%}btn-info{%endif%} pull-right" onclick="scheduleBuild({% url 'xhr_projectbuild' build.project.id as bpi%}{{bpi|json}}, {{build.project.name|json}}, {{build.get_sorted_target_list|mapselect:'target'|json}})">Run again</a> |
48 | {% endif %} | 48 | {% endif %} |
49 | </div> | 49 | </div> |
50 | {%endif%} | 50 | {%endif%} |
@@ -81,19 +81,18 @@ function _makeXHRBuildCall(url, data, onsuccess, onfail) { | |||
81 | alert("Call failed"); | 81 | alert("Call failed"); |
82 | console.log(_data); | 82 | console.log(_data); |
83 | if (onfail) onfail(data); | 83 | if (onfail) onfail(data); |
84 | } | 84 | } }); |
85 | }); | ||
86 | } | 85 | } |
87 | 86 | ||
88 | 87 | ||
89 | function scheduleBuild(url, projectName, buildlist) { | 88 | function scheduleBuild(url, projectName, buildlist) { |
90 | console.log("scheduleBuild"); | 89 | console.log("scheduleBuild"); |
91 | // _makeXHRBuildCall(url , {targets: buildlist.join(" ")}, function (_data) { | 90 | _makeXHRBuildCall(url, {targets: buildlist.join(" ")}, function (_data) { |
92 | 91 | ||
93 | $('#latest-builds').prepend('<div class="alert alert-info" style="padding-top:0px">' + '<span class="label label-info" style="font-weight: normal; margin-bottom: 5px; margin-left:-15px; padding-top:5px;">'+projectName+'</span><div class="row-fluid">' + | 92 | $('#latest-builds').prepend('<div class="alert alert-info" style="padding-top:0px">' + '<span class="label label-info" style="font-weight: normal; margin-bottom: 5px; margin-left:-15px; padding-top:5px;">'+projectName+'</span><div class="row-fluid">' + |
94 | '<div class="span4 lead">' + buildlist.join(" ") + | 93 | '<div class="span4 lead">' + buildlist.join(" ") + |
95 | '</div><div class="span4 lead pull-right">Build queued. Your build will start shortly.</div></div></div>'); | 94 | '</div><div class="span4 lead pull-right">Build queued. Your build will start shortly.</div></div></div>'); |
96 | // } | 95 | }); |
97 | } | 96 | } |
98 | 97 | ||
99 | </script> | 98 | </script> |