[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] email/inc class.boindex.inc.php class.svc_nextm... [V
From: |
Dave Hall |
Subject: |
[Phpgroupware-cvs] email/inc class.boindex.inc.php class.svc_nextm... [Version-0_9_16-branch] |
Date: |
Tue, 20 Dec 2005 02:24:10 +0000 |
CVSROOT: /cvsroot/phpgroupware
Module name: email
Branch: Version-0_9_16-branch
Changes by: Dave Hall <address@hidden> 05/12/20 02:24:10
Modified files:
inc : class.boindex.inc.php
class.svc_nextmatches.inc.php
class.uiindex.inc.php
Log message:
fix bug #15248
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/email/inc/class.boindex.inc.php.diff?only_with_tag=Version-0_9_16-branch&tr1=1.30.2.6&tr2=1.30.2.7&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/email/inc/class.svc_nextmatches.inc.php.diff?only_with_tag=Version-0_9_16-branch&tr1=1.2.2.3&tr2=1.2.2.4&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/phpgroupware/email/inc/class.uiindex.inc.php.diff?only_with_tag=Version-0_9_16-branch&tr1=1.21.2.4&tr2=1.21.2.5&r1=text&r2=text
Patches:
Index: email/inc/class.boindex.inc.php
diff -u email/inc/class.boindex.inc.php:1.30.2.6
email/inc/class.boindex.inc.php:1.30.2.7
--- email/inc/class.boindex.inc.php:1.30.2.6 Sat Nov 6 16:13:45 2004
+++ email/inc/class.boindex.inc.php Tue Dec 20 02:24:10 2005
@@ -11,7 +11,7 @@
* option) any later version.
*
\**************************************************************************/
- /* $Id: class.boindex.inc.php,v 1.30.2.6 2004/11/06 16:13:45 powerstat
Exp $ */
+ /* $Id: class.boindex.inc.php,v 1.30.2.7 2005/12/20 02:24:10 skwashd
Exp $ */
class boindex
{
@@ -401,64 +401,8 @@
$this->icon_size =
$GLOBALS['phpgw']->msg->get_pref_value('icon_size',$acctnum);
//echo "icon size is ".$this->icon_size."<br />\r\n";
- /* MOVED TO FUNCTION ABOVE
- // ---- account switchbox ----
- // make a HTML comobox used to switch accounts
- $make_acctbox = True;
- //$make_acctbox = False;
- if ($make_acctbox)
- {
- $feed_args = Array(
- 'pre_select_acctnum' =>
$GLOBALS['phpgw']->msg->get_acctnum(),
- 'widget_name' =>
'fldball_fake_uri',
- 'folder_key_name' => 'folder',
- 'acctnum_key_name' => 'acctnum',
- 'on_change' =>
'document.acctbox.submit()'
- );
- $this->xi['acctbox_listbox'] =
$GLOBALS['phpgw']->msg->all_ex_accounts_listbox($feed_args);
- }
- else
- {
- $this->xi['acctbox_listbox'] = ' ';
- }
- $this->xi['acctbox_frm_name'] = 'acctbox';
-
- // switchbox will itself contain "fake_uri" embedded
data which includes the applicable account number for the folder
- $this->xi['acctbox_action'] = $GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index');
-
- */
-
$this->xi['mailsvr_supports_folders'] =
$GLOBALS['phpgw']->msg->get_mailsvr_supports_folders();
- // if using folders, make a HTML comobox used to switch
folders
- /* MOVED TO FUNCTION ABOVE
- if ($this->xi['mailsvr_supports_folders'])
- {
- $feed_args = Array(
- 'mailsvr_stream' => '',
- 'pre_select_folder' => '',
- 'skip_folder' => '',
- 'show_num_new' =>
$this->xi['show_num_new'],
- 'widget_name' =>
'fldball_fake_uri',
- 'folder_key_name' => 'folder',
- 'acctnum_key_name' => 'acctnum',
- 'on_change' =>
'document.switchbox.submit()',
- 'first_line_txt' =>
$this->xi['first_line_txt']
- );
- $this->xi['switchbox_listbox'] =
$GLOBALS['phpgw']->msg->all_folders_listbox($feed_args);
- }
- else
- {
- $this->xi['switchbox_listbox'] = ' ';
- }
- $this->xi['switchbox_frm_name'] = 'switchbox';
-
- // switchbox will itself contain "fake_uri" embedded
data which includes the applicable account number for the folder
- $this->xi['switchbox_action'] = $GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index');
- */
+
// get statistics an the current folder
if ((!isset($this->xi['folder_info']))
|| (!$this->xi['folder_info']))
@@ -611,31 +555,6 @@
$this->xi['ctrl_bar_current_acctnum'] = 'extra
'.(string)$GLOBALS['phpgw']->msg->get_acctnum();
}
- /*
- // DEPRECIATED
- $this->xi['ctrl_bar_acct_0_link'] =
$GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index'
- // going to the
folder list page, we only need log into the INBOX folder
-
.'&fldball[folder]=INBOX'
-
.'&fldball[acctnum]=0'
- .'&sort='
- .'&order='
- .'&start=');
- $this->xi['ctrl_bar_acct_0_link'] = '<a
href="'.$this->xi['ctrl_bar_acct_0_link'].'">'.'goto default'.'</a>';
-
- // DEPRECIATED
- $this->xi['ctrl_bar_acct_1_link'] =
$GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index'
- // going to the
folder list page, we only need log into the INBOX folder
-
.'&fldball[folder]=INBOX'
-
.'&fldball[acctnum]=1'
- .'&sort='
- .'&order='
- .'&start=');
- $this->xi['ctrl_bar_acct_1_link'] = '<a
href="'.$this->xi['ctrl_bar_acct_1_link'].'">'.'goto extra 1'.'</a>';
- */
$this->xi['ctrl_bar_back1'] =
$GLOBALS['phpgw_info']['theme']['row_on'];
$sort_selected = Array(
@@ -659,74 +578,6 @@
$this->xi['sortbox_on_change'] =
'document.sortbox.submit()';
$this->xi['sortbox_select_name'] = 'sort';
- /* MOVED TO FUNCTION ABOVE
- if ($this->xi['folder_info']['number_all'] == 0)
- {
- $this->xi['stats_saved'] = '-';
- $this->xi['stats_new'] = '-';
- $this->xi['stats_size'] = '-';
- }
- else
- {
- $this->xi['stats_saved'] =
number_format($this->xi['folder_info']['number_all']);
- $this->xi['stats_new'] =
$this->xi['folder_info']['number_new'];
- if ($this->xi['stats_new'] == 0)
- {
- $this->xi['stats_new'] = '0';
- }
- else
- {
- $this->xi['stats_new'] =
number_format($this->xi['stats_new']);
- }
-
//$size_report_args['allow_stats_size_speed_skip'] = True;
- //$size_report_args['stats_size_threshold'] =
100;
- //$size_report_args['number_all'] =
$this->xi['folder_info']['number_all'];
- //$this->xi['stats_size'] =
$GLOBALS['phpgw']->msg->report_total_foldersize($size_report_args);
- // this function was rewritten
- $this->xi['stats_size'] =
$GLOBALS['phpgw']->msg->report_total_foldersize_conditional();
- }
- // simple check if we are in the INBOX folder - by Sam
Przyswa
- if
($GLOBALS['phpgw']->msg->get_folder_short($GLOBALS['phpgw']->msg->get_arg_value('folder'))
== 'INBOX')
- {
- //$nice_folder_name = $this->xi['lang_inbox'];
- // try this for common folder related lang
strings
- //$common_langs =
$GLOBALS['phpgw']->msg->get_common_langs();
- //$nice_folder_name =
$common_langs['lang_inbox'];
- // or try this shortcut, it works too
- $nice_folder_name =
$GLOBALS['phpgw']->msg->get_common_langs('lang_inbox');
- }
- else
- {
- $nice_folder_name =
$GLOBALS['phpgw']->msg->get_folder_short($GLOBALS['phpgw']->msg->get_arg_value('folder'));
- }
-
- $this->xi['stats_backcolor'] =
$GLOBALS['phpgw_info']['theme']['em_folder'];
- $this->xi['stats_backcolor_class'] = 'email_folder';
- $this->xi['stats_color'] =
$GLOBALS['phpgw_info']['theme']['em_folder_text'];
- $this->xi['stats_color_class'] = 'email_folder';
- //$this->xi['stats_folder'] =
$GLOBALS['phpgw']->msg->get_folder_short($GLOBALS['phpgw']->msg->get_arg_value('folder'));
- $this->xi['stats_folder'] = $nice_folder_name;
- $this->xi['stats_first'] =
$GLOBALS['phpgw']->msg->get_arg_value('start') + 1;
- // toggle the "get folder size" button or link, if
getting that size was skipped as a time-saving measure
- if ($this->xi['stats_size'] == '')
- {
- $this->xi['force_showsize_flag'] =
'force_showsize';
- $this->xi['get_size_link'] =
$GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index'
-
.'&fldball[folder]='.$GLOBALS['phpgw']->msg->prep_folder_out()
-
.'&fldball[acctnum]='.$GLOBALS['phpgw']->msg->get_acctnum()
-
.'&sort='.$GLOBALS['phpgw']->msg->get_arg_value('sort')
-
.'&order='.$GLOBALS['phpgw']->msg->get_arg_value('order')
-
.'&start='.$GLOBALS['phpgw']->msg->get_arg_value('start')
-
.'&'.$this->xi['force_showsize_flag'].'=1');
- $this->xi['frm_get_size_name'] =
'form_get_size';
- $this->xi['frm_get_size_action'] =
$GLOBALS['phpgw']->link(
- '/index.php',
-
'menuaction=email.uiindex.index');
- }
- */
-
// column labels for the message list
$flag_sort_pre = '* ';
$flag_sort_post = ' *';
@@ -764,7 +615,7 @@
);
$this->xi['hdr_date'] =
$this->svc_nextmatches->show_sort_order_mail
-
($GLOBALS['phpgw']->msg->get_arg_value('sort'),'1',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php?menuaction=email.uiindex.index',$this->xi['lang_date'],
+ ($GLOBALS['phpgw']->msg->get_arg_value('sort'),
0, $this->xi['default_order'], $GLOBALS['phpgw']->msg->get_arg_value('order'),
'/index.php?menuaction=email.uiindex.index',$this->xi['lang_date'],
'&fldball[folder]='.$GLOBALS['phpgw']->msg->prep_folder_out()
.'&fldball[acctnum]='.$GLOBALS['phpgw']->msg->get_acctnum());
$this->xi['hdr_size'] =
$this->svc_nextmatches->show_sort_order_mail($GLOBALS['phpgw']->msg->get_arg_value('sort'),'6',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php?menuaction=email.uiindex.index',$this->xi['lang_size'],
@@ -1183,45 +1034,6 @@
$this->xi['hdr_from'] = $this->xi['lang_from'];
$this->xi['hdr_date'] = $this->xi['lang_date'];
$this->xi['hdr_size'] = $this->xi['lang_size'];
- /*
- // column labels for the message list
- $flag_sort_pre = '* ';
- $flag_sort_post = ' *';
- switch
((int)$GLOBALS['phpgw']->msg->get_arg_value('sort'))
- {
- case 1 : $this->xi['lang_date'] =
$flag_sort_pre .$this->xi['lang_date'] .$flag_sort_post; break;
- case 2 : $this->xi['lang_from'] =
$flag_sort_pre .$this->xi['lang_from'] .$flag_sort_post; break;
- case 3 : $this->xi['lang_subject'] =
$flag_sort_pre .$this->xi['lang_subject'] .$flag_sort_post; break;
- case 6 : $this->xi['lang_size'] =
'*'.$this->xi['lang_size'].'*';
- $this->xi['lang_lines'] =
$this->xi['lang_lines'] .$flag_sort_post; break;
- }
- // default order is needed for the "nextmatchs" args,
to know when to toggle this between normal and reverse
- if
(($GLOBALS['phpgw']->msg->get_isset_pref('default_sorting']))
- &&
($GLOBALS['phpgw']->msg->get_pref_value('default_sorting') == 'new_old'))
- {
- $this->xi['default_order'] = 1;
- }
- else
- {
- $this->xi['default_order'] = 0;
- }
- // make these column labels into clickable HREF's for
their
- if (($GLOBALS['phpgw']->msg->get_isset_arg('newsmode'))
- && ($GLOBALS['phpgw']->msg->get_arg_value('newsmode')
== True))
- {
- $this->xi['hdr_subject'] =
$this->nextmatchs->show_sort_order($GLOBALS['phpgw']->msg->get_arg_value('sort'),'3',$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_subject'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_from'] =
$this->nextmatchs->show_sort_order($GLOBALS['phpgw']->msg->get_arg_value('sort'),'2',$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_from'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_date'] =
$this->nextmatchs->show_sort_order($GLOBALS['phpgw']->msg->get_arg_value('sort'),'1',$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_date'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_size'] =
$this->nextmatchs->show_sort_order($GLOBALS['phpgw']->msg->get_arg_value('sort'),'6',$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_lines'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- }
- else
- {
- $this->xi['hdr_subject'] =
$this->nextmatchs->show_sort_order_imap($GLOBALS['phpgw']->msg->get_arg_value('sort'),'3',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_subject'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_from'] =
$this->nextmatchs->show_sort_order_imap($GLOBALS['phpgw']->msg->get_arg_value('sort'),'2',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_from'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_date'] =
$this->nextmatchs->show_sort_order_imap($GLOBALS['phpgw']->msg->get_arg_value('sort'),'1',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_date'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- $this->xi['hdr_size'] =
$this->nextmatchs->show_sort_order_imap($GLOBALS['phpgw']->msg->get_arg_value('sort'),'6',$this->xi['default_order'],$GLOBALS['phpgw']->msg->get_arg_value('order'),'/index.php'.$GLOBALS['phpgw']->msg->get_arg_value('mlist_menuaction'),$this->xi['lang_size'],'&folder='.$GLOBALS['phpgw']->msg->prep_folder_out(''));
- }
- */
$this->xi['hdr_backcolor'] =
$GLOBALS['phpgw_info']['theme']['th_bg'];
$this->xi['hdr_backcolor_class'] = 'th';
Index: email/inc/class.svc_nextmatches.inc.php
diff -u email/inc/class.svc_nextmatches.inc.php:1.2.2.3
email/inc/class.svc_nextmatches.inc.php:1.2.2.4
--- email/inc/class.svc_nextmatches.inc.php:1.2.2.3 Sat Nov 6 16:13:46 2004
+++ email/inc/class.svc_nextmatches.inc.php Tue Dec 20 02:24:10 2005
@@ -25,7 +25,7 @@
* Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
\**************************************************************************/
- /* $Id: class.svc_nextmatches.inc.php,v 1.2.2.3 2004/11/06 16:13:46
powerstat Exp $ */
+ /* $Id: class.svc_nextmatches.inc.php,v 1.2.2.4 2005/12/20 02:24:10
skwashd Exp $ */
/* $Source:
/cvsroot/phpgroupware/email/inc/class.svc_nextmatches.inc.php,v $ */
/*!
@@ -132,33 +132,21 @@
to display the next page.
@author phpgw team, Angles
*/
- function
show_sort_order_mail($old_sort,$new_sort,$default_order,$order,$program,$text,$extra='')
+ function show_sort_order_mail($old_sort, $new_sort,
$default_order, $order, $program, $text, $extra='')
{
- if(is_array($extra))
+ if ( is_array($extra) )
{
$extra = $this->extras_to_string($extra);
}
- if($old_sort == $new_sort)
+ if ( $old_sort == $new_sort)
{
// alternate order, like on outkrook, click on
present sorting reverses order
- if((int)$order == 1)
- {
- $our_order = 0;
- }
- elseif((int)$order == 0)
- {
- $our_order = 1;
- }
- else
- {
- // we should never get here
- $our_order = 1;
- }
+ $our_order = ( (int) $order == 1 ) ? 0 : 1;
}
else
{
//user has selected a new sort scheme, reset
the order to users default
- $our_order = $default_order;
+ $our_order = (int)$default_order;
}
/*
@@ -178,8 +166,9 @@
//echo 'show_sort_order_mail: $program
['.serialize($program).'] <br />';
//echo 'show_sort_order_mail: $extra
['.serialize($extra).'] <br />';
$prog = explode('?',$program);
+
//echo 'show_sort_order_mail: $prog
['.serialize($prog).'] <br />';
- $extravar =
$prog[1].'&order='.$our_order.'&sort='.$new_sort.$extra;
+ $extravar =
"{$prog[1]}&order={$our_order}&sort={$new_sort}{$extra}";
//echo 'show_sort_order_mail: $extravar
['.serialize($extravar).'] <br />';
// this was b0rking menuaction when NOT using redirect,
instead using direct object calls to goto the next page
Index: email/inc/class.uiindex.inc.php
diff -u email/inc/class.uiindex.inc.php:1.21.2.4
email/inc/class.uiindex.inc.php:1.21.2.5
--- email/inc/class.uiindex.inc.php:1.21.2.4 Sat Nov 6 16:13:46 2004
+++ email/inc/class.uiindex.inc.php Tue Dec 20 02:24:10 2005
@@ -10,7 +10,7 @@
* option) any later version.
*
\**************************************************************************/
- /* $Id: class.uiindex.inc.php,v 1.21.2.4 2004/11/06 16:13:46 powerstat
Exp $ */
+ /* $Id: class.uiindex.inc.php,v 1.21.2.5 2005/12/20 02:24:10 skwashd
Exp $ */
class uiindex
{
@@ -26,7 +26,6 @@
function uiindex()
{
- //return;
}
/*!
@@ -43,7 +42,7 @@
$this->bo = CreateObject('email.boindex');
$this->bo->index_data();
-
+
if ($GLOBALS['phpgw']->msg->phpgw_before_xslt)
{
$this->index_old_tpl();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] email/inc class.boindex.inc.php class.svc_nextm... [Version-0_9_16-branch],
Dave Hall <=