Fix:3282 【礼品功能】送礼包页面-送礼寄语未增加字数限制,页面优化调整

This commit is contained in:
modendeveloper
2025-02-25 23:55:37 +08:00
parent e092fe4d4c
commit 8148f629de
+13
View File
@@ -30,7 +30,9 @@
maxlength="30"
border="none"
count
ref="textarea"
cols="30"
@input="messageChange"
rows="10"></u-textarea>
</view>
</view>
@@ -190,7 +192,18 @@ export default {
imageUrl: this.giftImage
}
},
onReady() {
this.$nextTick(() => {
this.$refs.textarea.setFormatter(val => {
return val.length > 30 ? val.substring(0, 30) : val
})
})
},
methods: {
messageChange(e) {
console.log(e);
this.message = e.substring(0, 30)
},
numberChange(e) {
this.computedPrice(e.value)
},