Commit ac5713a1 by 杨树贤

修改同步方式

parent 2c581ba3
Showing with 1 additions and 2 deletions
......@@ -666,9 +666,8 @@ class DataService
{
ini_set('memory_limit', -1);
$suppliers = SupplierChannelModel::select(['supplier_id', 'supplier_name'])->where('is_type', 0)
->where('status', 2)->get()->toArray();
->where('status', 2)->offset(200)->limit(200)->get()->toArray();
foreach ($suppliers as $supplier) {
usleep(100000);
if (!empty($supplier['supplier_name'])) {
echo "同步供应商到金蝶 : " . $supplier['supplier_name'] . PHP_EOL;
(new SyncSupplierService())->syncSupplierToErp($supplier['supplier_id']);
......
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