diff --git a/pages/ProductManage/EmptyPipeInStore.vue b/pages/ProductManage/EmptyPipeInStore.vue
index 581b783..63ece4f 100644
--- a/pages/ProductManage/EmptyPipeInStore.vue
+++ b/pages/ProductManage/EmptyPipeInStore.vue
@@ -18,7 +18,7 @@
物料
-
+
@@ -30,7 +30,7 @@
-
+
@@ -54,7 +54,9 @@
options3: [],
index3: '',
qty: '',
- disabled: false
+ disabled: false,
+ val1: '',
+ newoptions3: []
};
},
created () {
@@ -75,6 +77,27 @@
selectChange3(e) {
this.index3 = e
},
+ /** 模糊匹配 */
+ selectMatchItem (lists, keyWord) {
+ let resArr = []
+ lists.filter((item) => {
+ if (item.text.indexOf(keyWord) > -1) {
+ resArr.push(item)
+ }
+ })
+ return resArr
+ },
+ handleChange (e) {
+ if (e){
+ this.index3 = ''
+ this.newoptions3 = this.selectMatchItem(this.options3, e)
+ } else {
+ this.newoptions3 = this.options3
+ }
+ },
+ showSelector () {
+ this.newoptions3 = this.options3
+ },
/** 生产区域下拉框查询 */
async _queryProductArea () {
let res = await queryProductArea()
@@ -89,6 +112,7 @@
async _queryPaperMaterial (code) {
let res = await queryPaperMaterial(code)
this.options3 = [...res.rows]
+ this.newoptions3 = [...res.rows]
res.rows.map(el => {
if (el.value === code) {
this.index3 = res.material_code
@@ -127,14 +151,6 @@
this.disabled = false
return
}
- if (!this.qty) {
- uni.showToast({
- title: '数量不能为空',
- icon: 'none'
- })
- this.disabled = false
- return
- }
try {
let res = await emptyConfirm(this.qty, this.index3, this.index2, '1')
this.disabled = false
diff --git a/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue b/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue
index 85877ca..82241c3 100644
--- a/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue
+++ b/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue
@@ -12,7 +12,8 @@
-
+
+
{{emptyTips}}
@@ -60,6 +61,14 @@
default () {
return []
}
+ },
+ searchInput: {
+ type: Boolean,
+ default: false
+ },
+ svalue: {
+ type: [String, Number],
+ default: ''
},
value: {
type: [String, Number],
@@ -138,7 +147,11 @@
}
}
},
- methods: {
+ methods: {
+ handleInput($event) {
+ this.$emit('input', $event.target.value)
+ this.$emit('handleChange', $event.target.value)
+ },
initDefVal() {
let defValue = ''
if ((this.value || this.value === 0) && !this.isDisabled(this.value)) {
@@ -181,7 +194,7 @@
return isDisabled;
},
- clearVal() {
+ clearVal() {
this.emit('')
if (this.collection) {
uni.removeStorageSync(this.last)
@@ -423,5 +436,9 @@
bottom: 0;
right: 0;
left: 0;
+ }
+ .filter_input_s {
+ width: calc(100% - 30rpx);
+ margin: 0 20rpx 0 10rpx;
}