From 1bf07892f2cd8007f48469c42fa9fcc84d5ef435 Mon Sep 17 00:00:00 2001
From: eug-vs <eug-vs@keemail.me>
Date: Sat, 17 Apr 2021 13:39:30 +0300
Subject: feat: correctly add filters from Service JSON

---
 src/lib/ServiceContext.tsx | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

(limited to 'src/lib/ServiceContext.tsx')

diff --git a/src/lib/ServiceContext.tsx b/src/lib/ServiceContext.tsx
index ec76106..67f3756 100644
--- a/src/lib/ServiceContext.tsx
+++ b/src/lib/ServiceContext.tsx
@@ -2,17 +2,11 @@ import React from 'react';
 import { FormikProps } from 'formik';
 import { Props as ButtonProps } from '../components/Button';
 import { Field } from '../components/ListTable';
-import { Option } from '../components/Select';
 
 export interface Action extends ButtonProps {
   name: string;
 }
 
-export interface Filter {
-  field: string;
-  options: Option[];
-}
-
 export interface PanelProps<T> {
   item: T;
   mutate: (item: T) => void;
@@ -26,6 +20,7 @@ export interface ServiceParams<T = any> {
   default?: Partial<T>;
   routes?: Record<string, React.FC>;
   actions?: Action[];
+  filters?: string[];
   rowLink?: (item: T) => string;
   Form?: React.FC<FormikProps<T>>;
   Panel?: React.FC<PanelProps<T>>;
-- 
cgit v1.2.3

