Changeset 881 for trunk/cgi-bin


Ignore:
Timestamp:
06/14/16 12:10:29 (8 years ago)
Author:
Kris Deugau
Message:

/trunk

Add DNS field to email notice on allocation

Location:
trunk/cgi-bin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/cgi-bin/admin.cgi

    r880 r881  
    213213      mailNotify($ip_dbh, "a$webvar{alloctype}", "ADDED: $disp_alloctypes{$webvar{alloctype}} allocation",
    214214        "$disp_alloctypes{$webvar{alloctype}} $webvar{cidr} allocated to customer $webvar{custid}\n".
    215         "Description: $webvar{desc}\n\nAllocated by: $authuser\n");
     215        "Description: $webvar{desc}\n".
     216        ($webvar{rdns} ? "DNS name: $webvar{rdns}\n" : '').
     217        "\nAllocated by: $authuser\n");
    216218    }
    217219  } else {
  • trunk/cgi-bin/main.cgi

    r866 r881  
    891891      mailNotify($ip_dbh, "a$webvar{alloctype}", "ADDED: $disp_alloctypes{$webvar{alloctype}} allocation",
    892892        "$disp_alloctypes{$webvar{alloctype}} $msg allocated to customer $webvar{custid}\n".
    893         "Description: $webvar{desc}\n\nAllocated by: $authuser\n");
     893        "Description: $webvar{desc}\n".
     894        ($webvar{rdns} ? "DNS name: $webvar{rdns}\n" : '').
     895        "\nAllocated by: $authuser\n");
    894896    } else {
    895897      my $netblock = new NetAddr::IP $webvar{fullcidr};
     
    913915      mailNotify($ip_dbh, "a$webvar{alloctype}", "ADDED: $disp_alloctypes{$webvar{alloctype}} allocation",
    914916        "$disp_alloctypes{$webvar{alloctype}} $webvar{fullcidr} allocated to customer $webvar{custid}\n".
    915         "Description: $webvar{desc}\n\nAllocated by: $authuser\n");
     917        "Description: $webvar{desc}\n".
     918        ($webvar{rdns} ? "DNS name/pattern: $webvar{rdns}\n" : '').
     919        "\nAllocated by: $authuser\n");
    916920    }
    917921    syslog "notice", "$authuser allocated '$webvar{fullcidr}' to '$webvar{custid}' as ".
Note: See TracChangeset for help on using the changeset viewer.