From 5e43b59d8c98b394e58361c2214ea2899fc2294e Mon Sep 17 00:00:00 2001 From: goodmice Date: Mon, 11 Oct 2021 16:10:19 +0500 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=20=D1=82=D0=B8=D0=BF=20=D1=81=D1=82=D0=BE=D0=BB=D0=B1?= =?UTF-8?q?=D1=86=D0=B0=20"=D0=94=D0=B8=D0=B0=D0=BF=D0=BE=D0=B7=D0=BE?= =?UTF-8?q?=D0=BD=20=D1=81=D0=BE=20=D1=81=D1=80=D0=B5=D0=B4=D0=BD=D0=B8?= =?UTF-8?q?=D0=BC=20=D0=B7=D0=BD=D0=B0=D1=87=D0=B5=D0=BD=D0=B8=D0=B5=D0=BC?= =?UTF-8?q?"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Table/index.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/components/Table/index.ts b/src/components/Table/index.ts index d06ed94..a4363a5 100644 --- a/src/components/Table/index.ts +++ b/src/components/Table/index.ts @@ -167,6 +167,19 @@ export const makeNumericColumnPlanFact = (title: string, dataIndex: string, filt makeNumericColumn('ф', dataIndex + 'Fact', filters, filterDelegate, renderDelegate, width), ]) +export const makeNumericAvgRange = ( + title: string, + dataIndex: string, + filters: object[], + filterDelegate: (key: string | number) => any, + renderDelegate: (_: any, row: object) => any, + width: string +) => makeGroupColumn( title, [ + makeNumericColumn('мин', dataIndex + 'Min', filters, filterDelegate, renderDelegate, width), + makeNumericColumn('макс', dataIndex + 'Max', filters, filterDelegate, renderDelegate, width), + makeNumericColumn('сред', dataIndex + 'Avg', filters, filterDelegate, renderDelegate, width) +]) + type PaginationContainer = { skip?: number; take?: number;