Skip to content

Commit 657c878

Browse files
author
liubiao
committed
合并代码
1 parent 720275b commit 657c878

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

Diff for: pages/chat/chat.js

+3-9
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ Page({
3535

3636
const friend = JSON.parse(options.friend);
3737
console.log(friend);
38-
this.initData();
38+
this.setData({
39+
pageHeight: wx.getSystemInfoSync().windowHeight,
40+
});
3941
wx.setNavigationBarTitle({
4042
title: friend.friendName || ''
4143
});
@@ -51,14 +53,6 @@ Page({
5153
onReady() {
5254
this.chatInput = this.selectComponent('#chatInput');
5355
},
54-
initData() {
55-
let that = this;
56-
let systemInfo = wx.getSystemInfoSync();
57-
58-
that.setData({
59-
pageHeight: systemInfo.windowHeight,
60-
});
61-
},
6256
onSendMessageEvent(e) {
6357
let content = e.detail.value;
6458
this.msgManager.sendMsg({type: IMOperator.TextType, content});

0 commit comments

Comments
 (0)