diff --git a/resources/views/admin/platform_orders/index.blade.php b/resources/views/admin/platform_orders/index.blade.php index 2888efd..4639833 100644 --- a/resources/views/admin/platform_orders/index.blade.php +++ b/resources/views/admin/platform_orders/index.blade.php @@ -1036,9 +1036,11 @@ } if (trim((string) ($filters['site_subscription_id'] ?? '')) !== '') { $createQuery['site_subscription_id'] = (int) ($filters['site_subscription_id'] ?? 0); - // 治理口径:当从订阅维度锁定进入时,创建页应显式携带 require_subscription=1 - //(即使已带 site_subscription_id,也用于统一口径/便于排查链路来源)。 + // 治理口径:当从订阅维度锁定进入时: + // 1) 显式声明 require_subscription=1(统一来源口径/便于排查链路来源) + // 2) 显式声明 order_type=renewal(语义更清晰;create 页仍会二次强制兜底) $createQuery['require_subscription'] = '1'; + $createQuery['order_type'] = 'renewal'; } // 线索联动:若当前列表已按 lead_id 锁定,则新建订单也应带上 lead_id,维持闭环追溯 if (trim((string) ($filters['lead_id'] ?? '')) !== '') { diff --git a/tests/Feature/AdminPlatformOrderIndexCreateLinkPrefillFromFiltersTest.php b/tests/Feature/AdminPlatformOrderIndexCreateLinkPrefillFromFiltersTest.php index 0fbd2ca..e55cf41 100644 --- a/tests/Feature/AdminPlatformOrderIndexCreateLinkPrefillFromFiltersTest.php +++ b/tests/Feature/AdminPlatformOrderIndexCreateLinkPrefillFromFiltersTest.php @@ -73,6 +73,7 @@ class AdminPlatformOrderIndexCreateLinkPrefillFromFiltersTest extends TestCase 'plan_id' => $plan->id, 'site_subscription_id' => $sub->id, 'require_subscription' => '1', + 'order_type' => 'renewal', ]); $res->assertSee($expectedCreateUrl, false);