add factory get view

This commit is contained in:
owen05
2020-12-08 22:52:10 +08:00
parent 26b5cf2971
commit e8d83b947b
2 changed files with 16 additions and 0 deletions

View File

@@ -159,4 +159,12 @@ contract DPPFactory is Ownable {
{
return (_REGISTRY_[token0][token1], _REGISTRY_[token1][token0]);
}
function getPrivatePoolByUser(address user)
external
view
returns (address[] memory pools)
{
return _USER_REGISTRY_[user];
}
}

View File

@@ -131,4 +131,12 @@ contract DVMFactory is Ownable {
{
return (_REGISTRY_[token0][token1], _REGISTRY_[token1][token0]);
}
function getVendingMachineByUser(address user)
external
view
returns (address[] memory machines)
{
return _USER_REGISTRY_[user];
}
}