Commit d201ca55 authored by agping's avatar agping

feed流修改

parent 78dbd1ef
<template>
<div>
<!--<header-pulic :data="headerData"></header-pulic>-->
<div class="story_con">
<img :src="chengjiaoxibao_pic" class="chengjiaoxibao_di_pic">
<div class="story_conent">
......@@ -10,7 +9,7 @@
热烈祝贺
</span>
<span class="story_font_span1">
{{name}}
同联商业
</span>
<span></span>
<div class="story_font2">
......@@ -20,8 +19,8 @@
</div>
<div class="story_font2">
<span class="story_font_span3"></span>
<span class="story_font_span4"></span>
<span class="story_font_span3">成交</span>
<span class="story_font_span4">{{name}}</span>
<span class="story_font_span5">商铺一套!</span>
</div>
</div>
......@@ -30,17 +29,17 @@
<span class="ic_star_span">好项目就是这么热销</span>
<img :src="ic_star" class="ic_star1">
<p>
<span class="story_font_span6"></span>,值得你信赖的商铺.
<span class="story_font_span6">{{name}}</span>,值得你信赖的商铺.
</p>
<img :src="line_down" class="line_down">
<img :src="zan" class="zan">
<p style="margin-top:-0.35rem" class="story_font_p"></p>
<img :src="zan_clickpic" class="zan" @click="clickZan">
<p style="margin-top:-0.35rem" class="story_font_p">{{num}}</p>
</div>
</div>
</div>
<div class="story_font_img" id="story_font_img">
<img :src="five" id="zan_1">
<img :src="five" id="zan_1" v-show='zan_pic'>
</div>
</div>
</template>
......@@ -52,26 +51,43 @@
import line_down from '@/components/feed/images/line_down.png';
import zan from '@/components/feed/images/zan.png';
import five from '@/components/feed/images/5555.gif';
import zan_1 from '@/components/feed/images/zan_1.gif';
export default {
data: () => ({
headerData: {
'title': '成交喜报',
'noborder': true,
'isBack': false
},
chengjiaoxibao_pic,
chengjiaojiandan_pic,
ic_star,
line_down,
zan,
zan_1,
five,
name: '',
time: '',
zan_clickpic: zan,
click_num: 1,
num: '',
read_num:1,
zan_pic: false,
feed_id:'',
}),
created() {
let _this = this;
_this.feed_id = _this.$route.query.id;
_this.ajaxUl();
_this.axios({
method: 'post',
url: '/broker/editFeedClick',
responseType: 'json',
data: {
'id': _this.feed_id,
'click_num': 0,
'read_num': _this.read_num,
}
})
},
methods: {
ajaxUl() {
......@@ -81,17 +97,68 @@
url: '/broker/getFeedInfo',
responseType: 'json',
data: {
'id': 14,
'id': _this.feed_id,
}
})
.then(function(response) {
if(response.data.code == 200) {
} else {
}
_this.time = response.data.data.create_time;
_this.name = response.data.data.house_title;
_this.num = response.data.data.click_num;
} else {}
})
}
},
clickZan() {
let _this = this;
if(_this.click_num === 1) {
_this.zan_clickpic = zan_1;
_this.zan_pic = five;
_this.click_num = 0;
_this.axios({
method: 'post',
url: '/broker/editFeedClick',
responseType: 'json',
data: {
'id': _this.feed_id,
'click_num': 1,
}
})
.then(function(response) {
if(response.data.code == 200) {
_this.zan_pic = true;
_this.num = _this.num + 1;
setTimeout(function() {
_this.zan_pic = false;
},850);
}
})
.catch(function(error) {});
} else {
_this.zan_clickpic = zan;
_this.click_num = 1;
_this.axios({
method: 'post',
url: '/broker/editFeedClick',
responseType: 'json',
data: {
'id': _this.feed_id,
'click_num': 0,
}
})
.then(function(response) {
if(response.data.code == 200) {
_this.zan_pic = false;
_this.num = _this.num - 1;
}
})
.catch(function(error) {});
}
},
},
......@@ -152,7 +219,7 @@
.story_font_span3 {
float: left;
margin-left: 0.2rem;
margin-left: 0.6rem;
line-height: 0.88rem;
}
......@@ -250,6 +317,6 @@
#zan_1 {
width: 4rem;
height: 6rem;
display: none;
/*display: none;*/
}
</style>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment