In this post we are going to write Trigger on parent record i.e "WorkOrder". The trigger prevent WorkOrder status to get Complete until all associated WorkOrderLineItem which is the child record, status gets complete. (One parent can have many child)