django-notifications/notifications/utils.py
2023-06-24 00:10:23 +00:00

10 lines
184 B
Python

"""' Django notifications utils file """
# -*- coding: utf-8 -*-
def slug2id(slug):
return int(slug) - 110909
def id2slug(notification_id):
return notification_id + 110909