Skip to content

Commit

Permalink
LIMS-59: Write a location to DTH when marking a dewar as unprocessing
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark Williams committed Jun 26, 2023
1 parent 05514ca commit f53b4ff
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions api/src/Model/Services/AssignData.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,10 @@ function updateDewar($dewarId, $status)

function deactivateDewar($dewarId)
{
$this->updateDewarHistory($dewarId, 'unprocessing');
$location = $this->db->pq("SELECT storagelocation FROM dewar WHERE dewarid=:1", array($dewarId));
$this->updateDewarHistory($dewarId, 'unprocessing', $location[0]['STORAGELOCATION']);

$conts = $this->db->pq("SELECT containerid as id FROM container WHERE dewarid=:1", array($dewarId));
$conts = $this->db->pq("SELECT containerid FROM container WHERE dewarid=:1", array($dewarId));
foreach ($conts as $container)
{
$this->updateContainerAndHistory($container['CONTAINERID'], 'at facility', '', '');
Expand All @@ -113,4 +114,4 @@ function getContainerBarcodesForProposal($proposalId)
INNER JOIN containerregistry_has_proposal crhp ON crhp.containerregistryid = cr.containerregistryid
WHERE crhp.proposalid = :1", array($proposalId));
}
}
}

0 comments on commit f53b4ff

Please sign in to comment.