How to manage inventory assigned to employees
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
This is a very common requirement. Customers want to manage the laptop/computer inventory assigned to employees.
In the following scenario, there are two objects Type:
Employee
Computer
Computers are assigned to employees and Computer objects have an attribute called Status.
If a Computer object is assigned to any Employee object the status is not equal to Free.
We need to write an AQL that only lists the computers that have the status set as Free when assigning any computer to an employee object.
Environment
Any Insight / Assets Version
Solution
You can write an AQL on the Computer attribute of the Employee object as below.
1
"Status=Free OR object having inboundReferences(Name = ${Name})"
Note: This will only work given the scenario that Computer objects are always unassigned from a Person before the status is changed to Free.
Was this helpful?