diff src/app/query-mode.ts @ 55:308c96f734c8 ng2-table

first steps to importing state from URL.
author casties
date Mon, 27 Mar 2017 14:17:55 +0200
parents b65a031c4967
children
line wrap: on
line diff
--- a/src/app/query-mode.ts	Thu Mar 23 18:57:01 2017 +0100
+++ b/src/app/query-mode.ts	Mon Mar 27 14:17:55 2017 +0200
@@ -3,6 +3,10 @@
     label: string;
 }
 
+export function getQueryModeById(id: string) {
+    return QUERY_MODES.find((elem) => elem.id === id);
+}
+
 export var QUERY_MODES: QueryMode[] = [
     {id: 'type_is', label:'Object type is'},
     {id: 'att_contains', label: 'Attribute (contains)'},