Change phpgwapi app enable to 3, set navbar to ignore 2 & 3, add notifywindow app

with enable of 2, adjust admin tools to ignore enable of 3, not 2
This commit is contained in:
Miles Lott 2001-06-07 11:28:31 +00:00
parent 8186e6bf58
commit 548b5ba431
8 changed files with 25 additions and 15 deletions

View File

@ -25,16 +25,16 @@
if ($order) if ($order)
{ {
$ordermethod = "order by $order $sort"; $ordermethod = "ORDER BY $order $sort";
} }
else else
{ {
$ordermethod = "order by app_title asc"; $ordermethod = "ORDER BY app_title ASC";
} }
if (!$sort) if (!$sort)
{ {
$sort = "desc"; $sort = "DESC";
} }
$p->set_var('lang_installed',lang('Installed applications')); $p->set_var('lang_installed',lang('Installed applications'));
@ -46,7 +46,7 @@
$p->set_var('lang_delete',lang('Delete')); $p->set_var('lang_delete',lang('Delete'));
$p->set_var('lang_enabled',lang('Enabled')); $p->set_var('lang_enabled',lang('Enabled'));
$phpgw->db->query("select * from phpgw_applications $ordermethod",__LINE__,__FILE__); $phpgw->db->query("SELECT * FROM phpgw_applications WHERE app_enabled!='3' $ordermethod",__LINE__,__FILE__);
while ($phpgw->db->next_record()) while ($phpgw->db->next_record())
{ {
$tr_color = $phpgw->nextmatchs->alternate_row_color($tr_color); $tr_color = $phpgw->nextmatchs->alternate_row_color($tr_color);
@ -57,6 +57,7 @@
$p->set_var('tr_color',$tr_color); $p->set_var('tr_color',$tr_color);
$p->set_var('name',$name); $p->set_var('name',$name);
$p->set_var('edit','<a href="' . $phpgw->link('/admin/editapplication.php','app_name=' . urlencode($phpgw->db->f('app_name'))) . '"> ' . lang('Edit') . ' </a>'); $p->set_var('edit','<a href="' . $phpgw->link('/admin/editapplication.php','app_name=' . urlencode($phpgw->db->f('app_name'))) . '"> ' . lang('Edit') . ' </a>');
$p->set_var('delete','<a href="' . $phpgw->link('/admin/deleteapplication.php','app_name=' . urlencode($phpgw->db->f('app_name'))) . '"> ' . lang('Delete') . ' </a>'); $p->set_var('delete','<a href="' . $phpgw->link('/admin/deleteapplication.php','app_name=' . urlencode($phpgw->db->f('app_name'))) . '"> ' . lang('Delete') . ' </a>');

View File

@ -173,7 +173,7 @@
@reset($availableApps); @reset($availableApps);
while ($application = each($availableApps)) while ($application = each($availableApps))
{ {
if ($application[1]['enabled'] && $application[1]['status'] != 2) if ($application[1]['enabled'] && $application[1]['status'] != 3)
{ {
$perm_display[$i]['appName'] = $application[0]; $perm_display[$i]['appName'] = $application[0];
$perm_display[$i]['translatedName'] = $application[1]['title']; $perm_display[$i]['translatedName'] = $application[1]['title'];

View File

@ -238,7 +238,7 @@
@reset($sorted_apps); @reset($sorted_apps);
while ($permission = each($sorted_apps)) while ($permission = each($sorted_apps))
{ {
if ($permission[1]['enabled'] && $permission[1]['status'] != 2) if ($permission[1]['enabled'] && $permission[1]['status'] != 3)
{ {
$perm_display[$i][0] = $permission[0]; $perm_display[$i][0] = $permission[0];
$perm_display[$i][1] = $permission[1]['title']; $perm_display[$i][1] = $permission[1]['title'];

View File

@ -313,7 +313,7 @@
@reset($sorted_apps); @reset($sorted_apps);
while ($permission = each($sorted_apps)) while ($permission = each($sorted_apps))
{ {
if ($permission[1]['enabled'] && $permission[1]['status'] != 2) if ($permission[1]['enabled'] && $permission[1]['status'] != 3)
{ {
$perm_display[$i][0] = $permission[0]; $perm_display[$i][0] = $permission[0];
$perm_display[$i][1] = $permission[1]['title']; $perm_display[$i][1] = $permission[1]['title'];

View File

@ -107,11 +107,11 @@
display_row(lang("application title"),'<input name="n_app_title" value="' . $n_app_title . '">'); display_row(lang("application title"),'<input name="n_app_title" value="' . $n_app_title . '">');
if(!isset($n_app_status)) { $n_app_status = 1; } if(!isset($n_app_status)) { $n_app_status = 1; }
$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>';
display_row(lang("Status"),'<select name="n_app_status">' . $status_html . '</select>'); display_row(lang('Status'),'<select name="n_app_status">' . $status_html . '</select>');
if (! $app_order) if (! $app_order)
{ {

View File

@ -218,7 +218,7 @@
@reset($sorted_apps); @reset($sorted_apps);
while ($permission = each($sorted_apps)) while ($permission = each($sorted_apps))
{ {
if ($permission[1]['enabled'] && $permission[1]['status'] != 2) if ($permission[1]['enabled'] && $permission[1]['status'] != 3)
{ {
$perm_display[$i][0] = $permission[0]; $perm_display[$i][0] = $permission[0];
$perm_display[$i][1] = $permission[1]['title']; $perm_display[$i][1] = $permission[1]['title'];

View File

@ -723,7 +723,7 @@
continue; continue;
} }
if ($phpgw_info['apps'][$permission[0]]['status'] != 2) if ($phpgw_info['apps'][$permission[0]]['status'] != 2 && $phpgw_info['apps'][$permission[0]]['status'] != 3)
{ {
$phpgw_info['navbar'][$permission[0]]['title'] = $phpgw_info['apps'][$permission[0]]['title']; $phpgw_info['navbar'][$permission[0]]['title'] = $phpgw_info['apps'][$permission[0]]['title'];
$phpgw_info['navbar'][$permission[0]]['url'] = $phpgw->link('/' . $permission[0] . '/index.php'); $phpgw_info['navbar'][$permission[0]]['url'] = $phpgw->link('/' . $permission[0] . '/index.php');

View File

@ -16,7 +16,7 @@
$setup_info['phpgwapi']['title'] = 'phpgwapi'; $setup_info['phpgwapi']['title'] = 'phpgwapi';
$setup_info['phpgwapi']['version'] = '0.9.13.002'; $setup_info['phpgwapi']['version'] = '0.9.13.002';
$setup_info['phpgwapi']['versions']['current_header'] = '1.16'; $setup_info['phpgwapi']['versions']['current_header'] = '1.16';
$setup_info['phpgwapi']['enable'] = 2; $setup_info['phpgwapi']['enable'] = 3;
$setup_info['phpgwapi']['app_order'] = 1; $setup_info['phpgwapi']['app_order'] = 1;
/* The tables this app creates */ /* The tables this app creates */
@ -33,4 +33,13 @@
$setup_info['phpgwapi']['tables'][] = 'lang'; $setup_info['phpgwapi']['tables'][] = 'lang';
$setup_info['phpgwapi']['tables'][] = 'languages'; $setup_info['phpgwapi']['tables'][] = 'languages';
$setup_info['phpgwapi']['tables'][] = 'phpgw_nextid'; $setup_info['phpgwapi']['tables'][] = 'phpgw_nextid';
/* Basic information about this app */
$setup_info['notifywindow']['name'] = 'notifywindow';
$setup_info['notifywindow']['title'] = 'Notify Window';
$setup_info['notifywindow']['version'] = '0.9.13.002';
$setup_info['notifywindow']['enable'] = 2;
$setup_info['notifywindow']['app_order'] = 1;
$setup_info['notifywindow']['tables'] = '';
$setup_info['notifywindow']['hooks'][] = 'home';
?> ?>