1.    At any stage of the proceedings, upon application of a party or on the court’s own motion, the court may make an order restraining or otherwise controlling the conduct of an individual if the court finds the conduct:

Terms Used In North Dakota Code 27-20.1-20

a.    Is or may be detrimental or harmful to the child; or

b.    Will tend to defeat the execution of an order of disposition; and

2.    Due notice of the application or motion and the grounds therefor and an opportunity to be heard have been given to the person against whom the order is directed.