Compare commits
10
Commits
377fab52f7
...
xuchao
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a620a5c033 | ||
|
|
dfd26d7e4d | ||
|
|
b1fec7c10e | ||
|
|
b88088dcd8 | ||
|
|
d221c8a439 | ||
|
|
00cc714db6 | ||
|
|
9b2bb81578 | ||
|
|
b8e7c64b7f | ||
|
|
dee774ee73 | ||
|
|
c11dac5363 |
@@ -0,0 +1,85 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 只读审计——hhrs_lottery_pool.member_phone vs 《第二批年龄段25-40岁抽奖数据.xlsx》(2026-11-18 用户指令"比对手机不一致数量")
|
||||
# 用法: python3 docs/tools_audit_phone_vs_doc_20261118.py # 纯只读,不写库不改文件
|
||||
# 口径: 池按主键 id 关联文件 ID;池存掩码(前3+****+后4),文件明文按 11-10/11-17 既定白名单口径转掩码后比对;
|
||||
# 文件手机非法/空 → 期望 NULL。分类统计不一致,并抽样展示。
|
||||
import sys, os, re
|
||||
import pandas as pd
|
||||
|
||||
SRC = os.path.expanduser('~/Downloads/第二批年龄段25-40岁抽奖数据.xlsx')
|
||||
# 2026-11-18 文件为20列全量发卡明细:按位置取 col0=ID, col1=身份证, col2=姓名, col5=手机, col8=县区
|
||||
F = pd.read_excel(SRC, dtype=str, usecols=[0, 1, 2, 5, 8]).fillna('')
|
||||
F.columns = ['ID', '身份证', '姓名', '手机', '县区']
|
||||
print('文件行数:', len(F))
|
||||
assert F['ID'].astype(int).is_unique, '文件ID不唯一'
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
|
||||
def expect_mask(p):
|
||||
return (p[:3] + '****' + p[7:11]) if re.fullmatch(r'\d{11}', p) and p[:3] in allowed else None
|
||||
|
||||
fmap = {int(i): expect_mask(p) for i, p in zip(F['ID'], F['手机'])}
|
||||
n_valid = sum(1 for v in fmap.values() if v)
|
||||
print(f'文件 {len(fmap)} 行: 白名单口径有效手机 {n_valid}, 期望NULL {len(fmap)-n_valid}')
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT id, member_phone, created_time FROM hhrs_lottery_pool")
|
||||
pool = cur.fetchall()
|
||||
print('池总行数:', len(pool))
|
||||
|
||||
covered = [r for r in pool if r['id'] in fmap]
|
||||
uncovered = len(pool) - len(covered)
|
||||
print(f'文件覆盖池 {len(covered)} 行, 未覆盖(不在文件) {uncovered} 行')
|
||||
|
||||
cats = {'一致': 0, '掩码不同': 0, '池NULL但文件有效': 0, '池有值但文件应NULL': 0}
|
||||
samples = {k: [] for k in cats if k != '一致'}
|
||||
by_ct = {}
|
||||
for r in covered:
|
||||
exp = fmap[r['id']]
|
||||
got = r['member_phone']
|
||||
if got == exp:
|
||||
cats['一致'] += 1
|
||||
continue
|
||||
if got is None and exp is not None:
|
||||
k = '池NULL但文件有效'
|
||||
elif got is not None and exp is None:
|
||||
k = '池有值但文件应NULL'
|
||||
else:
|
||||
k = '掩码不同'
|
||||
cats[k] += 1
|
||||
if len(samples[k]) < 5:
|
||||
samples[k].append((r['id'], got, exp))
|
||||
for r in covered:
|
||||
ct = str(r['created_time'])
|
||||
by_ct.setdefault(ct, [0, 0])
|
||||
by_ct[ct][1] += 1
|
||||
if r['member_phone'] == fmap[r['id']]:
|
||||
by_ct[ct][0] += 1
|
||||
|
||||
print('\n=== 比对结果(文件覆盖范围内) ===')
|
||||
for k, v in cats.items():
|
||||
print(f'{k}: {v}')
|
||||
total_bad = sum(v for k, v in cats.items() if k != '一致')
|
||||
print(f'不一致合计: {total_bad}')
|
||||
print('\n按 created_time 分布(一致/总数):')
|
||||
for ct, (ok, tot) in sorted(by_ct.items()):
|
||||
print(f' {ct}: {ok}/{tot} (不一致 {tot-ok})')
|
||||
print('\n抽样(池id, 池现值, 文件期望掩码):')
|
||||
for k, ss in samples.items():
|
||||
for s in ss:
|
||||
print(f' [{k}] {s}')
|
||||
conn.close()
|
||||
@@ -0,0 +1,57 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 抽奖池手机号合规审计——按白名单号段+掩码格式全表排查,不合规的未中奖数据导出明细CSV
|
||||
# 用法: python3 docs/tools_audit_pool_phone_20261110.py
|
||||
# 口径与 tools_import_activated_batch_20261110.py 完全一致(号段白名单58段+「3+4星+4」格式);只读。
|
||||
import os, re
|
||||
import pymysql
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
_pat = re.compile(r'^(\d{3})\*{4}\d{4}$')
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
total = cur.fetchone()['c']
|
||||
cur.execute("SELECT id, member_name, county, member_identity_no, member_phone, won, created_time FROM hhrs_lottery_pool")
|
||||
bad = []
|
||||
for r in cur.fetchall():
|
||||
p = r['member_phone'] or ''
|
||||
m = _pat.match(p)
|
||||
if not m:
|
||||
why = '空值' if p == '' else '格式异常(非3+4星+4)'
|
||||
elif m.group(1) not in allowed:
|
||||
why = '号段不在白名单'
|
||||
else:
|
||||
continue
|
||||
r['问题'] = why
|
||||
bad.append(r)
|
||||
print(f'全池 {total} 行, 不合规 {len(bad)} 行')
|
||||
from collections import Counter
|
||||
bw = [r for r in bad if r['won'] == 0]
|
||||
ww = [r for r in bad if r['won'] == 1]
|
||||
print('其中 未中奖(won=0):', len(bw), ' 已中奖(won=1):', len(ww))
|
||||
print('未中奖问题分布:', Counter(r['问题'] for r in bw).most_common())
|
||||
print('未中奖号段分布:', Counter((r['member_phone'] or '')[:3] for r in bw if r['问题'] == '号段不在白名单').most_common())
|
||||
print('未中奖县区分布:', Counter(r['county'] for r in bw).most_common())
|
||||
|
||||
out = os.path.join(os.path.dirname(os.path.abspath(__file__)), '抽奖池_存量手机号不合规明细_20261110.csv')
|
||||
with open(out, 'w', encoding='utf-8-sig') as f:
|
||||
f.write('id,姓名,县区,脱敏身份证,脱敏手机号,问题,创建时间\n')
|
||||
for r in sorted(bw, key=lambda x: x['id']):
|
||||
f.write(f"{r['id']},{r['member_name']},{r['county']},{r['member_identity_no']},{r['member_phone']},{r['问题']},{r['created_time']}\n")
|
||||
print('未中奖明细已导出:', out)
|
||||
for r in ww:
|
||||
print('已中奖不合规(需单独关注):', r['id'], r['member_name'], r['county'], r['member_phone'], r['问题'])
|
||||
@@ -0,0 +1,53 @@
|
||||
# xuchao: 第四轮(2026-11-17)中奖公示回填执行脚本——干跑确认后 UPDATE 并验证
|
||||
# 用法: python3 docs/tools_backfill_round4_20261117.py
|
||||
# 沿用三期回填模式(见 tools_backfill_round3.py);WHERE draw_date IS NULL 保证幂等。
|
||||
# 与三期脚本的差异: card_model_id 直接写修正后的正式卡种 831756570496837
|
||||
# (三期回填时写的是测试卡种 747609734826757, 后续已随数据订正迁移, 此处不再沿用旧值)。
|
||||
# 回滚SQL(如需):
|
||||
# UPDATE hhrs_winner SET card_model_id=NULL, draw_date=NULL, prize_name=NULL,
|
||||
# prize_type=NULL, prize_amount=NULL WHERE round_id=857957849313349;
|
||||
import os
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
marker = "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
head = src.split(marker, 1)[0] + marker
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
R4 = 857957849313349 # xuchao: 第四轮轮次ID, 开奖日 2026-11-17
|
||||
|
||||
# 干跑: 确认轮次开奖日期与待回填行数(期望 2000)
|
||||
cur.execute("SELECT draw_date FROM hhrs_draw_round WHERE id=%s", (R4,))
|
||||
row = cur.fetchone()
|
||||
assert row and row['draw_date'] is not None, '轮次不存在或开奖日期为空'
|
||||
draw_date = str(row['draw_date'])
|
||||
print('第四轮开奖日期:', draw_date)
|
||||
assert draw_date == '2026-11-17', f'开奖日期与预期 2026-11-17 不符: {draw_date}'
|
||||
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_winner WHERE round_id=%s AND draw_date IS NULL", (R4,))
|
||||
pending = cur.fetchone()['c']
|
||||
print('待回填行数:', pending)
|
||||
if pending == 0:
|
||||
print('已回填过,无需重复执行')
|
||||
raise SystemExit
|
||||
assert pending == 2000, '行数与预期 2000 不符,中止'
|
||||
|
||||
cur.execute("""
|
||||
UPDATE hhrs_winner w JOIN hhrs_draw_round r ON r.id=w.round_id
|
||||
SET w.card_model_id=831756570496837, w.draw_date=r.draw_date,
|
||||
w.prize_name='怀化市社保卡千万好礼促消费千元权益包',
|
||||
w.prize_type='权益包', w.prize_amount=100000
|
||||
WHERE w.round_id=%s AND w.draw_date IS NULL""", (R4,))
|
||||
print('实际更新行数:', cur.rowcount)
|
||||
conn.commit()
|
||||
|
||||
# 验证: dates 接口口径(正式卡种)应含四个开奖日, 四期各 2000 行
|
||||
cur.execute("""SELECT draw_date, COUNT(*) c FROM hhrs_winner
|
||||
WHERE card_model_id=831756570496837 AND draw_date IS NOT NULL
|
||||
GROUP BY draw_date ORDER BY draw_date""")
|
||||
print('回填后公示日期分布:', {str(r['draw_date']): r['c'] for r in cur.fetchall()})
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_winner WHERE round_id=%s AND draw_date IS NULL", (R4,))
|
||||
assert cur.fetchone()['c'] == 0, '仍有未回填行'
|
||||
print('验证通过')
|
||||
@@ -0,0 +1,138 @@
|
||||
# xuchao: 第四轮(round_id=857957849313349)中奖 2000 人整批赠卡激活+绑卡
|
||||
# 镜像三轮 10-30 批量做法:卡源=怀化人社待售卡(business_id=842467665375109,state=1,卡号升序);
|
||||
# 刘逸帆 431202199910060033 已于 11-23 晨地推批次绑定,跳过 → 实绑 1999。
|
||||
# 一证一卡/校验位/轮内去重已在干跑预检通过(0 坏号/0 重复)。
|
||||
# 用法: python3 docs/tools_bind_round4_20261123.py # 干跑(默认,零写入)
|
||||
# python3 docs/tools_bind_round4_20261123.py --apply # 真执行(备份表→每200一事务)
|
||||
# 回滚(如需):
|
||||
# DELETE FROM card_bind WHERE id IN (对照表 bind_id);
|
||||
# UPDATE card SET state=1,is_active=0,is_bind=0,is_donation=0,identity_no=NULL,phone=NULL,
|
||||
# active_time=NULL,bind_time=NULL,validity_start=NULL,validity_end=NULL
|
||||
# WHERE id IN (对照表 card_id); -- 或按备份表 card_zzt_bak_<ts> 还原
|
||||
import sys, time, random, datetime, pymysql
|
||||
|
||||
APPLY = '--apply' in sys.argv
|
||||
CM = 831756570496837
|
||||
BIZ = 842467665375109
|
||||
R4 = 857957849313349
|
||||
TS = datetime.datetime.now().strftime('%Y%m%d%H%M%S')
|
||||
BAK_CARD = f'card_zzt_bak_{TS}'
|
||||
BAK_BIND = f'card_bind_zzt_bak_{TS}'
|
||||
CSV = f'/Users/jacobxu/Downloads/1123第四轮抽奖轮次-绑卡对照表.csv'
|
||||
|
||||
conn = pymysql.connect(host='47.99.164.129', port=3306, user='root', password='12301@123',
|
||||
database='dscp_business_uat', charset='utf8mb4',
|
||||
cursorclass=pymysql.cursors.DictCursor, autocommit=False)
|
||||
cur = conn.cursor()
|
||||
|
||||
# 1. 名单:GB11643 校验 + 轮内去重 + 剔除已有绑定(一证一卡)
|
||||
cur.execute("SELECT member_identity_no idno, member_name nm, county, id FROM hhrs_winner WHERE round_id=%s ORDER BY id", (R4,))
|
||||
winners = cur.fetchall()
|
||||
W = [7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2]; M = '10X98765432'
|
||||
def ok(s):
|
||||
s = s.strip().upper()
|
||||
if len(s) != 18 or not s[:17].isdigit(): return False
|
||||
return M[sum(int(c)*w for c, w in zip(s[:17], W)) % 11] == s[-1]
|
||||
seen, roster = set(), []
|
||||
for w in winners:
|
||||
idno = w['idno'].strip().upper()
|
||||
if not ok(idno) or idno in seen:
|
||||
print('剔除(坏号或轮内重复):', w); continue
|
||||
seen.add(idno)
|
||||
cur.execute("SELECT COUNT(*) c FROM card_bind WHERE identity_no=%s AND card_model_id=%s AND state=4 AND is_deleted=0", (idno, CM))
|
||||
if cur.fetchone()['c']:
|
||||
print('跳过(已绑定):', w['idno'], w['nm']); continue
|
||||
roster.append((idno, w))
|
||||
print(f'名单 {len(winners)} → 实绑 {len(roster)}')
|
||||
assert len(roster) == 1999, f'实绑数与预期 1999 不符,中止'
|
||||
|
||||
# 2. 卡源:怀化人社待售卡,卡号升序取同样张数;不足即中止
|
||||
cur.execute("SELECT COUNT(*) c FROM card WHERE card_model_id=%s AND business_id=%s AND state=1 AND is_deleted=0", (CM, BIZ))
|
||||
avail = cur.fetchone()['c']
|
||||
cur.execute("""SELECT id, card_number FROM card WHERE card_model_id=%s AND business_id=%s
|
||||
AND state=1 AND is_deleted=0 ORDER BY card_number LIMIT %s""", (CM, BIZ, len(roster)))
|
||||
cards = cur.fetchall()
|
||||
print(f'待售卡 {avail} 张, 取卡号升序 {len(cards)} 张: {cards[0]["card_number"]} ~ {cards[-1]["card_number"]}')
|
||||
assert len(cards) == len(roster), '可用卡不足,中止'
|
||||
|
||||
# 3. 干跑:打印首末配对与备份表名,不写
|
||||
if not APPLY:
|
||||
for i in (0, 1, len(roster)-1):
|
||||
print('样例配对:', roster[i][0], roster[i][1]['nm'], '->', cards[i]['card_number'])
|
||||
print(f'[干跑] 将建备份表 {BAK_CARD}(该商户全部 state=1 卡)/{BAK_BIND}(本卡种 bind 行),事务每200一批')
|
||||
sys.exit(0)
|
||||
|
||||
# 4. 备份表
|
||||
cur.execute(f"CREATE TABLE {BAK_CARD} AS SELECT * FROM card WHERE card_model_id=%s AND business_id=%s AND state=1", (CM, BIZ))
|
||||
cur.execute(f"CREATE TABLE {BAK_BIND} AS SELECT * FROM card_bind WHERE card_model_id=%s", (CM,))
|
||||
conn.commit()
|
||||
print('备份表完成:', BAK_CARD, cur.execute(f"SELECT COUNT(*) c FROM {BAK_CARD}") and cur.fetchone()['c'], '/', BAK_BIND, cur.execute(f"SELECT COUNT(*) c FROM {BAK_BIND}") and cur.fetchone()['c'])
|
||||
|
||||
# 5. 激活+绑定,每200行一事务(镜像 updateCardActivedZeng+uatbind.py 最终形态)
|
||||
now = datetime.datetime.now().replace(microsecond=0)
|
||||
end = now + datetime.timedelta(days=365)
|
||||
pairs = list(zip(roster, cards))
|
||||
rows_csv = []
|
||||
B = 200
|
||||
for bi in range(0, len(pairs), B):
|
||||
chunk = pairs[bi:bi+B]
|
||||
try:
|
||||
bind_ids = []
|
||||
ins = []
|
||||
for (idno, w), c in chunk:
|
||||
bid = int(time.time()*1000)*100000 + random.randint(0, 99999)
|
||||
# 防同秒 id 撞:递增保证块内唯一
|
||||
while any(x[0] == bid for x in bind_ids): bid += 1
|
||||
bind_ids.append((bid, c['id'], c['card_number'], idno))
|
||||
ins.append((bid, c['id'], CM, '怀化社保卡权益包', c['card_number'], 1, idno, now, end.date(), now, now))
|
||||
cur.executemany("""INSERT INTO card_bind (id, card_id, card_model_id, card_model_name, card_number,
|
||||
binder_type, identity_no, bind_time, expires_time, state, is_deleted, created_by, created_time, updated_by, updated_time)
|
||||
VALUES (%s,%s,%s,%s,%s,%s,%s,%s,%s,4,0,1,%s,1,%s)""", ins)
|
||||
for (bid, card_id, card_number, idno) in bind_ids:
|
||||
cur.execute("""UPDATE card SET state=4, is_active=1, is_donation=1, is_bind=1,
|
||||
active_time=%s, active_by=1, bind_time=%s, bind_by=1, identity_no=%s, phone=NULL,
|
||||
validity_start=%s, validity_end=%s, updated_by=1, updated_time=%s
|
||||
WHERE id=%s AND state=1 AND is_deleted=0""", (now, now, idno, now, end, now, card_id))
|
||||
assert cur.rowcount == 1, f'卡 {card_number} 更新行数 {cur.rowcount}!=1'
|
||||
conn.commit()
|
||||
for (idno, w), c in chunk:
|
||||
rows_csv.append((w['id'], idno, w['nm'], w['county'], c['card_number']))
|
||||
print(f'块 {bi//B+1}: {len(chunk)} 成功 (累计 {len(rows_csv)})')
|
||||
except Exception as e:
|
||||
conn.rollback()
|
||||
print(f'块 {bi//B+1} 失败,降级逐行: {e}')
|
||||
for (idno, w), c in chunk:
|
||||
try:
|
||||
bid = int(time.time()*1000)*100000 + random.randint(0, 99999)
|
||||
cur.execute("""INSERT INTO card_bind (id, card_id, card_model_id, card_model_name, card_number,
|
||||
binder_type, identity_no, bind_time, expires_time, state, is_deleted, created_by, created_time, updated_by, updated_time)
|
||||
VALUES (%s,%s,%s,%s,%s,1,%s,%s,%s,4,0,1,%s,1,%s)""",
|
||||
(bid, c['id'], CM, '怀化社保卡权益包', c['card_number'], idno, now, end.date(), now, now))
|
||||
cur.execute("""UPDATE card SET state=4, is_active=1, is_donation=1, is_bind=1,
|
||||
active_time=%s, active_by=1, bind_time=%s, bind_by=1, identity_no=%s, phone=NULL,
|
||||
validity_start=%s, validity_end=%s, updated_by=1, updated_time=%s
|
||||
WHERE id=%s AND state=1 AND is_deleted=0""", (now, now, idno, now, end, now, c['id']))
|
||||
assert cur.rowcount == 1
|
||||
conn.commit()
|
||||
rows_csv.append((w['id'], idno, w['nm'], w['county'], c['card_number']))
|
||||
except Exception as e2:
|
||||
conn.rollback()
|
||||
print('单行失败:', idno, w['nm'], c['card_number'], e2)
|
||||
|
||||
# 6. 终验
|
||||
cur.execute(f"""SELECT COUNT(*) c, COUNT(DISTINCT b.identity_no) u,
|
||||
SUM(b.name IS NOT NULL OR b.phone IS NOT NULL OR b.member_id IS NOT NULL) nn,
|
||||
MIN(b.bind_time) mn, MAX(b.bind_time) mx
|
||||
FROM card_bind b WHERE b.card_model_id=%s AND b.created_time>=%s""", (CM, now))
|
||||
print('终验 bind:', cur.fetchone())
|
||||
cur.execute("""SELECT COUNT(*) c FROM card WHERE card_model_id=%s AND business_id=%s AND state=4 AND bind_time>=%s""", (CM, BIZ, now))
|
||||
print('终验 card 新绑:', cur.fetchone())
|
||||
|
||||
# 7. 对照表 CSV
|
||||
import csv
|
||||
with open(CSV, 'w', newline='', encoding='utf-8-sig') as f:
|
||||
wcsv = csv.writer(f)
|
||||
wcsv.writerow(['winner_id', '身份证号', '姓名', '县区', '卡号'])
|
||||
wcsv.writerows(rows_csv)
|
||||
print(f'对照表 {len(rows_csv)} 行 → {CSV}')
|
||||
conn.close()
|
||||
@@ -0,0 +1,73 @@
|
||||
# xuchao: 怀化石化(减免卷)存量"已关闭"预约改为已核销——UAT(即生产库)数据修复
|
||||
# 用法: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 docs/tools_checkoff_petrol_closed_20261116.py # 干跑
|
||||
# ... docs/tools_checkoff_petrol_closed_20261116.py --apply # 实际执行
|
||||
# 背景: AppointmentScheduledTask 每晚23:45将当日未核销预约置"已关闭";资源开关
|
||||
# is_appointment_count 已于 2026-11-16 09:47 在管理后台开启(updated_by=1),
|
||||
# 此后新预约到期将自动核销,不再关闭。本脚本补齐存量7条:status 2→4,并按
|
||||
# 定时任务同款行为补写 card_check 自动核销记录(checker_id=-2/自动核销)。
|
||||
# 干跑核对行数=7 后才允许 --apply;事务内双自检通过才 COMMIT,否则回滚。
|
||||
import sys
|
||||
os_env = __import__('os')
|
||||
os_env.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
marker = "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(src.split(marker, 1)[0] + marker, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
RESOURCE_ID = 851222303983301 # 怀化石化(减免卷)
|
||||
CARD_MODEL_ID = 831756570496837 # 怀化社保卡权益包
|
||||
CARD_MODEL_NAME = '怀化社保卡权益包'
|
||||
EXPECTED = 7
|
||||
CHECK_ID_BASE = 926120000000001 # 预分配核销记录ID段 base..base+6,干跑校验未占用
|
||||
|
||||
APPLY = '--apply' in sys.argv
|
||||
|
||||
conn.begin()
|
||||
|
||||
cur.execute("""SELECT id, card_model_name, card_number, member_id, name, phone, identity_no,
|
||||
DATE_FORMAT(app_time,'%%Y-%%m-%%d 23:45:00') check_time
|
||||
FROM card_appointment
|
||||
WHERE resource_id=%s AND status=2 AND is_deleted=0
|
||||
ORDER BY app_time""", (RESOURCE_ID,))
|
||||
rows = cur.fetchall()
|
||||
print('待改核销预约:', len(rows), '行(预期', EXPECTED, ')')
|
||||
for r in rows:
|
||||
print(' ', r['id'], r['name'], r['phone'], r['check_time'])
|
||||
assert len(rows) == EXPECTED, '行数与预期不符,中止'
|
||||
|
||||
ids = [r['id'] for r in rows]
|
||||
check_ids = [CHECK_ID_BASE + i for i in range(len(rows))]
|
||||
cur.execute("SELECT COUNT(*) c FROM card_check WHERE id IN (%s)" % ','.join(map(str, check_ids)))
|
||||
assert cur.fetchone()['c'] == 0, '预分配核销记录ID已被占用,中止'
|
||||
cur.execute("SELECT COUNT(*) c FROM card_check WHERE appointment_id IN (%s)" % ','.join(map(str, ids)))
|
||||
assert cur.fetchone()['c'] == 0, '目标预约已有核销记录,避免重复核销,中止'
|
||||
|
||||
if not APPLY:
|
||||
print('干跑结束(未写入)。确认无误后加 --apply 执行')
|
||||
conn.rollback()
|
||||
sys.exit(0)
|
||||
|
||||
for i, r in enumerate(rows):
|
||||
cur.execute("""INSERT INTO card_check
|
||||
(id, card_id, card_model_id, card_model_name, resource_id, resource_name,
|
||||
card_number, member_id, name, phone, identity_no, check_time,
|
||||
checker_id, checker_name, appointment_id, is_deleted, created_time, updated_time)
|
||||
VALUES (%s, NULL, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s,
|
||||
-2, '自动核销', %s, 0, NOW(), NOW())""",
|
||||
(check_ids[i], CARD_MODEL_ID, CARD_MODEL_NAME, RESOURCE_ID, '怀化石化(减免卷)',
|
||||
r['card_number'], r['member_id'], r['name'], r['phone'], r['identity_no'], r['check_time'], r['id']))
|
||||
cur.execute("""UPDATE card_appointment SET status=4, updated_by=1
|
||||
WHERE resource_id=%s AND status=2 AND is_deleted=0""", (RESOURCE_ID,))
|
||||
print('UPDATE 影响行数:', cur.rowcount)
|
||||
assert cur.rowcount == EXPECTED, 'UPDATE行数不符,回滚'
|
||||
|
||||
# 事务内自检:预约无残留已关闭、核销记录恰好7条
|
||||
cur.execute("SELECT COUNT(*) c FROM card_appointment WHERE resource_id=%s AND status=2 AND is_deleted=0", (RESOURCE_ID,))
|
||||
assert cur.fetchone()['c'] == 0, '自检失败:仍有已关闭记录,回滚'
|
||||
cur.execute("SELECT COUNT(*) c FROM card_check WHERE resource_id=%s AND checker_id=-2 AND is_deleted=0", (RESOURCE_ID,))
|
||||
assert cur.fetchone()['c'] == EXPECTED, '自检失败:核销记录数不符,回滚'
|
||||
|
||||
conn.commit()
|
||||
print('COMMIT 完成:', EXPECTED, '条已关闭→已核销,并补写自动核销记录 id', check_ids[0], '..', check_ids[-1])
|
||||
@@ -0,0 +1,91 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 删除抽奖池存量手机号不合规且未中奖的115行(2026-11-10 用户指令)——先出回滚INSERT再事务删除
|
||||
# 用法: python3 docs/tools_delete_legacy_badphone_20261110.py # 干跑:只算+出回滚SQL,不删
|
||||
# python3 docs/tools_delete_legacy_badphone_20261110.py --execute # 执行删除(UAT=生产)
|
||||
# 目标集=全池按白名单口径不合规 ∩ won=0,须恰为115行且id与 docs/抽奖池_存量手机号不合规明细_20261110.csv 一致;
|
||||
# 已中奖的不合规行(张青喜 id=2382265)不在删除范围。回滚文件:docs/抽奖池_删除存量不合规115行_回滚INSERT_20261110.sql
|
||||
import os, re, sys
|
||||
import pymysql
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
DOCS = os.path.dirname(os.path.abspath(__file__))
|
||||
CSV = os.path.join(DOCS, '抽奖池_存量手机号不合规明细_20261110.csv')
|
||||
ROLLBACK_SQL = os.path.join(DOCS, '抽奖池_删除存量不合规115行_回滚INSERT_20261110.sql')
|
||||
EXPECT = 115
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
_pat = re.compile(r'^(\d{3})\*{4}\d{4}$')
|
||||
|
||||
def bad_phone(p):
|
||||
p = p or ''
|
||||
m = _pat.match(p)
|
||||
return (not m) or (m.group(1) not in allowed)
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
before = cur.fetchone()['c']
|
||||
cur.execute("SELECT id, member_name, county, batch_no, member_identity_no, member_phone, won, "
|
||||
"created_time, updated_time FROM hhrs_lottery_pool")
|
||||
targets = [r for r in cur.fetchall() if r['won'] == 0 and bad_phone(r['member_phone'])]
|
||||
print('全池', before, '行; 命中"不合规∩未中奖"', len(targets), '行')
|
||||
assert len(targets) == EXPECT, f'目标行数 {len(targets)} != {EXPECT},中止'
|
||||
|
||||
# 与已交付明细CSV的id集合互证
|
||||
csv_ids = set()
|
||||
with open(CSV, encoding='utf-8-sig') as f:
|
||||
next(f)
|
||||
for line in f:
|
||||
csv_ids.add(int(line.split(',', 1)[0]))
|
||||
live_ids = {r['id'] for r in targets}
|
||||
assert live_ids == csv_ids, f'与明细CSV的id集合不一致 差={live_ids ^ csv_ids}'
|
||||
print('id集合与明细CSV完全一致 ✓')
|
||||
|
||||
# 回滚INSERT(逐行全字段,值经转义)
|
||||
with open(ROLLBACK_SQL, 'w', encoding='utf-8') as f:
|
||||
f.write('-- xuchao: 2026-11-10 删除抽奖池存量手机号不合规未中奖115行 的回滚INSERT\n')
|
||||
f.write('-- 执行方式:整体在事务内跑一遍,核对行数=115后COMMIT\n')
|
||||
f.write('-- 注意:created_time/updated_time为删除时的原值;删除期间若有抽奖won回写不涉及本115行(均won=0)\n')
|
||||
for r in sorted(targets, key=lambda x: x['id']):
|
||||
v = lambda s: 'NULL' if s is None else conn.escape(str(s))
|
||||
f.write("INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,"
|
||||
"member_phone,won,created_time,updated_time) VALUES "
|
||||
f"({r['id']},{v(r['member_name'])},{v(r['county'])},{r['batch_no']},"
|
||||
f"{v(r['member_identity_no'])},{v(r['member_phone'])},0,{v(r['created_time'])},{v(r['updated_time'])});\n")
|
||||
print('回滚SQL已写:', ROLLBACK_SQL, f'({len(targets)}条INSERT)')
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过,未删除。执行请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
ids = [r['id'] for r in targets]
|
||||
cur.execute("DELETE FROM hhrs_lottery_pool WHERE won=0 AND id IN (%s)" % ','.join(map(str, ids)))
|
||||
n_del = cur.rowcount
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
after = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE won=1")
|
||||
won1 = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= '2026-11-10 17:53:31'")
|
||||
nb = cur.fetchone()['c']
|
||||
print(f'事务内自检: 实删 {n_del} 行; 全池 {before} -> {after} (应={before - EXPECT}); '
|
||||
f'won=1 仍 {won1} (应3997); 新批(11-10导入)仍 {nb} (应58893)')
|
||||
if n_del == EXPECT and after == before - EXPECT and won1 == 3997 and nb == 58893:
|
||||
conn.commit()
|
||||
print('COMMIT 成功')
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK')
|
||||
raise SystemExit(1)
|
||||
@@ -0,0 +1,74 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 删除"未中奖且无真实手机"行(2026-11-18 用户最终口径:中奖者8000人全保留只同步手机[已一致无需动,20人NULL以文档为准];
|
||||
# 未中奖且无真实手机者删除)。20个"池won=0但公示有名"的一期中奖者属中奖者,保留不改动。
|
||||
# 用法: python3 docs/tools_delete_nophone_20261118.py # 干跑:核对目标量,不写
|
||||
# python3 docs/tools_delete_nophone_20261118.py --execute # 整行备份+事务删除+自检+COMMIT(UAT=生产)
|
||||
# 目标: created_time='2026-10-15 09:57:17' AND member_phone IS NULL AND won=0,排除20个公示中奖pool_id;
|
||||
# 预期24,892行(=25,215 NULL手机 - 303已中奖 - 20公示保留)。不碰11-10批、中奖者、公示表。
|
||||
# 备份: hhrs_lottery_pool_delbak_20261118(整行);回滚=INSERT INTO hhrs_lottery_pool SELECT * FROM 备份表。
|
||||
import sys, os
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
LEGACY_CT = '2026-10-15 09:57:17'
|
||||
KEEP20 = [271705, 455355, 470658, 493004, 597303, 672481, 681391, 757339, 847426, 940646,
|
||||
943507, 982987, 1192268, 1234479, 1264630, 1951332, 2007782, 2180844, 2197340, 2213244]
|
||||
EXPECT_DEL, EXPECT_AFTER = 24892, 549678
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
def one(sql):
|
||||
cur.execute(sql)
|
||||
return cur.fetchone()['c']
|
||||
|
||||
ph = ','.join(str(i) for i in KEEP20)
|
||||
WHERE = (f"created_time='{LEGACY_CT}' AND member_phone IS NULL AND won=0 AND id NOT IN ({ph})")
|
||||
|
||||
n_target = one("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE " + WHERE)
|
||||
# 交叉验证:目标行无任何公示引用
|
||||
n_ref = one("SELECT COUNT(*) c FROM hhrs_winner w JOIN hhrs_lottery_pool p ON w.pool_id=p.id WHERE " +
|
||||
WHERE.replace('created_time', 'p.created_time').replace('member_phone', 'p.member_phone')
|
||||
.replace('won=0', 'p.won=0').replace('id NOT IN', 'p.id NOT IN'))
|
||||
n_keep = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE id IN ({ph})")
|
||||
# 既有悬空引用基线(历史遗留:一期1625+二轮3),本次不得新增
|
||||
n_dang0 = one("SELECT COUNT(*) c FROM hhrs_winner w LEFT JOIN hhrs_lottery_pool p ON w.pool_id=p.id "
|
||||
"WHERE w.pool_id IS NOT NULL AND p.id IS NULL")
|
||||
print(f'目标 {n_target}(应{EXPECT_DEL}) | 目标行公示引用 {n_ref}(应0) | 20保留行在池 {n_keep}(应20) | 既有悬空基线 {n_dang0}')
|
||||
assert n_target == EXPECT_DEL and n_ref == 0 and n_keep == 20, '预检不符,中止'
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过,未写入。执行请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
cur.execute("SHOW TABLES LIKE 'hhrs_lottery_pool_delbak_20261118'")
|
||||
assert not cur.fetchall(), '备份表已存在,中止(防重复执行)'
|
||||
cur.execute("CREATE TABLE hhrs_lottery_pool_delbak_20261118 AS SELECT * FROM hhrs_lottery_pool WHERE " + WHERE)
|
||||
assert one("SELECT COUNT(*) c FROM hhrs_lottery_pool_delbak_20261118") == EXPECT_DEL, '备份行数不符'
|
||||
print('整行备份表 hhrs_lottery_pool_delbak_20261118 已建:', EXPECT_DEL)
|
||||
|
||||
cur.execute("START TRANSACTION")
|
||||
cur.execute("DELETE FROM hhrs_lottery_pool WHERE " + WHERE)
|
||||
n_del = cur.rowcount
|
||||
n_all = one("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
n_won = int(one("SELECT SUM(won) c FROM hhrs_lottery_pool"))
|
||||
n_null = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}' AND member_phone IS NULL")
|
||||
n_b10 = one("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time>='2026-11-10 00:00:00'")
|
||||
n_keep2 = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE id IN ({ph})")
|
||||
n_ref2 = one("SELECT COUNT(*) c FROM hhrs_winner w LEFT JOIN hhrs_lottery_pool p ON w.pool_id=p.id "
|
||||
"WHERE w.pool_id IS NOT NULL AND p.id IS NULL")
|
||||
n_winpool = one("SELECT COUNT(DISTINCT w.pool_id) c FROM hhrs_winner w JOIN hhrs_lottery_pool p ON w.pool_id=p.id")
|
||||
print(f'自检: 删{n_del}(应{EXPECT_DEL}) | 全池{n_all}(应{EXPECT_AFTER}) | won={n_won}(应5997) | '
|
||||
f'存量NULL剩{n_null}(应323=303中奖+20保留) | 11-10批{n_b10}(应58893) | 20保留行{n_keep2}(应20) | '
|
||||
f'在池中奖者{n_winpool}(应6372) | 公示悬空引用{n_ref2}(应{n_dang0}不新增)')
|
||||
if (n_del, n_all, n_won, n_null, n_b10, n_keep2, n_winpool, n_ref2) == (EXPECT_DEL, EXPECT_AFTER, 5997, 323, 58893, 20, 6372, n_dang0):
|
||||
conn.commit()
|
||||
print('COMMIT 成功: 已删除未中奖且无真实手机行')
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK')
|
||||
raise SystemExit(1)
|
||||
@@ -0,0 +1,43 @@
|
||||
# xuchao: 只读诊断——手机号 15974016962(邢英杰/15042819861115084X) 权益包显示"没有权益包"
|
||||
# 沿 eligibility 链路逐级查: member(channel=15) → open_id → card_bind(卡种+state=4) → card / hhrs_winner
|
||||
# 用法: python3 docs/tools_diag_15974016962_20261123.py
|
||||
import os
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
marker = "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
head = src.split(marker, 1)[0] + marker
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
PHONE = '15974016962'
|
||||
IDNO = '15042819861115084X'
|
||||
CARD_MODEL = 831756570496837
|
||||
|
||||
def show(title, sql, *a):
|
||||
cur.execute(sql, a)
|
||||
rows = cur.fetchall()
|
||||
print(f'\n== {title} == ({len(rows)} 行)')
|
||||
for r in rows:
|
||||
print(dict(r))
|
||||
|
||||
# 1. member 表:该手机号全部渠道记录(eligibility 只认 channel=15 且未删除的第一条)
|
||||
show('member by mobile', "SELECT id, channel, mobile, open_id, name, is_deleted, created_time FROM member WHERE mobile=%s", PHONE)
|
||||
|
||||
# 2. card_bind:按证件号(全部卡种)
|
||||
show('card_bind by identity_no', "SELECT id, card_id, card_number, card_model_id, member_id, identity_no, name, phone, state, is_deleted, expires_time, bind_time FROM card_bind WHERE identity_no=%s", IDNO)
|
||||
|
||||
# 3. card_bind:按手机号
|
||||
show('card_bind by phone', "SELECT id, card_id, card_number, card_model_id, member_id, identity_no, name, phone, state, is_deleted, expires_time FROM card_bind WHERE phone=%s", PHONE)
|
||||
|
||||
# 4. card 表:该证件号/手机号名下的卡
|
||||
show('card by identity_no', "SELECT id, card_number, card_model_id, state, identity_no, phone, validity_end, is_deleted, active_time FROM card WHERE identity_no=%s OR phone=%s", IDNO, PHONE)
|
||||
|
||||
# 5. 中奖公示记录
|
||||
show('hhrs_winner by idno/phone', "SELECT id, round_id, member_name, member_identity_no, member_phone, card_model_id, prize_name, draw_date, remark FROM hhrs_winner WHERE member_identity_no=%s OR member_phone=%s", IDNO, PHONE)
|
||||
|
||||
# 6. 对照:eligibility 完整口径命中的 bind
|
||||
show('card_bind eligibility口径命中', "SELECT id, card_number, state, phone, is_deleted FROM card_bind WHERE identity_no=%s AND card_model_id=%s AND state=4 AND is_deleted=0", IDNO, CARD_MODEL)
|
||||
|
||||
conn.close()
|
||||
@@ -0,0 +1,102 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 9月底至1103已激活批次入抽奖池执行脚本——号段白名单过滤+事务导入+自检+COMMIT
|
||||
# 用法: python3 docs/tools_import_activated_batch_20261110.py # 干跑,只算不写
|
||||
# python3 docs/tools_import_activated_batch_20261110.py --execute # 执行入库(UAT=生产)
|
||||
# 口径(2026-11-10 用户确认): 手机号必须为「3位白名单号段 + 4星 + 4位尾号」,不合格整行剔除并出对照表;
|
||||
# 白名单号段: 130-139 | 140 141 144-149 | 150-159(除154) | 162 165 166 167 |
|
||||
# 170-173 175-178 | 180-189 | 190-193 195-199 (共58段,未启用154/164/174/194等)
|
||||
# 预期: 文件60,800行 → 合格58,893行入库、剔除1,907行;与池id交集必须为0;任一校验不过即中止回滚。
|
||||
# 连接参数复用 12301-dscp/docs/tools/settle_recompute_check.py 的 SETTLE_ENV=uat 分支。
|
||||
# 回滚(如业务要求撤批次): DELETE FROM hhrs_lottery_pool WHERE created_time >= '<本脚本输出的t0>'
|
||||
# AND id BETWEEN 2852613 AND 3982068; -- 执行前先 SELECT COUNT 复核应=58893 再删
|
||||
import sys, os, re
|
||||
import pandas as pd
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
XLSX = '/Users/jacobxu/Downloads/9月底至1103已激活数据.xlsx'
|
||||
DOCS = os.path.dirname(os.path.abspath(__file__))
|
||||
EXPECT_TOTAL, EXPECT_OK, EXPECT_REJ = 60800, 58893, 1907
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
assert len(allowed) == 58
|
||||
_pat = re.compile(r'^(\d{3})\*{4}\d{4}$')
|
||||
|
||||
def classify(p):
|
||||
if p == '':
|
||||
return '空值'
|
||||
m = _pat.match(p)
|
||||
if not m:
|
||||
return '格式异常(非3+4星+4)'
|
||||
if m.group(1) not in allowed:
|
||||
return '号段不在白名单'
|
||||
return '合格'
|
||||
|
||||
# ---- 读文件并按口径过滤 ----
|
||||
df = pd.read_excel(XLSX, sheet_name='已激活明细', dtype=str).fillna('')
|
||||
assert len(df) == EXPECT_TOTAL, f'明细行数 {len(df)} != 预期 {EXPECT_TOTAL}'
|
||||
df['剔除原因'] = df['脱敏手机号'].map(classify)
|
||||
ok = df[df['剔除原因'] == '合格'].copy()
|
||||
rej = df[df['剔除原因'] != '合格'].copy()
|
||||
assert len(ok) == EXPECT_OK and len(rej) == EXPECT_REJ, \
|
||||
f'合格/剔除行数与确认口径不符: {len(ok)}/{len(rej)} != {EXPECT_OK}/{EXPECT_REJ}'
|
||||
ids = [int(x) for x in ok['ID']]
|
||||
assert len(set(ids)) == len(ids), '文件合格行 ID 存在重复'
|
||||
rows = [(i, nm, ct, 0, idno, ph, 0) for i, nm, ct, idno, ph in
|
||||
zip([int(x) for x in ok['ID']], ok['姓名'], ok['发卡地区'], ok['脱敏身份证'], ok['脱敏手机号'])]
|
||||
rej[['ID', '姓名', '脱敏手机号', '脱敏身份证', '发卡地区', '剔除原因']].to_csv(
|
||||
os.path.join(DOCS, '已激活批次_剔除对照_20261110.csv'), index=False)
|
||||
print('文件行:', len(df), ' 合格:', len(ok), ' 剔除:', len(rej), '(对照表已写 docs/)')
|
||||
print('剔除原因分布:', rej['剔除原因'].value_counts().to_dict())
|
||||
|
||||
# ---- 连库预检 ----
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
before = cur.fetchone()['c']
|
||||
lo, hi = min(ids), max(ids)
|
||||
cur.execute("SELECT id FROM hhrs_lottery_pool WHERE id BETWEEN %s AND %s", (lo, hi))
|
||||
inter = set(ids) & {r['id'] for r in cur.fetchall()}
|
||||
print(f'池现有行数: {before} 本批ID窗[{lo}..{hi}]内池行交集: {len(inter)}')
|
||||
assert not inter, f'主键冲突,中止: {sorted(inter)[:10]}'
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过,未写入。执行入库请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
# ---- 事务导入 ----
|
||||
cur.execute("SELECT NOW() n")
|
||||
t0 = cur.fetchone()['n']
|
||||
print('批次时间戳 t0 =', t0)
|
||||
sql = ("INSERT INTO hhrs_lottery_pool "
|
||||
"(id, member_name, county, batch_no, member_identity_no, member_phone, won) "
|
||||
"VALUES (%s,%s,%s,%s,%s,%s,%s)")
|
||||
for i in range(0, len(rows), 2000):
|
||||
cur.executemany(sql, rows[i:i + 2000])
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= %s", (t0,))
|
||||
n_new = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
n_all = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= %s "
|
||||
"AND member_phone REGEXP '^[0-9]{3}\\\\*{4}[0-9]{4}$'", (t0,))
|
||||
n_fmt = cur.fetchone()['c']
|
||||
print('事务内自检: 本批行数', n_new, ' 全表行数', n_all, ' 本批手机号格式合格率', f'{n_fmt}/{n_new}')
|
||||
if n_new == len(rows) and n_all == before + len(rows) and n_fmt == n_new:
|
||||
conn.commit()
|
||||
print('COMMIT 成功: 池', before, '->', n_all)
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK,未入库')
|
||||
raise SystemExit(1)
|
||||
@@ -0,0 +1,82 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 第二批25-40岁未入池人员补导入抽奖池(2026-11-17 用户指令"补导入池")
|
||||
# 用法: python3 docs/tools_import_batch2_20261117.py # 干跑,只算不写
|
||||
# python3 docs/tools_import_batch2_20261117.py --execute # 执行入库(UAT=生产)
|
||||
# 源: ~/Downloads/第二批年龄段25-40岁抽奖数据 1.xlsx(业务补充发卡地区版;该列与池存量县区100%一致已验证)
|
||||
# 口径: 目标=文件ID不在池的17,195行;county=发卡地区;证号=明文转掩码(6+8星+4);
|
||||
# 手机=白名单号段11位转掩码,非法/空→NULL(与当日真值回刷口径一致,不剔行);
|
||||
# batch_no=0, won=0。回滚: DELETE FROM hhrs_lottery_pool WHERE created_time >= '<t0>' AND id BETWEEN 254 AND 3121236(先核数应=17195)。
|
||||
# 连接参数复用 12301-dscp/docs/tools/settle_recompute_check.py 的 SETTLE_ENV=uat 分支。
|
||||
import sys, os, re
|
||||
import pandas as pd
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
SRC = os.path.expanduser('~/Downloads/第二批年龄段25-40岁抽奖数据.xlsx')
|
||||
EXPECT = 17195
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
|
||||
def phone_mask(p):
|
||||
return (p[:3] + '****' + p[7:11]) if re.fullmatch(r'\d{11}', p) and p[:3] in allowed else None
|
||||
|
||||
def id_mask(i):
|
||||
assert re.fullmatch(r'\d{17}[\dXx]', i), f'证号格式异常: {i}'
|
||||
return i[:6] + '********' + i[14:]
|
||||
|
||||
F = pd.read_excel(SRC, dtype=str).fillna('')
|
||||
F.columns = ['ID', '身份证', '姓名', '手机', '发卡地区']
|
||||
assert F['ID'].astype(int).is_unique and len(F) == 532872
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
before = cur.fetchone()['c']
|
||||
cur.execute("SELECT id FROM hhrs_lottery_pool")
|
||||
pool_ids = {r['id'] for r in cur.fetchall()}
|
||||
|
||||
only = F[~F['ID'].astype(int).isin(pool_ids)].copy()
|
||||
assert len(only) == EXPECT, f'待导入 {len(only)} != {EXPECT},口径变化中止'
|
||||
assert only['发卡地区'].ne('').all(), '存在空发卡地区'
|
||||
rows = [(int(w['ID']), w['姓名'], w['发卡地区'], 0, id_mask(w['身份证']), phone_mask(w['手机']), 0)
|
||||
for _, w in only.iterrows()]
|
||||
n_ph = sum(1 for r in rows if r[5])
|
||||
print(f'待导入 {len(rows)} 行: 有效手机掩码 {n_ph}, 置NULL {len(rows)-n_ph}')
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过,未写入。执行请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
cur.execute("SELECT NOW() n")
|
||||
t0 = cur.fetchone()['n']
|
||||
sql = ("INSERT INTO hhrs_lottery_pool "
|
||||
"(id, member_name, county, batch_no, member_identity_no, member_phone, won) "
|
||||
"VALUES (%s,%s,%s,%s,%s,%s,%s)")
|
||||
for i in range(0, len(rows), 2000):
|
||||
cur.executemany(sql, rows[i:i + 2000])
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= %s", (t0,))
|
||||
n_new = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
n_all = cur.fetchone()['c']
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= %s AND county IS NULL", (t0,))
|
||||
n_nocounty = cur.fetchone()['c']
|
||||
print(f'自检: 本批 {n_new}(应{EXPECT}) 全表 {n_all}(应{before+EXPECT}) 本批无县区 {n_nocounty}(应0) t0={t0}')
|
||||
if n_new == EXPECT and n_all == before + EXPECT and n_nocounty == 0:
|
||||
conn.commit()
|
||||
print('COMMIT 成功:', before, '->', n_all)
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK')
|
||||
raise SystemExit(1)
|
||||
@@ -0,0 +1,49 @@
|
||||
# xuchao: 只读排查——怀化石化(减免卷) 资源规则、卡种渠道、预约状态分布与已关闭明细
|
||||
# 用法: python3 -I docs/tools_probe_petrol_appointment_20261116.py
|
||||
import os
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
marker = "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
head = src.split(marker, 1)[0] + marker
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
print('== DB:', ns.get('DB'), ns.get('HOST'))
|
||||
|
||||
print('== card_resource_rule 匹配 石化/减免 ==')
|
||||
cur.execute("""SELECT id, card_model_id, resource_name, sku_id, shop_id, is_appointment_count, is_silent_check, status, is_deleted
|
||||
FROM card_resource_rule WHERE resource_name LIKE '%石化%' OR resource_name LIKE '%减免%'""")
|
||||
for r in cur.fetchall():
|
||||
print(r)
|
||||
|
||||
print('== card_model 831756570496837 渠道 ==')
|
||||
cur.execute("SELECT id, name, channel FROM card_model WHERE id=831756570496837")
|
||||
print(cur.fetchall())
|
||||
|
||||
print('== 该资源在 card_appointment 的状态分布 ==')
|
||||
cur.execute("""SELECT resource_id, resource_name, status, COUNT(*) c
|
||||
FROM card_appointment
|
||||
WHERE resource_name LIKE '%石化%' OR resource_name LIKE '%减免%'
|
||||
GROUP BY resource_id, resource_name, status ORDER BY resource_id, status""")
|
||||
for r in cur.fetchall():
|
||||
print(r)
|
||||
|
||||
print('== 该资源已关闭(status=2)预约明细 ==')
|
||||
cur.execute("""SELECT id, name, phone, identity_no, card_number, resource_id, resource_name,
|
||||
DATE(app_time) app_date, status, created_time, updated_time, is_deleted
|
||||
FROM card_appointment
|
||||
WHERE (resource_name LIKE '%石化%' OR resource_name LIKE '%减免%') AND status=2
|
||||
ORDER BY app_time""")
|
||||
rows = cur.fetchall()
|
||||
print('合计', len(rows), '行')
|
||||
for r in rows:
|
||||
print(r)
|
||||
|
||||
print('== 其中已有 card_check 核销记录的 ==')
|
||||
cur.execute("""SELECT a.id, a.name, a.app_time, c.id check_id, c.checker_name
|
||||
FROM card_appointment a JOIN card_check c ON c.appointment_id=a.id
|
||||
WHERE (a.resource_name LIKE '%石化%' OR a.resource_name LIKE '%减免%') AND a.status=2""")
|
||||
for r in cur.fetchall():
|
||||
print(r)
|
||||
@@ -0,0 +1,123 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 真值回刷——抽奖池存量手机列(掩码)+第四轮公示手机(明文),源=《第二批年龄段25-40岁抽奖数据》(ID=池主键)
|
||||
# 用法: python3 docs/tools_refill_phone_20261117.py # 干跑:算变更量+建备份表,不改数据
|
||||
# python3 docs/tools_refill_phone_20261117.py --execute # 执行回刷(UAT=生产)
|
||||
# 口径(2026-11-17 用户确认"回刷池和公示"):
|
||||
# 池 member_phone = 文件明文转掩码(前3+****+后4),文件无手机→NULL;仅动存量行(created_time='2026-10-15 09:57:17');
|
||||
# hhrs_winner 第四轮(round_id=857957849313349) member_phone = 文件明文原样(与二三轮明文先例一致,接口出参自行脱敏);
|
||||
# 新批11-10的58,893行/173行公示不在本文件覆盖内,待业务另导该批原始明文后二次回刷。
|
||||
# 备份: hhrs_lottery_pool_phonebak_20261117(存量id+改前phone) / hhrs_winner_r4phone_bak_20261117(第四轮整行);
|
||||
# 验证无误后由业务确认可清理(仿《备份表清理台账》处置)。
|
||||
import sys, os, re
|
||||
import pandas as pd
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
SRC = '/Users/jacobxu/Downloads/第二批年龄段25-40岁抽奖数据.xlsx'
|
||||
LEGACY_CT = '2026-10-15 09:57:17'
|
||||
R4 = 857957849313349
|
||||
|
||||
F = pd.read_excel(SRC, dtype=str).fillna('')
|
||||
F.columns = ['ID', '身份证', '姓名', '手机']
|
||||
assert F['ID'].astype(int).is_unique and len(F) == 532872, '文件ID应唯一且532,872行'
|
||||
ph_ok = F['手机'].str.fullmatch(r'\d{11}').sum()
|
||||
ph_empty = (F['手机'] == '').sum()
|
||||
ph_other = len(F) - ph_ok - ph_empty
|
||||
print(f'文件 {len(F)} 行: 手机11位 {ph_ok}, 空 {ph_empty}, 其他形态 {ph_other}')
|
||||
|
||||
# 11位还需号段在白名单(沿用 11-10 用户定口径),否则与脏值同等对待→NULL
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
|
||||
def clean(p):
|
||||
"""合法=11位且号段白名单,返回原明文;否则 None(入库为NULL)"""
|
||||
return p if re.fullmatch(r'\d{11}', p) and p[:3] in allowed else None
|
||||
|
||||
def mask(p):
|
||||
return p[:3] + '****' + p[7:11] if p else None
|
||||
|
||||
fmap = dict(zip(F['ID'].astype(int), F['手机'].map(clean)))
|
||||
n_valid = sum(1 for v in fmap.values() if v)
|
||||
print(f'白名单口径下有效明文 {n_valid} 行, 其余 {len(fmap)-n_valid} 行将按NULL入库')
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
# 池存量现状
|
||||
cur.execute("SELECT id, member_phone FROM hhrs_lottery_pool WHERE created_time=%s", (LEGACY_CT,))
|
||||
legacy = {r['id']: r['member_phone'] for r in cur.fetchall()}
|
||||
print('池存量行数:', len(legacy))
|
||||
inter = sorted(set(legacy) & set(fmap))
|
||||
assert len(inter) == len(legacy), '文件未完全覆盖存量,中止'
|
||||
pool_changes = [(i, mask(fmap[i])) for i in inter if mask(fmap[i]) != legacy[i]]
|
||||
n_null = sum(1 for _, v in pool_changes if v is None)
|
||||
print(f'池需变更 {len(pool_changes)} 行(其中置NULL {n_null})')
|
||||
|
||||
# 第四轮公示现状
|
||||
cur.execute("SELECT id, pool_id, member_phone FROM hhrs_winner WHERE round_id=%s", (R4,))
|
||||
r4rows = cur.fetchall()
|
||||
win_changes = [(r['id'], fmap.get(r['pool_id'])) for r in r4rows if r['pool_id'] in fmap]
|
||||
print(f'公示第四轮共 {len(r4rows)} 行,本文件覆盖 {len(win_changes)} 行需刷为明文/NULL')
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑完成,未改动。执行请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
# ---- 备份表(DDL隐式提交,先行) ----
|
||||
cur.execute("SHOW TABLES LIKE 'hhrs_lottery_pool_phonebak_20261117'")
|
||||
if not cur.fetchall():
|
||||
cur.execute(f"CREATE TABLE hhrs_lottery_pool_phonebak_20261117 AS "
|
||||
f"SELECT id, member_phone FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}'")
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool_phonebak_20261117")
|
||||
print('池备份表行数:', cur.fetchone()['c'])
|
||||
cur.execute("SHOW TABLES LIKE 'hhrs_winner_r4phone_bak_20261117'")
|
||||
if not cur.fetchall():
|
||||
cur.execute(f"CREATE TABLE hhrs_winner_r4phone_bak_20261117 AS SELECT * FROM hhrs_winner WHERE round_id={R4}")
|
||||
|
||||
# ---- 池:staging 批量 UPDATE ----
|
||||
cur.execute("DROP TABLE IF EXISTS hhrs_stg_phone_20261117")
|
||||
cur.execute("CREATE TABLE hhrs_stg_phone_20261117 (id BIGINT PRIMARY KEY, new_phone VARCHAR(20))")
|
||||
vals = [(i, v) for i, v in pool_changes]
|
||||
sql = "INSERT INTO hhrs_stg_phone_20261117 (id, new_phone) VALUES (%s,%s)"
|
||||
for i in range(0, len(vals), 2000):
|
||||
cur.executemany(sql, vals[i:i + 2000])
|
||||
|
||||
cur.execute("START TRANSACTION")
|
||||
cur.execute("UPDATE hhrs_lottery_pool p JOIN hhrs_stg_phone_20261117 s ON p.id=s.id "
|
||||
f"SET p.member_phone=s.new_phone WHERE p.created_time='{LEGACY_CT}' AND NOT (p.member_phone <=> s.new_phone)")
|
||||
n_pool = cur.rowcount
|
||||
# 公示:逐行(1,827 行,量小)
|
||||
sqlw = "UPDATE hhrs_winner SET member_phone=%s WHERE id=%s"
|
||||
cur.executemany(sqlw, [(v, i) for i, v in win_changes])
|
||||
n_win = cur.rowcount
|
||||
# 事务内自检
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
all_rows = cur.fetchone()['c']
|
||||
cur.execute(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}' AND member_phone IS NULL")
|
||||
nulls_after = cur.fetchone()['c']
|
||||
cur.execute(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}' "
|
||||
"AND member_phone REGEXP '^[0-9]{3}\\\\*{4}[0-9]{4}$'")
|
||||
fmt_ok = cur.fetchone()['c']
|
||||
cur.execute(f"SELECT COUNT(*) c FROM hhrs_winner WHERE round_id={R4} AND member_phone REGEXP '^[0-9]{{11}}$'")
|
||||
plain_ok = cur.fetchone()['c']
|
||||
print(f'自检: 池更新 {n_pool}(应{len(pool_changes)}) | 公示更新 {n_win}(应{len(win_changes)}) | '
|
||||
f'全表 {all_rows}(应574570) | 存量NULL {nulls_after}(应{n_null}) | 存量掩码格式 {fmt_ok} | 公示明文 {plain_ok}')
|
||||
if n_pool == len(pool_changes) and n_win == len(win_changes) and all_rows == 574570:
|
||||
conn.commit()
|
||||
print('COMMIT 成功')
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK')
|
||||
raise SystemExit(1)
|
||||
cur.execute("DROP TABLE hhrs_stg_phone_20261117")
|
||||
print('staging 已清理;备份表保留待业务确认后清理')
|
||||
@@ -0,0 +1,99 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 存量手机回刷(2026-11-18 用户授权"存量515677行按新文档回刷")
|
||||
# 用法: python3 docs/tools_refill_phone_20261118.py # 干跑:算变更量,不写
|
||||
# python3 docs/tools_refill_phone_20261118.py --execute # 备份+事务回刷+全量自检+COMMIT(UAT=生产)
|
||||
# 源: ~/Downloads/第二批年龄段25-40岁抽奖数据.xlsx(2026-11-18新版,20列全量发卡明细,col0=ID,col5=手机明文)
|
||||
# 口径: 仅动存量(created_time='2026-10-15 09:57:17')515,677行;手机=白名单号段11位转掩码(前3+****+后4),非法/空→NULL;
|
||||
# 预期变更515,673(掩码不同490,458+置NULL25,215),4行已一致不动。不碰11-10批58,893行、won、公示。
|
||||
# 备份: hhrs_lottery_pool_phonebak_20261118(存量id+改前phone);回滚=按备份表整列还原。
|
||||
import sys, os, re
|
||||
import pandas as pd
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
SRC = os.path.expanduser('~/Downloads/第二批年龄段25-40岁抽奖数据.xlsx')
|
||||
LEGACY_CT = '2026-10-15 09:57:17'
|
||||
EXPECT_LEGACY, EXPECT_CHG, EXPECT_NULL = 515677, 515673, 25215
|
||||
|
||||
F = pd.read_excel(SRC, dtype=str, usecols=[0, 5]).fillna('')
|
||||
F.columns = ['ID', '手机']
|
||||
assert F['ID'].astype(int).is_unique and len(F) == 532872, '文件ID应唯一且532,872行'
|
||||
|
||||
allowed = set()
|
||||
allowed.update(f'13{d}' for d in range(10))
|
||||
allowed.update(['140', '141', '144', '145', '146', '147', '148', '149'])
|
||||
allowed.update(f'15{d}' for d in range(10) if d != 4)
|
||||
allowed.update(['162', '165', '166', '167'])
|
||||
allowed.update(['170', '171', '172', '173', '175', '176', '177', '178'])
|
||||
allowed.update(f'18{d}' for d in range(10))
|
||||
allowed.update(f'19{d}' for d in range(10) if d != 4)
|
||||
|
||||
def expect_mask(p):
|
||||
return (p[:3] + '****' + p[7:11]) if re.fullmatch(r'\d{11}', p) and p[:3] in allowed else None
|
||||
|
||||
fmap = {int(i): expect_mask(p) for i, p in zip(F['ID'], F['手机'])}
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
cur.execute("SELECT id, member_phone FROM hhrs_lottery_pool WHERE created_time=%s", (LEGACY_CT,))
|
||||
legacy = {r['id']: r['member_phone'] for r in cur.fetchall()}
|
||||
assert len(legacy) == EXPECT_LEGACY, f'存量 {len(legacy)} != {EXPECT_LEGACY}'
|
||||
assert set(legacy) <= set(fmap), '文件未完全覆盖存量,中止'
|
||||
changes = [(i, fmap[i]) for i in legacy if fmap[i] != legacy[i]]
|
||||
n_null = sum(1 for _, v in changes if v is None)
|
||||
print(f'存量 {len(legacy)} 行, 需变更 {len(changes)}(置NULL {n_null}), 已一致 {len(legacy)-len(changes)}')
|
||||
assert len(changes) == EXPECT_CHG and n_null == EXPECT_NULL, '变更量与11-18审计不符,中止'
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过,未写入。执行请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
# ---- 备份表(DDL隐式提交,先行) ----
|
||||
cur.execute("SHOW TABLES LIKE 'hhrs_lottery_pool_phonebak_20261118'")
|
||||
assert not cur.fetchall(), '备份表已存在,中止(防重复执行覆盖备份)'
|
||||
cur.execute(f"CREATE TABLE hhrs_lottery_pool_phonebak_20261118 AS "
|
||||
f"SELECT id, member_phone FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}'")
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool_phonebak_20261118")
|
||||
assert cur.fetchone()['c'] == EXPECT_LEGACY, '备份行数不符'
|
||||
print('备份表 hhrs_lottery_pool_phonebak_20261118 已建:', EXPECT_LEGACY)
|
||||
|
||||
# ---- staging 批量 UPDATE ----
|
||||
cur.execute("DROP TABLE IF EXISTS hhrs_stg_phone_20261118")
|
||||
cur.execute("CREATE TABLE hhrs_stg_phone_20261118 (id BIGINT PRIMARY KEY, new_phone VARCHAR(20))")
|
||||
sql = "INSERT INTO hhrs_stg_phone_20261118 (id, new_phone) VALUES (%s,%s)"
|
||||
for i in range(0, len(changes), 2000):
|
||||
cur.executemany(sql, changes[i:i + 2000])
|
||||
|
||||
cur.execute("START TRANSACTION")
|
||||
cur.execute("UPDATE hhrs_lottery_pool p JOIN hhrs_stg_phone_20261118 s ON p.id=s.id "
|
||||
f"SET p.member_phone=s.new_phone WHERE p.created_time='{LEGACY_CT}' "
|
||||
"AND NOT (p.member_phone <=> s.new_phone)")
|
||||
n_upd = cur.rowcount
|
||||
|
||||
# ---- 事务内全量自检 ----
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool")
|
||||
n_all = cur.fetchone()['c']
|
||||
cur.execute("SELECT id, member_phone FROM hhrs_lottery_pool WHERE created_time=%s", (LEGACY_CT,))
|
||||
after = {r['id']: r['member_phone'] for r in cur.fetchall()}
|
||||
n_match = sum(1 for i, v in after.items() if v == fmap[i])
|
||||
n_null_after = sum(1 for v in after.values() if v is None)
|
||||
cur.execute("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time>=%s", ('2026-11-10 00:00:00',))
|
||||
n_1110 = cur.fetchone()['c']
|
||||
cur.execute("SELECT SUM(won) w FROM hhrs_lottery_pool")
|
||||
n_won = int(cur.fetchone()['w'])
|
||||
print(f'自检: 更新{n_upd}(应{EXPECT_CHG}) | 全池{n_all}(应574570) | 存量与文档全量一致{n_match}(应{EXPECT_LEGACY}) | '
|
||||
f'存量NULL{n_null_after}(应{EXPECT_NULL}) | 11-10批{n_1110}(应58893) | won={n_won}(应5997)')
|
||||
if (n_upd, n_all, n_match, n_null_after, n_1110, n_won) == (EXPECT_CHG, 574570, EXPECT_LEGACY, EXPECT_NULL, 58893, 5997):
|
||||
conn.commit()
|
||||
print('COMMIT 成功: 存量手机已按新文档回刷')
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK')
|
||||
raise SystemExit(1)
|
||||
cur.execute("DROP TABLE hhrs_stg_phone_20261118")
|
||||
print('staging 已清理;备份表保留待业务确认后清理')
|
||||
@@ -0,0 +1,54 @@
|
||||
# xuchao: HHRS00406553(杨红)/HHRS00402305(钟慧林) 石化减免卷预约改回"预约成功"
|
||||
# 用法: /Applications/Xcode.app/Contents/Developer/usr/bin/python3 docs/tools_reopen_petrol_two_20261116.py # 干跑
|
||||
# ... --apply # 实际执行
|
||||
# 背景: 上午批量迁移(tools_checkoff_petrol_closed_20261116.py, hhrs commit b8e7c64)把这两条置了已核销并补写自动核销记录;
|
||||
# 用户指令改为保留"预约成功"。回退= UPDATE status 4→1 + DELETE 对应 card_check(均为本日上午脚本插入,硬删)。
|
||||
# 原值备查: status=4;card_check id 926120000000006(预约867991347166021,check_time 2026-11-10 23:45:00)、
|
||||
# 926120000000007(预约869714399186053,check_time 2026-11-15 23:45:00)——回滚即按原值重插+改回4。
|
||||
import sys
|
||||
os_env = __import__('os')
|
||||
os_env.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
marker = "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(src.split(marker, 1)[0] + marker, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
APPTS = [867991347166021, 869714399186053] # 杨红 / 钟慧林
|
||||
CHECKS = [926120000000006, 926120000000007]
|
||||
ids = ','.join(map(str, APPTS))
|
||||
cids = ','.join(map(str, CHECKS))
|
||||
APPLY = '--apply' in sys.argv
|
||||
|
||||
conn.begin()
|
||||
|
||||
cur.execute(f"""SELECT id, card_number, name, status, is_deleted FROM card_appointment
|
||||
WHERE id IN ({ids})""")
|
||||
rows = cur.fetchall()
|
||||
print('预约现状:', rows)
|
||||
assert len(rows) == 2 and all(r['status'] == 4 and r['is_deleted'] == b'\x00' for r in rows), '预约状态不符,中止'
|
||||
|
||||
cur.execute(f"""SELECT id, appointment_id, checker_id, is_deleted FROM card_check WHERE id IN ({cids})""")
|
||||
checks = cur.fetchall()
|
||||
print('核销记录现状:', checks)
|
||||
assert len(checks) == 2 and sorted(c['appointment_id'] for c in checks) == APPTS and all(c['checker_id'] == -2 for c in checks), '核销记录不符,中止'
|
||||
|
||||
if not APPLY:
|
||||
print('干跑结束(未写入)。确认后加 --apply')
|
||||
conn.rollback()
|
||||
sys.exit(0)
|
||||
|
||||
cur.execute(f"UPDATE card_appointment SET status=1, updated_by=1 WHERE id IN ({ids}) AND status=4")
|
||||
print('预约改回预约成功:', cur.rowcount, '行')
|
||||
assert cur.rowcount == 2, 'UPDATE行数不符,回滚'
|
||||
cur.execute(f"DELETE FROM card_check WHERE id IN ({cids}) AND checker_id=-2")
|
||||
print('删除自动核销记录:', cur.rowcount, '行')
|
||||
assert cur.rowcount == 2, 'DELETE行数不符,回滚'
|
||||
|
||||
cur.execute(f"SELECT COUNT(*) c FROM card_appointment WHERE id IN ({ids}) AND status=1")
|
||||
assert cur.fetchone()['c'] == 2, '自检失败'
|
||||
cur.execute(f"SELECT COUNT(*) c FROM card_check WHERE id IN ({cids})")
|
||||
assert cur.fetchone()['c'] == 0, '自检失败'
|
||||
conn.commit()
|
||||
print('COMMIT 完成')
|
||||
@@ -0,0 +1,76 @@
|
||||
#!/usr/bin/env python3
|
||||
# xuchao: 回撤 2026-11-17 当天全部三处修改(用户指令:当天提供的数据有问题)
|
||||
# 用法: python3 docs/tools_revert_20261117.py # 干跑:核对三处备份抓手与预期量
|
||||
# python3 docs/tools_revert_20261117.py --execute # 事务内回撤+自检+COMMIT(UAT=生产)
|
||||
# 回撤内容:
|
||||
# 1) 删除第二批补导入 17,195 行(created_time>='2026-11-17 12:39:48',含NULL手机825);
|
||||
# 2) 池存量 member_phone 按 hhrs_lottery_pool_phonebak_20261117(515,677行,10-15建池原值)整表还原;
|
||||
# 3) 第四轮公示 member_phone/updated_time 按 hhrs_winner_r4phone_bak_20261117(2,000整行)还原;
|
||||
# 不碰:11-10导入58,893行、11-10删除115行、二三轮公示、won状态、第四轮抽奖结果。
|
||||
# 已知局限:池存量 updated_time 今日被回刷自动刷新,备份表未存该列,回撤后保留当前值(仅元数据失真)。
|
||||
import sys, os, re
|
||||
|
||||
EXECUTE = '--execute' in sys.argv
|
||||
B2_T0 = '2026-11-17 12:39:48'
|
||||
LEGACY_CT = '2026-10-15 09:57:17'
|
||||
R4 = 857957849313349
|
||||
EXPECT_B2, EXPECT_BAK_POOL, EXPECT_BAK_WIN = 17195, 515677, 2000
|
||||
|
||||
os.environ['SETTLE_ENV'] = 'uat'
|
||||
path = '/Users/jacobxu/Documents/Project/12301-dscp/docs/tools/settle_recompute_check.py'
|
||||
src = open(path).read()
|
||||
head = src.split("cur = conn.cursor(pymysql.cursors.DictCursor)", 1)[0] + "cur = conn.cursor(pymysql.cursors.DictCursor)"
|
||||
ns = {'__name__': 'env'}
|
||||
exec(compile(head, path, 'exec'), ns)
|
||||
conn, cur = ns['conn'], ns['cur']
|
||||
|
||||
def one(sql):
|
||||
cur.execute(sql)
|
||||
return cur.fetchone()
|
||||
|
||||
# ---- 预检:三个抓手都在、量都对 ----
|
||||
n_b2 = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= '{B2_T0}'")['c']
|
||||
n_bp = one("SELECT COUNT(*) c FROM hhrs_lottery_pool_phonebak_20261117")['c']
|
||||
n_bw = one(f"SELECT COUNT(*) c FROM hhrs_winner_r4phone_bak_20261117 WHERE round_id={R4}")['c']
|
||||
n_pool = one("SELECT COUNT(*) c FROM hhrs_lottery_pool")['c']
|
||||
print(f'预检: 第二批在池 {n_b2}(应{EXPECT_B2}) 池备份 {n_bp}(应{EXPECT_BAK_POOL}) 公示备份(四期) {n_bw}(应{EXPECT_BAK_WIN}) 全池 {n_pool}(应591765)')
|
||||
assert (n_b2, n_bp, n_bw, n_pool) == (EXPECT_B2, EXPECT_BAK_POOL, EXPECT_BAK_WIN, 591765), '抓手量不符,中止'
|
||||
# 公示备份与现表可完整按id关联
|
||||
cur.execute(f"SELECT COUNT(*) c FROM hhrs_winner w JOIN hhrs_winner_r4phone_bak_20261117 b ON w.id=b.id WHERE w.round_id={R4}")
|
||||
assert one(f"SELECT COUNT(*) c FROM hhrs_winner w JOIN hhrs_winner_r4phone_bak_20261117 b ON w.id=b.id WHERE w.round_id={R4}")['c'] == 2000, '公示id关联不完整'
|
||||
|
||||
if not EXECUTE:
|
||||
print('干跑通过。回撤请加 --execute')
|
||||
raise SystemExit
|
||||
|
||||
cur.execute("START TRANSACTION")
|
||||
cur.execute(f"DELETE FROM hhrs_lottery_pool WHERE created_time >= '{B2_T0}'")
|
||||
d1 = cur.rowcount
|
||||
cur.execute("UPDATE hhrs_lottery_pool p JOIN hhrs_lottery_pool_phonebak_20261117 b ON p.id=b.id "
|
||||
"SET p.member_phone=b.member_phone")
|
||||
d2 = cur.rowcount
|
||||
cur.execute("UPDATE hhrs_winner w JOIN hhrs_winner_r4phone_bak_20261117 b ON w.id=b.id "
|
||||
"SET w.member_phone=b.member_phone, w.updated_time=b.updated_time WHERE w.round_id=%s", (R4,))
|
||||
d3 = cur.rowcount
|
||||
|
||||
# 终态自检(与11-17早晨状态完全一致)
|
||||
a_pool = one("SELECT COUNT(*) c FROM hhrs_lottery_pool")['c']
|
||||
a_b2 = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time >= '{B2_T0}'")['c']
|
||||
a_diff = one("SELECT COUNT(*) c FROM hhrs_lottery_pool p JOIN hhrs_lottery_pool_phonebak_20261117 b ON p.id=b.id "
|
||||
"WHERE NOT (p.member_phone <=> b.member_phone)")['c']
|
||||
a_ph = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE created_time='{LEGACY_CT}' "
|
||||
"AND member_phone REGEXP '^[0-9]{3}\\\\*{4}[0-9]{4}$'")['c']
|
||||
a_null = one(f"SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE member_phone IS NULL")['c']
|
||||
a_wdiff = one(f"SELECT COUNT(*) c FROM hhrs_winner w JOIN hhrs_winner_r4phone_bak_20261117 b ON w.id=b.id "
|
||||
f"WHERE w.round_id={R4} AND NOT (w.member_phone <=> b.member_phone)")['c']
|
||||
a_won = one("SELECT COUNT(*) c FROM hhrs_lottery_pool WHERE won=1")['c']
|
||||
print(f'自检: 删批{d1}(应{EXPECT_B2}) 池还原更新{d2} 公示还原{d3}(应1827) | 全池{a_pool}(应574570) '
|
||||
f'残留批次{a_b2}(应0) 池与备份不一致{a_diff}(应0) 存量掩码形态{a_ph}(应515677) 全池NULL{a_null}(应0) '
|
||||
f'公示与备份不一致{a_wdiff}(应0) won1={a_won}(应5997=昨3997+今日四期2000)')
|
||||
if (a_pool, a_b2, a_diff, a_ph, a_null, a_wdiff, a_won) == (574570, 0, 0, 515677, 0, 0, 5997) and d1 == EXPECT_B2:
|
||||
conn.commit()
|
||||
print('COMMIT 成功: 已回到 2026-11-17 早晨状态')
|
||||
else:
|
||||
conn.rollback()
|
||||
print('自检未通过,已 ROLLBACK,未做任何更改')
|
||||
raise SystemExit(1)
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,118 @@
|
||||
-- xuchao: 2026-11-10 删除抽奖池存量手机号不合规未中奖115行 的回滚INSERT
|
||||
-- 执行方式:整体在事务内跑一遍,核对行数=115后COMMIT
|
||||
-- 注意:created_time/updated_time为删除时的原值;删除期间若有抽奖won回写不涉及本115行(均won=0)
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (23013,'姚友华','溆浦县',0,'431224********5967','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (32525,'蒋南','鹤城区',0,'431281********322X','179****1790',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (41680,'郑芽丽','麻阳苗族自治县',0,'431226********064X','154****1541',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (77826,'蒲元香','中方县',0,'431221********2228','154****1542',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (163569,'滕文齐','麻阳苗族自治县',0,'431226********0910','154****1540',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (184213,'马维瑞','靖州苗族侗族自治县',0,'431229********0839','163****1638',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (191996,'刘园园','麻阳苗族自治县',0,'431226********2164','174****1748',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (200908,'高向','沅陵县',0,'430802********7777','194****1947',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (228465,'颜霜','麻阳苗族自治县',0,'431226********4323','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (233927,'谭年华','中方县',0,'430521********3328','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (245508,'邹露','麻阳苗族自治县',0,'431226********2441','154****1549',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (286320,'左良燕','麻阳苗族自治县',0,'431226********034X','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (290197,'周琳','麻阳苗族自治县',0,'431226********004X','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (293039,'邓宇峰','溆浦县',0,'431224********1459','142****1420',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (293558,'周颖','鹤城区',0,'431221********1610','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (305395,'谭春花','麻阳苗族自治县',0,'431226********272X','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (318055,'喻燕燕','鹤城区',0,'360425********6720','154****1547',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (336547,'蒋奥君','芷江侗族自治县',0,'431228********4624','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (361683,'莫云龙','麻阳苗族自治县',0,'431226********2456','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (361730,'沈荣锋','会同县',0,'431225********0016','179****1791',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (383375,'袁爱军','中方县',0,'431221********2611','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (439211,'陈棚','麻阳苗族自治县',0,'431226********2450','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (460730,'龙鑫麟','麻阳苗族自治县',0,'431226********4817','154****1549',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (483602,'向娟','麻阳苗族自治县',0,'431226********3920','161****1617',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (510149,'滕彬','麻阳苗族自治县',0,'431226********3610','164****1645',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (529540,'周秀清','溆浦县',0,'513021********1504','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (543930,'文俊','沅陵县',0,'431222********0414','174****1743',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (600823,'石元超','辰溪县',0,'431223********2838','154****1547',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (633211,'傅平','麻阳苗族自治县',0,'431226********2419','179****1790',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (709704,'滕佳','麻阳苗族自治县',0,'431226********0919','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (710808,'石园园','辰溪县',0,'431223********0813','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (726095,'滕树霖','麻阳苗族自治县',0,'431226********0010','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (785168,'李昌银','麻阳苗族自治县',0,'431226********4517','154****1540',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (806375,'熊艳蕾','沅陵县',0,'431222********4741','164****1645',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (808773,'吴长青','芷江侗族自治县',0,'431228********3617','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (828876,'陈丽华','麻阳苗族自治县',0,'431226********422X','160****1604',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (914288,'黄敏','芷江侗族自治县',0,'431228********2114','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (921726,'邓年云','沅陵县',0,'431222********3916','142****1428',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (967525,'田盼','麻阳苗族自治县',0,'431226********0322','169****1698',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (970351,'满延雄','麻阳苗族自治县',0,'431226********0616','154****1541',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (986026,'糜乐','沅陵县',0,'431222********0020','154****1541',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1004397,'宋立恒','麻阳苗族自治县',0,'431226********421X','160****1604',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1024879,'胡龙吟','洪江市',0,'433130********4614','161****1617',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1076747,'张洲','麻阳苗族自治县',0,'431226********0313','179****1798',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1121705,'唐丁月','辰溪县',0,'431223********2214','154****1544',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1122936,'滕明志','麻阳苗族自治县',0,'431226********0025','174****1744',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1196651,'黄敏怡','麻阳苗族自治县',0,'441223********2329','154****1540',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1215480,'吴延寿','新晃侗族自治县',0,'431227********6317','154****1543',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1225190,'高洪红','麻阳苗族自治县',0,'431226********5526','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1320466,'李玉','麻阳苗族自治县',0,'431226********0622','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1344268,'粟小勇','沅陵县',0,'431222********181X','194****1946',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1350511,'杨淳','芷江侗族自治县',0,'431228********4274','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1362228,'田晓','麻阳苗族自治县',0,'431226********5728','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1368825,'满迅','麻阳苗族自治县',0,'431226********0914','164****1647',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1406641,'符绿艳','麻阳苗族自治县',0,'431226********6969','164****1649',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1410172,'龚世清','沅陵县',0,'431222********1517','142****1420',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1437056,'杨英华','中方县',0,'431221********2411','154****1549',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1459077,'张涌','麻阳苗族自治县',0,'431226********0637','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1466442,'沈虹羽','鹤城区',0,'431202********0813','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1476145,'路证查','麻阳苗族自治县',0,'520202********2467','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1520093,'曾志伟','沅陵县',0,'431222********4735','154****1547',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1551767,'蒋海峰','会同县',0,'431225********3813','174****1747',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1597653,'张蕾','麻阳苗族自治县',0,'431226********5429','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1635955,'游文','溆浦县',0,'431224********4335','163****1639',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1668029,'黄玉','麻阳苗族自治县',0,'431226********6920','154****1541',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1688177,'张琬群','麻阳苗族自治县',0,'431226********0020','154****1549',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1699070,'米承亮','辰溪县',0,'431223********3419','169****1690',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1699372,'李茂吉','鹤城区',0,'431224********1098','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1726833,'李玲乐','靖州苗族侗族自治县',0,'431229********0024','143****1437',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1785693,'张丽帆','麻阳苗族自治县',0,'431226********2124','164****1645',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1787452,'刘丽姣','鹤城区',0,'430521********4287','179****1797',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1789362,'戴艳娟','麻阳苗族自治县',0,'431224********272X','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1804842,'滕明长','麻阳苗族自治县',0,'431226********2473','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1814610,'雷国盛','麻阳苗族自治县',0,'431226********5979','168****1682',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1815511,'周华忠','麻阳苗族自治县',0,'431226********3619','164****1640',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1843512,'邓叶萍','麻阳苗族自治县',0,'431226********1226','154****1548',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1859281,'李俊华','麻阳苗族自治县',0,'431226********3075','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1860255,'罗晨溪','芷江侗族自治县',0,'430523********861X','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1901033,'李小玉','麻阳苗族自治县',0,'431226********272X','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1954500,'王伶俐','麻阳苗族自治县',0,'431226********4227','164****1649',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1961379,'向军','辰溪县',0,'431223********1631','142****1426',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1962189,'潘春容','沅陵县',0,'431222********2380','179****1799',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (1985211,'向雪娥','洪江市',0,'431281********3649','143****1431',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2005458,'姚金伶','新晃侗族自治县',0,'431227********0366','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2019168,'滕亮','麻阳苗族自治县',0,'431226********3014','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2055936,'朱磊','沅陵县',0,'431222********0253','163****1634',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2058460,'舒水莲','麻阳苗族自治县',0,'431226********5427','174****1744',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2086742,'周生刚','溆浦县',0,'431224********2090','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2152761,'唐明明','麻阳苗族自治县',0,'431226********2137','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2188676,'梁承林','通道侗族自治县',0,'431230********0617','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2197253,'李滕','麻阳苗族自治县',0,'431226********0017','154****1542',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2200795,'满洋','麻阳苗族自治县',0,'431226********6960','164****1649',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2206859,'邓然江','麻阳苗族自治县',0,'431226********0021','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2291675,'段慧芬','麻阳苗族自治县',0,'431226********6688','164****1648',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2301056,'刘沈','溆浦县',0,'431224********6677','174****1742',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2365808,'向利元','溆浦县',0,'431224********3087','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2389730,'李小红','麻阳苗族自治县',0,'431223********5227','163****1636',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2396612,'谭金定','麻阳苗族自治县',0,'522229********1222','168****1687',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2420987,'滕术逢','麻阳苗族自治县',0,'431226********0913','154****1545',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2432663,'唐荣皓','鹤城区',0,'431223********2012','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2442831,'杨子怡','芷江侗族自治县',0,'431228********4065','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2485419,'龚洋','沅陵县',0,'431222********1228','174****1746',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2492572,'吴宇骁','沅陵县',0,'431222********0816','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2493380,'田玉山','麻阳苗族自治县',0,'431226********2732','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2534174,'钟雅婷','溆浦县',0,'431224********7661','154****1546',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2616631,'向正','沅陵县',0,'431222********2417','143****1434',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2631673,'刘会让','溆浦县',0,'431224********2072','164****1641',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2664496,'熊亚萍','麻阳苗族自治县',0,'431226********7000','154****1549',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2674657,'杨金依','通道侗族自治县',0,'431230********0664','174****1746',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2701945,'罗双','沅陵县',0,'431222********3541','174****1747',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2814665,'谭美丹','麻阳苗族自治县',0,'431226********2723','174****1749',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2819993,'董昭升','鹤城区',0,'430482********8616','142****1424',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2885754,'向宏星','麻阳苗族自治县',0,'433025********3315','174****1748',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (2938784,'邹欣磊','麻阳苗族自治县',0,'431226********2437','164****1646',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
INSERT INTO hhrs_lottery_pool (id,member_name,county,batch_no,member_identity_no,member_phone,won,created_time,updated_time) VALUES (3007486,'唐娟','麻阳苗族自治县',0,'431226********2125','174****1745',0,'2026-10-15 09:57:17','2026-10-15 09:57:17');
|
||||
@@ -0,0 +1,116 @@
|
||||
id,姓名,县区,脱敏身份证,脱敏手机号,问题,创建时间
|
||||
23013,姚友华,溆浦县,431224********5967,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
32525,蒋南,鹤城区,431281********322X,179****1790,号段不在白名单,2026-10-15 09:57:17
|
||||
41680,郑芽丽,麻阳苗族自治县,431226********064X,154****1541,号段不在白名单,2026-10-15 09:57:17
|
||||
77826,蒲元香,中方县,431221********2228,154****1542,号段不在白名单,2026-10-15 09:57:17
|
||||
163569,滕文齐,麻阳苗族自治县,431226********0910,154****1540,号段不在白名单,2026-10-15 09:57:17
|
||||
184213,马维瑞,靖州苗族侗族自治县,431229********0839,163****1638,号段不在白名单,2026-10-15 09:57:17
|
||||
191996,刘园园,麻阳苗族自治县,431226********2164,174****1748,号段不在白名单,2026-10-15 09:57:17
|
||||
200908,高向,沅陵县,430802********7777,194****1947,号段不在白名单,2026-10-15 09:57:17
|
||||
228465,颜霜,麻阳苗族自治县,431226********4323,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
233927,谭年华,中方县,430521********3328,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
245508,邹露,麻阳苗族自治县,431226********2441,154****1549,号段不在白名单,2026-10-15 09:57:17
|
||||
286320,左良燕,麻阳苗族自治县,431226********034X,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
290197,周琳,麻阳苗族自治县,431226********004X,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
293039,邓宇峰,溆浦县,431224********1459,142****1420,号段不在白名单,2026-10-15 09:57:17
|
||||
293558,周颖,鹤城区,431221********1610,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
305395,谭春花,麻阳苗族自治县,431226********272X,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
318055,喻燕燕,鹤城区,360425********6720,154****1547,号段不在白名单,2026-10-15 09:57:17
|
||||
336547,蒋奥君,芷江侗族自治县,431228********4624,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
361683,莫云龙,麻阳苗族自治县,431226********2456,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
361730,沈荣锋,会同县,431225********0016,179****1791,号段不在白名单,2026-10-15 09:57:17
|
||||
383375,袁爱军,中方县,431221********2611,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
439211,陈棚,麻阳苗族自治县,431226********2450,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
460730,龙鑫麟,麻阳苗族自治县,431226********4817,154****1549,号段不在白名单,2026-10-15 09:57:17
|
||||
483602,向娟,麻阳苗族自治县,431226********3920,161****1617,号段不在白名单,2026-10-15 09:57:17
|
||||
510149,滕彬,麻阳苗族自治县,431226********3610,164****1645,号段不在白名单,2026-10-15 09:57:17
|
||||
529540,周秀清,溆浦县,513021********1504,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
543930,文俊,沅陵县,431222********0414,174****1743,号段不在白名单,2026-10-15 09:57:17
|
||||
600823,石元超,辰溪县,431223********2838,154****1547,号段不在白名单,2026-10-15 09:57:17
|
||||
633211,傅平,麻阳苗族自治县,431226********2419,179****1790,号段不在白名单,2026-10-15 09:57:17
|
||||
709704,滕佳,麻阳苗族自治县,431226********0919,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
710808,石园园,辰溪县,431223********0813,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
726095,滕树霖,麻阳苗族自治县,431226********0010,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
785168,李昌银,麻阳苗族自治县,431226********4517,154****1540,号段不在白名单,2026-10-15 09:57:17
|
||||
806375,熊艳蕾,沅陵县,431222********4741,164****1645,号段不在白名单,2026-10-15 09:57:17
|
||||
808773,吴长青,芷江侗族自治县,431228********3617,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
828876,陈丽华,麻阳苗族自治县,431226********422X,160****1604,号段不在白名单,2026-10-15 09:57:17
|
||||
914288,黄敏,芷江侗族自治县,431228********2114,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
921726,邓年云,沅陵县,431222********3916,142****1428,号段不在白名单,2026-10-15 09:57:17
|
||||
967525,田盼,麻阳苗族自治县,431226********0322,169****1698,号段不在白名单,2026-10-15 09:57:17
|
||||
970351,满延雄,麻阳苗族自治县,431226********0616,154****1541,号段不在白名单,2026-10-15 09:57:17
|
||||
986026,糜乐,沅陵县,431222********0020,154****1541,号段不在白名单,2026-10-15 09:57:17
|
||||
1004397,宋立恒,麻阳苗族自治县,431226********421X,160****1604,号段不在白名单,2026-10-15 09:57:17
|
||||
1024879,胡龙吟,洪江市,433130********4614,161****1617,号段不在白名单,2026-10-15 09:57:17
|
||||
1076747,张洲,麻阳苗族自治县,431226********0313,179****1798,号段不在白名单,2026-10-15 09:57:17
|
||||
1121705,唐丁月,辰溪县,431223********2214,154****1544,号段不在白名单,2026-10-15 09:57:17
|
||||
1122936,滕明志,麻阳苗族自治县,431226********0025,174****1744,号段不在白名单,2026-10-15 09:57:17
|
||||
1196651,黄敏怡,麻阳苗族自治县,441223********2329,154****1540,号段不在白名单,2026-10-15 09:57:17
|
||||
1215480,吴延寿,新晃侗族自治县,431227********6317,154****1543,号段不在白名单,2026-10-15 09:57:17
|
||||
1225190,高洪红,麻阳苗族自治县,431226********5526,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1320466,李玉,麻阳苗族自治县,431226********0622,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
1344268,粟小勇,沅陵县,431222********181X,194****1946,号段不在白名单,2026-10-15 09:57:17
|
||||
1350511,杨淳,芷江侗族自治县,431228********4274,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1362228,田晓,麻阳苗族自治县,431226********5728,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
1368825,满迅,麻阳苗族自治县,431226********0914,164****1647,号段不在白名单,2026-10-15 09:57:17
|
||||
1406641,符绿艳,麻阳苗族自治县,431226********6969,164****1649,号段不在白名单,2026-10-15 09:57:17
|
||||
1410172,龚世清,沅陵县,431222********1517,142****1420,号段不在白名单,2026-10-15 09:57:17
|
||||
1437056,杨英华,中方县,431221********2411,154****1549,号段不在白名单,2026-10-15 09:57:17
|
||||
1459077,张涌,麻阳苗族自治县,431226********0637,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
1466442,沈虹羽,鹤城区,431202********0813,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1476145,路证查,麻阳苗族自治县,520202********2467,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
1520093,曾志伟,沅陵县,431222********4735,154****1547,号段不在白名单,2026-10-15 09:57:17
|
||||
1551767,蒋海峰,会同县,431225********3813,174****1747,号段不在白名单,2026-10-15 09:57:17
|
||||
1597653,张蕾,麻阳苗族自治县,431226********5429,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
1635955,游文,溆浦县,431224********4335,163****1639,号段不在白名单,2026-10-15 09:57:17
|
||||
1668029,黄玉,麻阳苗族自治县,431226********6920,154****1541,号段不在白名单,2026-10-15 09:57:17
|
||||
1688177,张琬群,麻阳苗族自治县,431226********0020,154****1549,号段不在白名单,2026-10-15 09:57:17
|
||||
1699070,米承亮,辰溪县,431223********3419,169****1690,号段不在白名单,2026-10-15 09:57:17
|
||||
1699372,李茂吉,鹤城区,431224********1098,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1726833,李玲乐,靖州苗族侗族自治县,431229********0024,143****1437,号段不在白名单,2026-10-15 09:57:17
|
||||
1785693,张丽帆,麻阳苗族自治县,431226********2124,164****1645,号段不在白名单,2026-10-15 09:57:17
|
||||
1787452,刘丽姣,鹤城区,430521********4287,179****1797,号段不在白名单,2026-10-15 09:57:17
|
||||
1789362,戴艳娟,麻阳苗族自治县,431224********272X,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
1804842,滕明长,麻阳苗族自治县,431226********2473,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
1814610,雷国盛,麻阳苗族自治县,431226********5979,168****1682,号段不在白名单,2026-10-15 09:57:17
|
||||
1815511,周华忠,麻阳苗族自治县,431226********3619,164****1640,号段不在白名单,2026-10-15 09:57:17
|
||||
1843512,邓叶萍,麻阳苗族自治县,431226********1226,154****1548,号段不在白名单,2026-10-15 09:57:17
|
||||
1859281,李俊华,麻阳苗族自治县,431226********3075,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
1860255,罗晨溪,芷江侗族自治县,430523********861X,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1901033,李小玉,麻阳苗族自治县,431226********272X,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
1954500,王伶俐,麻阳苗族自治县,431226********4227,164****1649,号段不在白名单,2026-10-15 09:57:17
|
||||
1961379,向军,辰溪县,431223********1631,142****1426,号段不在白名单,2026-10-15 09:57:17
|
||||
1962189,潘春容,沅陵县,431222********2380,179****1799,号段不在白名单,2026-10-15 09:57:17
|
||||
1985211,向雪娥,洪江市,431281********3649,143****1431,号段不在白名单,2026-10-15 09:57:17
|
||||
2005458,姚金伶,新晃侗族自治县,431227********0366,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
2019168,滕亮,麻阳苗族自治县,431226********3014,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
2055936,朱磊,沅陵县,431222********0253,163****1634,号段不在白名单,2026-10-15 09:57:17
|
||||
2058460,舒水莲,麻阳苗族自治县,431226********5427,174****1744,号段不在白名单,2026-10-15 09:57:17
|
||||
2086742,周生刚,溆浦县,431224********2090,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
2152761,唐明明,麻阳苗族自治县,431226********2137,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
2188676,梁承林,通道侗族自治县,431230********0617,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
2197253,李滕,麻阳苗族自治县,431226********0017,154****1542,号段不在白名单,2026-10-15 09:57:17
|
||||
2200795,满洋,麻阳苗族自治县,431226********6960,164****1649,号段不在白名单,2026-10-15 09:57:17
|
||||
2206859,邓然江,麻阳苗族自治县,431226********0021,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
2291675,段慧芬,麻阳苗族自治县,431226********6688,164****1648,号段不在白名单,2026-10-15 09:57:17
|
||||
2301056,刘沈,溆浦县,431224********6677,174****1742,号段不在白名单,2026-10-15 09:57:17
|
||||
2365808,向利元,溆浦县,431224********3087,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
2389730,李小红,麻阳苗族自治县,431223********5227,163****1636,号段不在白名单,2026-10-15 09:57:17
|
||||
2396612,谭金定,麻阳苗族自治县,522229********1222,168****1687,号段不在白名单,2026-10-15 09:57:17
|
||||
2420987,滕术逢,麻阳苗族自治县,431226********0913,154****1545,号段不在白名单,2026-10-15 09:57:17
|
||||
2432663,唐荣皓,鹤城区,431223********2012,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
2442831,杨子怡,芷江侗族自治县,431228********4065,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
2485419,龚洋,沅陵县,431222********1228,174****1746,号段不在白名单,2026-10-15 09:57:17
|
||||
2492572,吴宇骁,沅陵县,431222********0816,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
2493380,田玉山,麻阳苗族自治县,431226********2732,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
2534174,钟雅婷,溆浦县,431224********7661,154****1546,号段不在白名单,2026-10-15 09:57:17
|
||||
2616631,向正,沅陵县,431222********2417,143****1434,号段不在白名单,2026-10-15 09:57:17
|
||||
2631673,刘会让,溆浦县,431224********2072,164****1641,号段不在白名单,2026-10-15 09:57:17
|
||||
2664496,熊亚萍,麻阳苗族自治县,431226********7000,154****1549,号段不在白名单,2026-10-15 09:57:17
|
||||
2674657,杨金依,通道侗族自治县,431230********0664,174****1746,号段不在白名单,2026-10-15 09:57:17
|
||||
2701945,罗双,沅陵县,431222********3541,174****1747,号段不在白名单,2026-10-15 09:57:17
|
||||
2814665,谭美丹,麻阳苗族自治县,431226********2723,174****1749,号段不在白名单,2026-10-15 09:57:17
|
||||
2819993,董昭升,鹤城区,430482********8616,142****1424,号段不在白名单,2026-10-15 09:57:17
|
||||
2885754,向宏星,麻阳苗族自治县,433025********3315,174****1748,号段不在白名单,2026-10-15 09:57:17
|
||||
2938784,邹欣磊,麻阳苗族自治县,431226********2437,164****1646,号段不在白名单,2026-10-15 09:57:17
|
||||
3007486,唐娟,麻阳苗族自治县,431226********2125,174****1745,号段不在白名单,2026-10-15 09:57:17
|
||||
|
@@ -0,0 +1,22 @@
|
||||
-- xuchao: 怀化石化(减免卷)"已关闭→已核销"迁移的回滚段(2026-11-16 执行,UAT=生产库 dscp_business_uat)
|
||||
-- 回滚脚本(勿随迁移执行;仅当需要撤销时手动跑):
|
||||
-- BEGIN;
|
||||
-- DELETE FROM card_check WHERE id IN (926120000000001,926120000000002,926120000000003,926120000000004,926120000000005,926120000000006,926120000000007);
|
||||
-- UPDATE card_appointment SET status=2, updated_by=1 WHERE id IN (859787077677637,864426506904773,864779270436165,865456274982533,867141847644421,867991347166021,869714399186053) AND status=4;
|
||||
-- COMMIT;
|
||||
-- 注意:回滚只恢复数据状态;资源开关 card_resource_rule.is_appointment_count(851222303983301)=1
|
||||
-- 是运营 2026-11-16 09:47 在管理后台开启的(防再次自动取消),是否一并关闭请另行决策。
|
||||
|
||||
-- ============================================================
|
||||
-- 11-16 下午追加:用户指令将 HHRS00406553(杨红,预约867991347166021)、
|
||||
-- HHRS00402305(钟慧林,预约869714399186053) 两条改回"预约成功"(status=1),
|
||||
-- 并删除上午补写的 card_check 926120000000006/926120000000007(执行脚本
|
||||
-- docs/tools_reopen_petrol_two_20261116.py)。此2条的回滚(恢复为已核销):
|
||||
-- BEGIN;
|
||||
-- UPDATE card_appointment SET status=4, updated_by=1 WHERE id IN (867991347166021,869714399186053) AND status=1;
|
||||
-- INSERT INTO card_check (id,card_model_id,card_model_name,resource_id,resource_name,card_number,member_id,name,phone,identity_no,check_time,checker_id,checker_name,appointment_id,is_deleted,created_time,updated_time) VALUES
|
||||
-- (926120000000006,831756570496837,'怀化社保卡权益包',851222303983301,'怀化石化(减免卷)','HHRS00406553',867990787824453,'杨红','18166223577','431281199002031021','2026-11-10 23:45:00',-2,'自动核销',867991347166021,0,NOW(),NOW()),
|
||||
-- (926120000000007,831756570496837,'怀化社保卡权益包',851222303983301,'怀化石化(减免卷)','HHRS00402305',863774727165061,'钟慧林','13787579576','431225198701273622','2026-11-15 23:45:00',-2,'自动核销',869714399186053,0,NOW(),NOW());
|
||||
-- COMMIT;
|
||||
-- ============================================================
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 三期 Tab -->
|
||||
<!-- 各期 Tab -->
|
||||
<view class="tab-bar">
|
||||
<view
|
||||
class="tab-item"
|
||||
@@ -39,7 +39,7 @@
|
||||
<view class="search-area">
|
||||
<view class="search-bar">
|
||||
<u-icon name="search" color="#8e8e93" size="36"></u-icon>
|
||||
<input class="search-input" v-model="keyword" placeholder="搜索姓名/手机号/身份证号" confirm-type="search" @confirm="onSearch" />
|
||||
<input class="search-input" v-model="keyword" placeholder="搜索姓名/身份证号" confirm-type="search" @confirm="onSearch" />
|
||||
<view class="search-btn" @click="onSearch">搜索</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -50,12 +50,10 @@
|
||||
<view class="table-header">
|
||||
<text class="table-col col-name">姓名</text>
|
||||
<text class="table-col col-idcard">身份证</text>
|
||||
<text class="table-col col-phone">手机号码</text>
|
||||
</view>
|
||||
<view class="table-row" v-for="(item, index) in currentList" :key="index">
|
||||
<text class="table-col col-name">{{ item.memberName }}</text>
|
||||
<text class="table-col col-idcard">{{ item.memberIdentityNo }}</text>
|
||||
<text class="table-col col-phone">{{ item.memberPhone }}</text>
|
||||
</view>
|
||||
<!-- xuchao: 名单不足一页时隐藏加载更多 -->
|
||||
<view class="loadmore-area" v-if="(totals[currentTab] || 0) > pageSize">
|
||||
@@ -110,7 +108,7 @@ export default {
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
// xuchao: 关键字防抖 400ms 后走服务端模糊搜索(姓名/手机号/身份证任意片段)
|
||||
// xuchao: 关键字防抖 400ms 后走服务端模糊搜索(姓名/身份证任意片段)
|
||||
keyword() {
|
||||
clearTimeout(this._kwTimer)
|
||||
this._kwTimer = setTimeout(() => this.search(), 400)
|
||||
@@ -160,7 +158,7 @@ export default {
|
||||
}
|
||||
}).catch(() => { this.datesLoaded = true })
|
||||
},
|
||||
// xuchao: 拉取某期某页;keyword 走服务端 LIKE(姓名/手机/身份证任意片段),空串=不过滤
|
||||
// xuchao: 拉取某期某页;keyword 走服务端 LIKE(姓名/身份证任意片段),空串=不过滤
|
||||
loadTab(tabIndex, pageNo, keyword) {
|
||||
if (!this.tabs[tabIndex]) return
|
||||
const kw = keyword || ''
|
||||
@@ -459,11 +457,6 @@ export default {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.col-phone {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* 加载更多 */
|
||||
.loadmore-area {
|
||||
padding: 24px 0;
|
||||
|
||||
Reference in New Issue
Block a user