implemented enble == 4 type apps - opened in a popup window - for the manual

This commit is contained in:
Ralf Becker 2004-04-13 07:54:25 +00:00
parent d943b9f59d
commit b495aa7a0f
3 changed files with 13 additions and 5 deletions

View File

@ -38,7 +38,7 @@
function get_list() function get_list()
{ {
$this->db->query('SELECT * FROM phpgw_applications WHERE app_enabled<3',__LINE__,__FILE__); $this->db->query('SELECT * FROM phpgw_applications WHERE app_enabled!=3',__LINE__,__FILE__);
if($this->db->num_rows()) if($this->db->num_rows())
{ {
while ($this->db->next_record()) while ($this->db->next_record())

View File

@ -243,7 +243,8 @@
$selected[$n_app_status] = ' selected'; $selected[$n_app_status] = ' selected';
$status_html = '<option value="0"' . $selected[0] . '>' . lang('Disabled') . '</option>' $status_html = '<option value="0"' . $selected[0] . '>' . lang('Disabled') . '</option>'
. '<option value="1"' . $selected[1] . '>' . lang('Enabled') . '</option>' . '<option value="1"' . $selected[1] . '>' . lang('Enabled') . '</option>'
. '<option value="2"' . $selected[2] . '>' . lang('Enabled - Hidden from navbar') . '</option>'; . '<option value="2"' . $selected[2] . '>' . lang('Enabled - Hidden from navbar') . '</option>'
. '<option value="4"' . $selected[4] . '>' . lang('Enabled - Popup Window') . '</option>';
$this->display_row(lang('Status'),'<select name="n_app_status">' . $status_html . '</select>'); $this->display_row(lang('Status'),'<select name="n_app_status">' . $status_html . '</select>');
if (!$app_order) if (!$app_order)
@ -348,7 +349,8 @@
$selected[$n_app_status] = ' selected'; $selected[$n_app_status] = ' selected';
$status_html = '<option value="0"' . $selected[0] . '>' . lang('Disabled') . '</option>' $status_html = '<option value="0"' . $selected[0] . '>' . lang('Disabled') . '</option>'
. '<option value="1"' . $selected[1] . '>' . lang('Enabled') . '</option>' . '<option value="1"' . $selected[1] . '>' . lang('Enabled') . '</option>'
. '<option value="2"' . $selected[2] . '>' . lang('Enabled - Hidden from navbar') . '</option>'; . '<option value="2"' . $selected[2] . '>' . lang('Enabled - Hidden from navbar') . '</option>'
. '<option value="4"' . $selected[4] . '>' . lang('Enabled - Popup Window') . '</option>';
$this->display_row(lang("Status"),'<select name="n_app_status">' . $status_html . '</select>'); $this->display_row(lang("Status"),'<select name="n_app_status">' . $status_html . '</select>');
$this->display_row(lang("Select which location this app should appear on the navbar, lowest (left) to highest (right)"),'<input name="app_order" value="' . $app_order . '">'); $this->display_row(lang("Select which location this app should appear on the navbar, lowest (left) to highest (right)"),'<input name="app_order" value="' . $app_order . '">');

View File

@ -197,7 +197,7 @@
function getPreferredLanguage() function getPreferredLanguage()
{ {
// create a array of languages the user is accepting // create a array of languages the user is accepting
$userLanguages = explode(',',$GLOBALS['HTTP_ACCEPT_LANGUAGE']); $userLanguages = explode(',',$_SERVER['HTTP_ACCEPT_LANGUAGE']);
$supportedLanguages = $this->getInstalledLanguages(); $supportedLanguages = $this->getInstalledLanguages();
// find usersupported language // find usersupported language
@ -1102,6 +1102,12 @@
$GLOBALS['phpgw_info']['navbar'][$app]['url'] = $GLOBALS['phpgw']->link('/' . $app . '/index.php'); $GLOBALS['phpgw_info']['navbar'][$app]['url'] = $GLOBALS['phpgw']->link('/' . $app . '/index.php');
$GLOBALS['phpgw_info']['navbar'][$app]['name'] = $app; $GLOBALS['phpgw_info']['navbar'][$app]['name'] = $app;
// create popup target
if ($data['status'] == 4)
{
$GLOBALS['phpgw_info']['navbar'][$app]['target'] = ' target="'.$app.'" onClick="'."if (this != '') { window.open(this,this.target,'width=800,height=600,scrollbars=yes,resizable=yes'); return false; } else { return true; }".'"';
}
if ($app != $GLOBALS['phpgw_info']['flags']['currentapp']) if ($app != $GLOBALS['phpgw_info']['flags']['currentapp'])
{ {
$GLOBALS['phpgw_info']['navbar'][$app]['icon'] = $this->image($app,Array('navbar','nonav')); $GLOBALS['phpgw_info']['navbar'][$app]['icon'] = $this->image($app,Array('navbar','nonav'));
@ -1121,7 +1127,7 @@
} }
if ($GLOBALS['phpgw_info']['flags']['currentapp'] == 'home' || $GLOBALS['phpgw_info']['flags']['currentapp'] == 'preferences' || $GLOBALS['phpgw_info']['flags']['currentapp'] == 'about') if ($GLOBALS['phpgw_info']['flags']['currentapp'] == 'home' || $GLOBALS['phpgw_info']['flags']['currentapp'] == 'preferences' || $GLOBALS['phpgw_info']['flags']['currentapp'] == 'about')
{ {
$app = $app_title = 'phpGroupWare'; $app = $app_title = 'eGroupWare';
} }
else else
{ {