summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 4f2f4a2)
raw | patch | inline | side by side (parent: 4f2f4a2)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 9 Aug 2007 09:56:55 +0000 (09:56 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 9 Aug 2007 09:56:55 +0000 (09:56 +0000) |
Only handle posts if template was posted
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@7024 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@7024 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/admin/systems/class_dhcpSubnet.inc | patch | blob | history | |
plugins/admin/systems/dhcp_subnet.tpl | patch | blob | history |
diff --git a/plugins/admin/systems/class_dhcpSubnet.inc b/plugins/admin/systems/class_dhcpSubnet.inc
index 0e55c8e6f79bf9566727349eaf02d4c47fe8bb1e..7f8855b9eb80a7862f93067261f8391e31bb38fd 100644 (file)
/* Save data to object */
function save_object()
{
- if (isset($_POST['cn'])){
- $this->cn= validate($_POST['cn']);
- }
- if (isset($_POST['dhcp_netmask'])){
- $this->dhcpNetMask= validate($_POST['dhcp_netmask']);
- }
- if (isset($_POST['use_range'])){
- $this->use_range= TRUE;
- $this->range_start= validate($_POST['range_start']);
- $this->range_stop= validate($_POST['range_stop']);
- } else {
- $this->use_range= FALSE;
- }
+ if(isset($_POST['dhcp_subnet_posted'])){
+ if (isset($_POST['cn'])){
+ $this->cn= validate($_POST['cn']);
+ }
+ if (isset($_POST['dhcp_netmask'])){
+ $this->dhcpNetMask= validate($_POST['dhcp_netmask']);
+ }
+ if (isset($_POST['use_range'])){
+ $this->use_range= TRUE;
+ $this->range_start= validate($_POST['range_start']);
+ $this->range_stop= validate($_POST['range_stop']);
+ } else {
+ $this->use_range= FALSE;
+ }
- dhcpPlugin::save_object();
+ /* Move range to internal variable */
+ $this->dhcpRange= $this->range_start." ".$this->range_stop;
+ dhcpPlugin::save_object();
+ }
}
}
}
-
+// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
?>
index 419cb52376e591c1b3ce2b2bca03f799e218b07f..5b871fc2de9725da05af6e8a9dac422efbf1b215 100644 (file)
</td>
</tr>
</table>
-
+<input type='hidden' name='dhcp_subnet_posted' value='1'>
<p class="seperator"></p>
<!-- Place cursor in correct field -->