This commit is contained in:
gr
2026-10-15 11:03:54 +08:00
parent 70ddc1a70a
commit bb28d93cec
64 changed files with 12747 additions and 420 deletions
@@ -22,6 +22,12 @@ class AutoAssignLogLists extends BaseAdminDataLists implements ListsSearchInterf
'50_60' => '50%~60%',
];
/** 分档口径版本(auto_assign_log.rate_version)文案 */
private const RATE_VERSION_LABELS = [
'v1' => '旧口径·分母仅新指派',
'v2' => '新口径·每列独立分母',
];
/**
* @notes 设置搜索条件
*/
@@ -49,6 +55,12 @@ class AutoAssignLogLists extends BaseAdminDataLists implements ListsSearchInterf
$row['action_text'] = (int) ($row['action'] ?? 0) === 1 ? '已分配' : '未分配';
$row['tier_text'] = self::TIER_LABELS[(string) ($row['tier'] ?? '')] ?? '';
$row['visit2_rate'] = $row['visit2_rate'] !== null ? (float) $row['visit2_rate'] : null;
// 两套口径:visit2_rate=新口径 v2(每列独立分母),visit2_rate_new_assign=旧口径 v1(分母仅新指派);rate_version=本批次分档所用口径
$newAssignRate = $row['visit2_rate_new_assign'] ?? null;
$row['visit2_rate_new_assign'] = $newAssignRate !== null ? (float) $newAssignRate : null;
$rateVersion = trim((string) ($row['rate_version'] ?? ''));
$row['rate_version'] = $rateVersion !== '' ? $rateVersion : 'v1';
$row['rate_version_text'] = self::RATE_VERSION_LABELS[$row['rate_version']] ?? $row['rate_version'];
$rbTs = (int) ($row['rollback_time'] ?? 0);
$row['rollback_time_text'] = $rbTs > 0 ? date('Y-m-d H:i:s', $rbTs) : '';