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();
},
}
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· 单线程的Redis速度为什么快?
· SQL Server 2025 AI相关能力初探
· AI编程工具终极对决:字节Trae VS Cursor,谁才是开发者新宠?
· 展开说说关于C#中ORM框架的用法!