From 0ecc402885f332b21923bb12183dc072306f2b39 Mon Sep 17 00:00:00 2001 From: cuiqian2004 <cuiqian2004@163.com> Date: 星期五, 21 三月 2025 18:36:15 +0800 Subject: [PATCH] vue3 --- components/oi-form/list/input/index.vue | 33 ++++++++++++++++++++++++++------- 1 files changed, 26 insertions(+), 7 deletions(-) diff --git a/components/oi-form/list/input/index.vue b/components/oi-form/list/input/index.vue index a0ec6f0..c212abe 100644 --- a/components/oi-form/list/input/index.vue +++ b/components/oi-form/list/input/index.vue @@ -17,8 +17,12 @@ </template> <script> + import buttonClickMixin from '@/mixins/button-click.js'; + export default { + name: "OIFormInput", + mixins: [buttonClickMixin], props: { viewMode: { type: Boolean, @@ -36,24 +40,39 @@ }, methods: { onChange(e) { - this.$emit("change", e) + this.$emit("on-change", e) }, onConfirm(e) { + console.log("onConfirm") this.onChange(e) }, onClick(e) { this.$emit("click", e) }, onFocus(e) { - this.$emit("focus", e) + this.$emit("on-focus", e) }, onPrefixButton() { - this.$emit("click-prefix") + this.handleButtonClick((done) => { + this.$emit("on-click-prefix") + setTimeout(() => { + done(); // 閲嶇疆鐘舵� + }, 1000); + }); }, onSuffixButton() { - this.$emit("click-suffix") + + this.handleButtonClick((done) => { + this.$emit("on-click-suffix") + setTimeout(() => { + done(); // 閲嶇疆鐘舵� + }, 1000); + }); + + }, - } + }, + }; </script> @@ -62,10 +81,10 @@ border: 1px solid #d5d5d5; border-radius: 6px !important; padding: 3rpx; - width: calc(100%- 6rpx); + width: calc(100% - 6rpx); display: flex; flex-direction: row; - + .input-disabled { background-color: #f3f3f3 !important; } -- Gitblit v1.9.1