This commit is contained in:
zongzhimin
2018-04-14 11:43:10 +08:00
parent 37367c7785
commit 3eda178c36
3 changed files with 29 additions and 5 deletions
@@ -49,11 +49,20 @@ Vue.component('city_increase_ranking',{
},
follow:function(city,event){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
alert("请先登录")
clicked('/views/user/passLogin.html',true,false,{},{},function(){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
}else{
axios.get("/rest/quotations/collectCity",{params:{city:city}}).then(function(response){
$(event.target).parent().children().removeClass("dn");
$(event.target).addClass("dn");
reloadMyFocus()
plus.webview.getWebviewById('views/house/houseDetail.html').reload();
plus.webview.getWebviewById('views/house/houseManageList.html').reload();
plus.webview.getWebviewById('views/user/userInfo.html').reload();
}).catch(function(error){
console.log(error)
})
}
})
}else{
@@ -61,7 +70,6 @@ Vue.component('city_increase_ranking',{
$(event.target).parent().children().removeClass("dn");
$(event.target).addClass("dn");
reloadMyFocus()
//plus.webview.getWebviewById('views/user/userInfo.html').reload()
}).catch(function(error){
console.log(error)
})
@@ -67,11 +67,20 @@ Vue.component('city_potential_ranking',{
},
follow:function(city,event){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
alert("请先登录")
clicked('/views/user/passLogin.html',true,false,{},{},function(){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
}else{
axios.get("/rest/quotations/collectCity",{params:{city:city}}).then(function(response){
$(event.target).parent().children().removeClass("dn");
$(event.target).addClass("dn");
plus.webview.getWebviewById('views/house/houseDetail.html').reload();
plus.webview.getWebviewById('views/house/houseManageList.html').reload();
plus.webview.getWebviewById('views/user/userInfo.html').reload();
reloadMyFocus()
}).catch(function(error){
console.log(error)
})
}
})
}else{
+9 -2
View File
@@ -1472,12 +1472,19 @@ function markFocus(){
function addFocus(city){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
alert("请先登录")
clicked('/views/user/passLogin.html',true,false,{},{},function(){
if(localStorage.getItem("user_token") == null || localStorage.getItem("user_token") == ""){
}else{
axios.get("/rest/quotations/collectCity",{params:{city:city}}).then(function(response){
reloadMyFocus()
createData(city, myDatasVue.$data.cityDatas.length);
plus.webview.getWebviewById('views/house/houseDetail.html').reload();
plus.webview.getWebviewById('views/house/houseManageList.html').reload();
plus.webview.getWebviewById('views/user/userInfo.html').reload();
}).catch(function(error){
console.log(error)
})
}
})
}else{