def sort_by(self, name, sort_dir='asc'):
        """Sort by a given variable."""
        logger.log(5, "Sort by `%s` %s.", name, sort_dir)
        self.eval_js('table.sortBy("{}", "{}");'.format(name, sort_dir))
def sort_by ( self , name , sort_dir = 'asc' ) : logger . log ( 5 , "Sort by `%s` %s." , name , sort_dir ) self . eval_js ( 'table.sortBy("{}", "{}");' . format ( name , sort_dir ) )
Sort by a given variable.