Skip to content

Commit

Permalink
Merge pull request #1827 from Giveth/hotfix_add_solana_to_adminjs_forms
Browse files Browse the repository at this point in the history
Add chaintype and solana networks to tokenTab
  • Loading branch information
CarlosQ96 authored Sep 17, 2024
2 parents 2a564a3 + 2674708 commit bfdc9d8
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

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

21 changes: 21 additions & 0 deletions src/server/adminJs/tabs/tokenTab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { AdminJsRequestInterface } from '../adminJs-types';
import { Organization } from '../../../entities/organization';
import { logger } from '../../../utils/logger';
import { findTokenByTokenId } from '../../../repositories/tokenRepository';
import { ChainType } from '../../../types/network';

// generates orderly permutations and maps then into an array which is later flatten into 1 dimension
// Current length is the length of selected items from the total items
Expand Down Expand Up @@ -210,6 +211,18 @@ export const generateTokenTab = async () => {
value: NETWORK_IDS.MORDOR_ETC_TESTNET,
label: 'Ethereum Classic Testnet',
},
{
value: NETWORK_IDS.SOLANA_MAINNET,
label: 'SOLANA MAINNET',
},
{
value: NETWORK_IDS.SOLANA_TESTNET,
label: 'SOLANA TESTNET',
},
{
value: NETWORK_IDS.SOLANA_DEVNET,
label: 'SOLANA DEVNET',
},
],
},
symbol: { isVisible: true },
Expand All @@ -225,6 +238,14 @@ export const generateTokenTab = async () => {
filter: true,
},
},
chainType: {
isVisible: true,
availableValues: [
{ value: ChainType.EVM, label: 'EVM' },
{ value: ChainType.SOLANA, label: 'SOLANA' },
{ value: ChainType.STELLAR, label: 'STELLAR' },
],
},
coingeckoId: {
isVisible: {
show: true,
Expand Down

0 comments on commit bfdc9d8

Please sign in to comment.