feat: nhắc gia hạn QR theo dịch vụ, failover server hosting, CCCD admin, log cấp phát dịch vụ
- Mail campaign: mẫu nhắc gia hạn thanh toán QR, chọn dịch vụ + chu kỳ từng dòng (renewal_services) - Hosting: nhiều server Plesk cho một gói (service_plan_servers), chuyển server khi server chết - Admin xem/sửa giấy tờ định danh khách, tuỳ chọn gia hạn cho khách, nhật ký cấp phát dịch vụ - Đánh dấu mẫu email dịch vụ là non-marketing Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5.5
parent
047c23beff
commit
55a834a2f8
@@ -28,6 +28,7 @@ use Illuminate\Queue\InteractsWithQueue;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
use RuntimeException;
|
||||
use Throwable;
|
||||
use App\Support\ServiceProvisionLog;
|
||||
|
||||
class CreateVirtualMachineJob implements ShouldQueue
|
||||
{
|
||||
@@ -70,6 +71,8 @@ class CreateVirtualMachineJob implements ShouldQueue
|
||||
['customer_id' => $customerId, 'status' => 'running'],
|
||||
);
|
||||
|
||||
ServiceProvisionLog::forOrderItem($this->item->id, 'provision_started', $this->isRetry ? 'Bắt đầu khởi tạo lại máy chủ' : 'Bắt đầu khởi tạo máy chủ', ['is_retry' => $this->isRetry]);
|
||||
|
||||
$vmLogger->step('Create VM job started', [
|
||||
'order_item_id' => $this->item->id,
|
||||
'is_retry' => $this->isRetry,
|
||||
@@ -110,6 +113,8 @@ class CreateVirtualMachineJob implements ShouldQueue
|
||||
|
||||
$this->item->server_name = $combinedName;
|
||||
|
||||
ServiceProvisionLog::forOrderItem($this->item->id, 'provision_step', 'Đã giữ IP và bắt đầu clone VM', ['ip' => $reservedIp]);
|
||||
|
||||
$vmLogger->step('IP reserved for VM', [
|
||||
'order_item_id' => $this->item->id,
|
||||
'ip' => $reservedIp,
|
||||
@@ -226,6 +231,8 @@ class CreateVirtualMachineJob implements ShouldQueue
|
||||
|
||||
$adminDetail = $e instanceof VmProvisionException ? $e->adminDetail : $e->getMessage();
|
||||
|
||||
ServiceProvisionLog::forOrderItem($this->item->id, 'provision_failed', 'Khởi tạo máy chủ thất bại — ' . $adminDetail, ['stage' => 'create_vm']);
|
||||
|
||||
$vmLogger->exception('Create VM job failed', $e, [
|
||||
'order_item_id' => $this->item->id,
|
||||
'is_retry' => $this->isRetry,
|
||||
|
||||
Reference in New Issue
Block a user