from .tool.func import * def give_user_check_2(conn, name): curs = conn.cursor() plus_id = flask.request.args.get('plus', None) if admin_check('all', None, name) == 1 or (plus_id and admin_check('all', None, plus_id) == 1): if admin_check() != 1: return re_error('/error/4') num = int(number_check(flask.request.args.get('num', '1'))) sql_num = (num * 50 - 50) if num * 50 > 0 else 0 div = '' check_type = flask.request.args.get('type', '') if admin_check(4, (check_type + ' ' if check_type != '' else '') + 'check (' + name + ')') != 1: return re_error('/error/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] + ''' |
| ''' + load_lang('name') + ''' | ''' + load_lang('ip') + ''' | ''' + load_lang('time') + ''' |
| ''' + data[0] + ''' (''' + load_lang('delete') + ''') | ''' + data[1] + ''' | ''' + data[3] + ''' |
| ''' + ua + ''' | ||