<?php $pageTitle='Container types';
/** @noinspection PhpUnhandledExceptionInspection */
$showCreateLink = session::isAdmin() || platetype::canCreate();
include realpath(__DIR__).'/../../core/_common/header.php'; ?>
<script type="text/javascript">
window.addEventListener('DOMContentLoaded',function(){


    const headers = ['Name', 'Positions', 'Category'];
    const cellTemplates = [
        '<a href="/containertype/{{id}}">{{name}}</a>',
        '{{positions}}',
        '<a href="/containercategory/{{containercategoryid}}">{{containercategoryname}}</a>'
    ];

    ui.grid().box({
		classes:'r1 c1 h3 w3',
		url:'/api/containertype',
		headers:headers,
		cellTemplates:cellTemplates
	});


});
</script>
<?php include realpath(__DIR__).'/../../core/_common/footer.php';