contract AuctionMarket is Market {
	
    constructor() ERC721("NvirWorld", "Nvir") {
        
    }
	
	//경매 판매 생성
    function auctionMint(string memory _tokenURI, address _toAddress,uint _minValue,uint _auctionTime) public returns (uint) {
        uint _tokenId = totalSupply() + 1;
        price[_tokenId] = _minValue;

        _safeMint(_toAddress, _tokenId);
        _setTokenURI(_tokenId, _tokenURI);

        emit Minted(_toAddress, _minValue, _tokenId, _tokenURI);
		
		_createAuction(_tokenId,_minValue,_auctionTime);
        return _tokenId;
    }
	
	//경매생성
    function createAuction(uint _tokenId, uint _minValue,uint _auctionTime)  public virtual {
		require(listedMap[_tokenId] == false); // 즉시판매 진행중
		
		_createAuction(_tokenId,_minValue,_auctionTime);
    }
	
	//경매취소
	function cancelAuction(uint _tokenId)  public virtual {
		
		_cancelAuction(_tokenId);
	}	
	
	//입찰
	function bid(uint _tokenId) external payable {
		_bid(_tokenId);
	}
	
		//입찰취소
	function cancelBid(uint _tokenId) external payable {
		
		_cancelBid(_tokenId);
	}	
		
	//경매종료
	function endAuction(uint _tokenId) external payable {
		
		_endAuction(_tokenId);
	}
	

	
}
function createAuction(uint _tokenId, uint _minValue,uint _auctionTime)  public virtual {
quire(listedMap[_tokenId] == false); // 즉시판매 진행중
		
reateAuction(_tokenId,_minValue,_auctionTime);
}

//경매생성