Commit 7d5224b8 authored by linj's avatar linj

fix ; fmt

parent a92ce051
...@@ -8,11 +8,12 @@ import ( ...@@ -8,11 +8,12 @@ import (
"github.com/33cn/chain33/common/db/table" "github.com/33cn/chain33/common/db/table"
pty "github.com/33cn/plugin/plugin/dapp/trade/types" pty "github.com/33cn/plugin/plugin/dapp/trade/types"
"github.com/33cn/chain33/types"
"fmt" "fmt"
"github.com/33cn/chain33/common/db"
"github.com/33cn/chain33/common"
"strconv" "strconv"
"github.com/33cn/chain33/common"
"github.com/33cn/chain33/common/db"
"github.com/33cn/chain33/types"
) )
/* /*
...@@ -58,7 +59,6 @@ var opt_order_table = &table.Option{ ...@@ -58,7 +59,6 @@ var opt_order_table = &table.Option{
}, },
} }
type OrderRow struct { type OrderRow struct {
*pty.LocalOrder *pty.LocalOrder
} }
...@@ -89,7 +89,7 @@ func (r *OrderRow) Get(key string) ([]byte, error) { ...@@ -89,7 +89,7 @@ func (r *OrderRow) Get(key string) ([]byte, error) {
case "asset": case "asset":
return []byte(fmt.Sprintf("%s", r.asset())), nil return []byte(fmt.Sprintf("%s", r.asset())), nil
case "asset_isSell_status": case "asset_isSell_status":
return []byte(fmt.Sprintf("%s_%d_", r.asset(), r.isSell(), r.status())), nil return []byte(fmt.Sprintf("%s_%d_%s", r.asset(), r.isSell(), r.status())), nil
case "owner": case "owner":
return []byte(fmt.Sprintf("%s", r.Owner)), nil return []byte(fmt.Sprintf("%s", r.Owner)), nil
case "owner_asset": case "owner_asset":
...@@ -238,7 +238,6 @@ func parseOrderPriceFloat(s string) int64 { ...@@ -238,7 +238,6 @@ func parseOrderPriceFloat(s string) int64 {
return int64(x * float64(types.Coin)) return int64(x * float64(types.Coin))
} }
func (t *trade) genSellMarket(tx *types.Transaction, sell *pty.ReceiptSellBase, txIndex string) *pty.LocalOrder { func (t *trade) genSellMarket(tx *types.Transaction, sell *pty.ReceiptSellBase, txIndex string) *pty.LocalOrder {
order := &pty.LocalOrder{ order := &pty.LocalOrder{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment