充值家族房卡协议
parent
b24f5508a9
commit
c3fea3ad73
|
|
@ -45,6 +45,7 @@ function M:FG_GroupList(callback)
|
||||||
group.isOpenChatRoom = tem.isOpenChatRoom
|
group.isOpenChatRoom = tem.isOpenChatRoom
|
||||||
group.isWatch = tem.isWatch
|
group.isWatch = tem.isWatch
|
||||||
group.wechatId = tem.wechatId
|
group.wechatId = tem.wechatId
|
||||||
|
group.groupDiamo = tem.groupDiamo
|
||||||
l_groups:add(group)
|
l_groups:add(group)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
@ -1662,3 +1663,14 @@ function M:SetCanWatch(groupId, value, callback)
|
||||||
callback(res)
|
callback(res)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- 亲友圈充值房卡
|
||||||
|
function M:FG_Recharge_Diamo(groupId, diamo, callback)
|
||||||
|
local _data = {}
|
||||||
|
_data.id = groupId
|
||||||
|
_data.diamo = diamo
|
||||||
|
local _client = ControllerManager.GroupClient
|
||||||
|
_client:send(Protocol.WEB_FG_RECHARGE_DIAMO, _data, function(res)
|
||||||
|
callback(res)
|
||||||
|
end)
|
||||||
|
end
|
||||||
|
|
|
||||||
|
|
@ -275,6 +275,9 @@ Protocol = {
|
||||||
-- 亲友圈聊天室
|
-- 亲友圈聊天室
|
||||||
WEB_FG_GETCHATROOM = "group/get_chat_rooms",
|
WEB_FG_GETCHATROOM = "group/get_chat_rooms",
|
||||||
|
|
||||||
|
-- 亲友圈房卡充值
|
||||||
|
WEB_FG_RECHARGE_DIAMO = "group/recharge_diamo",
|
||||||
|
|
||||||
-------------- group-log---------------------
|
-------------- group-log---------------------
|
||||||
-- 获取奖励日志
|
-- 获取奖励日志
|
||||||
WEB_FG_GET_REWARDS_LOG = "group/log/get_reward_log",
|
WEB_FG_GET_REWARDS_LOG = "group/log/get_reward_log",
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,8 @@ BaseView = {
|
||||||
_is_destroy = false,
|
_is_destroy = false,
|
||||||
--关闭摧毁
|
--关闭摧毁
|
||||||
_close_destroy = false,
|
_close_destroy = false,
|
||||||
|
--缩放全屏
|
||||||
|
_scale = false,
|
||||||
-- 全屏
|
-- 全屏
|
||||||
_full = false,
|
_full = false,
|
||||||
--全屏偏移
|
--全屏偏移
|
||||||
|
|
@ -53,6 +55,12 @@ function M:Show()
|
||||||
self._contentPane.height = GRoot.inst.height
|
self._contentPane.height = GRoot.inst.height
|
||||||
self._contentPane.x = offset
|
self._contentPane.x = offset
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if self._scale then
|
||||||
|
local scaleY = GRoot.inst.height / self._contentPane.height
|
||||||
|
local scaleX = GRoot.inst.width / self._contentPane.width
|
||||||
|
self._contentPane:SetScale(scaleX, scaleY)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,15 +8,29 @@ local data = {
|
||||||
|
|
||||||
local FamilyRoomCard = {}
|
local FamilyRoomCard = {}
|
||||||
|
|
||||||
local function charge(num)
|
local function charge(num, self)
|
||||||
print('充值',num)
|
local fgCtr = ControllerManager.GetController(NewGroupController)
|
||||||
|
fgCtr:FG_Recharge_Diamo(self.groupId, num, function(res)
|
||||||
|
print("收到充值房卡回调")
|
||||||
|
pt(res)
|
||||||
|
if res.ReturnCode ~= 0 then
|
||||||
|
ViewUtil.ErrorTip(res.ReturnCode, "操作失败")
|
||||||
|
return
|
||||||
|
end
|
||||||
|
local groupDiamo = res.Data.groupDiamo
|
||||||
|
local playerDiamo = res.Data.userDiamo
|
||||||
|
self.tex_curCard.text = "当前帐号房卡:" .. playerDiamo
|
||||||
|
self.tex_famliyCard.text = "亲友圈房卡:" .. groupDiamo
|
||||||
|
self.group.groupDiamo = groupDiamo
|
||||||
|
DataManager.SelfUser.diamo = playerDiamo
|
||||||
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
--#endregion
|
--#endregion
|
||||||
|
|
||||||
function FamilyRoomCard:TryShow()
|
function FamilyRoomCard:TryShow(groupId)
|
||||||
local Instance = self.New()
|
local Instance = self.New()
|
||||||
Instance:Show()
|
Instance:Show(groupId)
|
||||||
end
|
end
|
||||||
|
|
||||||
function FamilyRoomCard.New()
|
function FamilyRoomCard.New()
|
||||||
|
|
@ -42,9 +56,7 @@ function FamilyRoomCard.New()
|
||||||
obj:GetController("cColor").selectedIndex = data[_idx].colorIndex
|
obj:GetController("cColor").selectedIndex = data[_idx].colorIndex
|
||||||
|
|
||||||
obj.onClick:Set(function()
|
obj.onClick:Set(function()
|
||||||
|
charge(num, Instance)
|
||||||
charge(num)
|
|
||||||
print('房卡',num)
|
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -53,11 +65,12 @@ function FamilyRoomCard.New()
|
||||||
return Instance
|
return Instance
|
||||||
end
|
end
|
||||||
|
|
||||||
function FamilyRoomCard:Show()
|
function FamilyRoomCard:Show(groupId)
|
||||||
|
self.groupId = groupId
|
||||||
|
self.group = DataManager.groups:get(self.groupId)
|
||||||
|
|
||||||
self.tex_curCard.text = "当前帐号房卡:" .. DataManager.SelfUser.diamo
|
self.tex_curCard.text = "当前帐号房卡:" .. DataManager.SelfUser.diamo
|
||||||
|
self.tex_famliyCard.text = "亲友圈房卡:" .. self.group.groupDiamo
|
||||||
--self.tex_famliyCard.text = "亲友圈房卡:" ..
|
|
||||||
|
|
||||||
BaseWindow.Show(self)
|
BaseWindow.Show(self)
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -249,7 +249,7 @@ function M:ShowShop()
|
||||||
--self._child_familyLobbyShopView = LobbyShopView.new(self, self._group.id)
|
--self._child_familyLobbyShopView = LobbyShopView.new(self, self._group.id)
|
||||||
--self._child_familyLobbyShopView:Show()
|
--self._child_familyLobbyShopView:Show()
|
||||||
|
|
||||||
FamilyRoomCard:TryShow()
|
FamilyRoomCard:TryShow(self._group.id)
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:ShowAllRank()
|
function M:ShowAllRank()
|
||||||
|
|
|
||||||
|
|
@ -5,8 +5,8 @@
|
||||||
<image id="n1_c8pn" name="n1" src="c8pn7czv" fileName="RoomCrad/Image/Rectangle 41.png" xy="18,36"/>
|
<image id="n1_c8pn" name="n1" src="c8pn7czv" fileName="RoomCrad/Image/Rectangle 41.png" xy="18,36"/>
|
||||||
<image id="n2_c8pn" name="n2" src="c8pn7czw" fileName="RoomCrad/Image/title_top.png" xy="0,-9"/>
|
<image id="n2_c8pn" name="n2" src="c8pn7czw" fileName="RoomCrad/Image/title_top.png" xy="0,-9"/>
|
||||||
<text id="n3_c8pn" name="n3" xy="371,6" size="530,116" font="Alibaba PuHuiTi 3.0" fontSize="90" color="#ffffff" align="center" vAlign="middle" autoSize="none" bold="true" text="充值房卡"/>
|
<text id="n3_c8pn" name="n3" xy="371,6" size="530,116" font="Alibaba PuHuiTi 3.0" fontSize="90" color="#ffffff" align="center" vAlign="middle" autoSize="none" bold="true" text="充值房卡"/>
|
||||||
<text id="n4_c8pn" name="tex_curCard" xy="159,174" size="401,56" font="Alibaba PuHuiTi 3.0" fontSize="42" color="#666666" align="center" vAlign="middle" autoSize="none" bold="true" text="当前帐号房卡:20"/>
|
<text id="n4_c8pn" name="tex_curCard" xy="139,174" size="456,56" font="Alibaba PuHuiTi 3.0" fontSize="42" color="#666666" vAlign="middle" autoSize="none" bold="true" text="当前帐号房卡:999999"/>
|
||||||
<text id="n6_c8pn" name="tex_famliyCard" xy="708,174" size="401,56" font="Alibaba PuHuiTi 3.0" fontSize="42" color="#666666" align="center" vAlign="middle" autoSize="none" bold="true" text="亲友圈房卡:191"/>
|
<text id="n6_c8pn" name="tex_famliyCard" xy="688,174" size="401,56" font="Alibaba PuHuiTi 3.0" fontSize="42" color="#666666" vAlign="middle" autoSize="none" bold="true" text="亲友圈房卡:999999"/>
|
||||||
<list id="n8_c8pn" name="list_bayCrad" xy="90,260" size="1092,493" layout="row" overflow="hidden" colGap="33" defaultItem="ui://htcn7v3rc8pn7czy" align="center" autoClearItems="true">
|
<list id="n8_c8pn" name="list_bayCrad" xy="90,260" size="1092,493" layout="row" overflow="hidden" colGap="33" defaultItem="ui://htcn7v3rc8pn7czy" align="center" autoClearItems="true">
|
||||||
<item/>
|
<item/>
|
||||||
<item/>
|
<item/>
|
||||||
|
|
|
||||||
Binary file not shown.
|
|
@ -1,109 +1,109 @@
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"lua_path": "/tolua_project,/base_project,/main_project",
|
"lua_path": "/tolua_project,/base_project,/main_project",
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "base_script",
|
"name": "base_script",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/base_script",
|
"bundle": "base/base_script",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "common",
|
"name": "common",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/common",
|
"bundle": "base/common",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "login",
|
"name": "login",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/login",
|
"bundle": "base/login",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "lobby",
|
"name": "lobby",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/lobby",
|
"bundle": "base/lobby",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "Family",
|
"name": "Family",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/Family",
|
"bundle": "base/Family",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "chat",
|
"name": "chat",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/chat",
|
"bundle": "base/chat",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "newgroup",
|
"name": "newgroup",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/newgroup",
|
"bundle": "base/newgroup",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "rank",
|
"name": "rank",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/rank"
|
"bundle": "base/rank"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "main_majiang",
|
"name": "main_majiang",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/main_majiang"
|
"bundle": "base/main_majiang"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "main_poker",
|
"name": "main_poker",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/main_poker"
|
"bundle": "base/main_poker"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "main_zipai",
|
"name": "main_zipai",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/main_zipai"
|
"bundle": "base/main_zipai"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "static",
|
"name": "static",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/static",
|
"bundle": "base/static",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"is_res": true,
|
"is_res": true,
|
||||||
"name": "embed",
|
"name": "embed",
|
||||||
"check": true,
|
"check": true,
|
||||||
"bundle": "base/embed",
|
"bundle": "base/embed",
|
||||||
"version": "1.0.8"
|
"version": "1.0.9"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "main_pokemajiang",
|
"name": "main_pokemajiang",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/main_pokemajiang"
|
"bundle": "base/main_pokemajiang"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"ver": "1.0.8",
|
"ver": "1.0.9",
|
||||||
"name": "main_zipaimajiang",
|
"name": "main_zipaimajiang",
|
||||||
"check": true,
|
"check": true,
|
||||||
"version": "1.0.8",
|
"version": "1.0.9",
|
||||||
"bundle": "base/main_zipaimajiang"
|
"bundle": "base/main_zipaimajiang"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -581,7 +581,7 @@ Camera:
|
||||||
m_Enabled: 1
|
m_Enabled: 1
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
m_ClearFlags: 2
|
m_ClearFlags: 2
|
||||||
m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0.019607844}
|
m_BackGroundColor: {r: 0, g: 0, b: 0, a: 0.019607844}
|
||||||
m_projectionMatrixMode: 1
|
m_projectionMatrixMode: 1
|
||||||
m_GateFitMode: 2
|
m_GateFitMode: 2
|
||||||
m_FOVAxisMode: 0
|
m_FOVAxisMode: 0
|
||||||
|
|
@ -598,7 +598,7 @@ Camera:
|
||||||
far clip plane: 30
|
far clip plane: 30
|
||||||
field of view: 60
|
field of view: 60
|
||||||
orthographic: 1
|
orthographic: 1
|
||||||
orthographic size: 10.8
|
orthographic size: 10
|
||||||
m_Depth: 1
|
m_Depth: 1
|
||||||
m_CullingMask:
|
m_CullingMask:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
|
|
@ -622,7 +622,7 @@ Transform:
|
||||||
m_PrefabAsset: {fileID: 0}
|
m_PrefabAsset: {fileID: 0}
|
||||||
m_GameObject: {fileID: 2064634016}
|
m_GameObject: {fileID: 2064634016}
|
||||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
m_LocalPosition: {x: 22.44, y: -10.8, z: 0}
|
m_LocalPosition: {x: 30, y: -10, z: 0}
|
||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,6 @@ GraphicsSettings:
|
||||||
- {fileID: 16000, guid: 0000000000000000f000000000000000, type: 0}
|
- {fileID: 16000, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
- {fileID: 16001, guid: 0000000000000000f000000000000000, type: 0}
|
- {fileID: 16001, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
- {fileID: 17000, guid: 0000000000000000f000000000000000, type: 0}
|
- {fileID: 17000, guid: 0000000000000000f000000000000000, type: 0}
|
||||||
- {fileID: 16003, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_PreloadedShaders: []
|
m_PreloadedShaders: []
|
||||||
m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000,
|
m_SpritesDefaultMaterial: {fileID: 10754, guid: 0000000000000000f000000000000000,
|
||||||
type: 0}
|
type: 0}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue