作者 ZhengBing He

ticketsDing

<?php
namespace App\Console\Commands;
namespace App\Console\Commands\WorkOrder;
use App\Models\WorkOrder\TicketLog;
use App\Models\WorkOrder\WorkOrderLog;
use App\Services\DingTalkService;
use Illuminate\Console\Command;
... ... @@ -42,12 +43,12 @@ class WorkOrderDing extends Command
{
while (true) {
try {
$log = WorkOrderLog::where('ding', 0)->first();
$log = TicketLog::where('ding', 0)->first();
if (!$log) {
sleep(3);
continue;
}
$mobile = $log->manager->mobile;
$mobile = $log->engineer->mobile;
$response = Http::withBasicAuth(
env('DINGDING_BASIC_USER'),
env('DINGDING_BASIC_PASS')
... ...