Updated readme, install and other documentation, changed panel() to site() since it makes more sense that way with netbox. started fixing authentication, hostfact had a login method, but netbox does not, but the user model provides a password that we can authenticate against.

This commit is contained in:
Tony Roy 2021-03-13 14:34:15 -04:00
commit 0df9b15379
7 changed files with 120 additions and 92 deletions

View file

@ -64,7 +64,7 @@ class Client
'tags' => 'Extras\Tags',
//ipam
'aggregates' => 'IPAM\Aggregates'
'aggregates' => 'IPAM\Aggregates',
'ipAddresses' => 'IPAM\IpAddresses',
'prefixes' => 'IPAM\Prefixes',
'rirs' => 'IPAM\Rirs',
@ -131,9 +131,7 @@ class Client
if (!isset($this->classes[$name])) {
throw new \InvalidArgumentException(sprintf('Undefined method called:"%s"', $name));
}
$class = '\\wickedsoft\\NetBox\\Api\\' . $this->classes[$name];
return new $class($this);
}
@ -145,9 +143,7 @@ class Client
if (!isset($this->httpClient)) {
$this->httpClient = new HttpClient();
}
$this->httpClient->setOptions($this->getOptions());
return $this->httpClient;
}