Help with writing deluge function

Help with writing deluge function

Hello guys, i am working on wrting deluge that his scenario says:
when a lead is on status "Not Qualified"
search the related scheudle calls
and change their call status to "Cancelled"

unfourtently its not working
somebody can help me about it?
i am attaching a photo below