mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-03-03 01:21:42 +01:00
Cleaned up a ton of code in preferences and fixed a few preferences bug in the main screen and in email
This commit is contained in:
parent
d17083b543
commit
e9fa1314a9
@ -25,7 +25,7 @@
|
||||
section_start("Address Book",$img);
|
||||
|
||||
$pg = $phpgw->link($phpgw_info["server"]["webserver_url"]."/addressbook/preferences.php");
|
||||
echo "<A href=".$pg.">" . lang("Select columns to display") . "</A>";
|
||||
echo "<A href=".$pg.">" . lang("Addressbook preferences") . "</A>";
|
||||
|
||||
section_end();
|
||||
}
|
||||
|
@ -39,7 +39,7 @@
|
||||
echo "<p><center>" . $phpgw->common->error_list($errors) . "</center>";
|
||||
}
|
||||
|
||||
echo "<p><b>" . lang("select addressbook columns to display") . ":" . "</b><hr><p>";
|
||||
echo "<p><b>" . lang("Addressbook preferences") . ":" . "</b><hr><p>";
|
||||
?>
|
||||
<form method="POST" action="<?php echo $phpgw->link(); ?>">
|
||||
<table border="0" align="center" cellspacing="1" cellpadding="1">
|
||||
|
@ -1,6 +1,9 @@
|
||||
[0.9.3] - Fixed the new user account form not returning the users firstname or last name when an
|
||||
error is reported.
|
||||
- Fixed NNTP to handle new VFS api.
|
||||
- Fixed a number of preferences bugs on the main screen.
|
||||
- Fixed E-Mail sigs not being added.
|
||||
- Moved E-Mail preferences into its own section.
|
||||
|
||||
[0.9.2] - Fixed sorting bug in currentusers.php
|
||||
- Cleaned up error reporting and form in newaccount.php
|
||||
|
@ -12,52 +12,15 @@
|
||||
|
||||
/* $Id$ */
|
||||
|
||||
$phpgw_info["flags"] = array("noheader" => True, "nonavbar" => True);
|
||||
|
||||
if ($submit) {
|
||||
$phpgw_info["flags"] = array("nonavbar" => True, "noheader" => True);
|
||||
}
|
||||
$phpgw_info["flags"]["currentapp"] = "preferences";
|
||||
include("../header.inc.php");
|
||||
if ($phpgw_info["user"]["permissions"]["anonymous"]) {
|
||||
Header("Location: " . $phpgw->link($phpgw_info["server"]["webserver_url"] . "/"));
|
||||
exit;
|
||||
} else if (! $submit) {
|
||||
$phpgw->common->phpgw_header();
|
||||
$phpgw->common->navbar();
|
||||
}
|
||||
|
||||
// This function is not going to be needed when email is moved into its own preferences section.
|
||||
function display_option($text,$check,$option,$indent) {
|
||||
global $phpgw, $phpgw_info;
|
||||
if ($phpgw_info["user"]["apps"][$check]) {
|
||||
?>
|
||||
<tr>
|
||||
<td>
|
||||
<?php
|
||||
for ($i=0; $i < $indent; $i++, print '<blockquote>') {};
|
||||
echo lang($text);
|
||||
for ($i=0; $i < $indent; $i++, print '</blockquote>') {};
|
||||
?>
|
||||
</td>
|
||||
<td>
|
||||
<input type="checkbox" name="<?php echo $option; ?>" value="True"<?php if ($phpgw_info["user"]["preferences"][$check][$option]) echo " checked"; ?>>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
if ($check == "email") {
|
||||
?>
|
||||
<tr>
|
||||
<td>
|
||||
<?php echo lang("email signature"); ?>
|
||||
</td>
|
||||
<td>
|
||||
<textarea name="email_sig" rows="3" cols="30"><?php echo $phpgw_info["user"]["preferences"]["email"]["email_sig"]; ?></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
include("../header.inc.php");
|
||||
|
||||
if (! $submit) {
|
||||
|
||||
?>
|
||||
<form method="POST" action="<?php echo $phpgw->link("settings.php"); ?>">
|
||||
<table border=0>
|
||||
@ -158,8 +121,6 @@
|
||||
}
|
||||
echo "></td></tr>";
|
||||
}
|
||||
|
||||
display_option("show new messages on main screen","email","mainscreen_showmail",0);
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo lang("Default application"); ?></td>
|
||||
@ -183,24 +144,10 @@
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><?php echo lang("Default sorting order"); ?></td>
|
||||
<td><?php
|
||||
$default_order_display[$phpgw_info["user"]["preferences"]["common"]["default_sorting"]] = " selected"; ?>
|
||||
<select name="default_sorting">
|
||||
<option value="old_new"<?php echo $default_order_display["old_new"]; ?>>oldest -> newest</option>
|
||||
<option value="new_old"<?php echo $default_order_display["new_old"]; ?>>newest -> oldest</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
// }
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td colspan="2" align="center">
|
||||
<input type="submit" name="submit" value="<?php echo lang("submit"); ?>">
|
||||
</td>
|
||||
</tr>
|
||||
<td colspan="2" align="center">
|
||||
<input type="submit" name="submit" value="<?php echo lang("submit"); ?>">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
|
||||
@ -221,7 +168,6 @@
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"dateformat","common");
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"timeformat","common");
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"lang","common");
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"default_sorting","email");
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"default_app","common");
|
||||
|
||||
if ($navbar_text) {
|
||||
@ -234,13 +180,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
if ($phpgw_info["user"]["apps"]["email"]) {
|
||||
if ($mainscreen_showmail) {
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"mainscreen_showmail","email");
|
||||
}
|
||||
$phpgw->common->preferences_add($phpgw_info["user"]["userid"],"email_sig","email");
|
||||
}
|
||||
|
||||
$phpgw->db->unlock();
|
||||
|
||||
Header("Location: " . $phpgw->link("index.php"));
|
||||
|
Loading…
Reference in New Issue
Block a user