@@ -42,6 +42,8 @@ import {
4242 nftSafeSigningInq ,
4343 nftValidateCurrentAuthorityInq ,
4444 nftUpdateTryFailuresInq ,
45+ nftMintListInq ,
46+ nftTransferDestinationInq ,
4547} from "./inq/index.js" ;
4648
4749import API from "./api.js" ;
@@ -738,6 +740,8 @@ class Menu{
738740 this . nftAuthorityChange ( ms ) ;
739741 } else if ( action === 1 ) {
740742 this . nftValidateMetaAuthorities ( ms ) ;
743+ } else if ( action === 2 ) {
744+ this . nftBatchTransfer ( ms ) ;
741745 } else {
742746 this . multisig ( ms ) ;
743747 }
@@ -1016,6 +1020,29 @@ class Menu{
10161020 }
10171021 this . nfts ( ms ) ;
10181022 }
1023+
1024+ nftBatchTransfer = async ( ms : any ) => {
1025+ clear ( ) ;
1026+ const [ vault ] = await getAuthorityPDA ( ms . publicKey , new BN ( 1 ) , this . api . programId ) ;
1027+ this . header ( vault ) ;
1028+ const { mintList} = await nftMintListInq ( ) ;
1029+ if ( mintList && mintList . length > 0 ) {
1030+ const status = new Spinner ( "Loading the mint list..." ) ;
1031+ status . start ( ) ;
1032+ const mints = await loadNFTMints ( mintList ) ;
1033+ status . stop ( ) ;
1034+ // should check that the vault actually owns these
1035+ console . log ( JSON . stringify ( mints ) ) ;
1036+ const { destination} = await nftTransferDestinationInq ( ) ;
1037+ if ( destination && destination . length > 0 ) {
1038+ console . log ( 'destination: ' + destination ) ;
1039+ console . log ( 'current vault' , vault . toBase58 ( ) ) ;
1040+ }
1041+ }
1042+
1043+ // this goes back to main nft menu
1044+ // this.nfts(ms);
1045+ }
10191046} ;
10201047
10211048export default Menu ;
0 commit comments