<?php
include 'header.php';
include('xcrud/xcrud.php');
echo Xcrud::load_css();
$xcrud=Xcrud::get_instance();
$xcrud->table('customer_menu');
$xcrud->validation_required('menu_id,filename,added_by');
$xcrud->relation('customer_id','customer','customer_id','name');
$xcrud->relation('menu_id','menu','menu_id','menu_name');
$xcrud->relation('menu_option_id','menu_option','menu_option_id','name','','','',' ','','menu_id','menu_id');
$xcrud->relation('added_by','user','user_id','name');
//$xcrud->pass_default('added_by',$_SESSION['admin_id']);
$xcrud->unset_title();
$xcrud->unset_add();
$xcrud->label('customer_id','Customer');
$xcrud->label('menu_id','Menu');
$xcrud->label('menu_option_id','Sub Menu');
//$xcrud->change_type('filename','file','',array('path'=>'../uploads/2018/krishna-987'));
?>
<div class="row">
	<div class="col-sm-12"><button class="btn btn-blue btn-block">Documents</button></div>
	<div class="col-sm-12">&nbsp</div>
	<div class="col-sm-12">
<?php
echo $xcrud->render();
?>
	</div>
</div>
</div>
</div>
</div>
<?php
include "footer.php";
echo Xcrud::load_js();
?>