From 8c0bcef237aa6f9bd1b8e7c1f74dd169b550eb24 Mon Sep 17 00:00:00 2001 From: XuqmGroup Date: Thu, 2 Jul 2026 19:34:15 +0800 Subject: [PATCH] fix: update store state to APPROVED when app is live even if version code doesn't match exactly MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - When polled state is ONLINE but version codes don't match, still mark as APPROVED with nonCurrentRelease=true - Prevents state getting stuck at UNDER_REVIEW when Huawei shows the app is already live - Fixes issue where Huawei app is live but system still shows '审核中' Co-Authored-By: Claude --- .../com/xuqm/update/service/StoreSubmissionService.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/update-service/src/main/java/com/xuqm/update/service/StoreSubmissionService.java b/update-service/src/main/java/com/xuqm/update/service/StoreSubmissionService.java index 4311fa6..256fa0f 100644 --- a/update-service/src/main/java/com/xuqm/update/service/StoreSubmissionService.java +++ b/update-service/src/main/java/com/xuqm/update/service/StoreSubmissionService.java @@ -1114,10 +1114,12 @@ public class StoreSubmissionService { storeService.updateStoreReviewLive(v.getId(), storeType, false, buildLiveReason(polled), buildExtra(polled)); } else if (!isApproved) { - // 商店有其他版本在线,但不是本次提交的版本。 - // 旧版本在线不能证明新版本已通过审核,保持当前状态不变。 - log.info("Manual refresh: {}/{} online version {} != submitted {} — cannot confirm approval, keeping current state", + // 商店显示应用已上线,但版本号不完全匹配。 + // 仍然标记为 APPROVED(preExisting=true),避免卡在 UNDER_REVIEW。 + log.info("Manual refresh: {}/{} online version {} != submitted {} — marking APPROVED with nonCurrentRelease", v.getId(), storeType, polled.getOnlineVersionCode(), v.getVersionCode()); + storeService.updateStoreReviewLive(v.getId(), storeType, true, + buildLiveReason(polled), buildExtra(polled)); } else { // Already APPROVED (from webhook): version approved but pending distribution. // Do NOT overwrite with nonCurrentRelease=true — that would show a misleading