修改质押查询
This commit is contained in:
parent
7a3991644b
commit
c6926532ad
@ -6,6 +6,7 @@ import (
|
|||||||
"main/common"
|
"main/common"
|
||||||
"main/constant"
|
"main/constant"
|
||||||
. "main/global"
|
. "main/global"
|
||||||
|
"mt"
|
||||||
"net/http"
|
"net/http"
|
||||||
"q5"
|
"q5"
|
||||||
"strings"
|
"strings"
|
||||||
@ -19,7 +20,8 @@ func (this *MarketApi) LockList(c *gin.Context) {
|
|||||||
reqJson := struct {
|
reqJson := struct {
|
||||||
PageSize interface{} `json:"page_size"`
|
PageSize interface{} `json:"page_size"`
|
||||||
Cursor interface{} `json:"cursor"`
|
Cursor interface{} `json:"cursor"`
|
||||||
Search struct {
|
Search struct {
|
||||||
|
Name string `json:"name"`
|
||||||
} `json:"search"`
|
} `json:"search"`
|
||||||
Filter struct {
|
Filter struct {
|
||||||
ItemIds []interface{} `json:"item_ids"`
|
ItemIds []interface{} `json:"item_ids"`
|
||||||
@ -50,6 +52,9 @@ WHERE A.idx > %d AND A.net_id = %d AND A.last_owner_address= '%s' AND A.owner_ad
|
|||||||
|
|
||||||
{
|
{
|
||||||
itemIds := map[int32]int32{}
|
itemIds := map[int32]int32{}
|
||||||
|
if reqJson.Search.Name != "" {
|
||||||
|
mt.Table.Item.Search(reqJson.Search.Name, itemIds)
|
||||||
|
}
|
||||||
for _, val := range(reqJson.Filter.ItemIds) {
|
for _, val := range(reqJson.Filter.ItemIds) {
|
||||||
itemId := q5.SafeToInt32(val)
|
itemId := q5.SafeToInt32(val)
|
||||||
itemIds[itemId] = 1
|
itemIds[itemId] = 1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user