From 4107d6c4a57cf48bddc50307d2e22df3f8f2f912 Mon Sep 17 00:00:00 2001 From: luffyzhao Date: Fri, 25 May 2018 13:45:16 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9select=E9=BB=98=E8=AE=A4value?= =?UTF-8?q?=E4=B8=BA0=E4=B8=8D=E8=83=BD=E9=80=89=E5=AE=9A=E7=9A=84Bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 4 ++-- src/components/select/select.vue | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index a2279f44..b5950044 100644 --- a/package.json +++ b/package.json @@ -74,7 +74,7 @@ "cross-env": "^5.1.3", "css-loader": "^0.28.10", "eslint": "^3.19.0", - "eslint-plugin-vue": "^2.1.0", + "eslint-plugin-vue": "2.1.0", "extract-text-webpack-plugin": "^2.1.2", "file-loader": "^1.1.11", "friendly-errors-webpack-plugin": "^1.6.1", @@ -109,7 +109,7 @@ "vue-router": "^3.0.1", "vue-style-loader": "^4.0.2", "vue-template-compiler": "^2.5.16", - "webpack": "^3.11.0", + "webpack": "3.11.0", "webpack-dev-server": "^2.11.1", "webpack-merge": "^3.0.0" }, diff --git a/src/components/select/select.vue b/src/components/select/select.vue index ce4a1868..2792bc3c 100644 --- a/src/components/select/select.vue +++ b/src/components/select/select.vue @@ -410,7 +410,6 @@ getInitialValue(){ const {multiple, value} = this; let initialValue = Array.isArray(value) ? value : [value]; - if (!multiple && (typeof initialValue[0] === 'undefined' || (String(initialValue[0]).trim() === '' && !Number.isFinite(initialValue[0])))) initialValue = []; return initialValue.filter((item) => { return Boolean(item) || item === 0 });