no message
This commit is contained in:
@@ -21,25 +21,25 @@
|
||||
<view class="filter_item">
|
||||
<view class="filter_label">上轴左</view>
|
||||
<view class="filter_input_wraper">
|
||||
<uni-data-select v-model="upL" :localdata="axis"></uni-data-select>
|
||||
<uni-data-select v-model="upL" :searchInput="true" :localdata="newaxis1" @handleChange="handleChange1" @showSelector="showSelector1"></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
<view class="filter_item">
|
||||
<view class="filter_label">上轴右</view>
|
||||
<view class="filter_input_wraper">
|
||||
<uni-data-select v-model="upR" :localdata="axis"></uni-data-select>
|
||||
<uni-data-select v-model="upR" :searchInput="true" :localdata="newaxis2" @handleChange="handleChange2" @showSelector="showSelector2"></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
<view class="filter_item">
|
||||
<view class="filter_label">下轴左</view>
|
||||
<view class="filter_input_wraper">
|
||||
<uni-data-select v-model="lowL" :localdata="axis"></uni-data-select>
|
||||
<uni-data-select v-model="lowL" :searchInput="true" :localdata="newaxis3" @handleChange="handleChange3" @showSelector="showSelector3"></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
<view class="filter_item">
|
||||
<view class="filter_label">下轴右</view>
|
||||
<view class="filter_input_wraper">
|
||||
<uni-data-select v-model="lowR" :localdata="axis"></uni-data-select>
|
||||
<uni-data-select v-model="lowR" :searchInput="true" :localdata="newaxis4" @handleChange="handleChange4" @showSelector="showSelector4"></uni-data-select>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -69,6 +69,10 @@
|
||||
options2: [],
|
||||
index2: '',
|
||||
axis: [],
|
||||
newaxis1: [],
|
||||
newaxis2: [],
|
||||
newaxis3: [],
|
||||
newaxis4: [],
|
||||
upL: '',
|
||||
upR: '',
|
||||
lowL: '',
|
||||
@@ -157,6 +161,60 @@
|
||||
} catch (e) {
|
||||
this.disabled = false
|
||||
}
|
||||
},
|
||||
/** 模糊匹配 */
|
||||
selectMatchItem (lists, keyWord) {
|
||||
let resArr = []
|
||||
lists.filter((item) => {
|
||||
if (item.text.indexOf(keyWord) > -1) {
|
||||
resArr.push(item)
|
||||
}
|
||||
})
|
||||
return resArr
|
||||
},
|
||||
handleChange1 (e) {
|
||||
if (e){
|
||||
this.upL = ''
|
||||
this.newaxis1 = this.selectMatchItem(this.axis, e)
|
||||
} else {
|
||||
this.newaxis1 = this.axis
|
||||
}
|
||||
},
|
||||
showSelector1 () {
|
||||
this.newaxis1 = this.axis
|
||||
},
|
||||
handleChange2 (e) {
|
||||
if (e){
|
||||
this.upR = ''
|
||||
this.newaxis2 = this.selectMatchItem(this.axis, e)
|
||||
} else {
|
||||
this.newaxis2 = this.axis
|
||||
}
|
||||
},
|
||||
showSelector2 () {
|
||||
this.newaxis2 = this.axis
|
||||
},
|
||||
handleChange3 (e) {
|
||||
if (e){
|
||||
this.lowL = ''
|
||||
this.newaxis3 = this.selectMatchItem(this.axis, e)
|
||||
} else {
|
||||
this.newaxis3 = this.axis
|
||||
}
|
||||
},
|
||||
showSelector3 () {
|
||||
this.newaxis3 = this.axis
|
||||
},
|
||||
handleChange4 (e) {
|
||||
if (e){
|
||||
this.lowR = ''
|
||||
this.newaxis4 = this.selectMatchItem(this.axis, e)
|
||||
} else {
|
||||
this.newaxis4 = this.axis
|
||||
}
|
||||
},
|
||||
showSelector4 () {
|
||||
this.newaxis4 = this.axis
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user