Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
token
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wallet
token
Commits
0114bc5f
Commit
0114bc5f
authored
Sep 21, 2018
by
rlgy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
f47dae56
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
0 deletions
+13
-0
CoinReleaseCheckController.php
backend/controllers/CoinReleaseCheckController.php
+11
-0
CoinReleaseCheck.php
common/models/psources/CoinReleaseCheck.php
+1
-0
GuodunController.php
h5/controllers/GuodunController.php
+1
-0
No files found.
backend/controllers/CoinReleaseCheckController.php
View file @
0114bc5f
...
...
@@ -11,6 +11,7 @@ namespace backend\controllers;
use
common\models\psources\CoinExtract
;
use
common\models\psources\CoinPublish
;
use
common\models\psources\CoinReleaseCheck
;
use
common\models\psources\CoinReleaseMember
;
use
Yii
;
class
CoinReleaseCheckController
extends
BaseController
...
...
@@ -151,6 +152,16 @@ class CoinReleaseCheckController extends BaseController
if
(
$model
->
save
(
false
))
{
if
(
$step
==
self
::
STEP_CHECK_SECOND
&&
CoinReleaseCheck
::
CHECK_SECOND_STATUS_SUCCEED
==
$model
->
check_second_status
)
{
//TODO 提币
}
elseif
(
self
::
STEP_CANCEL
==
$step
)
{
//返还币
$assets
=
CoinReleaseMember
::
findOne
(
$model
->
mid
);
if
(
$assets
)
{
$assets
->
release
+=
$model
->
amount
;
$assets
->
output
-=
$model
->
amount
;
if
(
!
$assets
->
save
())
{
//todo loh
}
}
}
return
[
'code'
=>
0
,
'msg'
=>
'操作成功'
];
}
...
...
common/models/psources/CoinReleaseCheck.php
View file @
0114bc5f
...
...
@@ -14,6 +14,7 @@ use Yii;
/**
* @property integer $id
* @property integer $uid
* @property integer $mid
* @property string $mobile
* @property string $coin
* @property double $amount
...
...
h5/controllers/GuodunController.php
View file @
0114bc5f
...
...
@@ -88,6 +88,7 @@ class GuodunController extends BaseController
//添加提币申请
$request_coin
=
new
CoinReleaseCheck
();
$request_coin
->
uid
=
$user_asset
->
user_id
;
$request_coin
->
mid
=
$id
;
$request_coin
->
mobile
=
$user_asset
->
mobile
;
$request_coin
->
amount
=
$amount
*
1e8
;
$request_coin
->
coin
=
$user_asset
->
coin
;
...
...
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