bettar / miele-lxiv

DICOM Viewer 64-bit fully open source
https://itunes.apple.com/us/app/miele-lxiv/id988332475
GNU General Public License v3.0
111 stars 29 forks source link

Customizing database cleanup options #108

Closed infinus closed 1 year ago

infinus commented 1 year ago

Is it possible to make the database auto cleaning feature a bit more flexible with dates? I'd like to be able to select how many weeks/months/years instead of using the current preset options. I've mocked up an example in photoshop:

sample

bettar commented 1 year ago

In your photoshop mockup you are showing a setting of "1" "months" which is already one of the currently available choices. Realistically, what would be the range of your proposed spinboxes, for example [1..12] or should it be [1..7] ? to be combined with [weeks,months,years] ? Would you also like days ?

Just to understand what your are missing with the current implementation, if your request was already implemented how would you set it up, something like "5 months" ? Please give some examples. Let's also hear the comments from other users...

infinus commented 1 year ago

We could include days for maximum flexibility for all use cases!  But now that you ask perhaps a text field allowing for only numeric entry instead of a drop down for the numeric portion. 

Here is my reasoning:

Say you are using acquisition date as the metric. If  we have a drop down the option of days, months years I’d say the numbers would have to go to at least 31 since there can be 31 days a month. This would also scale to a max of 31 years which is a long time but there may be use cases where you could be looking at datasets across a persons lifetime which could be larger than 31 years especially if older images are digitized or anonymized images that have random dates entered as the acquisition date. 

I think by having text entry this gives you maximum usefulness in the broadest use cases. Generally people will use auto cleaning for various reasons. Either to maintain  drive space, for legal or other required reasons. Using the current implementation is not very useful at all because the maximum term is entirely too short! 

This maximum flexibility would also be helpful if you ever elect to implement the archive feature as you could use the same logic to move data vs delete.

bettar commented 1 year ago

You didn't give me the answer I asked, which I am going to repeat, for the purpose of understanding your use case: if this functionality was already implemented, was values would you set for:

infinus commented 1 year ago

For my specific use case right now I would likely choose 6-10 years from acquisition date.

bettar commented 1 year ago

another option could be to write a plugin that does the database cleaning according to your custom rules

infinus commented 1 year ago

Unfortunately the ability to code was not something I've been blessed with. I've tried but I've had as much luck learning to code as I did learning French. Despite many attempts coding has eluded me!

bettar commented 1 year ago

For my specific use case right now I would likely choose 6-10 years from acquisition date.

so you wouldn't use the second new setting that you are requesting, "delete studies not opened during last:" ?