예제 #1
0
 public function assign_context_menu($task_id)
 {
     $context_menu = $this->create_context_menu($task_id);
     $wintask = new api_wintask();
     $wintask->setContextMenu($context_menu);
     $this->jquery .= $wintask->contextMenuRender('phpos_task_' . $task_id, 'div', 'left');
 }
예제 #2
0
?>
_phpos/themes/default/phposAPI_installer.css" />
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
<meta http-equiv="Expires" content="0" />
<meta http-equiv="Cache-Control" content="no-store, no-cache, must-revalidate" />
<meta http-equiv="Cache-Control" content="post-check=0, pre-check=0" />
<meta http-equiv="Pragma" content="no-cache" />

</head>
<body>
<?php 
// Language switch
$in_login = 1;
include PHPOS_DIR . 'plugins/tray.languages.php';
$wintask = new api_wintask();
$wintask->setContextMenu($tray['context_menu']);
$js_context_menu = $wintask->contextMenuRender('lang', 'div', 'hover');
?>
		
		
		<div id="lang" title="<?php 
echo $tray['title'];
?>
" class="phpos_tray_item phpos_tray_item_mouseleave">
			<div>
				<img src="<?php 
echo $tray['icons'][0];
?>
" /> 
				<span><b style="color:white"><?php 
echo strtoupper($_SESSION['installer_lang']);
require PHPOS_DIR . 'plugins/fs.db_mysqlPlugin.php';
//$filesystem_class = 'phpos_fs_plugin_'.$my_app->get_param('fs');
$phposFS = new phpos_fs_plugin_db_mysql();
// start filesytem
$config = new phpos_config();
$config->set_id_user();
$shortcut = new phpos_shortcuts();
$startmenu = new phpos_startmenu();
$records = $startmenu->get_all();
$i = 1;
foreach ($records as $item) {
    if ($shortcut->is_shortcut($item['id_file'])) {
        $row = $shortcut->get_shortcut($item['id_file']);
        $icon = $shortcut->link_icon($row['plugin_id'], $row['app_id'], $row['icon'], $row['app_action']);
        $app_action = 'app_id:' . $row['app_id'] . '@' . $row['app_action'];
        $action = winopen($row['file_title'], $row['plugin_id'], $app_action, $row['app_params']);
        $context_menu = array('delete::' . txt('del_from_start') . '::delete_menustart_item("' . $item['id'] . '");::delete');
        $apiWindow = new api_wintask();
        $apiWindow->setContextMenu($context_menu);
        $js .= $apiWindow->contextMenuRender('startmenu_left_item_' . $i, 'img');
        $apiWindow->resetContextMenu();
        $items .= '<div id="startmenu_left_item_' . $i . '" class="startmenu_left_item" onclick="' . $action . '"><img src="' . $icon . '"><span>' . $row['file_title'] . '</span></div>';
        $i++;
    }
}
$js .= "\n function delete_menustart_item(delete_id)\n {\n\t\tphpos.managerWindows('action=delete_start_item&item_id='+delete_id);\n\t\tphpos.menustartClose();\n  }\n\t";
$my_app = new phpos_app();
jquery_function($js);
jquery_onready($js_delete);
include PHPOS_DIR . 'views/startmenuView.php';
echo $my_app->render_javascript_jquery();