diff --git a/static/js/lib/paging/page_common.js b/static/js/lib/paging/page_common.js index ed3990d..07c674a 100644 --- a/static/js/lib/paging/page_common.js +++ b/static/js/lib/paging/page_common.js @@ -29,6 +29,9 @@ function createPage(el) { // 设置分页 function setPage(dom, pageData) { var pageData=pageData; + + $(dom.el).off('click'); + if(pageData==undefined){ pageData={}; } @@ -163,6 +166,7 @@ function setPage(dom, pageData) { }) // 下一页事件 + console.log(dom.el) $(dom.el).on('click','a.next_btn',function(){ console.log(Current) console.log(btnSum) diff --git a/static/js/project/bidding/biddingList.js b/static/js/project/bidding/biddingList.js index 77b222f..1bd688f 100644 --- a/static/js/project/bidding/biddingList.js +++ b/static/js/project/bidding/biddingList.js @@ -255,6 +255,7 @@ define(['jquery', "template", "Tools", "biddingApi", "itemsApi", "paging",'dateT turnThePage = function (pageNum) { module.data.form.pageNum = pageNum ; + module.data.pageNum = pageNum ; tools.doGet(biddingList, module.data.form, module.biddingList,true); } @@ -310,6 +311,7 @@ define(['jquery', "template", "Tools", "biddingApi", "itemsApi", "paging",'dateT // module.data.form.biddingStartTime= $('#auctionStartTimeStr').val(); // module.data.form.biddingStopTime= $('#endTimeStr').val(); module.data.form.pageNum= '1'; + module.data.pageNum= '1'; module.data.form.pageSize= module.data.pageSize; if (module.data.form.signupStartTime){ diff --git a/static/js/project/listingItems/itemsList.js b/static/js/project/listingItems/itemsList.js index d457ba3..124135b 100644 --- a/static/js/project/listingItems/itemsList.js +++ b/static/js/project/listingItems/itemsList.js @@ -196,7 +196,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper if (pageCount < 1) { pageCount = 1; } - if (module.data.itemsInformationList == '') { + if (module.data.itemsInformationList == ''&&content.length>0) { // 初始化 分页器 var page_s1 = createPage('.page_s1'); // 设置分页 @@ -211,11 +211,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper module.data.pageCount = pageCount; module.data.itemsInformationList = content; var ItemsInformationData = template('ItemsInformationData', module.data); - - $("#ItemsInformationContent").html(ItemsInformationData); - - } } @@ -227,7 +223,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper if (pageCount < 1) { pageCount = 1; } - if (module.data.itemsInformationList1 == '') { + if (module.data.itemsInformationList1 == ''&&content.length>0) { // 初始化 分页器 var page_s1 = createPage('.page_s1'); // 设置分页 @@ -290,6 +286,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper console.log(deptId) $('#locInfoall').attr("class", "auction_hall_table_tab auction_loc"); $("#deptLocationContent div").attr("class", "auction_hall_table_tab auction_loc"); + $("#xqxmSearch").attr("class", "input_data_btn"); if (deptId == '') { $('#locInfoall').addClass('auction_hall_table_tab_select'); document.getElementById('secondDept').style.display = 'none'; @@ -338,7 +335,13 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper turnThePage = function (pageNum) { module.data.pageNum = pageNum; module.data.form.pageNum = pageNum; - tools.doGet(itemsList, module.data.form, module.itemList, true); + let type = module.data.searchType; + + if (type == 'gyxm'){ + tools.doGet(itemsList, module.data.form, module.itemList, true); + }else{ + tools.doGet(needProjectList, {deptId:module.data.deptId,projectNumber:module.data.projectNumber,pageSize:module.data.pageSize,pageNum:'1'}, module.itemLists, true); + } } typeCheck = function (id, projectNumber) { @@ -407,7 +410,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper module.data.form.biddingStopTime = $('#endTimeStr').val(); } - module.data.form.pageNum = module.data.pageNum; + module.data.form.pageNum = '1'; module.data.form.pageSize = module.data.pageSize; console.log(module.data.form) @@ -415,7 +418,7 @@ define(['jquery', "template", "Tools", "itemsApi", "paging", 'dateTime', 'swiper if (module.data.searchType == 'gyxm'){ tools.doGet(itemsList, module.data.form, module.itemList, true); }else{ - tools.doGet(needProjectList, {projectNumber:module.data.projectNumber,pageSize:module.data.pageSize,pageNum:'1'}, module.itemLists, true); + tools.doGet(needProjectList, {deptId:module.data.deptId,projectNumber:module.data.projectNumber,pageSize:module.data.pageSize,pageNum:'1'}, module.itemLists, true); } }