From 36a32208334b5d4eb9d45b261a695176b4565c22 Mon Sep 17 00:00:00 2001 From: SMxJrz Date: Tue, 1 Mar 2016 08:47:29 -0500 Subject: [PATCH 1/2] Added a filter to the md-data-table toolset, this allows the table to filter on each column. The filter uses the column object to perform the checks and It will do lookups to the table data based on the orderBy attribute, (alternatively you can provide searchBy in that object if you don't want to do ordering for that particular column). This change only provides the filter for the user, how they lay it out should ultimately be up to them. --- app/templates/nutrition-table.html | 16 +++++++++++--- src/scripts/mdTableFilter.js | 34 ++++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+), 3 deletions(-) create mode 100644 src/scripts/mdTableFilter.js diff --git a/app/templates/nutrition-table.html b/app/templates/nutrition-table.html index c13f3a17..637c3584 100644 --- a/app/templates/nutrition-table.html +++ b/app/templates/nutrition-table.html @@ -6,13 +6,24 @@ {{hideHead ? 'Show Head' : 'Decapitate'}} {{blah ? 'turn on' : 'turn off'}} Load - + filter_list more_vert +
+
Filter by Column(s)
+
+
+ + + + +
+
+
@@ -27,7 +38,6 @@
-