- Sets correctly the selected filter operation

- Use enter to set a filter
- Replaced submit buttons with buttons
This commit is contained in:
Paolo
2017-12-01 16:57:18 +01:00
parent 54f1403054
commit e2908cc1d7
4 changed files with 37 additions and 14 deletions
+7 -2
View File
@@ -14,6 +14,7 @@
$(".remove-field").each(function() {
$(this).click(function() {
$("#rmField").val($(this).attr('fieldToRemove'));
$("#filterForm").submit();
});
});
@@ -24,6 +25,7 @@
$(".remove-filter").each(function() {
$(this).click(function() {
$("#rmFilter").val($(this).attr('filterToRemove'));
$("#filterForm").submit();
});
});
@@ -31,8 +33,11 @@
$("#filterForm").submit();
});
$(".select-filter-operation-value").keyup(function() {
$("#filterForm").submit();
$(".select-filter-operation-value").keydown(function(event) {
if (event.which == 13)
{
$("#filterForm").submit();
}
});
});
@@ -6,7 +6,7 @@
{
$selectedField = $selectedFields[$selectedFieldsCounter];
?>
<input type="submit" value="<?php echo $selectedField; ?> X" class="remove-field" fieldToRemove="<?php echo $selectedField; ?>">
<input type="button" value="<?php echo $selectedField; ?> X" class="remove-field" fieldToRemove="<?php echo $selectedField; ?>">
<?php
}
?>
@@ -17,7 +17,7 @@
<?php echo FilterWidget::renderFilterType($md); ?>
<span>
<input type="submit" value="X" class="remove-filter" filterToRemove="<?php echo $md->name; ?>">
<input type="button" value="X" class="remove-filter" filterToRemove="<?php echo $md->name; ?>">
</span>
</div>