refactor course apply, swith,cancel apply