Adds a Confirm Delete page and actually delete the assets.

This commit is contained in:
2018-07-07 12:21:12 +00:00
parent 344db6e4c5
commit e40c05c1f8
7 changed files with 114 additions and 2 deletions

View File

@@ -485,6 +485,14 @@ class Asset
if (!unlink(ASSETSDIR . '/' . $this->subdir . '/' . $this->filename))
return false;
$db->query('
UPDATE tags
SET id_asset_thumb = 0
WHERE id_asset_thumb = {int:id_asset} AND kind = "Album"',
[
'id_asset' => $this->id_asset,
]);
$db->query('
DELETE FROM assets_meta
WHERE id_asset = {int:id_asset}',