Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
H
hh_ccs
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
贺阳
hh_ccs
Commits
68e36974
提交
68e36974
authored
9月 19, 2025
作者:
贺阳
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
提单倒挂处理重复的问题
上级
18514bc4
显示空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
10 行增加
和
0 行删除
+10
-0
cc_bill_loading.py
ccs_connect_tiktok/models/cc_bill_loading.py
+10
-0
没有找到文件。
ccs_connect_tiktok/models/cc_bill_loading.py
浏览文件 @
68e36974
...
...
@@ -696,6 +696,10 @@ class CcBl(models.Model):
if
log
.
process_code
==
node
.
tk_code
:
node_logs
[
i
]
=
(
node
,
log
,
log
.
operate_time
)
break
# 用于记录已经报告过倒挂的节点,避免重复报告
reported_inversions
=
set
()
# 遍历每个有日志的节点,与前面所有有日志的节点比较
for
current_idx
in
sorted
(
node_logs
.
keys
()):
current_node
,
current_log
,
current_time
=
node_logs
[
current_idx
]
...
...
@@ -707,15 +711,21 @@ class CcBl(models.Model):
# 检查时间顺序
if
current_time
and
prev_time
:
if
current_time
<
prev_time
:
# 使用节点编码作为唯一标识,避免重复报告同一个节点的倒挂
inversion_key
=
current_log
.
process_code
if
inversion_key
not
in
reported_inversions
:
try
:
progress_name
=
current_log
.
progress_name
or
"空"
process_code
=
current_log
.
process_code
or
"空"
issues
.
append
(
f
"{bl.bl_no},出现{progress_name}({process_code})倒挂"
)
reported_inversions
.
add
(
inversion_key
)
except
Exception
as
e
:
logging
.
warning
(
f
"构建倒序问题描述失败: {str(e)}"
)
if
"节点倒挂"
not
in
reported_inversions
:
issues
.
append
(
f
"{bl.bl_no},出现节点倒挂"
)
reported_inversions
.
add
(
"节点倒挂"
)
# 检查漏推问题
missing_issues
=
self
.
_check_bl_missing_nodes
(
bl
,
sync_logs
)
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论