Commit cc0f0ed1 by fengweida

修复bug

1 parent 055bd749
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control" v-model="searchText" placeholder="输入搜索内容"> <input type="text" class="form-control" v-model="searchText" placeholder="输入搜索内容">
<span class="input-group-btn"> <span class="input-group-btn">
<button class="btn btn-danger" type="button" @click="cleanSearchText">搜索内容</button> <button class="btn btn-danger" type="button" @click="cleanSearchText">搜索内容</button>
</span> </span>
</div> </div>
</div> </div>
...@@ -90,6 +90,9 @@ ...@@ -90,6 +90,9 @@
let serviceList = []; let serviceList = [];
for (let i = 0; i < valArr.length; i++) { for (let i = 0; i < valArr.length; i++) {
let val = valArr[i]; let val = valArr[i];
if (val.trim() == ''){
continue;
}
this.allServiceList.forEach((item) => { this.allServiceList.forEach((item) => {
console.log(item) console.log(item)
if (item.serviceName.indexOf(val) != -1) { if (item.serviceName.indexOf(val) != -1) {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!