<?php
/** @var \Magento\Sales\Block\Adminhtml\Order\Invoice\View\Items $block*/

//echo get_class($block);
$_order = $block->getOrder();
$items = $block->getInvoice()->getAllItems();
$invoice = $block->getSource();
echo $block->getLayout()->createBlock('Magetop\Advancepreview\Block\Adminhtml\Order\View\CustomItems')->setData(array('order'=>$_order, 'invoice'=>$invoice))->setTemplate('Magetop_Advancepreview::order/invoice/view/custom-items.phtml')->toHtml();

?>
