mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 19:04:52 +00:00
Add move/transfer assets
Add ability to move / transfer assets between clients. Moving an asset involves the asset being archived and then re-created under the new client with most of the same information. Information about the old & new asset is stored in the audit logs and within the asset notes. Information from the audit logs is accessible via a new History tab on the asset, subject to audit log retention.
This commit is contained in:
@@ -29,6 +29,9 @@
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="pill" href="#pills-notes<?php echo $asset_id; ?>">Notes</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="pill" href="#pills-history<?php echo $asset_id; ?>">History</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<hr>
|
||||
@@ -386,6 +389,32 @@
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="tab-pane fade" id="pills-history<?php echo $asset_id; ?>">
|
||||
|
||||
<?php $sql_history = mysqli_query($mysqli, "SELECT * FROM logs WHERE log_type = 'asset' and log_entity_id = $asset_id and log_client_id = $client_id"); ?>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Asset History</label>
|
||||
|
||||
<ul>
|
||||
|
||||
<?php
|
||||
while ($row = mysqli_fetch_array($sql_history)) {
|
||||
$log_action = nullable_htmlentities(($row['log_action']));
|
||||
$log_description = nullable_htmlentities(($row['log_description']));
|
||||
$log_created_at = nullable_htmlentities(($row['log_created_at']));
|
||||
echo "<li>$log_created_at - $log_action: $log_description</li>";
|
||||
}
|
||||
?>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer bg-white">
|
||||
|
||||
Reference in New Issue
Block a user