mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-04 12:30:04 +01:00
Converted over to templates
This commit is contained in:
parent
abf8c3bcd9
commit
b4996f1819
@ -22,6 +22,8 @@
|
||||
include("../header.inc.php");
|
||||
include($phpgw_info["server"]["app_inc"]."/accounts_".$phpgw_info["server"]["account_repository"].".inc.php");
|
||||
|
||||
$phpgw->template->set_file(array("body" => "delete_common.tpl"));
|
||||
|
||||
// I didn't active this code until all tables are up to date using the owner field
|
||||
// The calendar isn't update to date. (jengo)
|
||||
// NOTE: This is so I don't forget, add a double explode() to the app_tables field
|
||||
@ -57,30 +59,14 @@
|
||||
if (($account_id) && (! $confirm)) {
|
||||
// the account can have special chars/white spaces, if it is a ldap dn
|
||||
$account_id = rawurlencode($account_id);
|
||||
?>
|
||||
<center>
|
||||
<table border=0 with=65%>
|
||||
<tr colspan=2>
|
||||
<td align=center>
|
||||
<?php echo lang("Are you sure you want to delete this account ?"); ?>
|
||||
<td>
|
||||
</tr>
|
||||
<tr colspan=2>
|
||||
<td align=center>
|
||||
<?php echo "<font color=\"red\"><blink>".lang("All records and account information will be lost!")."</blink></font>"; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("accounts.php") . "\">" . lang("No"); ?></a>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("deleteaccount.php","account_id=$account_id&confirm=true") . "\">" . lang("Yes"); ?></a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</center>
|
||||
<?php
|
||||
$phpgw->template->set_var("message",lang("Are you sure you want to delete this account ?") . "<br>"
|
||||
. "<font color=\"red\"><blink>" . lang("All records and account information will be lost!") . "</blink></font>");
|
||||
$phpgw->template->set_var("yes",'<a href="' . $phpgw->link("deleteaccount.php","account_id=$account_id&confirm=true")
|
||||
. '">' . lang("Yes") . '</a>');
|
||||
$phpgw->template->set_var("no",'<a href="' . $phpgw->link("accounts.php")
|
||||
. '">' . lang("No") . '</a>');
|
||||
$phpgw->template->pparse("out","body");
|
||||
|
||||
$phpgw->common->phpgw_footer();
|
||||
}
|
||||
|
||||
|
@ -13,13 +13,14 @@
|
||||
|
||||
$phpgw_info["flags"] = array("noheader" => True, "nonavbar" => True, "currentapp" => "admin");
|
||||
|
||||
if (! $app_name)
|
||||
if (! $app_name) {
|
||||
Header("Location: " . $phpgw->link("applications.php"));
|
||||
|
||||
}
|
||||
include("../header.inc.php");
|
||||
$phpgw->template->set_file(array("body" => "delete_common.tpl"));
|
||||
|
||||
if ($confirm) {
|
||||
$phpgw->db->query("delete from applications where app_name='$app_name'");
|
||||
$phpgw->db->query("delete from applications where app_name='$app_name'",__LINE__,__FILE__);
|
||||
|
||||
Header("Location: " . $phpgw->link("applications.php"));
|
||||
$phpgw->common->phpgw_exit();
|
||||
@ -27,24 +28,12 @@
|
||||
|
||||
$phpgw->common->phpgw_header();
|
||||
echo parse_navbar();
|
||||
?>
|
||||
<center>
|
||||
<table border=0 with=65%>
|
||||
<tr colspan=2>
|
||||
<td align=center>
|
||||
<?php echo lang("Are you sure you want to delete this application ?"); ?>
|
||||
<td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("applications.php") . "\">" . lang("No") . "</a>"; ?>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("deleteapplication.php","app_name=" . urlencode($app_name) . "&confirm=True") . "\">" . lang("Yes") . "</a>"; ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</center>
|
||||
<?php
|
||||
|
||||
$phpgw->template->set_var("message",lang("Are you sure you want to delete this application ?"));
|
||||
$phpgw->template->set_var("no",'<a href="' . $phpgw->link("applications.php")
|
||||
. '">' . lang("No") . '</a>');
|
||||
$phpgw->template->set_var("yes",'<a href="' . $phpgw->link("deleteapplication.php","app_name=" . urlencode($app_name) . "&confirm=True") . '">' . lang("Yes") . '</a>');
|
||||
$phpgw->template->pparse("out","body");
|
||||
|
||||
$phpgw->common->phpgw_footer();
|
||||
?>
|
||||
|
@ -14,14 +14,15 @@
|
||||
$phpgw_info = array();
|
||||
$phpgw_info["flags"] = array("noheader" => True, "nonavbar" => True, "currentapp" => "admin");
|
||||
|
||||
if (! $group_id)
|
||||
if (! $group_id) {
|
||||
Header("Location: " . $phpgw->link("groups.php"));
|
||||
|
||||
}
|
||||
include("../header.inc.php");
|
||||
$phpgw->template->set_file(array("body" => "delete_common.tpl"));
|
||||
|
||||
if ((($group_id) && ($confirm)) || $removeusers) {
|
||||
if ($removeusers) {
|
||||
$phpgw->db->query("select account_id,account_groups from accounts where account_groups like '%$group_id%'");
|
||||
$phpgw->db->query("select account_id,account_groups from accounts where account_groups like '%$group_id%'",__LINE__,__FILE__);
|
||||
while ($phpgw->db->next_record()) {
|
||||
$groups[$phpgw->db->f("account_id")] = $phpgw->db->f("account_groups");
|
||||
}
|
||||
@ -31,17 +32,17 @@
|
||||
if ($user_[1] == ",") {
|
||||
$user_[1] = "";
|
||||
}
|
||||
$phpgw->db->query("update accounts set account_groups='$user_[1]' where account_id=$user[0]");
|
||||
$phpgw->db->query("update accounts set account_groups='$user_[1]' where account_id=$user[0]",__LINE__,__FILE__);
|
||||
}
|
||||
$confirm = True;
|
||||
}
|
||||
|
||||
$phpgw->db->query("select group_name from groups where group_id=$group_id");
|
||||
$phpgw->db->query("select group_name from groups where group_id=$group_id",__LINE__,__FILE__);
|
||||
$phpgw->db->next_record();
|
||||
|
||||
$group_name = $phpgw->db->f("group_name");
|
||||
|
||||
$phpgw->db->query("select count(*) from accounts where account_groups like '%$group_id%'");
|
||||
$phpgw->db->query("select count(*) from accounts where account_groups like '%$group_id%'",__LINE__,__FILE__);
|
||||
$phpgw->db->next_record();
|
||||
if ($phpgw->db->f(0) != 0) {
|
||||
$phpgw->common->phpgw_header();
|
||||
@ -54,7 +55,7 @@
|
||||
|
||||
echo '<table border="0"><tr><td>';
|
||||
|
||||
$phpgw->db->query("select account_id,account_lid from accounts where account_groups like '%$group_id%'");
|
||||
$phpgw->db->query("select account_id,account_lid from accounts where account_groups like '%$group_id%'",__LINE__,__FILE__);
|
||||
while ($phpgw->db->next_record()) {
|
||||
echo '<tr><td><a href="' . $phpgw->link("editaccount.php","account_=" . $phpgw->db->f("account_id")) . '">' . $phpgw->db->f("loginid") . '</a></tr></td>';
|
||||
}
|
||||
@ -65,11 +66,11 @@
|
||||
}
|
||||
|
||||
if ($confirm) {
|
||||
$phpgw->db->query("select group_name from groups where group_id=$group_id");
|
||||
$phpgw->db->query("select group_name from groups where group_id=$group_id",__LINE__,__FILE__);
|
||||
$phpgw->db->next_record();
|
||||
$group_name = $phpgw->db->f("group_name");
|
||||
|
||||
$phpgw->db->query("delete from groups where group_id=$group_id");
|
||||
$phpgw->db->query("delete from groups where group_id=$group_id",__LINE__,__FILE__);
|
||||
|
||||
$sep = $phpgw->common->filesystem_separator();
|
||||
|
||||
@ -87,24 +88,12 @@
|
||||
|
||||
$phpgw->common->phpgw_header();
|
||||
echo parse_navbar();
|
||||
?>
|
||||
<center>
|
||||
<table border=0 with=65%>
|
||||
<tr colspan=2>
|
||||
<td align=center>
|
||||
<?php echo lang("Are you sure you want to delete this group ?"); ?>
|
||||
<td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("groups.php") . "\">" . lang("No") . "</a>"; ?>
|
||||
</td>
|
||||
<td>
|
||||
<a href="<?php echo $phpgw->link("deletegroup.php","group_id=$group_id&confirm=true") . "\">" . lang("Yes") . "</a>"; ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</center>
|
||||
<?php
|
||||
$phpgw->common->phpgw_footer();
|
||||
|
||||
$phpgw->template->set_var("message",lang("Are you sure you want to delete this group ?"));
|
||||
$phpgw->template->set_var("yes",'<a href="' . $phpgw->link("deletegroup.php","group_id=$group_id&confirm=true") . '">' . lang("Yes") . '</a>');
|
||||
$phpgw->template->set_var("no",'<a href="' . $phpgw->link("groups.php") . '">' . lang("No") . '</a>');
|
||||
|
||||
$phpgw->template->pparse("out","body");
|
||||
|
||||
$phpgw->common->phpgw_footer();
|
||||
?>
|
||||
|
@ -1,17 +1,12 @@
|
||||
<!-- BEGIN form -->
|
||||
<center>
|
||||
<table border="0" with="65%">
|
||||
{messages}
|
||||
<tr colspan="2">
|
||||
<td align="center">{message}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{no}</td>
|
||||
<td>{yes}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</center>
|
||||
<!-- END form -->
|
||||
|
||||
<!-- BEGIN message_row -->
|
||||
<tr colspan="2">
|
||||
<td align="center">{message_display}<td>
|
||||
</tr>
|
||||
<!-- END message_row -->
|
||||
|
Loading…
Reference in New Issue
Block a user