修改峰平谷不对齐

This commit is contained in:
2026-07-24 10:40:19 +08:00
parent e37e494a1f
commit c118ab39b7
3 changed files with 43 additions and 14 deletions

View File

@@ -22,9 +22,11 @@ def collect_sum_data():
try:
data = request.get_json(silent=True) or {}
history_id = data.get('history_id')
log_info(f'[求和数据API] 采集求和数据历史记录ID: {history_id or "全部"}', 'api')
start_date = data.get('start_date')
end_date = data.get('end_date')
log_info(f'[求和数据API] 采集求和数据历史记录ID: {history_id or "全部"},日期范围: {start_date or "开始"} ~ {end_date or "结束"}', 'api')
result = collect_sum_data_from_history(history_id)
result = collect_sum_data_from_history(history_id, start_date, end_date)
if result['success']:
log_info(f'[求和数据API] 采集成功: {result["message"]}', 'api')
return jsonify(result)