我也出现了这个问题,在同时用到picker-view和enablePullDownRefresh时,往下滑动的操作时很难触发picker-view,或者2个都被触发。 我用的是官方的demo [代码]<[代码][代码]view[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]view[代码] [代码]style[代码][代码]=[代码][代码]"width:100%;height:100vh;background:#333;color:#fff;"[代码] [代码]catchtouchmove[代码][代码]=[代码][代码]'preventTouchMove'[代码][代码]>{{year}}年{{month}}月{{day}}日</[代码][代码]view[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]picker-view[代码] [代码]indicator-style[代码][代码]=[代码][代码]"height: 50px;"[代码] [代码]style[代码][代码]=[代码][代码]"width: 100%; height: 300px;position:fixed;bottom:0;left:0;background:#fff;"[代码] [代码]value[代码][代码]=[代码][代码]"{{value}}"[代码] [代码]bindchange[代码][代码]=[代码][代码]"bindChange"[代码] [代码]catchtouchmove[代码][代码]=[代码][代码]'preventTouchMove'[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]view[代码] [代码]wx:for[代码][代码]=[代码][代码]"{{years}}"[代码] [代码]style[代码][代码]=[代码][代码]"line-height: 50px"[代码][代码]>{{item}}年</[代码][代码]view[代码][代码]>[代码][代码] [代码][代码]</[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]view[代码] [代码]wx:for[代码][代码]=[代码][代码]"{{months}}"[代码] [代码]style[代码][代码]=[代码][代码]"line-height: 50px"[代码][代码]>{{item}}月</[代码][代码]view[代码][代码]>[代码][代码] [代码][代码]</[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]<[代码][代码]view[代码] [代码]wx:for[代码][代码]=[代码][代码]"{{days}}"[代码] [代码]style[代码][代码]=[代码][代码]"line-height: 50px"[代码][代码]>{{item}}日</[代码][代码]view[代码][代码]>[代码][代码] [代码][代码]</[代码][代码]picker-view-column[代码][代码]>[代码][代码] [代码][代码]</[代码][代码]picker-view[代码][代码]>[代码][代码]</[代码][代码]view[代码][代码]>[代码][代码]const date = [代码][代码]new[代码] [代码]Date()[代码][代码]const years = [][代码][代码]const months = [][代码][代码]const days = [][代码] [代码]for[代码] [代码](let i = 1990; i <= date.getFullYear(); i++) {[代码][代码] [代码][代码]years.push(i)[代码][代码]}[代码] [代码]for[代码] [代码](let i = 1; i <= 12; i++) {[代码][代码] [代码][代码]months.push(i)[代码][代码]}[代码] [代码]for[代码] [代码](let i = 1; i <= 31; i++) {[代码][代码] [代码][代码]days.push(i)[代码][代码]}[代码] [代码]Page({[代码][代码] [代码][代码]data: {[代码][代码] [代码][代码]years: years,[代码][代码] [代码][代码]year: date.getFullYear(),[代码][代码] [代码][代码]months: months,[代码][代码] [代码][代码]month: 2,[代码][代码] [代码][代码]days: days,[代码][代码] [代码][代码]day: 2,[代码][代码] [代码][代码]value: [9999, 1, 1],[代码][代码] [代码][代码]},[代码][代码] [代码][代码]bindChange: [代码][代码]function[代码] [代码](e) {[代码][代码] [代码][代码]const val = e.detail.value[代码][代码] [代码][代码]this[代码][代码].setData({[代码][代码] [代码][代码]year: [代码][代码]this[代码][代码].data.years[val[0]],[代码][代码] [代码][代码]month: [代码][代码]this[代码][代码].data.months[val[1]],[代码][代码] [代码][代码]day: [代码][代码]this[代码][代码].data.days[val[2]][代码][代码] [代码][代码]})[代码][代码] [代码][代码]},[代码][代码] [代码][代码]preventTouchMove(e){}[代码][代码]})[代码][代码]{[代码][代码] [代码][代码]"enablePullDownRefresh"[代码][代码]: [代码][代码]true[代码][代码]}[代码]
pick-view 上划bug使用 picker-view picker-view-column 做省市区级联,只能向下滑动(滚动), 向上滑动(滚动)就会触发 enablePullDownRefresh 我 enablePullDownRefresh 设置是需要一些刷新 我以前不知道是自己没测出来还是就有这个问题
2018-09-29