mirror of
https://github.com/arsenetar/dupeguru.git
synced 2026-01-22 14:41:39 +00:00
Improved delta values to support non-numerical values
Delta values now work for non-numerical values. Any column, when its value differs from its ref, becomes orange. A column that was already a "delta column" keeps its previous behavior (dupe cells for these columns are always displayed in orange). Sorting behavior, when Dupes Only and Delta Values are enabled at the same time, has also been extended to non-numerical values, making it easy to mass-mark dupe rows with orange values. Documentation was updated, unit tests were added. Fixes #213
This commit is contained in:
@@ -62,15 +62,6 @@ class DupeGuru(DupeGuruBase):
|
||||
def __init__(self):
|
||||
DupeGuruBase.__init__(self, DupeGuruView(), '/tmp')
|
||||
|
||||
def _get_dupe_sort_key(self, dupe, get_group, key, delta):
|
||||
r = cmp_value(dupe, key)
|
||||
if delta and (key in self.result_table.DELTA_COLUMNS):
|
||||
r -= cmp_value(get_group().ref, key)
|
||||
return r
|
||||
|
||||
def _get_group_sort_key(self, group, key):
|
||||
return cmp_value(group.ref, key)
|
||||
|
||||
def _prioritization_categories(self):
|
||||
return prioritize.all_categories()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user