Commit 8a4dcdad by mushishixian

导出

parent 2d25db7d
...@@ -14,7 +14,6 @@ use App\Model\LogModel; ...@@ -14,7 +14,6 @@ use App\Model\LogModel;
use App\Model\RedisModel; use App\Model\RedisModel;
use App\Model\SupplierContactModel; use App\Model\SupplierContactModel;
use App\Model\SupplierExtendModel; use App\Model\SupplierExtendModel;
use function Sodium\add;
class SupplierTransformer class SupplierTransformer
{ {
...@@ -30,6 +29,7 @@ class SupplierTransformer ...@@ -30,6 +29,7 @@ class SupplierTransformer
$supplier['viewed'] = array_get($viewData, $supplier['supplier_id'], false); $supplier['viewed'] = array_get($viewData, $supplier['supplier_id'], false);
$supplier = $this->getStockupType($supplier); $supplier = $this->getStockupType($supplier);
$supplier['supplier_group'] = array_get(config('fixed.SupplierGroup'), $supplier['supplier_group'], '未设置'); $supplier['supplier_group'] = array_get(config('fixed.SupplierGroup'), $supplier['supplier_group'], '未设置');
$supplier['region_name'] = array_get(config('fixed.Region'), $supplier['region']);
$supplier['create_time'] = $supplier['create_time']?date('Y-m-d H:i:s', $supplier['create_time']):''; $supplier['create_time'] = $supplier['create_time']?date('Y-m-d H:i:s', $supplier['create_time']):'';
$supplier['audit_time'] = $supplier['audit_time'] ? date('Y-m-d H:i:s', $supplier['audit_time']) : ''; $supplier['audit_time'] = $supplier['audit_time'] ? date('Y-m-d H:i:s', $supplier['audit_time']) : '';
$supplier['update_time'] = $supplier['update_time'] ? date('Y-m-d H:i:s', $supplier['update_time']) : ''; $supplier['update_time'] = $supplier['update_time'] ? date('Y-m-d H:i:s', $supplier['update_time']) : '';
......
...@@ -45,6 +45,7 @@ Route::group(['middleware' => ['web'], 'namespace' => 'Api'], function () { ...@@ -45,6 +45,7 @@ Route::group(['middleware' => ['web'], 'namespace' => 'Api'], function () {
Route::match(['get', 'post'], '/test', function () { Route::match(['get', 'post'], '/test', function () {
$service = new \App\Http\Services\DataService(); $service = new \App\Http\Services\DataService();
$service->exportSuppliers(); $service->exportSuppliers();
// $service->exportSupplierContact();
// $service->export(); // $service->export();
// $service->repairData(10); // $service->repairData(10);
// $service->completeContact(10); // $service->completeContact(10);
......
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