js
bindKeyInput(e){
console.log(e)
this.setData({
[`${e.currentTarget.dataset.params}`]:e.detail.value
})
console.log(`商品名称:${this.data.goodsName}`)
}
html
<view class='flex1 flex-row'>
<view class='s_width1 colorTitle'>商品名称</view>
<input type='text' class='flex1' value='{{goodsName}}' data-params='goodsName' />
</view>