<style>
	#hlsgrid_${id}{
		width:${width!};
	}
</style>
<div id="hlsgrid_${id}" class="hlsgrid ${hlsClassName!}">
	<#include "Grid.ftl"/>
</div>
<script>
	$("#${id}").data('kendoGrid').wrapper.on('click.kendoGrid','.hlsgrid-btn-delete', function(e) {
		var grid = $("#${id}").data('kendoGrid'), data = grid.dataItem($(e.target).closest('tr'));
		kendo.ui.showConfirmDialog({
            title: $l('hap.tip.info'),
            message: $l('hap.tip.delete_confirm')
        }).done(function (event) {
            if(event.button =="OK"){
             	if(!grid.trigger("remove",data)){
	           		grid.dataSource.remove(data);
			  	 	grid.dataSource.sync();
             	}else{
             		if(data.row_clear_flag){
             			grid.dataSource.remove(data);
             		}
             	};
            }
        })
 	});
</script>