From 298991253c87d4475928561c71baa6430de62c27 Mon Sep 17 00:00:00 2001 From: hectorqin Date: Fri, 21 Aug 2020 09:59:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=A1=A8=E6=A0=BCFilter?= =?UTF-8?q?=E6=BF=80=E6=B4=BB=E7=8A=B6=E6=80=81=E6=98=BE=E7=A4=BAbug,?= =?UTF-8?q?=E8=A1=A5=E5=85=85=E6=9C=AC=E5=9C=B0=E5=8F=91=E5=B8=83=E5=91=BD?= =?UTF-8?q?=E4=BB=A4=E5=8F=8A=E7=BC=96=E8=AF=91=E4=BE=9D=E8=B5=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 ++ src/renderers/Table.tsx | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 9554d6e3..707b2b58 100644 --- a/package.json +++ b/package.json @@ -10,6 +10,7 @@ "stop": "fis3 server stop", "dev": "fis3 release -cwd ./public", "publish2npm": "sh publish.sh && npm publish", + "publish": "sh publish.sh", "prettier": "prettier --write '{src,examples,scss}/**/*.{tsx,ts,jsx,scss}'" }, "repository": { @@ -119,6 +120,7 @@ "fis3-deploy-skip-packed": "0.0.5", "fis3-hook-commonjs": "^0.1.31", "fis3-hook-node_modules": "^2.3.1", + "fis3-hook-relative": "^2.0.3", "fis3-packager-deps-pack": "^0.1.2", "fis3-parser-typescript": "^1.3.0", "fis3-postpackager-loader": "^2.1.11", diff --git a/src/renderers/Table.tsx b/src/renderers/Table.tsx index ffd98fca..83f0743f 100644 --- a/src/renderers/Table.tsx +++ b/src/renderers/Table.tsx @@ -2510,7 +2510,8 @@ export class HeadCellFilterDropDown extends React.Component< alterOptions(options: Array) { const {data, filterable, name} = this.props; - const filterValue = (data && data[name]) || ''; + const filterValue = + data && typeof data[name] !== 'undefined' ? data[name] : ''; if (filterable.multiple) { options = options.map(option => ({ @@ -2591,7 +2592,7 @@ export class HeadCellFilterDropDown extends React.Component<