|
@@ -9,7 +9,6 @@ import {
|
|
|
industryObject,
|
|
|
getIndustryCategory
|
|
|
} from './DicIndustryList';
|
|
|
-
|
|
|
(function(){
|
|
|
$("#demandList_patent").on('click', 'li', function () {
|
|
|
var theId = $(this).attr('val');
|
|
@@ -19,16 +18,14 @@ import {
|
|
|
var theKeyword,Province;
|
|
|
var thePageNo = 1,
|
|
|
thePageLength = 1,
|
|
|
- pageSize = 6;
|
|
|
- $("#demandList_patent").on('click', 'li', function () {
|
|
|
- var theId = $(this).attr('value');
|
|
|
- window.open(globalConfig.context + '/portal/financial/investmentDetail.html?organizationId=' + theId );
|
|
|
- });
|
|
|
+ pageSize = 6;
|
|
|
//用JS导入行业下拉列表的数据
|
|
|
var list_html="";
|
|
|
for(var i=0;i<industryObject.length;i++){
|
|
|
list_html+="<p value='"+industryObject[i].value+"'>"+industryObject[i].label+"</li>";
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
$(".list_city").html(list_html);
|
|
|
//行业下拉选择
|
|
|
$('.list_city').hide();
|
|
@@ -40,9 +37,6 @@ import {
|
|
|
$('.list_city').hide();
|
|
|
});
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
//点击下拉框中的p
|
|
|
$('.list_city p').click(function() {
|
|
|
$(".allproduct_top form input").val("");
|
|
@@ -70,11 +64,12 @@ import {
|
|
|
pageSize:8
|
|
|
},
|
|
|
success: function (data) {
|
|
|
+
|
|
|
if(data.data.totalCount==0){
|
|
|
$(".pagination_box").css("display","none");
|
|
|
$("#demandList_patent").html("<div class='list_none'></div>");
|
|
|
}else{
|
|
|
- manage(data.data,ptxt);
|
|
|
+ manage(data.data,ptxt);
|
|
|
page_ol(data.data.totalCount);
|
|
|
$(".pageNext").attr("all_length",Math.ceil(data.data.totalCount/8));
|
|
|
}
|
|
@@ -120,8 +115,8 @@ import {
|
|
|
|
|
|
function manage(data,ptxt){
|
|
|
var demand_html="";
|
|
|
- for(var i=0;i<data.list.length;i++){
|
|
|
- var hangye=$(".place_city .thon").html();
|
|
|
+ for(var i=0;i<data.list.length;i++){
|
|
|
+ var hangye=data.list[i].fieldAs;
|
|
|
var price=data.list[i].transferPrice?data.list[i].transferPrice:"面议";
|
|
|
var people=data.list[i].ownerName?data.list[i].ownerName:"保密";
|
|
|
var sketch=data.list[i].sketch?data.list[i].sketch.substring(0,18):"暂无简介";
|
|
@@ -157,8 +152,8 @@ import {
|
|
|
}
|
|
|
function manage_search(data,ptxt){
|
|
|
var demand_html="";
|
|
|
- for(var i=0;i<data.list.length;i++){
|
|
|
- var hangye=$(".place_city .thon").html();
|
|
|
+ for(var i=0;i<data.list.length;i++){
|
|
|
+ var hangye=data.list[i].fieldAs;
|
|
|
var price=data.list[i].transferPrice?data.list[i].transferPrice:"面议";
|
|
|
var people=data.list[i].ownerName?data.list[i].ownerName:"保密";
|
|
|
var sketch=data.list[i].sketch?data.list[i].sketch.substring(0,18):"暂无简介";
|
|
@@ -257,8 +252,8 @@ import {
|
|
|
loadDate_search(thePageNo);
|
|
|
}
|
|
|
} else if (this.className === 'pageNext') {
|
|
|
- thePageLength=$(".pageNext").attr("all_length");
|
|
|
- if (thePageNo < thePageLength) {
|
|
|
+ thePageLength=$(".pageNext").attr("all_length");
|
|
|
+ if (parseInt(thePageNo) <parseInt(thePageLength)) {
|
|
|
thePageNo = thePageLength;
|
|
|
loadDate_search(thePageNo);
|
|
|
}
|
|
@@ -271,17 +266,19 @@ import {
|
|
|
loadDate_search(thePageNo);
|
|
|
}
|
|
|
}
|
|
|
- }else{
|
|
|
+ }else{
|
|
|
if (this.className === 'pagePre') {
|
|
|
if (thePageNo > 1) {
|
|
|
thePageNo = 1;
|
|
|
loadDate(thePageNo);
|
|
|
}
|
|
|
- } else if (this.className === 'pageNext') {
|
|
|
- thePageLength=$(".pageNext").attr("all_length");
|
|
|
- if (thePageNo < thePageLength) {
|
|
|
- thePageNo = thePageLength;
|
|
|
+ } else if (this.className === 'pageNext') {
|
|
|
+ thePageLength=$(".pageNext").attr("all_length");
|
|
|
+ if (parseInt(thePageNo) <parseInt(thePageLength)) {
|
|
|
+ thePageNo = thePageLength;
|
|
|
loadDate(thePageNo);
|
|
|
+ }else{
|
|
|
+
|
|
|
}
|
|
|
} else {
|
|
|
var nextPageNo = $(this).children()[0].text;
|
|
@@ -297,6 +294,9 @@ import {
|
|
|
//右侧内容的分页功能,点击一次发送一个ajax的请求,只请求6组数据
|
|
|
function loadDate(pageNo) {
|
|
|
var left_val=$(".place_city .thon").attr("value");
|
|
|
+ if(left_val=='null'){
|
|
|
+ left_val=''
|
|
|
+ };
|
|
|
$.ajax({
|
|
|
method: "get",
|
|
|
dataType: "json",
|