Commit e9806f5d authored by 刘用法's avatar 刘用法

滚动收起键盘

parent 58d2a288
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<template> <template>
<view :style="{'width': fieldsWidth}"> <view :style="{'width': fieldsWidth}">
<u-input :type="type" class="input-item" v-model="dataValue" @input="valueChange" :placeholder="placeholder" :placeholder-style="placeholderStyle" <u-input :type="type" class="input-item" v-model="dataValue" @input="valueChange" :placeholder="placeholder" :placeholder-style="placeholderStyle"
:custom-style="customStyle" :clearable="false" :border="border" border-color="#ECECEC" :maxlength="maxlength"/> :custom-style="customStyle" :clearable="false" :border="border" border-color="#ECECEC" :maxlength="maxlength" :cursor-spacing="10" hold-keyboard/>
</view> </view>
</template> </template>
...@@ -93,7 +93,11 @@ ...@@ -93,7 +93,11 @@
}, },
watch: {}, watch: {},
mounted() {}, mounted() {},
methods: {} methods: {
handleFocus() {
console.log('handle focus')
}
}
} }
</script> </script>
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
</scroll-view> </scroll-view>
<view class="form-list"> <view class="form-list" @touchmove="handleTouchstart">
<u-form :model="form" ref="uForm"> <u-form :model="form" ref="uForm">
<template v-for="(groupItem, groupIndex) in (list.length>0?list[tabIndex].items:[])"> <template v-for="(groupItem, groupIndex) in (list.length>0?list[tabIndex].items:[])">
<view class="class-item" :key="groupIndex" v-show="current == groupIndex"> <view class="class-item" :key="groupIndex" v-show="current == groupIndex">
...@@ -674,6 +674,9 @@ ...@@ -674,6 +674,9 @@
} }
} }
}, 10) }, 10)
},
handleTouchstart() {
uni.hideKeyboard()
} }
} }
} }
......
...@@ -938,6 +938,7 @@ ...@@ -938,6 +938,7 @@
font-size: 26rpx; font-size: 26rpx;
color: #333333; color: #333333;
margin-top: 30rpx; margin-top: 30rpx;
margin-bottom: 30rpx;
} }
.record-line-view { .record-line-view {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment