2014-09-09 10:47:13 +00:00
{% extends "baseprojectpage.html" %}
<!--
vim: expandtab tabstop=2
-->
2014-06-26 14:21:42 +00:00
{% load projecttags %}
{% load humanize %}
2014-09-09 10:47:13 +00:00
{% load static %}
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
{% block projectinfomain %}
< script src = "{% static " js / angular . min . js " % } " > < / script >
2014-11-07 13:26:45 +00:00
< script src = "{% static " js / angular-animate . min . js " % } " > < / script >
2014-09-09 10:47:13 +00:00
< script src = "{% static " js / angular-cookies . min . js " % } " > < / script >
2014-11-11 17:01:09 +00:00
< script src = "{% static " js / angular-route . min . js " % } " > < / script >
< script src = "{% static " js / angular-sanitize . min . js " % } " > < / script >
2014-09-09 10:47:13 +00:00
< script src = "{% static " js / ui-bootstrap-tpls-0 . 11 . 0 . js " % } " > < / script >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< div id = "main" role = "main" ng-app = "project" ng-controller = "prjCtrl" class = "top-padded" >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- project name -->
< div class = "page-header" >
< h1 > {[project.name]}< / h1 >
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- alerts section 1 -->
< div ng-repeat = "a in zone1alerts" >
< div class = "alert alert-dismissible lead" role = "alert" ng-class = "a.type" > < button type = "button" class = "close" data-dismiss = "alert" > < span aria-hidden = "true" > × < / span > < / button >
< span ng-bind-html = "a.text" > < / span >
< / div >
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- custom templates for ng -->
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< script type = "text/ng-template" id = "suggestion_details" >
< a > {[match.model.name]} {[match.model.detail]} < / a >
< / script >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- modal dialogs -->
< script type = "text/ng-template" id = "dependencies_modal" >
< div class = "modal-header" >
< button type = "button" class = "close" data-dismiss = "modal" aria-hidden = "true" > x< / button >
< h3 > < span ng-bind = "layerAddName" > < / span > dependencies< / h3 >
< / div >
< div class = "modal-body" >
< p > < strong > {[layerAddName]}< / strong > depends on some layers that are not added to your project. Select the ones you want to add:< / p >
< ul class = "unstyled" >
< li ng-repeat = "ld in items" >
< label class = "checkbox" >
< input type = "checkbox" ng-model = "selectedItems[ld.id]" > {[ld.name]}
< / label >
< / li >
< / ul >
< / div >
< div class = "modal-footer" >
< button class = "btn btn-primary" ng-click = "ok()" > Add layers< / button >
< button class = "btn" ng-click = "cancel()" > Cancel< / button >
< / div >
< / form >
< / script >
< script type = "text/ng-template" id = "change_version_modal" >
< div class = "modal-header" >
< button type = "button" class = "close" data-dismiss = "modal" aria-hidden = "true" > x< / button >
< h3 > Changing release to {[releaseName]}< / h3 >
< / div >
< div class = "modal-body" >
< p > The following project layers do not exist for {[releaseName]}:< / p >
< ul >
< li ng-repeat = "i in items" > < span class = "layer-info" data-toggle = "tooltip" tooltip = "{[i.detail]}" > {[i.name]}< / span > < / li >
< / ul >
< p > If you change the release to {[releaseName]}, the above layers will be deleted from your project layers.< / p >
< / div >
< div class = "modal-footer" >
< button class = "btn btn-primary" ng-click = "ok()" > Change release and delete layers< / button >
< button class = "btn" ng-click = "cancel()" > Cancel< / button >
< / div >
< / script >
2014-10-02 16:58:15 +00:00
< script type = "text/ng-template" id = "target_display" >
< div ng-switch on = "t.task.length" >
< div ng-switch-when = "0" > {[t.target]}< / div >
< div ng-switch-default > {[t.target]}:{[t.task]}< / div >
< / div >
< / script >
2014-09-09 10:47:13 +00:00
<!-- build form -->
< div class = "well" >
2015-01-08 13:15:14 +00:00
< form class = "build-form" ng-submit = "buildNamedTarget()" >
2014-11-11 12:22:46 +00:00
< div class = "input-append controls" >
2015-01-26 12:17:18 +00:00
< input type = "text" class = "huge input-xxlarge" placeholder = "Type the target(s) you want to build" autocomplete = "off" ng-model = "targetName" typeahead = "e.name for e in getAutocompleteSuggestions('targets', $viewValue)|filter:$viewValue" typeahead-template-url = "suggestion_details" ng-disabled = "!layers.length" / >
2015-01-20 16:56:35 +00:00
< button type = "submit" class = "btn btn-large btn-primary" ng-disabled = "!targetName.length" >
2014-09-09 10:47:13 +00:00
Build
< / button >
< / div >
2014-11-11 12:22:46 +00:00
< i class = "icon-question-sign get-help get-help-blue" title = "Type the name of one or more targets you want to build, separated by a space. You can also specify a task by appending a semicolon and a task name to a target name, like so: <code>core-image-minimal:do_build</code>" > < / i >
2014-09-09 10:47:13 +00:00
< p >
2015-01-20 15:57:11 +00:00
< a href = "{% url 'all-targets' %}" >
2014-09-09 10:47:13 +00:00
View all targets
< / a >
{% if completedbuilds.count %}
| < a href = "{% url 'projectbuilds' project.id %}" > View all project builds ({{completedbuilds.count}})< / a >
{% endif %}
< / p >
< / form >
< / div >
2015-01-08 13:15:14 +00:00
<!-- latest builds list -->
2014-11-07 13:26:45 +00:00
< a id = "buildslist" > < / a >
2014-09-09 10:47:13 +00:00
< h2 class = "air" ng-if = "builds.length" > Latest builds< / h2 >
2014-11-07 13:26:45 +00:00
< div class = "animate-repeat alert" ng-repeat = "b in builds track by b.id" ng-class = "{'queued':'alert-info', 'deleted':'alert-info', 'in progress': 'alert-info', 'failed':'alert-error', 'completed':{'In Progress':'alert-info', 'Succeeded':'alert-success', 'Failed':'alert-error'}[b.build[0].status]}[b.status]" >
2014-09-09 10:47:13 +00:00
< div class = "row-fluid" >
< switch ng-switch = "b.status" >
2014-11-07 13:26:45 +00:00
2014-09-09 10:47:13 +00:00
< case ng-switch-when = "failed" >
2014-11-07 13:26:45 +00:00
< div class = "lead span3" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
2015-01-08 13:15:14 +00:00
< div >
< button class = "btn pull-right btn-danger" ng-click = "buildExistingTarget(b.targets)" > Run again< / button >
< / div >
2014-09-09 10:47:13 +00:00
< div class = "row-fluid" >
< div class = "air well" ng-repeat = "e in b.errors" >
2015-01-08 13:15:14 +00:00
< pre > {[e.msg]}< / pre >
< ngif ng-if = "e.msg.indexOf('Nothin') == 0" >
< div ng-repeat = "t in getTargetNameFromErrorMsg(e.msg)" >
< p class = "lead" > The target < strong > {[t]}< / strong > is not provided by any of your project layers.< / p >
< p > Your build has failed because the target < strong > {[t]}< / strong > is not provided by any of your project layers.< / p >
< ngif ng-if = "layersForTargets[t].length > 0" >
< p > The following layers provide this target. You could add one of them to your project.< / p >
< button class = "btn btn-danger add-layer-with-dependencies" ng-repeat = "l in layersForTargets[t]" ng-click = "layerAddById(l.id)" > Add {[l.name]}< / button >
< / ngif >
< / div >
< / ngif >
< ngif ng-if = "e.msg.indexOf('Nothin') != 0" >
< p >
Please contact your system administrator to help troubleshoot this error.
< / p >
< / ngif >
2014-09-09 10:47:13 +00:00
< / div >
< / div >
< / case >
2014-11-07 13:26:45 +00:00
2014-09-09 10:47:13 +00:00
< case ng-switch-when = "queued" >
2014-10-02 16:58:15 +00:00
< div class = "lead span5" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
2014-09-09 10:47:13 +00:00
< div class = "span4 lead" > Build queued
< i title = "This build will start as soon as a build server is available" class = "icon-question-sign get-help get-help-blue heading-help" data-toggle = "tooltip" > < / i >
< / div >
2015-01-08 13:15:14 +00:00
< button class = "btn pull-right btn-info" ng-click = "buildCancel(b)" > Cancel< / button >
2014-09-09 10:47:13 +00:00
< / case >
2014-11-07 13:26:45 +00:00
2014-09-09 10:47:13 +00:00
< case ng-switch-when = "created" >
2014-10-02 16:58:15 +00:00
< div class = "lead span3" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
2014-09-09 10:47:13 +00:00
< div class = "span6" >
< span class = "lead" > Creating build< / span >
2014-06-30 17:33:04 +00:00
< / div >
2015-01-08 13:15:14 +00:00
< button class = "btn pull-right btn-info" ng-click = "buildCancel(b)" > Cancel< / button >
2014-09-09 10:47:13 +00:00
< / case >
2014-11-07 13:26:45 +00:00
2014-09-09 10:47:13 +00:00
< case ng-switch-when = "deleted" >
2014-10-02 16:58:15 +00:00
< div class = "lead span3" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
2014-09-09 10:47:13 +00:00
< div class = "span6" id = "{[b.id]}-deleted" >
< span class = "lead" > Build deleted< / span >
2014-06-30 17:33:04 +00:00
< / div >
2015-01-08 13:15:14 +00:00
< button class = "btn pull-right btn-info" ng-click = "buildDelete(b)" > Close< / button >
2014-09-09 10:47:13 +00:00
< / case >
2014-11-07 13:26:45 +00:00
2014-09-09 10:47:13 +00:00
< case ng-switch-when = "in progress" >
2014-11-07 13:26:45 +00:00
< switch ng-switch = "b.build.length" >
< case ng-switch-when = "0" >
< div class = "lead span5" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
< div class = "span4 lead" >
Checking out layers
2014-09-09 10:47:13 +00:00
< / div >
2014-11-07 13:26:45 +00:00
< / case >
< case ng-switch-default = "" >
< div class = "lead span3" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / div >
< div class = "span4 offset1" >
< div class = "progress" style = "margin-top:5px;" data-toggle = "tooltip" tooltip = "{[b.build[0].completeper]}% of tasks complete" >
< div style = "width: {[b.build[0].completeper]}%;" class = "bar" > < / div >
< / div >
< / div >
< div class = "text-right lead" > ETA: {[b.build[0].eta|date:"HH:mm:ss"]}< / div >
< / case >
2014-09-09 10:47:13 +00:00
< / case >
2014-11-07 13:26:45 +00:00
2014-10-02 16:58:15 +00:00
< case ng-switch-when = "completed" >
2014-11-11 12:22:46 +00:00
< div class = "lead span3" > < a class = "success" href = "{[b.build[0].build_page_url]}" > < span ng-repeat = "t in b.targets" ng-include src = "'target_display'" > < / span > < / a > < / div >
2014-09-09 10:47:13 +00:00
< div class = "span2 lead" >
2014-11-07 13:26:45 +00:00
< ngif ng-if = "b.build[0].completed_on - todaydate > 0" >
{[b.build[0].completed_on|date:'HH:mm']}
< / ngif >
< ngif ng-if = "b.build[0].completed_on - todaydate < 0" >
{[b.build[0].completed_on|date:'dd/MM/yy HH:mm']}
< / ngif >
2014-09-09 10:47:13 +00:00
< / div >
2014-11-24 18:27:48 +00:00
< div class = "span2" >
< ngif ng-if = "b.build[0].errors" >
< span >
< i class = "icon-minus-sign red lead" > < / i >
< a href = "{[b.build[0].build_page_url]}#errors" class = "lead error" > {[b.build[0].errors]}
< ng-pluralize count = "b.build[0].errors" when = "{'1':'error','other':'errors'}" > < / ng-pluralize > < / a >
< / span >
< / ngif >
< / div >
< div class = "span2" >
< ngif ng-if = "b.build[0].warnings" >
< span >
< i class = "icon-warning-sign yellow lead" > < / i >
< a href = "{[b.build[0].build_page_url]}#warnings" class = "lead warning" > {[b.build[0].warnings]}
< ng-pluralize count = "b.build[0].warnings" when = "{'1':'warning','other':'warnings'}" > < / ng-pluralize > < / a >
< / span >
< / ngif >
< / div >
2014-11-07 13:26:45 +00:00
< div > < span class = "lead" > Build time: < a href = "{[b.build[0].build_time_page_url]}" > {[b.build[0].build_time|timediff]}< / a > < / span >
2014-10-02 16:58:15 +00:00
< button class = "btn pull-right" ng-class = "{'Succeeded': 'btn-success', 'Failed': 'btn-danger'}[b.build[0].status]"
2015-01-08 13:15:14 +00:00
ng-click="buildExistingTarget(b.targets)">Run again< / button >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< / div >
< / case >
2014-11-07 13:26:45 +00:00
2014-10-02 16:58:15 +00:00
< case ng-switch-default = "" >
< div > FIXME!< / div >
< / case >
2014-09-09 10:47:13 +00:00
< / switch >
< div class = "lead pull-right" >
< / div >
< / div >
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< h2 class = "air" > Project configuration< / h2 >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- alerts section 2 -->
< div ng-repeat = "a in zone2alerts" >
< div class = "alert alert-dismissible lead" role = "alert" ng-class = "a.type" > < button type = "button" class = "close" data-dismiss = "alert" > < span aria-hidden = "true" > × < / span > < / button >
< span ng-bind-html = "a.text" > < / span >
< / div >
< / div >
< div class = "row-fluid" >
<!-- project layers -->
< div id = "layer-container" class = "well well-transparent span4" >
< h3 >
2014-11-27 14:27:18 +00:00
Layers < span class = "muted counter" > ({[layers.length]})< / span >
2014-09-09 10:47:13 +00:00
< i class = "icon-question-sign get-help heading-help" title = "OpenEmbedded organises metadata into modules called 'layers'. Layers allow you to isolate different types of customizations from each other. <a href='http://www.yoctoproject.org/docs/current/dev-manual/dev-manual.html#understanding-and-creating-layers' target='_blank'>More on layers</a>" > < / i >
< / h3 >
< div class = "alert" ng-if = "!layers.length" >
< b > You need to add some layers < / b >
< p >
You can:
< ul >
< li > < a href = "{% url 'layers'%}" > View all layers available in Toaster< / a >
< li > < a href = "{% url 'importlayer' %}" > Import a layer< / a >
< li > < a href = "https://www.yoctoproject.org/docs/1.6.1/dev-manual/dev-manual.html#understanding-and-creating-layers" target = "_blank" > Read about layers in the manual< / a >
< / ul >
Or type a layer name below.
< / p >
< / div >
2014-11-11 12:22:46 +00:00
< form ng-submit = "layerAdd()" >
< div class = "input-append" >
2015-01-08 13:15:14 +00:00
< input type = "text" class = "input-xlarge" id = "layer" autocomplete = "off" placeholder = "Type a layer name" data-minLength = "1" ng-model = "layerAddName" typeahead = "e.name for e in getAutocompleteSuggestions('layers', $viewValue)|filter:$viewValue" typeahead-template-url = "suggestion_details" typeahead-on-select = "onLayerSelect($item, $model, $label)" typeahead-editable = "false" ng-class = "{ 'has-error': layerAddName.$invalid }" / >
2014-09-09 10:47:13 +00:00
< input type = "submit" id = "add-layer" class = "btn" value = "Add" ng-disabled = "!layerAddName.length" / >
2014-11-11 12:22:46 +00:00
< / div >
{% csrf_token %}
2014-09-09 10:47:13 +00:00
< / form >
< p > < a href = "{% url 'layers' %}" > View all layers< / a > | < a href = "{% url 'importlayer' %}" > Import layer< / a > < / p >
< ul class = "unstyled configuration-list" >
2014-11-07 13:26:45 +00:00
< li ng-repeat = "l in layers track by l.id" class = "animate-repeat" >
2014-11-14 17:07:06 +00:00
< a href = "{[l.layerdetailurl]}" target = "_#" class = "layer-info" data-toggle = "tooltip" tooltip = "{[l.giturl]} | {[l.branch.name]}" > {[l.name]}< / a >
2014-09-09 10:47:13 +00:00
< i class = "icon-trash" ng-click = "layerDel(l.id)" tooltip = "Delete" > < / i >
2014-11-14 17:07:06 +00:00
< / li >
2014-09-09 10:47:13 +00:00
< / ul >
2014-06-30 17:33:04 +00:00
< / div >
2014-09-09 10:47:13 +00:00
<!-- project targets -->
< div id = "target-container" class = "well well-transparent span4" >
< h3 >
Targets
< i class = "icon-question-sign get-help heading-help" title = "What you build, often a recipe producing a root file system file (an image). Something like <code>core-image-minimal</code> or <code>core-image-sato</code>" > < / i >
< / h3 >
2015-01-08 13:15:14 +00:00
< form ng-submit = "buildNamedTarget()" >
2014-11-11 12:22:46 +00:00
< div class = "input-append" >
2015-01-08 13:15:14 +00:00
< input type = "text" class = "input-xlarge" placeholder = "Type the target(s) you want to build" autocomplete = "off" data-minLength = "1" ng-model = "targetName1" typeahead = "e.name for e in getAutocompleteSuggestions('targets', $viewValue)|filter:$viewValue" typeahead-template-url = "suggestion_details" ng-disabled = "!layers.length" >
2015-01-20 16:56:35 +00:00
< button type = "submit" class = "btn btn-primary" ng-disabled = "!targetName1.length" >
2014-11-11 12:22:46 +00:00
Build < / button >
< / div >
2014-09-09 10:47:13 +00:00
{% csrf_token %}
< / form >
2015-01-20 17:47:31 +00:00
< p >
< a href = "{% url 'all-targets' %}" > View all targets< / a > < / p >
2014-09-09 10:47:13 +00:00
< div ng-if = "frequenttargets.length" >
2014-11-11 12:22:46 +00:00
< h4 class = "air" >
2014-09-09 10:47:13 +00:00
Most built targets
< / h4 >
< ul class = "unstyled configuration-list" >
< li ng-repeat = "t in frequenttargets" >
< label class = "checkbox" >
< input type = "checkbox" ng-model = "mostBuiltTargets[t]" > {[t]}
< / label >
< / li >
< / ul >
2015-01-20 16:56:35 +00:00
< button class = "btn btn-large btn-primary" ng-disabled = "enableBuildSelectedTargets()" ng-click = "buildSelectedTargets()" > Build selected targets< / button >
2014-09-09 10:47:13 +00:00
< / div >
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- project configuration -->
< div id = "machine-distro" class = "well well-transparent span4" >
< h3 >
2014-11-27 14:27:18 +00:00
Machine
2014-09-09 10:47:13 +00:00
< i class = "icon-question-sign get-help heading-help" title = "The machine is the hardware for which you want to build. You can only set one machine per project" > < / i >
< / h3 >
< p class = "lead" id = "select-machine-opposite" >
2014-11-11 12:22:46 +00:00
< span > {[machine.name]}< / span >
2014-11-14 15:44:55 +00:00
< i id = "change-machine" class = "icon-pencil" ng-click = "toggle('#select-machine')" > < / i >
2014-09-09 10:47:13 +00:00
< / p >
< div id = "select-machine" style = "display: none" >
< div class = "alert alert-info" >
< strong > Machine changes have a big impact on build outcome.< / strong >
You cannot really compare the builds for the new machine with the previous ones.
2014-06-30 17:33:04 +00:00
< / div >
2015-01-08 13:15:14 +00:00
< form ng-submit = "editProjectSettings('#select-machine')" class = "input-append" >
< input type = "text" id = "machine" autocomplete = "off" ng-model = "machineName" typeahead = "m.name for m in getAutocompleteSuggestions('machines', $viewValue)" / >
2014-09-09 10:47:13 +00:00
< input type = "submit" id = "apply-change-machine" class = "btn" type = "button" ng-disabled = "machineName == machine.name || machineName.length == 0" value = "Save" > < / input >
< input type = "reset" id = "cancel-machine" class = "btn btn-link" ng-click = "toggle('#select-machine')" value = "Cancel" > < / input >
{% csrf_token %}
< / form >
< p > < a href = "{% url 'machines' %}" class = "link" > View all machines< / a > < / p >
< / div >
< p class = "link-action" >
< a href = "{% url 'projectconf' project.id %}" class = "link" > Edit configuration variables< / a >
< i data-original-title = "You can set other project configuration options here. Each option, like everything else in the build system, is a variable - value pair" class = "icon-question-sign get-help heading-help" title = "" > < / i >
2015-01-26 12:17:18 +00:00
< / p >
2014-06-30 17:33:04 +00:00
< / div >
2014-09-09 10:47:13 +00:00
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< h2 > Project details< / h2 >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
<!-- alerts section 3 -->
< div ng-repeat = "a in zone3alerts" >
< div class = "alert alert-dismissible lead" role = "alert" ng-class = "a.type" > < button type = "button" class = "close" data-dismiss = "alert" > < span aria-hidden = "true" > × < / span > < / button >
< span ng-bind-html = "a.text" > < / span >
< / div >
< / div >
< div id = "project-details" class = "well well-transparent" >
< h3 > Project name< / h3 >
< p class = "lead" id = "change-project-name-opposite" >
< span > {[project.name]}< / span >
2014-11-14 15:44:55 +00:00
< i class = "icon-pencil" ng-click = "toggle('#change-project-name')" > < / i >
2014-09-09 10:47:13 +00:00
< / p >
< div id = "change-project-name" style = "display:none;" >
2015-01-08 13:15:14 +00:00
< form ng-submit = "editProjectSettings('#change-project-name')" class = "input-append" >
2014-09-09 10:47:13 +00:00
< input type = "text" class = "input-xlarge" id = "type-project-name" ng-model = "projectName" >
< input type = "submit" class = "btn" value = "Save" ng-disabled = "project.name == projectName" / >
< input type = "reset" class = "btn btn-link" value = "Cancel" ng-click = "toggle('#change-project-name')" >
< / form >
< / div >
2014-06-30 17:33:04 +00:00
2014-09-09 10:47:13 +00:00
< h3 >
Release
< i class = "icon-question-sign get-help heading-help" title = "The version of the build system you want to use" > < / i >
< / h3 >
< p class = "lead" id = "change-project-version-opposite" >
2014-11-27 12:18:25 +00:00
< span id = "project-version" > {[project.release.desc]}< / span >
2014-11-14 15:44:55 +00:00
< i id = "change-version" class = "icon-pencil" ng-click = "toggle('#change-project-version')" > < / i >
2014-09-09 10:47:13 +00:00
< / p >
< div class = "div-inline" id = "change-project-version" style = "display:none;" >
2015-01-08 13:15:14 +00:00
< form ng-submit = "testProjectSettingsChange('#change-project-version')" class = "input-append" >
2014-09-09 10:47:13 +00:00
< select id = "select-version" ng-model = "projectVersion" >
2014-11-27 12:18:25 +00:00
< option ng-repeat = "r in releases" value = "{[r.id]}" ng-selected = "r.id == project.release.id" > {[r.description]}< / option >
2014-09-09 10:47:13 +00:00
< / select >
< input type = "submit" class = "btn" style = "margin-left:5px;" value = "Save" ng-disabled = "project.release.id == projectVersion" / >
< input type = "reset" class = "btn btn-link" value = "Cancel" ng-click = "toggle('#change-project-version')" ng-disabled = "project.release.id == projectVersion" / >
< / form >
< / div >
< / div >
2014-08-29 15:41:59 +00:00
2014-09-09 10:47:13 +00:00
<!-- end main -->
< / div >
2014-08-29 15:41:59 +00:00
2014-09-09 10:47:13 +00:00
<!-- load application logic ! -->
< script src = "{% static " js / projectapp . js " % } " > < / script >
<!-- dump initial data for use in the angular app -->
< script >
angular.element(document).ready(function() {
scope = angular.element("#main").scope();
scope.urls = {};
scope.urls.xhr_build = "{% url 'xhr_projectbuild' project.id %}";
scope.urls.xhr_edit = "{% url 'xhr_projectedit' project.id %}";
scope.urls.xhr_datatypeahead = "{% url 'xhr_datatypeahead' %}";
scope.urls.layers = "{% url 'layers' %}";
scope.urls.targets = "{% url 'targets' %}";
2014-12-08 15:29:01 +00:00
scope.urls.importlayer = "{% url 'importlayer'%}";
scope.urls.layer = "{% url 'layerdetails' %}";
2014-11-11 17:01:09 +00:00
scope.project = {{prj|json}};
scope.builds = {{builds|json}};
scope.layers = {{layers|json}};
scope.targets = {{targets|json}};
scope.frequenttargets = {{freqtargets|json}};
scope.machine = {{machine|json}};
scope.releases = {{releases|json}};
2014-09-09 10:47:13 +00:00
2014-11-07 13:26:45 +00:00
var now = (new Date()).getTime();
scope.todaydate = now - (now % 86400000);
2014-09-09 10:47:13 +00:00
scope.zone1alerts = [];
scope.zone2alerts = [];
scope.zone3alerts = [];
scope.mostBuiltTargets = {};
2014-11-07 13:26:45 +00:00
scope.updateDisplayWithCommands();
2014-09-09 10:47:13 +00:00
scope.validateData();
2015-01-08 13:15:14 +00:00
scope.init();
2014-09-09 10:47:13 +00:00
scope.$digest();
});
< / script >
2014-06-30 17:33:04 +00:00
2014-06-26 14:21:42 +00:00
{% endblock %}