From 9f7d7a32a3775f2e58649dec923847fce058806b Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Wed, 30 Nov 2016 20:30:48 +0200 Subject: [PATCH] Make larger area clickable in datatable header --- resources/lang/en/texts.php | 4 ++-- resources/views/list.blade.php | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/resources/lang/en/texts.php b/resources/lang/en/texts.php index 8249acde2689..d15a3468cf54 100644 --- a/resources/lang/en/texts.php +++ b/resources/lang/en/texts.php @@ -2249,9 +2249,9 @@ $LANG = array( 'deleted_product' => 'Successfully deleted product', 'deleted_products' => 'Successfully deleted :count products', 'restored_product' => 'Successfully restored product', - 'update_credit' => 'Update credit', + 'update_credit' => 'Update Credit', 'updated_credit' => 'Successfully updated credit', - 'edit_credit' => 'Edit credit', + 'edit_credit' => 'Edit Credit', ); diff --git a/resources/views/list.blade.php b/resources/views/list.blade.php index 9f93cc0e9453..ec250f1d67e3 100644 --- a/resources/views/list.blade.php +++ b/resources/views/list.blade.php @@ -169,6 +169,12 @@ filterTable_{{ $entityType }}($('#tableFilter_{{ $entityType }}').val()); } + $('.listForm_{{ $entityType }} .head0').click(function(event) { + if (event.target.type !== 'checkbox') { + $('.listForm_{{ $entityType }} .head0 input[type=checkbox]').click(); + } + }); + // Enable/disable bulk action buttons window.onDatatableReady_{{ Utils::pluralizeEntityType($entityType) }} = function() { $(':checkbox').click(function() {