mirror of
https://git.yoctoproject.org/poky
synced 2026-06-01 00:59:48 +00:00
bitbake: toaster: warn new filter replaces existing filter
If the user pop-ups a filter dialog when another filter is already active, warn the user that the new filter would replace the previous filter. [YOCTO #5960] (Bitbake rev: 6be58123fcdb0ff20de2a88315e1e3012effd1d3) Signed-off-by: David Reyna <David.Reyna@windriver.com> Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
604d2c8df3
commit
4f02193f05
@@ -105,6 +105,7 @@ select { width: auto; }
|
|||||||
.no-results { margin: 10px 0; }
|
.no-results { margin: 10px 0; }
|
||||||
.task-name { margin-left: 7px; }
|
.task-name { margin-left: 7px; }
|
||||||
.icon-hand-right {color: #ccccc; }
|
.icon-hand-right {color: #ccccc; }
|
||||||
|
.help-inline { margin: 5px; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -28,6 +28,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<button type="submit" class="btn btn-primary">Apply</button>
|
<button type="submit" class="btn btn-primary">Apply</button>
|
||||||
|
{% if request.GET.filter %}
|
||||||
|
{% if request.GET.filter|string_remove_regex:':.*' != f.options.0.1|string_remove_regex:':.*' %}
|
||||||
|
<span class="help-inline pull-left">You can only apply one filter to the table. This filter will override the current filter.</span>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
|||||||
@@ -188,6 +188,12 @@ def string_slice(strvar,slicevar):
|
|||||||
else:
|
else:
|
||||||
return strvar[int(first):int(last)]
|
return strvar[int(first):int(last)]
|
||||||
|
|
||||||
|
@register.filter
|
||||||
|
def string_remove_regex(value,ex):
|
||||||
|
""" remove sub-string of string that matches regex
|
||||||
|
"""
|
||||||
|
return re.sub(ex, '', value)
|
||||||
|
|
||||||
@register.filter
|
@register.filter
|
||||||
def filtered_installedsize(size, installed_size):
|
def filtered_installedsize(size, installed_size):
|
||||||
"""If package.installed_size not null and not empty return it,
|
"""If package.installed_size not null and not empty return it,
|
||||||
|
|||||||
Reference in New Issue
Block a user