Skip to content

Commit

Permalink
Feature: Implement Search Functionality for Crypto Market (#522)
Browse files Browse the repository at this point in the history
fix search token in token info
  • Loading branch information
waelhanfi04 authored Sep 18, 2023
1 parent 7c6e9e6 commit 5ad7300
Show file tree
Hide file tree
Showing 3 changed files with 245 additions and 178 deletions.
10 changes: 9 additions & 1 deletion src/app/core/services/wallet/cryptofetch-service.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,15 @@ export class CryptofetchServiceService {
const params = new HttpParams().set('cryptochunk', pageNumber);

// Making the HTTP GET request
return this.http.get( sattUrl + '/wallet/getallCrypto', { params });
return this.http.get(sattUrl + '/wallet/getallCrypto', { params });
}

searchCryptoMarket(value: string): Observable<any> {
const requestBody = { value };
return this.http.post<any>(
sattUrl + '/wallet/searchCryptoMarket',
requestBody
);
}

transactionHistory() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ <h1 class="crypto-market-cap-title mb-0">
class="search-query d-flex mt-3"
type="text"
name="search"
placeholder="{{ 'searchToken' | translate }}
"
placeholder="{{ 'searchToken' | translate }}"
(input)="onInputChange($event)"
/>
<span *ngIf="searchQuery" class="clear-icon" (click)="clear()">x</span>
</div>
Expand Down
Loading

0 comments on commit 5ad7300

Please sign in to comment.