bug
This commit is contained in:
@@ -81,7 +81,7 @@
|
||||
|
||||
<div class="searchbar row commentReleaseBox dn">
|
||||
<div class="search-input col-85">
|
||||
<input type="text" maxlength="250">
|
||||
<input type="text" maxlength="250" id="commentInput">
|
||||
</div>
|
||||
<a class="col-15" id="publishBtn">发布</a>
|
||||
</div>
|
||||
@@ -538,17 +538,21 @@ function addComment(){
|
||||
console.log(error);
|
||||
});
|
||||
}
|
||||
|
||||
mui.init({
|
||||
beforeback: function() {
|
||||
//获得父页面的webview
|
||||
var list = plus.webview.getWebviewById('yfindex.html');
|
||||
//触发父页面的自定义事件(refresh),从而进行刷新
|
||||
mui.fire(list, 'refresh');
|
||||
//返回true,继续页面关闭逻辑
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
$(function() {
|
||||
$('#commentInput').on('click', function () {
|
||||
var target = this;
|
||||
// 使用定时器是为了让输入框上滑时更加自然
|
||||
/*setTimeout(function(){
|
||||
target.scrollIntoView(true);
|
||||
},100);*/
|
||||
setTimeout(function(){
|
||||
document.body.scrollTop = document.body.scrollHeight;
|
||||
target.scrollIntoView(true);
|
||||
},100);
|
||||
});
|
||||
})
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user