Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(marketplace): cancel sell order #891

Merged
merged 20 commits into from
Mar 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,356 changes: 1,148 additions & 208 deletions api/regen/ecocredit/marketplace/v1/tx.pulsar.go

Large diffs are not rendered by default.

38 changes: 38 additions & 0 deletions api/regen/ecocredit/marketplace/v1/tx_grpc.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 16 additions & 0 deletions proto/regen/ecocredit/marketplace/v1/tx.proto
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ service Msg {
// UpdateSellOrders updates existing sell orders.
rpc UpdateSellOrders(MsgUpdateSellOrders) returns (MsgUpdateSellOrdersResponse);

// CancelSellOrder cancels a sell order and returns the funds from escrow.
rpc CancelSellOrder(MsgCancelSellOrder) returns (MsgCancelSellOrderResponse);

// Buy creates credit buy orders.
rpc Buy (MsgBuy) returns (MsgBuyResponse);

Expand Down Expand Up @@ -104,6 +107,19 @@ message MsgUpdateSellOrders {
// MsgUpdateSellOrdersResponse is the Msg/UpdateSellOrders response type.
message MsgUpdateSellOrdersResponse {}

// MsgCancelSellOrder is the Msg/CancelSellOrder request type.
message MsgCancelSellOrder {

// seller is the address of the seller.
string seller = 1;

// sell_order_id is the id of the seller order to cancel.
uint64 sell_order_id = 2;
}

// MsgCancelSellOrder is the Msg/CancelSellOrder response type.
message MsgCancelSellOrderResponse {}

// MsgBuy is the Msg/Buy request type.
message MsgBuy {

Expand Down
3 changes: 2 additions & 1 deletion x/ecocredit/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ require (
github.com/gogo/protobuf v1.3.3
github.com/golang/mock v1.6.0
github.com/golang/protobuf v1.5.2
github.com/google/go-cmp v0.5.7
github.com/gorilla/mux v1.8.0
github.com/grpc-ecosystem/grpc-gateway v1.16.0
github.com/pkg/errors v0.9.1
Expand Down Expand Up @@ -68,7 +69,6 @@ require (
github.com/gogo/gateway v1.1.0 // indirect
github.com/golang/snappy v0.0.3 // indirect
github.com/google/btree v1.0.0 // indirect
github.com/google/go-cmp v0.5.7 // indirect
github.com/google/orderedcode v0.0.1 // indirect
github.com/gorilla/handlers v1.5.1 // indirect
github.com/gorilla/websocket v1.4.2 // indirect
Expand Down Expand Up @@ -125,6 +125,7 @@ require (
golang.org/x/sys v0.0.0-20210917161153-d61c044b1678 // indirect
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 // indirect
golang.org/x/text v0.3.7 // indirect
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
gopkg.in/ini.v1 v1.63.2 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
Expand Down
Loading