|
@@ -21,6 +21,10 @@ Page({
|
21
|
21
|
onLoad(options) {
|
22
|
22
|
let that = this;
|
23
|
23
|
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+ //获取自己的头像
|
24
|
28
|
app.postRequest('my/images/headurl', {}, function (res) {
|
25
|
29
|
if (res.code == 201) {
|
26
|
30
|
// console.log(res);
|
|
@@ -34,7 +38,7 @@ Page({
|
34
|
38
|
// emojiChar: "☺-😋-😌-😍-😏-😜-😝-😞-😔-😪-😭-😁-😂-😃-😅-😆-👿-😒-😓-😔-😏-😖-😘-😚-😒-😡-😢-😣-😤-😢-😨-😳-😵-😷-😸-😻-😼-😽-😾-😿-🙊-🙋-🙏-✈-🚇-🚃-🚌-🍄-🍅-🍆-🍇-🍈-🍉-🍑-🍒-🍓-🐔-🐶-🐷-👦-👧-👱-👩-👰-👨-👲-👳-💃-💄-💅-💆-💇-🌹-💑-💓-💘-🚲",
|
35
|
39
|
|
36
|
40
|
|
37
|
|
-
|
|
41
|
+
|
38
|
42
|
|
39
|
43
|
},
|
40
|
44
|
toChat(e) { //跳转进入聊天页面
|
|
@@ -52,7 +56,7 @@ Page({
|
52
|
56
|
// wx.setStorageSync('','');
|
53
|
57
|
wx.setStorageSync('chat_to_id', e.currentTarget.dataset.item.to_id)
|
54
|
58
|
wx.navigateTo({
|
55
|
|
- url: '../chat/chat?to_id=' + e.currentTarget.dataset.item.to_id + '&headUrl=' + e.currentTarget.dataset.item.img + '&myheadurl='+_that.data.myheadurl
|
|
59
|
+ url: '../information/chat/chat?to_id=' + e.currentTarget.dataset.item.to_id + '&headUrl=' + e.currentTarget.dataset.item.img + '&myheadurl='+_that.data.myheadurl
|
56
|
60
|
});
|
57
|
61
|
},
|
58
|
62
|
/**
|
|
@@ -72,7 +76,7 @@ Page({
|
72
|
76
|
} catch (e) {
|
73
|
77
|
|
74
|
78
|
}
|
75
|
|
- console.log(e,111111222222);
|
|
79
|
+
|
76
|
80
|
webSocket.sendSocketMessage({
|
77
|
81
|
msg: JSON.stringify({ form_id: getApp().UserId(), type: 'Chat_list' }),
|
78
|
82
|
success: function (res) {
|
|
@@ -81,8 +85,8 @@ Page({
|
81
|
85
|
console.log('发送消息失败')
|
82
|
86
|
}
|
83
|
87
|
})
|
84
|
|
-
|
85
|
88
|
webSocket.onSocketMessageCallback = this.onSocketMessageCallback;
|
|
89
|
+
|
86
|
90
|
// console.log(Times.dealChatTime(new Date(), 1555257947));
|
87
|
91
|
// _this.setData({
|
88
|
92
|
// conversations: [{
|
|
@@ -120,7 +124,7 @@ Page({
|
120
|
124
|
//清除缓存
|
121
|
125
|
if (chatlistcount && dataAtt[index].to_str == chatlistcount) {
|
122
|
126
|
wx.removeStorageSync('ChatListCount');
|
123
|
|
- console.log(112233);
|
|
127
|
+ // console.log(112233);
|
124
|
128
|
dataAtt[index].count = 0;
|
125
|
129
|
}
|
126
|
130
|
if (dataAtt[index].type == 2) {
|