Commit 4882a474 authored by qinj's avatar qinj

企查查分页查询

parent 19cea903
...@@ -325,10 +325,10 @@ ...@@ -325,10 +325,10 @@
label="社会统一信用代码"> label="社会统一信用代码">
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination v-show="page.TotalRecords>0" <pagination v-show="TotalRecords>0"
:total="page.TotalRecords" :total="TotalRecords"
:page.sync="page.CurrentPage" :page.sync="page.currentPage"
:limit.sync="page.PageSize" :limit.sync="page.pageSize"
@pagination="getList" /> @pagination="getList" />
</el-dialog> </el-dialog>
...@@ -379,10 +379,8 @@ export default { ...@@ -379,10 +379,8 @@ export default {
dialogTableVisible: false, dialogTableVisible: false,
TotalRecords: 0, TotalRecords: 0,
page: { page: {
TotalRecords: 0, pageSize: 10,
PageIndex: 0, currentPage:1
PageSize: 10,
CurrentPage:1
} }
} }
...@@ -400,12 +398,15 @@ export default { ...@@ -400,12 +398,15 @@ export default {
}, },
methods: { methods: {
getList() { getList() {
this.page.TotalRecords=null
this.page.searchKey = this.formInline.Name this.page.searchKey = this.formInline.Name
delete this.page.TotalRecords
this.page.pageIndex=0
this.$request(Qcc.searchUrl, this.page).then((resp) => { this.$request(Qcc.searchUrl, this.page).then((resp) => {
if (resp.results.Result) { if (resp.results.Result) {
this.tableData = resp.results.Result this.tableData = resp.results.Result
this.page = resp.results.Paging this.page = resp.results.Paging
this.page.currentPage=this.page.PageIndex
this.TotalRecords=this.page.TotalRecords
} else { } else {
this.$message.warning('无相关公司!') this.$message.warning('无相关公司!')
} }
......
...@@ -489,8 +489,8 @@ export default { ...@@ -489,8 +489,8 @@ export default {
dialogTableVisible: false, dialogTableVisible: false,
TotalRecords: 0, TotalRecords: 0,
page: { page: {
currentPage: 0, pageSize: 10,
pageSize: 0 currentPage:1
} }
} }
...@@ -513,11 +513,14 @@ export default { ...@@ -513,11 +513,14 @@ export default {
getList() { getList() {
this.page.searchKey = this.formInline.Name this.page.searchKey = this.formInline.Name
delete this.page.TotalRecords
this.page.pageIndex=0
this.$request(Qcc.searchUrl, this.page).then((resp) => { this.$request(Qcc.searchUrl, this.page).then((resp) => {
if(resp.results.Result){ if(resp.results.Result){
this.tableData = resp.results.Result this.tableData = resp.results.Result
this.page = resp.results.Paging this.page = resp.results.Paging
this.TotalRecords = resp.results.Paging.TotalRecords this.page.currentPage=this.page.PageIndex
this.TotalRecords=this.page.TotalRecords
}else{ }else{
this.$message.warning('无相关公司!') this.$message.warning('无相关公司!')
} }
......
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