修复随机号码前先按权重随机工单,并修复降权号码筛选与清理

This commit is contained in:
root
2026-07-04 22:09:39 +08:00
parent 9b57b0c400
commit 6b72cd7b67
37 changed files with 2201 additions and 473 deletions
+19
View File
@@ -42,6 +42,7 @@ class Number extends Model
'status_text',
'manual_manage_text',
'platform_status_text',
'ratio_deferred_text',
];
/**
@@ -81,6 +82,17 @@ class Number extends Model
];
}
/**
* @return array<string, string>
*/
public function getRatioDeferredList(): array
{
return [
'0' => __('Ratio deferred no'),
'1' => __('Ratio deferred yes'),
];
}
/**
* @return array<string, string>
*/
@@ -158,6 +170,13 @@ class Number extends Model
return $list[$key] ?? $key;
}
public function getRatioDeferredTextAttr($value, $data): string
{
$key = (string) ((int) ($data['ratio_deferred'] ?? 0));
$list = $this->getRatioDeferredList();
return $list[$key] ?? $key;
}
/**
* 根据链接码生成完整分流 URL
*/