Commit 3d6e1ea4 by 陈超

T

parent ae29f005
......@@ -319,17 +319,20 @@
el: "#app",
data: function() {
return {
data: {},
bought: false,
isCollect: false
}
},
created:function(){
let p = {:json_encode($data)};
console.log(p)
this.data = {:json_encode($data)};
},
computed: {
isCollect: function() {
return this.data.iscollect == 1
},
shareIcon: function() {
return "__THEME__/img/share_star.png"
return this.isCollect ? "__THEME__/img/share_star.png" : "__THEME__/img/share_unstar.png"
}
}
})
......
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