From 0ea7e863c42afcff944865175201bc3e39dfcbb4 Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 22 Jul 2008 10:21:04 +0000 Subject: [PATCH] Added intial dns acls. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11743 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../systems/services/dns/class_servDNS.inc | 4 ++- .../services/dns/class_servDNSeditZone.inc | 9 +++++- .../systems/services/dns/servdnseditzone.tpl | 32 ++++++++----------- 3 files changed, 25 insertions(+), 20 deletions(-) diff --git a/gosa-plugins/dns/admin/systems/services/dns/class_servDNS.inc b/gosa-plugins/dns/admin/systems/services/dns/class_servDNS.inc index 08b15e808..93d5db4d0 100644 --- a/gosa-plugins/dns/admin/systems/services/dns/class_servDNS.inc +++ b/gosa-plugins/dns/admin/systems/services/dns/class_servDNS.inc @@ -111,7 +111,7 @@ class servdns extends goService */ $smarty= get_smarty(); $smarty->assign("dns_take_over",FALSE); - $smarty->assign("is_createable",$this->acl_is_createable()); + $smarty->assign("is_createable",$this->acl_is_writeable("")); $display= ""; @@ -584,6 +584,7 @@ class servdns extends goService "plProvidedAcls"=> array( "zoneName" =>_("Zone name"), "ReverseZone" =>_("Reverse zone"), + "NetworkClass" =>_("Network class"), "sOAprimary" =>_("Primary dns server"), "sOAmail" =>_("Mail address"), "sOAserial" =>_("Serial"), @@ -591,6 +592,7 @@ class servdns extends goService "sOAretry" =>_("Retry"), "sOAexpire" =>_("Expire"), "sOAttl" =>_("TTL"), + "mXRecord" =>_("MX records"), "zoneRecords" =>_("Zone records")) )); } diff --git a/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc b/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc index 2123d3cda..927b22895 100644 --- a/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc +++ b/gosa-plugins/dns/admin/systems/services/dns/class_servDNSeditZone.inc @@ -212,7 +212,14 @@ class servdnseditZone extends plugin $smarty->assign("Zone_is_used",$this->Zone_is_used); $ui = get_userinfo(); - $smarty->assign("ACLs",$this->parent->getacl("")); + /* Assign ACLs + All acls are defined in our parent class. + */ + $tmp = $this->parent->plInfo(); + foreach($tmp['plProvidedAcls'] as $name => $desc){ + $smarty->assign($name."ACL", $this->parent->getacl($name)); + } + $display= ""; /* Open Zone Entry Edit Dialog diff --git a/gosa-plugins/dns/admin/systems/services/dns/servdnseditzone.tpl b/gosa-plugins/dns/admin/systems/services/dns/servdnseditzone.tpl index fa8aba6cc..fb947b41f 100644 --- a/gosa-plugins/dns/admin/systems/services/dns/servdnseditzone.tpl +++ b/gosa-plugins/dns/admin/systems/services/dns/servdnseditzone.tpl @@ -7,7 +7,7 @@ {t}Zone name{/t}{$must} -{render acl=$ACLs} +{render acl=$zoneNameACL} {/render} @@ -16,7 +16,7 @@ {t}Network address{/t}{$must} -{render acl=$ACLs} +{render acl=$ReverseZoneACL} {/render} @@ -25,7 +25,7 @@ {t}Netmask{/t} -{render acl=$ACLs} +{render acl=$NetworkClassACL} @@ -52,9 +52,7 @@ {/if} -{render acl=$ACLs} -{/render} @@ -71,7 +69,7 @@ {t}Primary dns server for this zone{/t}{$must} -{render acl=$ACLs} +{render acl=$sOAprimaryACL} {/render} @@ -80,7 +78,7 @@ {t}Mail address{/t}{$must} -{render acl=$ACLs} +{render acl=$sOAmailACL} {/render} @@ -89,7 +87,7 @@ {t}Serial number (automatically incremented){/t}{$must} -{render acl=$ACLs} +{render acl=$sOAserialACL} {/render} @@ -102,7 +100,7 @@ {t}Refresh{/t}{$must} -{render acl=$ACLs} +{render acl=$sOArefreshACL} {/render} @@ -111,7 +109,7 @@ {t}Retry{/t}{$must} -{render acl=$ACLs} +{render acl=$sOAretryACL} {/render} @@ -120,7 +118,7 @@ {t}Expire{/t}{$must} -{render acl=$ACLs} +{render acl=$sOAexpireACL} {/render} @@ -129,7 +127,7 @@ {t}TTL{/t}{$must} -{render acl=$ACLs} +{render acl=$sOAttlACL} {/render} @@ -148,13 +146,13 @@ @@ -163,7 +161,7 @@ @@ -171,9 +169,7 @@
-{render acl=$ACLs} +{render acl=$mXRecordACL} {$Mxrecords} {/render} -{render acl=$ACLs} +{render acl=$mXRecordACL} {/render} -{render acl=$ACLs} +{render acl=$mXRecordACL} {/render}

{t}Global zone records{/t}

-{render acl=$ACLs} +{render acl=$zoneRecordsACL} {$records} {/render}

-{render acl=$ACLs} -{/render}

-- 2.30.2