Commit d6b743a9 by 杨树贤

测试供应商有效

parent a8a4ca3b
......@@ -38,7 +38,7 @@ class SetSupplierFollowUp extends Command
// $service->importSupplierGroup(true);
// $service->changeSupplierType();
// $service->generateYunxinAccount(true);
$service->exportSupplierForUnionData();
$service->checkCompanyName();
// $service->makeSupplierSystemTagAbnormal();
}
}
......@@ -553,5 +553,18 @@ class DataService
'update_time' => time(),
]);
}
public function checkCompanyName()
{
$suppliers = SupplierChannelModel::where('group_code', '')->where('is_type', 0)
->where('create_time', '<', 1655778780)->where('update_time', '<', 1655778780)->get();
foreach ($suppliers as $supplier) {
$company = (new CompanyService())->getCompanyInfo($supplier['supplier_name'], '', 1);
if ($company) {
echo $supplier['supplier_name'] . PHP_EOL;
sleep(0.1);
}
}
}
}
......@@ -60,5 +60,5 @@ Route::group(['middleware' => ['external'], 'namespace' => 'Sync'], function ()
});
Route::match(['get', 'post'], '/test', function () {
(new \App\Http\Services\SyncSupplierService())->syncSupplierToUnited(5);
(new \App\Http\Services\DataService())->checkCompanyName();
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment