|
@@ -223,7 +223,7 @@
|
|
|
<div class="right">
|
|
|
<ul class="item">
|
|
|
<li><span>载体名称:</span><span>{{item.carrierName?item.carrierName:'-'}}</span></li>
|
|
|
- <li><span>可用情况:</span><span>{{item.state==1?"可用":"不可用"}}</span></li>
|
|
|
+ <li><span>可用情况:</span><span>{{item.situationState=='1'?"可用":"不可用"}}</span></li>
|
|
|
<li><span>产业板块:</span><span>{{item.productModule?item.productModule:'- '}}</span></li>
|
|
|
<li><span>所属园区:</span><span>{{item.parkData?item.parkData.title:''}}</span></li>
|
|
|
<li><span>联系地址:</span><span>{{item.addr?item.addr:'-'}}</span></li>
|
|
@@ -267,17 +267,17 @@
|
|
|
window.history.go(-1);
|
|
|
sessionStorage.setItem('znxztabs', JSON.stringify({}));
|
|
|
sessionStorage.setItem('znxz', '');
|
|
|
- },
|
|
|
- getParkData(id) {
|
|
|
- // let that = this;
|
|
|
- // $.ajax({
|
|
|
- // url: conpath + "/selectionAddr/listAll/" + id,
|
|
|
- // type: "get",
|
|
|
- // dataType: "json",
|
|
|
- // success: function (data) {
|
|
|
- // that.contentList = data.data;
|
|
|
- // }
|
|
|
- // })
|
|
|
+ },
|
|
|
+ compare(property) {
|
|
|
+ return function (a, b) {
|
|
|
+ if (a[property] < b[property]) {
|
|
|
+ return 1;
|
|
|
+ }
|
|
|
+ if (a[property] > b[property]) {
|
|
|
+ return -1;
|
|
|
+ }
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
},
|
|
|
getListData(json) {
|
|
|
let that = this;
|
|
@@ -289,8 +289,8 @@
|
|
|
dataType: "json",
|
|
|
success: function (data) {
|
|
|
let dataList = data.list;
|
|
|
- that.contentList = data.list;
|
|
|
-
|
|
|
+ that.contentList= dataList.sort((a, b) => { return b.recommend - a.recommend });
|
|
|
+
|
|
|
dataList.forEach(function (d) {
|
|
|
// 添加选择地址
|
|
|
if (!d.point) return;
|
|
@@ -328,11 +328,10 @@
|
|
|
mounted() {
|
|
|
const url = new URL(window.location.href);
|
|
|
const id = url.searchParams.get('id');
|
|
|
- this.getParkData(id);
|
|
|
// 检索数据
|
|
|
const retrievedUser = sessionStorage.getItem('znxz');
|
|
|
const znxztabs = sessionStorage.getItem('znxztabs');
|
|
|
-
|
|
|
+
|
|
|
// 将字符串转换回JSON对象
|
|
|
if (retrievedUser) {
|
|
|
const userObject = JSON.parse(retrievedUser);
|