Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

Commit

Permalink
inventory infos should not be displayed on computer creation (id <= 0) (
Browse files Browse the repository at this point in the history
  • Loading branch information
orthagh authored and Walid committed Oct 30, 2017
1 parent b4e071d commit 6f0b819
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion inc/inventorycomputercomputer.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,8 @@ function hasAutomaticInventory($computers_id) {
static function showFormForAgentWithNoInventory($item) {
$id = $item->getID();
$pfComputer = new self();
if (!empty($pfComputer->hasAutomaticInventory($id))) {
if ($item->isNewItem()
|| !empty($pfComputer->hasAutomaticInventory($id))) {
return true;
} else {
$pfAgent = new PluginFusioninventoryAgent();
Expand Down

0 comments on commit 6f0b819

Please sign in to comment.