31 if (!$this->service || !$this->service->isSupportPrintCheck())
36 $cashboxList = Sale\Cashbox\Manager::getList([
37 'select' => [
'ID',
'KKM_ID'],
39 '=HANDLER' => $this->service->getCashboxClass(),
40 '=KKM_ID' => $this->kkmId,
43 foreach ($cashboxList as $cashboxItem)
45 $cashboxId = $cashboxItem[
'ID'];
46 $serviceCashbox = Sale\Cashbox\Manager::getObjectById($cashboxId);
47 if (
Sale\
Cashbox\Manager::isCashboxChecksExist($cashboxId))
49 Sale\Cashbox\Manager::deactivateCashbox($cashboxId);
53 $deleteResult = Sale\Cashbox\Manager::delete($cashboxId);
54 if ($deleteResult->isSuccess())
56 AddEventToStatFile(
'sale',
'deleteCashbox',
'', $serviceCashbox::getCode());
60 $result->addErrors($deleteResult->getErrors());