用户小界面
|
|
@ -348,8 +348,8 @@ function M:FG_Get_Online_Member(groupId, callback)
|
|||
local _data = {}
|
||||
_data.id = groupId
|
||||
_data.uid = DataManager.SelfUser.account_id
|
||||
local _client = ControllerManager.GroupClient
|
||||
_client:send(Protocol.WEB_FG_GET_ONLINE_MEMBER, _data, function(res)
|
||||
--local _client = ControllerManager.GroupClient
|
||||
self._mgr_client:send(Protocol.WEB_FG_GET_ONLINE_MEMBER, _data, function(res)
|
||||
callback(res)
|
||||
end)
|
||||
end
|
||||
|
|
@ -359,8 +359,8 @@ function M:FG_Get_Offline_Member(groupId, callback)
|
|||
local _data = {}
|
||||
_data.id = groupId
|
||||
_data.uid = DataManager.SelfUser.account_id
|
||||
local _client = ControllerManager.GroupClient
|
||||
_client:send(Protocol.WEB_FG_GET_OFFLINE_MEMBER, _data, function(res)
|
||||
--local _client = ControllerManager.GroupClient
|
||||
self._mgr_client:send(Protocol.WEB_FG_GET_OFFLINE_MEMBER, _data, function(res)
|
||||
callback(res)
|
||||
end)
|
||||
end
|
||||
|
|
|
|||
|
|
@ -401,7 +401,8 @@ Protocol = {
|
|||
FGMGR_EVT_NEWCHAT = "12011",
|
||||
-- 设置是否允许观战
|
||||
WEB_FG_SET_CANWATCH = "group/set_group_guest",
|
||||
|
||||
-- 家族成员在线状态推送
|
||||
FGMGR_EVT_Member_State = "13007",
|
||||
--end::::::::::::::牌友圈协议::::::::::::::::::::
|
||||
|
||||
-------------------Game ----------------------------
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@ function FamilyEventView.new(root)
|
|||
mgr_ctr:AddEventListener(GroupMgrEvent.ChatRoomData, handler(self, self._evtChatRoomData))
|
||||
mgr_ctr:AddEventListener(GroupMgrEvent.OnNewApply, handler(self, self._evtOnNewApply))
|
||||
mgr_ctr:AddEventListener(GroupMgrEvent.OnNewRecord, handler(self, self._evtOnNewRecord))
|
||||
mgr_ctr:AddEventListener(GroupMgrEvent.OnMemberState, handler(self, self._evtOnMemberState))
|
||||
return self
|
||||
end
|
||||
|
||||
|
|
@ -156,4 +157,10 @@ function M:_evtOnNewRecord(...)
|
|||
view.com_FamilyChatRoom:OnNewChatRefalsh(arg[1])
|
||||
end
|
||||
|
||||
function M:_evtOnMemberState(...)
|
||||
print("_evtOnMemberState")
|
||||
local arg = {...}
|
||||
pt(arg)
|
||||
end
|
||||
|
||||
return M
|
||||
|
|
|
|||
|
|
@ -23,16 +23,16 @@ FamilyView = {}
|
|||
|
||||
local M = FamilyView
|
||||
|
||||
local function FamilyOnline(groupId)
|
||||
local fgCtr = ControllerManager.GetController(GroupMgrController)
|
||||
fgCtr:FG_Get_Online_Member(groupId, function(res)
|
||||
local function FamilyOnline(groupId, self)
|
||||
--localfgCtr = ControllerManager.GetController(GroupMgrController)
|
||||
self._mgr_ctr:FG_Get_Online_Member(groupId, function(res)
|
||||
|
||||
end)
|
||||
end
|
||||
|
||||
local function FamilyOffline(groupId)
|
||||
local fgCtr = ControllerManager.GetController(GroupMgrController)
|
||||
fgCtr:FG_Get_Offline_Member(groupId, function(res)
|
||||
local function FamilyOffline(groupId, self)
|
||||
--local fgCtr = ControllerManager.GetController(GroupMgrController)
|
||||
self._mgr_ctr:FG_Get_Offline_Member(groupId, function(res)
|
||||
|
||||
end)
|
||||
end
|
||||
|
|
@ -134,9 +134,8 @@ function M:InitCloseClick()
|
|||
self.btn_close.onClick:Set(function()
|
||||
print("lingmengfamily", self.lastType, self.familyType.selectedIndex)
|
||||
if not self.lastType or self.familyType.selectedIndex == 1 then
|
||||
|
||||
if self._group then
|
||||
FamilyOffline(self._group.id)
|
||||
FamilyOffline(self._group.id, self)
|
||||
end
|
||||
|
||||
ControllerManager.ChangeController(LoddyController)
|
||||
|
|
@ -341,10 +340,6 @@ function M:ChangeNumber(fgCtr, group_id, limit, num, minus_only, sort_type)
|
|||
end
|
||||
|
||||
function M:ConnetFamilyRoom(fgCtr, id)
|
||||
if self._group then
|
||||
FamilyOffline(self._group.id)
|
||||
end
|
||||
|
||||
fgCtr:FG_EnterGroup(id, function(res)
|
||||
ViewUtil:CloseModalWait()
|
||||
if res.ReturnCode ~= 0 then
|
||||
|
|
@ -359,7 +354,7 @@ function M:ConnetFamilyRoom(fgCtr, id)
|
|||
pt(res)
|
||||
end)
|
||||
|
||||
FamilyOnline(self._group.id)
|
||||
FamilyOnline(self._group.id, self)
|
||||
|
||||
return 1
|
||||
end
|
||||
|
|
@ -561,6 +556,11 @@ function M:UpdateFamilyRoom(fgCtr, id)
|
|||
end
|
||||
|
||||
function M:ConnetFamily(index, groups, isCreate)
|
||||
|
||||
if self._group then
|
||||
FamilyOffline(self._group.id, self)
|
||||
end
|
||||
|
||||
UpdateBeat:Remove(self.OnUpdate, self)
|
||||
ViewUtil:CloseModalWait()
|
||||
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 5.1 MiB After Width: | Height: | Size: 4.9 MiB |
|
Before Width: | Height: | Size: 2.7 MiB After Width: | Height: | Size: 811 KiB |
|
Before Width: | Height: | Size: 587 KiB After Width: | Height: | Size: 2.6 MiB |
|
Before Width: | Height: | Size: 3.9 MiB After Width: | Height: | Size: 3.9 MiB |
|
Before Width: | Height: | Size: 2.4 MiB After Width: | Height: | Size: 2.4 MiB |
|
Before Width: | Height: | Size: 4.4 MiB After Width: | Height: | Size: 4.4 MiB |
|
Before Width: | Height: | Size: 1.6 MiB After Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 482 KiB After Width: | Height: | Size: 831 KiB |