Used django json serializer to send flag objects back to client side. This data has been parsed by json reader and is ready to be used in modal window.