teacher side functionality complete