diff options
Diffstat (limited to 'ishtar_common/utils.py')
-rw-r--r-- | ishtar_common/utils.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ishtar_common/utils.py b/ishtar_common/utils.py index 8cb06aacb..1c64f7940 100644 --- a/ishtar_common/utils.py +++ b/ishtar_common/utils.py @@ -441,6 +441,14 @@ def get_all_related_objects(model): ] +def num2col(n): + string = "" + while n > 0: + n, remainder = divmod(n - 1, 26) + string = chr(65 + remainder) + string + return string + + def merge_tsvectors(vectors): """ Parse tsvector to merge them in one string |