public function deleteStockIssueAction() { $this->_helper->layout->disableLayout(); $this->_helper->viewRenderer->setNoRender(TRUE); if ($this->_request->isPost()) { $batch_id = $this->_request->b_id; $loc_id = $this->_request->loc_id; $vvm_stage_id = $this->_request->vvm_id; $qty_issued = $this->_request->qty_issued; $item_cat_id = $this->_request->item_cat_id; if ($item_cat_id == 1) { $loc_type = Model_PlacementLocations::LOCATIONTYPE_CCM; } else { $loc_type = Model_PlacementLocations::LOCATIONTYPE_NONCCM; } $placement_locations = $this->_em->getRepository("PlacementLocations")->findBy(array("locationId" => $loc_id, "locationType" => $loc_type)); $placement_loc_id = $placement_locations[0]->getPkId(); $placement_details = $batch_id . "|" . $placement_loc_id . "|" . $vvm_stage_id . "|" . $qty_issued; $placement_type = Model_PlacementLocations::PLACEMENT_TRANSACTION_TYPE_P; $placement = new Model_Placements(); $flag = $placement->updateStockPlacement($placement_details, $placement_type); if ($flag) { $this->redirect("/stock/issue-search"); exit; } } }