From 2cb1563f63386b35a69e460051aa9b4a2851d104 Mon Sep 17 00:00:00 2001
From: ftimme <ft@falkotimme.com>
Date: Wed, 30 May 2012 07:30:44 -0400
Subject: [PATCH] - Added (clickable) placeholders to client messaging function. - Added check so that the client password isn't inserted into the message (for security reasons).

---
 interface/web/dns/dns_rr_del.php |   25 +++++++++++++++++++------
 1 files changed, 19 insertions(+), 6 deletions(-)

diff --git a/interface/web/dns/dns_rr_del.php b/interface/web/dns/dns_rr_del.php
index d996c91..d88e2d9 100644
--- a/interface/web/dns/dns_rr_del.php
+++ b/interface/web/dns/dns_rr_del.php
@@ -42,13 +42,26 @@
 require_once('../../lib/config.inc.php');
 require_once('../../lib/app.inc.php');
 
-// Checke Berechtigungen f�r Modul
-if(!stristr($_SESSION["s"]["user"]["modules"],'dns')) {
-	header("Location: ../index.php");
-	exit;
+//* Check permissions for module
+$app->auth->check_module_permissions('dns');
+
+$app->uses('tpl,tform,tform_actions,validate_dns');
+$app->load('tform_actions');
+
+class page_action extends tform_actions {
+
+	function onAfterDelete() {
+		global $app; $conf;
+				
+		//* Update the serial number of the SOA record
+		$soa = $app->db->queryOneRecord("SELECT serial FROM dns_soa WHERE id = '".intval($this->dataRecord["zone"])."' AND ".$app->tform->getAuthSQL('r'));
+		$soa_id = intval($this->dataRecord["zone"]);
+		$serial = $app->validate_dns->increase_serial($soa["serial"]);
+		$app->db->datalogUpdate('dns_soa', "serial = $serial", 'id', $soa_id);
+	}
 }
 
-$app->uses("tform_actions");
-$app->tform_actions->onDelete();
+$page = new page_action;
+$page->onDelete();
 
 ?>
\ No newline at end of file

--
Gitblit v1.9.1