26 lines
474 B
Plaintext
26 lines
474 B
Plaintext
|
|
/**
|
||
|
|
* 行情API
|
||
|
|
*/
|
||
|
|
import { get } from './request.uts'
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 获取币种列表
|
||
|
|
*/
|
||
|
|
export func getCoinList (): Promise<any> {
|
||
|
|
return get('/api/market/list', null)
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 获取币种详情
|
||
|
|
*/
|
||
|
|
export func getCoinDetail (code: string): Promise<any> {
|
||
|
|
return get('/api/market/detail', { code } as UTSJSONObject)
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 搜索币种
|
||
|
|
*/
|
||
|
|
export func searchCoins (keyword: string): Promise<any> {
|
||
|
|
return get('/api/market/search', { keyword } as UTSJSONObject)
|
||
|
|
}
|