Ejemplo n.º 1
0
	keys_ids["118"] = "#VentaShortcut"; //letra v corta
	keys_ids["105"] = "#InventarioShortcut";
	keys_ids["99"] = "#CompraShortcut";	
	function shortcut(key) {
		if (keys_ids[key])
			window.location = $(keys_ids[key]).attr("href");

	}

	var new_purchase_shortcut = '<?php 
echo NEW_PURCHASE_SHORTCUT;
?>
'; 
	var new_sell_shortcut = '<?php 
echo NEW_SELL_SHORTCUT;
?>
'; 
	var goto_inventory_shortcut = '<?php 
echo GOTO_INVENTORY_SHORTCUT;
?>
'; 
			
	$(document).bind('keydown', new_purchase_shortcut, function() { shortcut(99);}); //nueva compra
	$(document).bind('keydown', new_sell_shortcut, function() { shortcut(118);}); //nueva venta
	$(document).bind('keydown', goto_inventory_shortcut, function() { shortcut(105);}); //ir a inventario


</script>
<?php 
echo html_control_panel($page_id, $cp_boxes);
Ejemplo n.º 2
0
<?php

// +-----------------------------------------------------------------+
// |                   PhreeBooks Open Source ERP                    |
// +-----------------------------------------------------------------+
// | Copyright (c) 2008 PhreeSoft, LLC                               |
// | http://www.PhreeSoft.com                                        |
// +-----------------------------------------------------------------+
// | This program is free software: you can redistribute it and/or   |
// | modify it under the terms of the GNU General Public License as  |
// | published by the Free Software Foundation, either version 3 of  |
// | the License, or any later version.                              |
// |                                                                 |
// | This program is distributed in the hope that it will be useful, |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of  |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the   |
// | GNU General Public License for more details.                    |
// |                                                                 |
// | The license that is bundled with this package is located in the |
// | file: /doc/manual/ch01-Introduction/license.html.               |
// | If not, see http://www.gnu.org/licenses/                        |
// +-----------------------------------------------------------------+
//  Path: /modules/assets/pages/cat_assets/template_main.php
//
// display alerts/error messages, if any since the toolbar is not shown
if ($messageStack->size > 0) {
    echo $messageStack->output();
}
echo html_control_panel($module, $cp_boxes);