Authored by 陈轩

fix YH-4546

... ... @@ -11,10 +11,6 @@ var tip = require('plugin/tip');
window.tip = tip;
var KEY_CODE = {
ENTER: 13
};
var $msgRoll, $msgBox, $msgContent, $msgSend;
var $punch, $punchModal;
... ... @@ -32,6 +28,7 @@ function appJump(where, option, checkLogin) {
}
$anchor.attr('href', [where, '?openby:yohobuy=', JSON.stringify(option)].join(''));
// alert($anchor.attr('href'))
$anchor.appendTo('body');
$anchor[0].click();
... ... @@ -121,13 +118,18 @@ var page = {
},
leaveMsg: function(content) {
console.log('hi')
console.log('hi');
$.post('/activity/vip-day/msg/save.json?app_version=1&uid=' + yoho.getUid(), {
content: content
})
.done(function(res) {
if (res.code !== 200) {
tip.show('留言失败~稍后再试');
if (res.redirect) {
location.href = res.redirect;
} else {
tip.show('留言失败~稍后再试');
}
return;
}
... ... @@ -177,6 +179,7 @@ var page = {
$msgRoll
.append($frag, $frag.clone());
// .css({ visibility: 'visible' });
var oneMsgH, onePageH;
... ... @@ -185,7 +188,7 @@ var page = {
oneMsgH = $msgRoll[0].getBoundingClientRect().height - 6;
onePageH = $fragClone[0].offsetTop;
console.log(oneMsgH)
console.log(oneMsgH);
function rolling() {
... ... @@ -213,4 +216,4 @@ var page = {
window.$ = $;
$(function() {
page.init();
});
\ No newline at end of file
});
... ...