gbmodel/model_sqlalchemy.py
def check_dup_team(self, t_name, session_id):
        """
        Check if the new team name already existed in the given session
        Input: name of the new team and session id of the selected session
        Output: return False if the team already exists, True otherwise
        """
        try:
            result = teams().query.filter_by(name=t_name,
                                             session_id=session_id).first()
        except exc.SQLAlchemyError:
            handle_exception()
            result = None

        if result is not None:
            return False
        return True

        Check if the new team name already existed in the given session
        Input: name of the new team and session id of the selected session
        Output: return False if the team already exists, True otherwise
        
Check if the new team name already existed in the given session
Input: name of the new team and session id of the selected session
Output: return False if the team already exists, True otherwise
Check if the new team name already existed in the given session Input : name of the new team and session id of the selected session Output : return False if the team already exists True otherwise
def check_dup_team(self, t_name, session_id):
        try:
            result = teams().query.filter_by(name=t_name,
                                             session_id=session_id).first()
        except exc.SQLAlchemyError:
            handle_exception()
            result = None
        if result is not None:
            return False
        return True
def check_dup_team ( self , t_name , session_id ) : try : result = teams ( ) . query . filter_by ( name = t_name , session_id = session_id ) . first ( ) except exc . SQLAlchemyError : handle_exception ( ) result = None if result is not None : return False return True
Check if the new team name already existed in the given session
Input: name of the new team and session id of the selected session
Output: return False if the team already exists, True otherwise
Check if the new team name already existed in the given session Input : name of the new team and session id of the selected session Output : return False if the team already exists True otherwise
"""
        Check if the new team name already existed in the given session
        Input: name of the new team and session id of the selected session
        Output: return False if the team already exists, True otherwise
        """
self
t_name
session_id