Changeset 315 for trunk/dns.cgi


Ignore:
Timestamp:
04/24/12 17:17:48 (13 years ago)
Author:
Kris Deugau
Message:

/trunk

Action logging all appears to be moved to DNSDB.pm. Removed
logaction() in dns.cgi. Closes #35

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dns.cgi

    r314 r315  
    21332133
    21342134
    2135 sub logaction {
    2136   my $domid = shift;
    2137   my $username = shift;
    2138   my $groupid = shift;
    2139   my $entry = shift;
    2140   my $revid = shift || 0;
    2141 
    2142 ##fixme: push SQL into DNSDB.pm
    2143 ##fixme: add bits to retrieve group/domain name info to retain after entity is deleted?
    2144   my $sth = $dbh->prepare("SELECT user_id, firstname || ' ' || lastname FROM users WHERE username=?");
    2145   $sth->execute($username);
    2146   my ($user_id, $fullname) = $sth->fetchrow_array;
    2147 
    2148   $sth = $dbh->prepare("INSERT INTO log (domain_id,user_id,group_id,email,name,entry,rdns_id) ".
    2149         "VALUES (?,?,?,?,?,?,?)") or warn $dbh->errstr;
    2150   $sth->execute($domid,$user_id,$groupid,$username,$fullname,$entry,$revid) or warn $sth->errstr;
    2151 } # end logaction()
    2152 
    2153 
    21542135# we have to do this in a variety of places;  let's make it consistent
    21552136sub fill_permissions {
Note: See TracChangeset for help on using the changeset viewer.