Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
quxiu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
冷斌
quxiu
Commits
695ebe14
Commit
695ebe14
authored
May 21, 2020
by
冷斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bug
parent
560b45f4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
10 deletions
+22
-10
api/Appapi/Api/Live.php
+14
-10
api/Appapi/Domain/Live.php
+8
-0
No files found.
api/Appapi/Api/Live.php
View file @
695ebe14
...
...
@@ -1578,8 +1578,9 @@ class Api_Live extends PhalApi_Api {
$key
=
'getGiftList'
;
$giftlist
=
getcaches
(
$key
);
$domain
=
new
Domain_Live
();
if
(
!
$giftlist
){
$domain
=
new
Domain_Live
();
$giftlist
=
$domain
->
getGiftList
();
setcaches
(
$key
,
$giftlist
);
}
...
...
@@ -1590,15 +1591,18 @@ class Api_Live extends PhalApi_Api {
}
}
$giftlist
=
$data
;
$welfare
=
DI
()
->
notorm
->
welfare_rate
->
select
(
'rate'
)
->
where
(
'id=1'
)
->
fetchOne
();
$info
[
'welfare_price'
]
=
$welfare
[
'rate'
];
$giftlist
[]
=
[
'type'
=>
0
,
'mark'
=>
4
,
'giftname'
=>
'宝箱'
,
'needcoin'
=>
$welfare
[
'rate'
],
];
$welfareGift
=
$domain
->
randomGift
();
if
(
!
empty
(
$welfareGift
))
{
$welfare
=
DI
()
->
notorm
->
welfare_rate
->
select
(
'rate'
)
->
where
(
'id=1'
)
->
fetchOne
();
$info
[
'welfare_price'
]
=
$welfare
[
'rate'
];
$giftlist
[]
=
[
'type'
=>
0
,
'mark'
=>
4
,
'giftname'
=>
'宝箱'
,
'needcoin'
=>
$welfare
[
'rate'
],
];
}
$domain2
=
new
Domain_User
();
$coin
=
$domain2
->
getBalance
(
$uid
);
...
...
api/Appapi/Domain/Live.php
View file @
695ebe14
...
...
@@ -234,4 +234,12 @@ class Domain_Live {
$rs
=
$model
->
weekList
(
$types
,
$gid
,
$p
);
return
$rs
;
}
public
function
randomGift
()
{
$rs
=
array
();
$model
=
new
Model_Live
();
$rs
=
$model
->
randomGift
();
return
$rs
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment