What is our justification for crying on our loved ones when it is mentioned that Imam Ali is saying that Holy Prophet forbade us from crying and asked us to be patient

What Prophet prohibited is not crying, but getting to a state called jazza, where the person do things like beating himself, or objecting what Allah did.
Crying is an emotional case, which can not be controlled. Even Prophet himself cried when his son Ibrahim died.