Files
zentao-flow/tmp/verify_chg065b.py

19 lines
1003 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# -*- coding: utf-8 -*-
import io, sys, json, requests
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')
token = open('.claude/ai_token.txt').read().strip()
B = 'http://localhost:8086'
def score(account, label, keys):
r = requests.post(f'{B}/zentao/count/myWorkScore', json={'account': account, 'date': '2026-06-01 00:00:00'},
headers={'Authorization': token}, timeout=60)
d = r.json()
data = d.get('data') or {}
perf = data.get('performance') or data
print(f'== {label}({account} 2026-06)code={d.get("code")} ==')
for k in keys:
print(f' {k} = {perf.get(k)}')
rd = perf.get('perfRawDetail')
if rd: print(' perfRawDetail keys:', list(rd.keys())[:6])
score('liyuyan', '产品助理XMZL', ['workloadPrdScore','releaseScore','productBugRate','productProblemResponse','productResponsibilityScore'])
score('liushengqing', 'UI', ['punctualityScore','designScore','workAttitude','totalTask','delayTask','finishPunctuality'])