mirror of
https://git.yoctoproject.org/poky
synced 2026-02-10 02:33:02 +01:00
Move the "is available to the project" state computation to the template for the Layer add/remove buttons, Recipe build/Add layer as done for the Package add/remove. This is more reliable as we can get an inconsistent state on the front end JS as there are many opportunities for hitting out of date project information. [YOCTO #8294] (Bitbake rev: 43469c3360566ad4897785f14f8717a9bc8b6078) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
17 lines
863 B
HTML
17 lines
863 B
HTML
<button data-recipe-name="{{data.name}}" class="btn btn-block layer-exists-{{data.layer_version.pk}} build-recipe-btn" style="margin-top: 5px;
|
|
{% if data.layer_version.pk not in extra.current_layers %}
|
|
display:none;
|
|
{% endif %}"
|
|
>
|
|
Build recipe
|
|
</button>
|
|
<button class="btn btn-block layerbtn layer-add-{{data.layer_version.pk}}" data-layer='{ "id": {{data.layer_version.pk}}, "name": "{{data.layer_version.layer.name}}", "layerdetailurl": "{%url 'layerdetails' extra.pid data.layer_version.pk%}"}' data-directive="add"
|
|
{% if data.layer_version.pk in extra.current_layers %}
|
|
style="display:none;"
|
|
{% endif %}
|
|
>
|
|
<i class="icon-plus"></i>
|
|
Add layer
|
|
<i title="" class="icon-question-sign get-help" data-original-title="To build this target, you must first add the {{data.layer_version.layer.name}} layer to your project"></i>
|
|
</button>
|