var qs = parseQueryString(location.href),id,source; $().ready(function(){ if(qs.id){id = qs.id} if(qs.source){source = qs.source} getProductListByCatId(); }) function getProductListByCatId () { $(".loading").show(); $.ajax({ url:'/user/product/getProductListByCatId', type:'post', dataType:'json', data:{ id:id, source:source }, success:function (res) { $(".loading").hide(); if(res&&res.errno == 0){ var listHtml = '',status = ''; res.rst.data.forEach(function (item,index) { if(item.prod_title){ status = '
' + item.name + '
' + status + '' + item.description + '
额度(元)
' + item.upper_amount + '-' + item.lower_amount + '期限
' + item.term + '' + item.applicants_ch + '人申请成功