from rest_framework import serializers
from ..models import InAppNotification

class InAppNotificationSerializer(serializers.ModelSerializer):
    created_on = serializers.DateTimeField(format="%Y-%m-%d %H:%M:%S")

    class Meta:
        model = InAppNotification
        fields = ['id', 'message', 'is_read', 'created_on']
