from .tool.func import * async def list_user_check(name = 'test', plus_name = None, arg_num = 1, do_type = 'normal'): with get_db_connect() as conn: curs = conn.cursor() plus_id = plus_name check_type = do_type if do_type in ['simple', 'normal'] else 'normal' check_type = '' if check_type == 'normal' else check_type num = arg_num sql_num = (num * 50 - 50) if num * 50 > 0 else 0 if await acl_check(tool = 'all_admin_auth', ip = name) != 1 or (plus_id and await acl_check(tool = 'all_admin_auth', ip = plus_id) != 1): if await acl_check('', 'owner_auth', '', '') == 1: return await re_error(conn, 4) div = '' if await acl_check(tool = 'check_auth', memo = (check_type + ' ' if check_type != '' else '') + 'check (' + name + ')') == 1: return await re_error(conn, 3) if check_type == '': if ip_or_user(name) == 0: curs.execute(db_change("select data from user_set where name = \"approval_question\" and id = ?"), [name]) approval_question = curs.fetchall() if approval_question and approval_question[0][0]: curs.execute(db_change("select data from user_set where name = \"approval_question_answer\" and id = ?"), [name]) approval_question_answer = curs.fetchall() if approval_question_answer and approval_question_answer[0]: div += '''
| Q | ''' + approval_question[0][0] + ''' | A | ''' + approval_question_answer[0][0] + ''' |
| ''' + get_lang(conn, 'name') + ''' | ''' + get_lang(conn, 'ip') + ''' | ''' + get_lang(conn, 'time') + ''' |
| ''' + data[0] + ''' (''' + get_lang(conn, 'delete') + ''') | ''' + data[1] + ''' | ''' + data[3] + ''' |
| ''' + ua + ''' | ||