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
0c648d3a
Commit
0c648d3a
authored
Jul 23, 2018
by
rlgy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加平台信息
parent
e00df676
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
4 deletions
+19
-4
CoinBusiness.php
common/business/CoinBusiness.php
+17
-2
ExchangeBusiness.php
common/business/ExchangeBusiness.php
+2
-2
No files found.
common/business/CoinBusiness.php
View file @
0c648d3a
...
@@ -76,6 +76,21 @@ class CoinBusiness
...
@@ -76,6 +76,21 @@ class CoinBusiness
if
(
$rows
[
'count'
]
>
0
)
{
if
(
$rows
[
'count'
]
>
0
)
{
$rows
=
$rows
[
'data'
];
$rows
=
$rows
[
'data'
];
foreach
(
$rows
as
$key
=>
$value
)
{
foreach
(
$rows
as
$key
=>
$value
)
{
if
(
empty
(
$value
[
'publish_count'
]))
{
$rows
[
$key
][
'publish_count'
]
=
0
;
}
if
(
empty
(
$value
[
'circulate_count'
]))
{
$rows
[
$key
][
'circulate_count'
]
=
0
;
}
if
(
empty
(
$value
[
'release'
]))
{
$rows
[
$key
][
'release'
]
=
''
;
}
if
(
empty
(
$value
[
'sid'
]))
{
$rows
[
$key
][
'sid'
]
=
''
;
}
if
(
empty
(
$value
[
'introduce'
]))
{
$rows
[
$key
][
'introduce'
]
=
''
;
}
$coin
=
CoinFactory
::
createCoin
(
$value
[
'name'
],
$value
[
'id'
],
$value
[
'sid'
]);
$coin
=
CoinFactory
::
createCoin
(
$value
[
'name'
],
$value
[
'id'
],
$value
[
'sid'
]);
$rows
[
$key
][
'quotation'
]
=
$coin
->
quotation
();
$rows
[
$key
][
'quotation'
]
=
$coin
->
quotation
();
$coin
->
__destruct
();
$coin
->
__destruct
();
...
@@ -91,7 +106,7 @@ class CoinBusiness
...
@@ -91,7 +106,7 @@ class CoinBusiness
*/
*/
public
static
function
getApiListForIndex
(
$condition
=
[])
public
static
function
getApiListForIndex
(
$condition
=
[])
{
{
$rows
=
Coin
::
getSelectList
(
1
,
999
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'chain'
],
$condition
);
$rows
=
Coin
::
getSelectList
(
1
,
999
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'
platform'
,
'
chain'
],
$condition
);
if
(
$rows
[
'count'
]
>
0
)
{
if
(
$rows
[
'count'
]
>
0
)
{
$rows
=
$rows
[
'data'
];
$rows
=
$rows
[
'data'
];
foreach
(
$rows
as
$key
=>
$row
)
{
foreach
(
$rows
as
$key
=>
$row
)
{
...
@@ -115,7 +130,7 @@ class CoinBusiness
...
@@ -115,7 +130,7 @@ class CoinBusiness
*/
*/
public
static
function
SearchByName
(
$page
=
1
,
$limit
=
10
,
$condition
=
[])
public
static
function
SearchByName
(
$page
=
1
,
$limit
=
10
,
$condition
=
[])
{
{
$rows
=
Coin
::
getSelectList
(
$page
,
$limit
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'chain'
],
$condition
);
$rows
=
Coin
::
getSelectList
(
$page
,
$limit
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'
platform'
,
'
chain'
],
$condition
);
if
(
$rows
[
'count'
]
>
0
)
{
if
(
$rows
[
'count'
]
>
0
)
{
$rows
=
$rows
[
'data'
];
$rows
=
$rows
[
'data'
];
foreach
(
$rows
as
$key
=>
$row
)
{
foreach
(
$rows
as
$key
=>
$row
)
{
...
...
common/business/ExchangeBusiness.php
View file @
0c648d3a
...
@@ -120,7 +120,7 @@ class ExchangeBusiness
...
@@ -120,7 +120,7 @@ class ExchangeBusiness
*/
*/
public
static
function
getApiListForIndex
(
$condition
=
[])
public
static
function
getApiListForIndex
(
$condition
=
[])
{
{
$rows
=
Coin
::
getSelectList
(
1
,
999
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'chain'
],
$condition
);
$rows
=
Coin
::
getSelectList
(
1
,
999
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'
platform'
,
'
chain'
],
$condition
);
if
(
$rows
[
'count'
]
>
0
)
{
if
(
$rows
[
'count'
]
>
0
)
{
$rows
=
$rows
[
'data'
];
$rows
=
$rows
[
'data'
];
foreach
(
$rows
as
$key
=>
$row
)
{
foreach
(
$rows
as
$key
=>
$row
)
{
...
@@ -161,7 +161,7 @@ class ExchangeBusiness
...
@@ -161,7 +161,7 @@ class ExchangeBusiness
*/
*/
public
static
function
SearchByName
(
$page
=
1
,
$limit
=
10
,
$condition
=
[])
public
static
function
SearchByName
(
$page
=
1
,
$limit
=
10
,
$condition
=
[])
{
{
$rows
=
Coin
::
getSelectList
(
$page
,
$limit
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'chain'
],
$condition
);
$rows
=
Coin
::
getSelectList
(
$page
,
$limit
,
[
'id'
,
'sid'
,
'icon'
,
'name'
,
'nickname'
,
'
platform'
,
'
chain'
],
$condition
);
if
(
$rows
[
'count'
]
>
0
)
{
if
(
$rows
[
'count'
]
>
0
)
{
$rows
=
$rows
[
'data'
];
$rows
=
$rows
[
'data'
];
foreach
(
$rows
as
$key
=>
$row
)
{
foreach
(
$rows
as
$key
=>
$row
)
{
...
...
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