First alpha release

Added following features to 1.0.0
### 1.0.0
- Consolidated buttons and links on report into dropdown buttons.
- On report, added dropdown menu options for flags.
- Rename Tools-UI advance duplicate tagged menu to [**Advance Duplicate File Deletion Menu**]
- When [**Advance Duplicate File Deletion Menu**] completes report, gives user prompt to open the report in browser.
- Added performance enhancement for removing (clearing) duplicate tags from all scenes by using SQL call.
- Added option to report to delete files that do not exist by duplicate candidates in report, as well as by tagged files.
- Added logic to disable scene in report if deleted by [**Advance Duplicate File Deletion Menu**]. Note: Requires a refresh.
- Added report option to delete by flags set on the report.
This commit is contained in:
David Maisonave
2024-11-26 19:52:21 -05:00
parent e1f3335db8
commit 214ba134c4
10 changed files with 392 additions and 98 deletions

View File

@@ -846,6 +846,22 @@ class StashPluginHelper(StashInterface):
return None
return results['rows'][0][0]
def removeTagFromAllScenes(self, tagName=None, tagID=-1): # Requires either tagName or tagID to be populated.
if tagID < 1:
if tagName == None or tagName == "":
self.Error("Called removeTagFromAllScenes without a tagName or a tagID. One of these two fields MUST be populated.")
return False
if tag := self.find_tag(tagName):
tagID = tag['id']
else:
self.Warn(f"Failed to get tag {tagName}.")
return False
self.Debug(f"Removing tag ID {tagID} from all scenes.")
results = self.sql_commit(f"delete from scenes_tags where tag_id = {tagID}")
self.Debug(f"Called sql_commit and received results {results}.")
return True
# ############################################################################################################
# Functions which are candidates to be added to parent class use snake_case naming convention.
# ############################################################################################################