added --include_is_my_output to claim_search

This commit is contained in:
Lex Berezhny 2020-03-22 01:51:09 -04:00
parent b5c24d6a48
commit 09644914a6
2 changed files with 8 additions and 3 deletions

View file

@ -2249,7 +2249,7 @@ class Daemon(metaclass=JSONRPCServerType):
[--any_locations=<any_locations>...] [--all_locations=<all_locations>...]
[--not_locations=<not_locations>...]
[--order_by=<order_by>...] [--page=<page>] [--page_size=<page_size>]
[--wallet_id=<wallet_id>] [--include_purchase_receipt]
[--wallet_id=<wallet_id>] [--include_purchase_receipt] [--include_is_my_output]
Options:
--name=<name> : (str) claim name (normalized)
@ -2353,6 +2353,8 @@ class Daemon(metaclass=JSONRPCServerType):
--wallet_id=<wallet_id> : (str) wallet to check for claim purchase reciepts
--include_purchase_receipt : (bool) lookup and include a receipt if this wallet
has purchased the claim
--include_is_my_output : (bool) lookup and include a boolean indicating
if claim being resolved is yours
Returns: {Paginated[Output]}
"""

View file

@ -732,9 +732,12 @@ class Ledger(metaclass=LedgerRegistry):
return result
async def claim_search(
self, accounts, include_purchase_receipt=False, **kwargs) -> Tuple[List[Output], dict, int, int]:
self, accounts, include_purchase_receipt=False, include_is_my_output=False,
**kwargs) -> Tuple[List[Output], dict, int, int]:
return await self._inflate_outputs(
self.network.claim_search(**kwargs), accounts, include_purchase_receipt=include_purchase_receipt
self.network.claim_search(**kwargs), accounts,
include_purchase_receipt=include_purchase_receipt,
include_is_my_output=include_is_my_output
)
async def get_claim_by_claim_id(self, accounts, claim_id) -> Output: