diff options
10 files changed, 8 insertions, 149 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index 88194504c5..422f2bfd93 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py | |||
| @@ -288,9 +288,7 @@ class BuildArtifact(models.Model): | |||
| 288 | 288 | ||
| 289 | 289 | ||
| 290 | def is_available(self): | 290 | def is_available(self): |
| 291 | if settings.MANAGED and build.project is not None: | 291 | return build.buildrequest.environment.has_artifact(file_path) |
| 292 | return build.buildrequest.environment.has_artifact(file_path) | ||
| 293 | return False | ||
| 294 | 292 | ||
| 295 | class ProjectTarget(models.Model): | 293 | class ProjectTarget(models.Model): |
| 296 | project = models.ForeignKey(Project) | 294 | project = models.ForeignKey(Project) |
diff --git a/bitbake/lib/toaster/toastergui/templates/base.html b/bitbake/lib/toaster/toastergui/templates/base.html index 3f3253d6b2..7430338b1c 100644 --- a/bitbake/lib/toaster/toastergui/templates/base.html +++ b/bitbake/lib/toaster/toastergui/templates/base.html | |||
| @@ -48,7 +48,6 @@ | |||
| 48 | }; | 48 | }; |
| 49 | </script> | 49 | </script> |
| 50 | <script src="{% static 'js/base.js' %}"></script> | 50 | <script src="{% static 'js/base.js' %}"></script> |
| 51 | {%if MANAGED %} | ||
| 52 | <script> | 51 | <script> |
| 53 | $(document).ready(function () { | 52 | $(document).ready(function () { |
| 54 | /* Vars needed for base.js */ | 53 | /* Vars needed for base.js */ |
| @@ -59,10 +58,6 @@ | |||
| 59 | basePageInit(ctx); | 58 | basePageInit(ctx); |
| 60 | }); | 59 | }); |
| 61 | </script> | 60 | </script> |
| 62 | {% endif %} | ||
| 63 | <script> | ||
| 64 | |||
| 65 | </script> | ||
| 66 | 61 | ||
| 67 | {% block extraheadcontent %} | 62 | {% block extraheadcontent %} |
| 68 | {% endblock %} | 63 | {% endblock %} |
| @@ -80,14 +75,13 @@ | |||
| 80 | <span class="brand"> | 75 | <span class="brand"> |
| 81 | <a href="/">Toaster</a> | 76 | <a href="/">Toaster</a> |
| 82 | {% if DEBUG %} | 77 | {% if DEBUG %} |
| 83 | <i class="icon-info-sign" title="<strong>Toaster version information</strong>" data-content="<dl><dt>Branch</dt><dd>{{TOASTER_BRANCH}}</dd><dt>Revision</dt><dd>{{TOASTER_REVISION}}</dd><dt>Mode</dt><dd>{%if MANAGED%}Build{%else%}Analysis{%endif%}</dd></dl>"></i> | 78 | <i class="icon-info-sign" title="<strong>Toaster version information</strong>" data-content="<dl><dt>Branch</dt><dd>{{TOASTER_BRANCH}}</dd><dt>Revision</dt><dd>{{TOASTER_REVISION}}</dd></dl>"></i> |
| 84 | {% endif %} | 79 | {% endif %} |
| 85 | </span> | 80 | </span> |
| 86 | <a class="pull-right manual" target="_blank" href="http://www.yoctoproject.org/docs/latest/toaster-manual/toaster-manual.html"> | 81 | <a class="pull-right manual" target="_blank" href="http://www.yoctoproject.org/docs/latest/toaster-manual/toaster-manual.html"> |
| 87 | <i class="icon-book"></i> | 82 | <i class="icon-book"></i> |
| 88 | Toaster manual | 83 | Toaster manual |
| 89 | </a> | 84 | </a> |
| 90 | {%if MANAGED %} | ||
| 91 | <div class="btn-group pull-right"> | 85 | <div class="btn-group pull-right"> |
| 92 | <a class="btn" id="new-project-button" href="{% url 'newproject' %}">New project</a> | 86 | <a class="btn" id="new-project-button" href="{% url 'newproject' %}">New project</a> |
| 93 | </div> | 87 | </div> |
| @@ -132,7 +126,6 @@ | |||
| 132 | </ul> | 126 | </ul> |
| 133 | </div> | 127 | </div> |
| 134 | 128 | ||
| 135 | {%endif%} | ||
| 136 | 129 | ||
| 137 | </div> | 130 | </div> |
| 138 | </div> | 131 | </div> |
diff --git a/bitbake/lib/toaster/toastergui/templates/basebuilddetailpage.html b/bitbake/lib/toaster/toastergui/templates/basebuilddetailpage.html index c8e217e9dd..d324c90712 100644 --- a/bitbake/lib/toaster/toastergui/templates/basebuilddetailpage.html +++ b/bitbake/lib/toaster/toastergui/templates/basebuilddetailpage.html | |||
| @@ -7,10 +7,8 @@ | |||
| 7 | <div class="section"> | 7 | <div class="section"> |
| 8 | <ul class="breadcrumb" id="breadcrumb"> | 8 | <ul class="breadcrumb" id="breadcrumb"> |
| 9 | <li><a href="{% url 'all-builds' %}">All builds</a></li> | 9 | <li><a href="{% url 'all-builds' %}">All builds</a></li> |
| 10 | {% if MANAGED and build.project %} | ||
| 11 | <li><a href="{% url 'project' build.project.id %}">{{build.project.name}}</a></li> | 10 | <li><a href="{% url 'project' build.project.id %}">{{build.project.name}}</a></li> |
| 12 | {%endif%} | 11 | <li><a href="{%url 'builddashboard' build.pk%}">{{build.target_set.all.0.target}} {%if build.target_set.all.count > 1%}(+ {{build.target_set.all.count|add:"-1"}}){%endif%} ({{build.completed_on|date:"d/m/y H:i"}})</a></li> |
| 13 | <li><a href="{%url 'builddashboard' build.pk%}">{{build.target_set.all.0.target}} {%if build.target_set.all.count > 1%}(+ {{build.target_set.all.count|add:"-1"}}){%endif%}{%if not MANAGED %}{{build.machine}}{%endif%} ({{build.completed_on|date:"d/m/y H:i"}})</a></li> | ||
| 14 | {% block localbreadcrumb %}{% endblock %} | 12 | {% block localbreadcrumb %}{% endblock %} |
| 15 | </ul> | 13 | </ul> |
| 16 | <script> | 14 | <script> |
diff --git a/bitbake/lib/toaster/toastergui/templates/basebuildpage.html b/bitbake/lib/toaster/toastergui/templates/basebuildpage.html index c03f1b4015..b7a4dd21ed 100644 --- a/bitbake/lib/toaster/toastergui/templates/basebuildpage.html +++ b/bitbake/lib/toaster/toastergui/templates/basebuildpage.html | |||
| @@ -8,14 +8,12 @@ | |||
| 8 | <!-- Breadcrumbs --> | 8 | <!-- Breadcrumbs --> |
| 9 | <div class="section"> | 9 | <div class="section"> |
| 10 | <ul class="breadcrumb" id="breadcrumb"> | 10 | <ul class="breadcrumb" id="breadcrumb"> |
| 11 | <li><a href="{% url 'all-builds' %}">All builds</a></li> | 11 | <li><a href="{% url 'all-builds' %}">All builds</a></li> |
| 12 | {% if MANAGED and build.project %} | ||
| 13 | <li><a href="{% url 'project' build.project.id %}">{{build.project.name}}</a></li> | 12 | <li><a href="{% url 'project' build.project.id %}">{{build.project.name}}</a></li> |
| 14 | {%endif%} | ||
| 15 | <li> | 13 | <li> |
| 16 | {% block parentbreadcrumb %} | 14 | {% block parentbreadcrumb %} |
| 17 | <a href="{%url 'builddashboard' build.pk%}"> | 15 | <a href="{%url 'builddashboard' build.pk%}"> |
| 18 | {{build.get_sorted_target_list.0.target}} {%if build.target_set.all.count > 1%}(+ {{build.target_set.all.count|add:"-1"}}){%endif%} {%if not MANAGED %}{{build.machine}}{% endif %} ({{build.completed_on|date:"d/m/y H:i"}}) | 16 | {{build.get_sorted_target_list.0.target}} {%if build.target_set.all.count > 1%}(+ {{build.target_set.all.count|add:"-1"}}){%endif%} ({{build.completed_on|date:"d/m/y H:i"}}) |
| 19 | </a> | 17 | </a> |
| 20 | {% endblock %} | 18 | {% endblock %} |
| 21 | </li> | 19 | </li> |
diff --git a/bitbake/lib/toaster/toastergui/templates/basetable_top_buildprojects.html b/bitbake/lib/toaster/toastergui/templates/basetable_top_buildprojects.html index d517179592..7b19f4befe 100644 --- a/bitbake/lib/toaster/toastergui/templates/basetable_top_buildprojects.html +++ b/bitbake/lib/toaster/toastergui/templates/basetable_top_buildprojects.html | |||
| @@ -1,7 +1,6 @@ | |||
| 1 | {% extends "basetable_top.html" %} | 1 | {% extends "basetable_top.html" %} |
| 2 | 2 | ||
| 3 | {%block custombuttons %} | 3 | {%block custombuttons %} |
| 4 | {% if MANAGED %} | ||
| 5 | <div class="btn-group builds-projects"> | 4 | <div class="btn-group builds-projects"> |
| 6 | <button class="btn dropdown-toggle" data-toggle="dropdown"> | 5 | <button class="btn dropdown-toggle" data-toggle="dropdown"> |
| 7 | <span class="selection">Show all builds</span> | 6 | <span class="selection">Show all builds</span> |
| @@ -12,5 +11,4 @@ | |||
| 12 | <li><a href="{% url 'all-projects'%}">Show all projects</a></li> | 11 | <li><a href="{% url 'all-projects'%}">Show all projects</a></li> |
| 13 | </ul> | 12 | </ul> |
| 14 | </div> | 13 | </div> |
| 15 | {% endif %} | ||
| 16 | {%endblock%} | 14 | {%endblock%} |
diff --git a/bitbake/lib/toaster/toastergui/templates/basetable_top_projectbuilds.html b/bitbake/lib/toaster/toastergui/templates/basetable_top_projectbuilds.html index bfefff5e33..f5b01c8ef6 100644 --- a/bitbake/lib/toaster/toastergui/templates/basetable_top_projectbuilds.html +++ b/bitbake/lib/toaster/toastergui/templates/basetable_top_projectbuilds.html | |||
| @@ -1,7 +1,6 @@ | |||
| 1 | {% extends "basetable_top.html" %} | 1 | {% extends "basetable_top.html" %} |
| 2 | 2 | ||
| 3 | {%block custombuttons %} | 3 | {%block custombuttons %} |
| 4 | {% if MANAGED %} | ||
| 5 | <div class="btn-group builds-projects"> | 4 | <div class="btn-group builds-projects"> |
| 6 | <button class="btn dropdown-toggle" data-toggle="dropdown"> | 5 | <button class="btn dropdown-toggle" data-toggle="dropdown"> |
| 7 | <span class="selection">Show all projects</span> | 6 | <span class="selection">Show all projects</span> |
| @@ -12,5 +11,4 @@ | |||
| 12 | <li><a href="{% url 'all-projects'%}">Show all projects</a></li> | 11 | <li><a href="{% url 'all-projects'%}">Show all projects</a></li> |
| 13 | </ul> | 12 | </ul> |
| 14 | </div> | 13 | </div> |
| 15 | {% endif %} | ||
| 16 | {%endblock%} | 14 | {%endblock%} |
diff --git a/bitbake/lib/toaster/toastergui/templates/bpackage.html b/bitbake/lib/toaster/toastergui/templates/bpackage.html index 1c47354a99..d775fec737 100644 --- a/bitbake/lib/toaster/toastergui/templates/bpackage.html +++ b/bitbake/lib/toaster/toastergui/templates/bpackage.html | |||
| @@ -88,9 +88,6 @@ | |||
| 88 | </a> | 88 | </a> |
| 89 | </td> | 89 | </td> |
| 90 | <!-- Layer directory --> | 90 | <!-- Layer directory --> |
| 91 | {% if not MANAGED or not build.project %} | ||
| 92 | <td class="recipe__layer_version__local_path">{{package.recipe.layer_version.local_path}}</td> | ||
| 93 | {% endif %} | ||
| 94 | {%else%} | 91 | {%else%} |
| 95 | <td class="recipe__name"></td> | 92 | <td class="recipe__name"></td> |
| 96 | <td class="recipe__version"></td> | 93 | <td class="recipe__version"></td> |
diff --git a/bitbake/lib/toaster/toastergui/templates/build.html b/bitbake/lib/toaster/toastergui/templates/build.html index f7ad2f4892..f0b5ea529f 100644 --- a/bitbake/lib/toaster/toastergui/templates/build.html +++ b/bitbake/lib/toaster/toastergui/templates/build.html | |||
| @@ -68,11 +68,9 @@ | |||
| 68 | {% query build.task_build outcome=4 order__gt=0 as exectask%} | 68 | {% query build.task_build outcome=4 order__gt=0 as exectask%} |
| 69 | {% if exectask.count == 1 %} | 69 | {% if exectask.count == 1 %} |
| 70 | <a href="{% url "task" build.id exectask.0.id %}">{{exectask.0.recipe.name}}.{{exectask.0.task_name}}</a> | 70 | <a href="{% url "task" build.id exectask.0.id %}">{{exectask.0.recipe.name}}.{{exectask.0.task_name}}</a> |
| 71 | {% if MANAGED and build.project %} | ||
| 72 | <a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}"> | 71 | <a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}"> |
| 73 | <i class="icon-download-alt" title="" data-original-title="Download task log file"></i> | 72 | <i class="icon-download-alt" title="" data-original-title="Download task log file"></i> |
| 74 | </a> | 73 | </a> |
| 75 | {% endif %} | ||
| 76 | {% elif exectask.count > 1%} | 74 | {% elif exectask.count > 1%} |
| 77 | <a href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}} task{{exectask.count|pluralize}}</a> | 75 | <a href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}} task{{exectask.count|pluralize}}</a> |
| 78 | {%endif%} | 76 | {%endif%} |
| @@ -84,21 +82,15 @@ | |||
| 84 | </td> | 82 | </td> |
| 85 | <td class="warnings_no">{% if build.warnings_no %}<a class="warnings_no warning" href="{% url "builddashboard" build.id %}#warnings">{{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a>{%endif%}</td> | 83 | <td class="warnings_no">{% if build.warnings_no %}<a class="warnings_no warning" href="{% url "builddashboard" build.id %}#warnings">{{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a>{%endif%}</td> |
| 86 | <td class="time"><a href="{% url "buildtime" build.id %}">{{build.timespent|sectohms}}</a></td> | 84 | <td class="time"><a href="{% url "buildtime" build.id %}">{{build.timespent|sectohms}}</a></td> |
| 87 | {% if not MANAGED or not build.project %} | ||
| 88 | <td class="log">{{build.cooker_log_path}}</td> | ||
| 89 | {% endif %} | ||
| 90 | <td class="output"> | 85 | <td class="output"> |
| 91 | {% if build.outcome == build.SUCCEEDED %} | 86 | {% if build.outcome == build.SUCCEEDED %} |
| 92 | <a href="{%url "builddashboard" build.id%}#images">{{fstypes|get_dict_value:build.id}}</a> | 87 | <a href="{%url "builddashboard" build.id%}#images">{{fstypes|get_dict_value:build.id}}</a> |
| 93 | {% endif %} | 88 | {% endif %} |
| 94 | </td> | 89 | </td> |
| 95 | {% if MANAGED %} | ||
| 96 | <td class="project"> | ||
| 97 | {% if build.project %} | 90 | {% if build.project %} |
| 98 | <a href="{% url 'project' build.project.id %}">{{build.project.name}}</a> | 91 | <a href="{% url 'project' build.project.id %}">{{build.project.name}}</a> |
| 99 | {% endif %} | 92 | {% endif %} |
| 100 | </td> | 93 | </td> |
| 101 | {% endif %} | ||
| 102 | </tr> | 94 | </tr> |
| 103 | 95 | ||
| 104 | {% endfor %} | 96 | {% endfor %} |
diff --git a/bitbake/lib/toaster/toastergui/templates/builddashboard.html b/bitbake/lib/toaster/toastergui/templates/builddashboard.html index ad497e6277..47b8d7aa1f 100644 --- a/bitbake/lib/toaster/toastergui/templates/builddashboard.html +++ b/bitbake/lib/toaster/toastergui/templates/builddashboard.html | |||
| @@ -37,9 +37,7 @@ | |||
| 37 | <span > <i class="icon-warning-sign yellow"></i><strong><a href="#warnings" class="warning show-warnings"> {{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a></strong></span> | 37 | <span > <i class="icon-warning-sign yellow"></i><strong><a href="#warnings" class="warning show-warnings"> {{build.warnings_no}} warning{{build.warnings_no|pluralize}}</a></strong></span> |
| 38 | {% endif %} | 38 | {% endif %} |
| 39 | <span class="pull-right">Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a> | 39 | <span class="pull-right">Build time: <a href="{% url 'buildtime' build.pk %}">{{ build.timespent|sectohms }}</a> |
| 40 | {% if MANAGED and build.project %} | ||
| 41 | <a class="btn {%if build.outcome == build.SUCCEEDED%}btn-success{%else%}btn-danger{%endif%} pull-right log" href="{% url 'build_artifact' build.id "cookerlog" build.id %}">Download build log</a> | 40 | <a class="btn {%if build.outcome == build.SUCCEEDED%}btn-success{%else%}btn-danger{%endif%} pull-right log" href="{% url 'build_artifact' build.id "cookerlog" build.id %}">Download build log</a> |
| 42 | {% endif %} | ||
| 43 | </span> | 41 | </span> |
| 44 | {%endif%} | 42 | {%endif%} |
| 45 | </div> | 43 | </div> |
| @@ -117,19 +115,11 @@ | |||
| 117 | <dt> | 115 | <dt> |
| 118 | <i class="icon-question-sign get-help" title="The location in disk of the license manifest, a document listing all packages installed in your image and their licenses"></i> | 116 | <i class="icon-question-sign get-help" title="The location in disk of the license manifest, a document listing all packages installed in your image and their licenses"></i> |
| 119 | 117 | ||
| 120 | {% if MANAGED and build.project %} | ||
| 121 | License manifest | 118 | License manifest |
| 122 | {% else %} | ||
| 123 | <a href="{% url 'targetpkg' build.pk target.target.pk %}">License manifest</a> | ||
| 124 | {% endif %} | ||
| 125 | </dt> | 119 | </dt> |
| 126 | {% if MANAGED and build.project %} | ||
| 127 | <dd> | 120 | <dd> |
| 128 | <a href="{% url 'targetpkg' build.pk target.target.pk %}">View in Toaster</a> | | 121 | <a href="{% url 'targetpkg' build.pk target.target.pk %}">View in Toaster</a> | |
| 129 | <a href="{% url 'build_artifact' build.pk 'licensemanifest' target.target.pk %}">Download</a></dd> | 122 | <a href="{% url 'build_artifact' build.pk 'licensemanifest' target.target.pk %}">Download</a></dd> |
| 130 | {% else %} | ||
| 131 | <dd><code>{{target.target.license_manifest_path}}</code></dd> | ||
| 132 | {% endif %} | ||
| 133 | <dt> | 123 | <dt> |
| 134 | <i class="icon-question-sign get-help" title="Image files are stored in <code>/build/tmp/deploy/images/</code>"></i> | 124 | <i class="icon-question-sign get-help" title="Image files are stored in <code>/build/tmp/deploy/images/</code>"></i> |
| 135 | Image files | 125 | Image files |
| @@ -170,13 +160,9 @@ | |||
| 170 | Other artifacts</dt> | 160 | Other artifacts</dt> |
| 171 | <dd><div> | 161 | <dd><div> |
| 172 | {% for ba in build.buildartifact_set.all|dictsort:"file_name" %} | 162 | {% for ba in build.buildartifact_set.all|dictsort:"file_name" %} |
| 173 | {% if MANAGED and build.project %} | ||
| 174 | <a href="{%url 'build_artifact' build.id 'buildartifact' ba.id %}"> | 163 | <a href="{%url 'build_artifact' build.id 'buildartifact' ba.id %}"> |
| 175 | {% endif %} | ||
| 176 | {{ba.get_local_file_name}} | 164 | {{ba.get_local_file_name}} |
| 177 | {% if MANAGED and build.project %} | ||
| 178 | </a> | 165 | </a> |
| 179 | {% endif %} | ||
| 180 | 166 | ||
| 181 | ({{ba.file_size|filtered_filesizeformat}}) <br/> | 167 | ({{ba.file_size|filtered_filesizeformat}}) <br/> |
| 182 | {% endfor %} | 168 | {% endfor %} |
| @@ -211,11 +197,9 @@ | |||
| 211 | <span class="task-name">{{exectask.0.task_name}}</span> | 197 | <span class="task-name">{{exectask.0.task_name}}</span> |
| 212 | </a> | 198 | </a> |
| 213 | 199 | ||
| 214 | {% if MANAGED and build.project %} | ||
| 215 | <a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}"> | 200 | <a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}"> |
| 216 | <i class="icon-download-alt" title="" data-original-title="Download task log file"></i> | 201 | <i class="icon-download-alt" title="" data-original-title="Download task log file"></i> |
| 217 | </a> | 202 | </a> |
| 218 | {% endif %} | ||
| 219 | 203 | ||
| 220 | {% elif exectask.count > 1%} | 204 | {% elif exectask.count > 1%} |
| 221 | <a class="error" href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}}</a> | 205 | <a class="error" href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}}</a> |
diff --git a/bitbake/lib/toaster/toastergui/views.py b/bitbake/lib/toaster/toastergui/views.py index 4dac62c568..bfae304587 100755 --- a/bitbake/lib/toaster/toastergui/views.py +++ b/bitbake/lib/toaster/toastergui/views.py | |||
| @@ -807,18 +807,6 @@ eans multiple licenses exist that cover different parts of the source', | |||
| 807 | ] | 807 | ] |
| 808 | } | 808 | } |
| 809 | 809 | ||
| 810 | if not toastermain.settings.MANAGED or build.project is None: | ||
| 811 | |||
| 812 | tc_layerDir = { | ||
| 813 | 'name':'Layer directory', | ||
| 814 | 'qhelp':'Location in disk of the layer providing the recipe that builds the package', | ||
| 815 | 'orderfield' : _get_toggle_order( request, "recipe__layer_version__local_path" ), | ||
| 816 | 'ordericon' : _get_toggle_order_icon( request, "recipe__layer_version__local_path" ), | ||
| 817 | 'orderkey' : "recipe__layer_version__local_path", | ||
| 818 | 'clclass' : 'layer_directory', | ||
| 819 | 'hidden' : 1, | ||
| 820 | } | ||
| 821 | context['tablecols'].append(tc_layerDir) | ||
| 822 | 810 | ||
| 823 | response = render(request, template, context) | 811 | response = render(request, template, context) |
| 824 | _set_parameters_values(pagesize, orderby, request) | 812 | _set_parameters_values(pagesize, orderby, request) |
| @@ -1209,9 +1197,6 @@ def tasks_common(request, build_id, variant, task_anchor): | |||
| 1209 | ]} | 1197 | ]} |
| 1210 | 1198 | ||
| 1211 | 1199 | ||
| 1212 | if not toastermain.settings.MANAGED or build.project is None: | ||
| 1213 | context['tablecols'].append(tc_log) | ||
| 1214 | |||
| 1215 | response = render(request, template, context) | 1200 | response = render(request, template, context) |
| 1216 | _set_parameters_values(pagesize, orderby, request) | 1201 | _set_parameters_values(pagesize, orderby, request) |
| 1217 | return response | 1202 | return response |
| @@ -1336,18 +1321,6 @@ def recipes(request, build_id): | |||
| 1336 | ] | 1321 | ] |
| 1337 | } | 1322 | } |
| 1338 | 1323 | ||
| 1339 | if not toastermain.settings.MANAGED or build.project is None: | ||
| 1340 | context['tablecols'].append( | ||
| 1341 | { | ||
| 1342 | 'name':'Layer directory', | ||
| 1343 | 'qhelp':'Path to the layer prodiving the recipe', | ||
| 1344 | 'orderfield': _get_toggle_order(request, "layer_version__local_path"), | ||
| 1345 | 'ordericon':_get_toggle_order_icon(request, "layer_version__local_path"), | ||
| 1346 | 'orderkey' : 'layer_version__local_path', | ||
| 1347 | 'clclass': 'layer_version__local_path', 'hidden': 1, | ||
| 1348 | }) | ||
| 1349 | |||
| 1350 | |||
| 1351 | response = render(request, template, context) | 1324 | response = render(request, template, context) |
| 1352 | _set_parameters_values(pagesize, orderby, request) | 1325 | _set_parameters_values(pagesize, orderby, request) |
| 1353 | return response | 1326 | return response |
| @@ -1550,18 +1523,6 @@ def bpackage(request, build_id): | |||
| 1550 | ] | 1523 | ] |
| 1551 | } | 1524 | } |
| 1552 | 1525 | ||
| 1553 | if not toastermain.settings.MANAGED or build.project is None: | ||
| 1554 | |||
| 1555 | tc_layerDir = { | ||
| 1556 | 'name':'Layer directory', | ||
| 1557 | 'qhelp':'Path to the layer providing the recipe that builds the package', | ||
| 1558 | 'orderfield': _get_toggle_order(request, "recipe__layer_version__local_path"), | ||
| 1559 | 'ordericon':_get_toggle_order_icon(request, "recipe__layer_version__local_path"), | ||
| 1560 | 'orderkey' : 'recipe__layer_version__local_path', | ||
| 1561 | 'clclass': 'recipe__layer_version__local_path', 'hidden': 1, | ||
| 1562 | } | ||
| 1563 | context['tablecols'].append(tc_layerDir) | ||
| 1564 | |||
| 1565 | response = render(request, template, context) | 1526 | response = render(request, template, context) |
| 1566 | _set_parameters_values(pagesize, orderby, request) | 1527 | _set_parameters_values(pagesize, orderby, request) |
| 1567 | return response | 1528 | return response |
| @@ -1877,7 +1838,6 @@ def managedcontextprocessor(request): | |||
| 1877 | import subprocess | 1838 | import subprocess |
| 1878 | ret = { | 1839 | ret = { |
| 1879 | "projects": Project.objects.all(), | 1840 | "projects": Project.objects.all(), |
| 1880 | "MANAGED" : toastermain.settings.MANAGED, | ||
| 1881 | "DEBUG" : toastermain.settings.DEBUG, | 1841 | "DEBUG" : toastermain.settings.DEBUG, |
| 1882 | "TOASTER_BRANCH": toastermain.settings.TOASTER_BRANCH, | 1842 | "TOASTER_BRANCH": toastermain.settings.TOASTER_BRANCH, |
| 1883 | "TOASTER_REVISION" : toastermain.settings.TOASTER_REVISION, | 1843 | "TOASTER_REVISION" : toastermain.settings.TOASTER_REVISION, |
| @@ -1892,8 +1852,8 @@ from orm.models import Project, ProjectLayer, ProjectTarget, ProjectVariable | |||
| 1892 | 1852 | ||
| 1893 | # we have a set of functions if we're in managed mode, or | 1853 | # we have a set of functions if we're in managed mode, or |
| 1894 | # a default "page not available" simple functions for interactive mode | 1854 | # a default "page not available" simple functions for interactive mode |
| 1895 | if toastermain.settings.MANAGED: | ||
| 1896 | 1855 | ||
| 1856 | if True: | ||
| 1897 | from django.contrib.auth.models import User | 1857 | from django.contrib.auth.models import User |
| 1898 | from django.contrib.auth import authenticate, login | 1858 | from django.contrib.auth import authenticate, login |
| 1899 | from django.contrib.auth.decorators import login_required | 1859 | from django.contrib.auth.decorators import login_required |
| @@ -2937,11 +2897,8 @@ if toastermain.settings.MANAGED: | |||
| 2937 | return context | 2897 | return context |
| 2938 | 2898 | ||
| 2939 | 2899 | ||
| 2940 | else: | 2900 | @_template_renderer('builds.html') |
| 2941 | # shows the "all builds" page for interactive mode; this is the old code, simply moved | 2901 | def builds_old(request): |
| 2942 | |||
| 2943 | @_template_renderer('build.html') | ||
| 2944 | def builds(request): | ||
| 2945 | # define here what parameters the view needs in the GET portion in order to | 2902 | # define here what parameters the view needs in the GET portion in order to |
| 2946 | # be able to display something. 'count' and 'page' are mandatory for all views | 2903 | # be able to display something. 'count' and 'page' are mandatory for all views |
| 2947 | # that use paginators. | 2904 | # that use paginators. |
| @@ -3132,57 +3089,3 @@ else: | |||
| 3132 | _set_parameters_values(pagesize, orderby, request) | 3089 | _set_parameters_values(pagesize, orderby, request) |
| 3133 | 3090 | ||
| 3134 | return context | 3091 | return context |
| 3135 | |||
| 3136 | |||
| 3137 | |||
| 3138 | |||
| 3139 | @_template_renderer('landing_not_managed.html') | ||
| 3140 | def newproject(request): | ||
| 3141 | return {} | ||
| 3142 | |||
| 3143 | @_template_renderer('landing_not_managed.html') | ||
| 3144 | def project(request, pid): | ||
| 3145 | return {} | ||
| 3146 | |||
| 3147 | from django.views.decorators.csrf import csrf_exempt | ||
| 3148 | @csrf_exempt | ||
| 3149 | @_template_renderer('landing_not_managed.html') | ||
| 3150 | def xhr_datatypeahead(request, pid): | ||
| 3151 | return {} | ||
| 3152 | |||
| 3153 | |||
| 3154 | @_template_renderer('landing_not_managed.html') | ||
| 3155 | def xhr_configvaredit(request, pid): | ||
| 3156 | return {} | ||
| 3157 | |||
| 3158 | @_template_renderer('landing_not_managed.html') | ||
| 3159 | def importlayer(request): | ||
| 3160 | return {} | ||
| 3161 | |||
| 3162 | @_template_renderer('landing_not_managed.html') | ||
| 3163 | def projectconf(request, pid): | ||
| 3164 | return {} | ||
| 3165 | |||
| 3166 | @_template_renderer('landing_not_managed.html') | ||
| 3167 | def projectbuilds(request, pid): | ||
| 3168 | return {} | ||
| 3169 | |||
| 3170 | @_template_renderer('landing_not_managed.html') | ||
| 3171 | def build_artifact(request, build_id, artifact_type, artifact_id): | ||
| 3172 | return {} | ||
| 3173 | |||
| 3174 | @_template_renderer('landing_not_managed.html') | ||
| 3175 | def projects(request): | ||
| 3176 | return {} | ||
| 3177 | |||
| 3178 | @_template_renderer('landing_not_managed.html') | ||
| 3179 | def xhr_importlayer(request): | ||
| 3180 | return {} | ||
| 3181 | |||
| 3182 | @_template_renderer('landing_not_managed.html') | ||
| 3183 | def xhr_updatelayer(request): | ||
| 3184 | return {} | ||
| 3185 | |||
| 3186 | @_template_renderer('landing_not_managed.html') | ||
| 3187 | def buildrequestdetails(request, pid, brid): | ||
| 3188 | return {} | ||
