settings function in teacher ctrl