mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-03-13 04:33:30 -04:00
68 lines
2.2 KiB
PHP
68 lines
2.2 KiB
PHP
<?php $this->load->view("partial/header"); ?>
|
|
|
|
<script type="text/javascript">
|
|
$(document).ready(function()
|
|
{
|
|
<?php $this->load->view('partial/bootstrap_tables_locale'); ?>
|
|
|
|
table_support.init({
|
|
resource: '<?php echo site_url($controller_name);?>',
|
|
headers: <?php echo $table_headers; ?>,
|
|
pageSize: <?php echo $this->config->item('lines_per_page'); ?>,
|
|
uniqueId: 'person_id',
|
|
confirmDeleteMessage : '<?php echo $this->lang->line($controller_name."_confirm_delete")?>',
|
|
enableActions: function()
|
|
{
|
|
var email_disabled = $("tr.selected a[href^='mailto:']").length == 0;
|
|
$("#email").attr('disabled', email_disabled);
|
|
}
|
|
});
|
|
|
|
$("#email").click(function(evvent)
|
|
{
|
|
var recipients = $.map($("tr.selected a[href^='mailto:']"), function(element)
|
|
{
|
|
return $(element).attr('href').replace(/^mailto:/, '');
|
|
});
|
|
location.href = "mailto:" + recipients.join(",");
|
|
});
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
<div id="title_bar" class="btn-toolbar">
|
|
<?php
|
|
if ($controller_name == 'customers')
|
|
{
|
|
?>
|
|
<button class='btn btn-info btn-sm pull-right modal-dlg modal-btn-submit' data-href='<?php echo site_url($controller_name."/excel_import"); ?>'
|
|
title='<?php echo $this->lang->line('customers_import_items_excel'); ?>'>
|
|
<span class="glyphicon glyphicon-import"> </span><?php echo $this->lang->line('common_import_excel'); ?>
|
|
</button>
|
|
<?php
|
|
}
|
|
?>
|
|
<button class='btn btn-info btn-sm pull-right modal-dlg modal-btn-submit' data-href='<?php echo site_url($controller_name."/view"); ?>'
|
|
title='<?php echo $this->lang->line($controller_name. '_new'); ?>'>
|
|
<span class="glyphicon glyphicon-user"> </span><?php echo $this->lang->line($controller_name. '_new'); ?>
|
|
</button>
|
|
</div>
|
|
|
|
<div id="toolbar">
|
|
<div class="pull-left btn-toolbar">
|
|
<button id="delete" class="btn btn-default btn-sm">
|
|
<span class="glyphicon glyphicon-trash"> </span><?php echo $this->lang->line("common_delete");?>
|
|
</button>
|
|
<button id="email" class="btn btn-default btn-sm">
|
|
<span class="glyphicon glyphicon-envelope"> </span><?php echo $this->lang->line("common_email");?>
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="table_holder">
|
|
<table id="table"></table>
|
|
</div>
|
|
|
|
<?php $this->load->view("partial/footer"); ?>
|