B-44: 返修——多币种对方汇总、镜像科目筛选、冲销独立生效日、创建来源撤销边界与并发幂等

This commit is contained in:
腾讯WorkBuddy
2026-08-19 13:28:28 +08:00
parent d59576739f
commit f16e8aad34
7 changed files with 528 additions and 91 deletions
+5 -4
View File
@@ -133,10 +133,11 @@ def _event_filters(
if subject:
if subject not in SUBJECTS:
raise PositionInputError("科目筛选无效。")
conditions.append(
"(p.subject_code = ? OR (p.subject_code = ? AND p.subject_code = ?))"
)
params.extend([subject, MIRROR[subject], subject])
# The stored subject lives on one company's perspective; the viewer on
# the other side sees its mirror. Match both so mirror events are never
# dropped from the filter.
conditions.append("(p.subject_code = ? OR p.subject_code = ?)")
params.extend([subject, MIRROR[subject]])
if posting_kind:
conditions.append("p.posting_kind = ?")
params.append(posting_kind)