diff --git a/src/mixins/popup/index.js b/src/mixins/popup/index.js index 4ecc1e418..388528bab 100644 --- a/src/mixins/popup/index.js +++ b/src/mixins/popup/index.js @@ -66,15 +66,14 @@ export default { /** * 显示popup */ - open(options) { + open() { if (this.opened) return; this.opening = true; this.$emit('input', true); - const props = merge({}, this, options); - const zIndex = props.zIndex; + const zIndex = this.zIndex; // 如果属性中传入了`zIndex`,则覆盖`popupContext`中对应的`zIndex` if (zIndex) { diff --git a/src/mixins/popup/popup-context.js b/src/mixins/popup/popup-context.js index a4cccf692..66dae4ea2 100644 --- a/src/mixins/popup/popup-context.js +++ b/src/mixins/popup/popup-context.js @@ -25,7 +25,7 @@ const PopupContext = { }, plusKeyByOne(key) { - const oldVal = context[key]; + const oldVal = +context[key]; context[key] = oldVal + 1; return oldVal;