兼容安卓和ios,type需要改为search,需要form嵌套,这样可以保证ios的回车显示搜索。

<form @submit.prevent="formSubmit" action="javascript:return true">
          <input
            class="mbSearchInput submitInput"
            placeholder="请输入任务ID号或任务名称"
            @keydown="testDataSearchKeyDown"
            type="search"
            v-model="TaskName" />
        </form>
formSubmit() {
      return false;
    },
    testDataSearchKeyDown(e){
      console.log(e.keyCode)
      if(e.keyCode == '13') {
        this.testDataSearchClick();
      }
  },