rating/source/locked now log info when set
This commit is contained in:
parent
eeaa27133a
commit
7049b3bf4d
2 changed files with 3 additions and 0 deletions
|
@ -208,6 +208,7 @@ class Ratings implements Extension {
|
|||
private function set_rating($image_id, $rating) {
|
||||
global $database;
|
||||
$database->Execute("UPDATE images SET rating=? WHERE id=?", array($rating, $image_id));
|
||||
log_info("core-image", "Rating for Image #{$image_id} set to: ".$this->theme->rating_to_name($rating));
|
||||
}
|
||||
}
|
||||
add_event_listener(new Ratings());
|
||||
|
|
|
@ -372,6 +372,7 @@ class Image {
|
|||
global $database;
|
||||
if(empty($source)) $source = null;
|
||||
$database->execute("UPDATE images SET source=:source WHERE id=:id", array("source"=>$source, "id"=>$this->id));
|
||||
log_info("core-image", "Source for Image #{$this->id} set to: ".$source);
|
||||
}
|
||||
|
||||
|
||||
|
@ -385,6 +386,7 @@ class Image {
|
|||
$sln = str_replace("'", "", $sln);
|
||||
$sln = str_replace('"', "", $sln);
|
||||
$database->execute("UPDATE images SET locked=:yn WHERE id=:id", array("yn"=>$sln, "id"=>$this->id));
|
||||
log_info("core-image", "Locked status of Image #{$this->id} set to: ".$sln);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Reference in a new issue