]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
toaster: tweaks to recipe file downloads
authorBelen Barros Pena <belen.barros.pena@linux.intel.com>
Thu, 28 Apr 2016 12:45:17 +0000 (13:45 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 13 Jun 2016 21:04:29 +0000 (22:04 +0100)
* In the custom images table, show the recipe file and download icon
only when the recipe file exists and can be downloaded.

* Also in the custom images table, make sure the download icon tooltip
shows on hover.

* In the custom image details page, show the correct icon (download)
next to the recipe file in the right hand column.

* In the custom image details page, show the recipe file and download
icon in the right hand column only when the recipe file exists and can
be downloaded

* Also in the custom image details page, simplify the help text we show
when the 'download' button is disabled: it gave so much information about
what's actually happening under the hood that it was a bit hard to
follow.

Signed-off-by: Belen Barros Pena <belen.barros.pena@linux.intel.com>
Signed-off-by: Elliot Smith <elliot.smith@intel.com>
lib/toaster/toastergui/tables.py
lib/toaster/toastergui/templates/customrecipe.html

index caa2fba51a80ba889a4135ce2d1c9ea185308290..2bbef637aa8e4245bd21d8a7d927f9db71d6ea08 100644 (file)
@@ -495,12 +495,9 @@ class CustomImagesTable(ToasterTable):
                         static_data_template=name_link_template)
 
         recipe_file_template = '''
-        <code>{{data.name}}_{{data.version}}.bb</code>
         {% if data.get_base_recipe_file %}
-        <a href="{% url 'customrecipedownload' extra.pid data.pk %}">
-        <i class="icon-download-alt" data-original-title="Download recipe
-        file"></i>
-        </a>
+        <code>{{data.name}}_{{data.version}}.bb</code>
+        <a href="{% url 'customrecipedownload' extra.pid data.pk %}" class="icon-download-alt get-help" title="Download recipe file"></a>
         {% endif %}'''
 
         self.add_column(title="Recipe file",
index aeb4466a209cb7a31c4c2c7d5d838da97f59dbff..4b1ef6617fee3b6d87ae638846004d695ab2adec 100644 (file)
         Download recipe file
         {% if not base_recipe_file %}
         <i class="icon-question-sign get-help"
-          data-original-title="The {{recipe.name}} recipe cannot yet be downloaded as the Based on recipe '{{recipe.base_recipe.name}}' has not yet been fetched"></i>
+          data-original-title="The recipe file doesn't exist yet, so you cannot download it. You need to build your custom image first"></i>
         {% endif %}
       </a>
     </div>
         </dd>
         {% endwith %}
         {% endif %}
+        {% if base_recipe_file %}
         <dt>Recipe file</dt>
         <dd>
           <code>{{recipe.name}}_{{recipe.version}}.bb</code>
-          {% if base_recipe_path %}
-          <a href="{% url 'customrecipedownload' project.pk recipe.pk %}"><i class="icon-share" title="" data-original-title="View recipe file"></i></a>
-          {% endif %}
+          <a href="{% url 'customrecipedownload' project.pk recipe.pk %}"><i class="icon-download-alt" title="Download recipe file"></i></a>
         </dd>
+        {% endif %}
         <dt>Layer</dt>
         <dd><a href="{% url 'layerdetails' project.id recipe.layer_version.pk %}">{{recipe.layer_version.layer.name}}</a></dd>
         {% if recipe.summary %}