vue 搜索框

//按时间查询数据 
<el-form class="line" inline @submit.native.prevent="GEOMNum()">
                  <el-form-item>
                    <el-date-picker
                      value-format="yyyy-MM-dd"
                      type="date"
                      v-model="creTime"
                      :placeholder="this.LANG.test1.desc49"
                    ></el-date-picker>
                    <el-button
                      class="button"
                      @click="GEOMNum()"
                      type="primary"
                      >{{ LANG.test1.desc48 }}</el-button
                    >
                  </el-form-item>
                </el-form>
//按账号查询数据 
<el-input :placeholder="this.LANG.test1.desc50" v-model="address"  clearable  @clear="resetGoods">
</el-input>
<el-button @click="GEOMNum()" type="primary">{{ LANG.test1.desc48}}</el-button>
 methods: {
    GEOMNum: function (index) {
      this.$axios
        .get("bk", {
          params: {
            currentPage: this.currentPage,
            creTime: this.creTime,
            address: this.address,
            pageSize: this.pageSize,
          },
        })
        .then((res) => {
          console.log(res);
          if (res.code == 0) {
            this.dataList = res.data.dataList;
            this.totalPage = res.data.totalPage;
            this.currentPage = res.data.currentPage;
            this.pageSize = res.data.pageSize;
            this.total = res.data.total;
            console.log(this.totalPage);
            console.log(this.currentPage);
            console.log(this.pageSize);
            console.log(this.total);
          }
        });
    },
    time() {
      this.GEOMNum();
    },
    // 重置搜索框
    resetGoods() {
      this.address = "";
      this.GEOMNum();
    },
    // 点击搜索按钮
    searchGoodsResult() {
      this.GEOMNum();
    },
}
posted @   koo-  阅读(438)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· 单线程的Redis速度为什么快?
· SQL Server 2025 AI相关能力初探
· AI编程工具终极对决:字节Trae VS Cursor,谁才是开发者新宠?
· 展开说说关于C#中ORM框架的用法!
点击右上角即可分享
微信分享提示