Commit 386603bd authored by 黄奎's avatar 黄奎

页面修改

parent c0b47847
...@@ -3,17 +3,14 @@ ...@@ -3,17 +3,14 @@
<div class="page-search row items-center"> <div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md"> <div class="col row wrap q-mr-lg q-col-gutter-md">
<div class="col-3"> <div class="col-3">
<q-input ref="filter" filled v-model="keyWords" label="系列名称"> <q-input @input="resetSearch" clearable standout="bg-primary text-white" v-model="msg.CateName" label="系列名称"
<template v-slot:append> @clear="resetSearch" maxlength="20" />
<q-icon v-if="keyWords !== ''" name="clear" class="cursor-pointer" @click="resetFilter" />
</template>
</q-input>
</div> </div>
</div> </div>
</div> </div>
<div class="page-content"> <div class="page-content">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-column-table" separator="none" :data="dataList" <q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat class="sticky-column-table"
:columns="columns" > separator="none" :data="dataList" :columns="columns">
<template v-slot:top="props"> <template v-slot:top="props">
<div class="col-2 q-table__title">系列信息</div> <div class="col-2 q-table__title">系列信息</div>
<q-space /> <q-space />
...@@ -65,6 +62,7 @@ ...@@ -65,6 +62,7 @@
PageSize: 10, PageSize: 10,
rowsPerPage: 10, rowsPerPage: 10,
PageCount: 1, PageCount: 1,
CateName: "", //系列名称
}, },
currentUrl: "", currentUrl: "",
dataList: [], dataList: [],
...@@ -115,12 +113,17 @@ ...@@ -115,12 +113,17 @@
mounted() { mounted() {
this.currentUrl = this.$route.path this.currentUrl = this.$route.path
this.getcoursecategorytree() this.getcategorypage()
}, },
methods: { methods: {
//重新查询
resetSearch() {
this.msg.PageIndex = 1;
this.getcategorypage();
},
changePage(val) { changePage(val) {
this.msg.PageIndex = val; this.msg.PageIndex = val;
this.getcoursecategorytree() this.getcategorypage()
}, },
//删除系列 //删除系列
deleteCategory(item) { deleteCategory(item) {
...@@ -151,21 +154,12 @@ ...@@ -151,21 +154,12 @@
}); });
}, },
//搜索分类
myFilterMethod(node, filter) {
return node.CateName && node.CateName.indexOf(filter) > -1;
},
//重置搜索关键词
resetFilter() {
this.keyWords = ''
this.$refs.filter.focus()
},
//刷新页面 //刷新页面
refreshPage() { refreshPage() {
this.getcoursecategorytree(); this.getcategorypage();
}, },
//获取课程分类树形结构 //获取课程系列分页列表
getcoursecategorytree() { getcategorypage() {
this.isShow = false; this.isShow = false;
queryCourseCategoryPage(this.msg).then(res => { queryCourseCategoryPage(this.msg).then(res => {
this.isShow = true; this.isShow = true;
...@@ -174,7 +168,7 @@ ...@@ -174,7 +168,7 @@
this.msg.PageCount = res.Data.PageCount this.msg.PageCount = res.Data.PageCount
}) })
}, },
//新增修改角色 //新增修改课程系列
EditCategory(obj) { EditCategory(obj) {
if (obj) { if (obj) {
this.categoryObj = obj this.categoryObj = obj
......
...@@ -3,11 +3,8 @@ ...@@ -3,11 +3,8 @@
<div class="page-search row items-center"> <div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md"> <div class="col row wrap q-mr-lg q-col-gutter-md">
<div class="col-3"> <div class="col-3">
<q-input ref="filter" filled v-model="msg.Name" label="供应商名称"> <q-input @input="resetSearch" clearable standout="bg-primary text-white" v-model="msg.Name" label="供应商名称"
<template v-slot:append> @clear="resetSearch" maxlength="20" />
<q-icon v-if="msg.Name !== ''" name="clear" class="cursor-pointer" @click="resetFilter" />
</template>
</q-input>
</div> </div>
</div> </div>
</div> </div>
...@@ -123,6 +120,11 @@ ...@@ -123,6 +120,11 @@
this.getsupplierpage() this.getsupplierpage()
}, },
methods: { methods: {
//重新查询
resetSearch() {
this.msg.pageIndex = 1;
this.getsupplierpage();
},
changePage(val) { changePage(val) {
this.msg.pageIndex = val; this.msg.pageIndex = val;
this.getsupplierpage() this.getsupplierpage()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment