diff --git a/fangija-zsyf/views/house/houseList.html b/fangija-zsyf/views/house/houseList.html index 9dc2545..b312ab5 100644 --- a/fangija-zsyf/views/house/houseList.html +++ b/fangija-zsyf/views/house/houseList.html @@ -169,7 +169,7 @@ $(document).on('infinite', '.infinite-scroll-bottom', function() { }, 1000); }); -//我的收藏查询请求 +//我的房产查询请求 function selectHouseInfoList(){ axios.get(BASE_PATH + "/rest/index/ourHouseInfoList", { @@ -353,29 +353,63 @@ function addItems(itemsPerLoad, lastIndex, dataObj, xqOneMonthUpDownRangeMap, xq html += "
抵押可贷额度: "+tempTotalPricePercent+"
"; + //调整最新的等级显示(其它等级不显示start) if(result.level!=null && result.level == 1){ - html += "豪宅级"; + //html += "豪宅级"; + html += '房屋评级'; }else if(result.level!=null && result.level == 2){ - html += "公寓级"; + //html += "公寓级"; + html += '房屋评级'; }else if(result.level!=null && result.level == 3){ - html += "平房级"; + //html += "平房级"; + html += '房屋评级'; }else if(result.level!=null && result.level == 4){ - html += "草屋级"; + //html += "草屋级"; + html += '房屋评级'; }else if(result.level!=null && result.level == 5){ - html += "山洞级"; + //html += "山洞级"; + html += '房屋评级'; }else{ - html += "其它"; + //html += "其它"; } + //控制贷款按钮是否可以显示,便于ios版本审核 if(localStorage.getItem("showLoanMenu")!=null && localStorage.getItem("showLoanMenu")=="true"){ - html += '立即申请'; - }else{ - html += ''; + html += '立即申请'; } + html += ""; } $('.infinite-scroll-bottom .list-container').append(html); } +//删除房产AJAX请求 +$(document).on("click",".confirm-ok", function () { + //获取删除的房产id + var id = $(this).attr("id"); + $.confirm("确定删除?", function () { + axios.post(BASE_PATH + "/rest/index/deleteHouseInfoByStatus", + { + id: id + }).then(function (response) { + var status = response.data.status; + if(status){ + $.toast(response.data.data); + checkIsLogin(); + //删除房产会影响个人中心房产列表, 刷新 + if(plus.webview.getWebviewById('views/user/userInfo.html')!= null){ + plus.webview.getWebviewById('views/user/userInfo.html').reload(); + } + //plus.webview.getWebviewById('yfindex.html').reload(); + }else{ + $.toast(response.data.message); + } + }).catch(function (error) { + console.log(error); + }); + }); + $(".modal-text").css("text-align","center"); +}); + /* 说明-房产等级 */ $(document).on('click','.alert-text-title', function () { $.alert('房产等级是房屋在城市中的综合评级,由高至低分别为 豪宅、公寓、平房、草屋、山洞共5个级别。', '房产等级');