Browse Source

修复更改图片使用函数array_diff报错

wechat_public_accounts
linyaostalker 5 years ago
parent
commit
265e6ec21d
  1. 2
      vendor/antgoods/goods/src/controllers/GoodsController.php

2
vendor/antgoods/goods/src/controllers/GoodsController.php

@ -115,7 +115,7 @@ class GoodsController extends Controller
$file_id_str = $model->imageId; $file_id_str = $model->imageId;
$model->save(); $model->save();
$goods_manager = new GoodsManager(); $goods_manager = new GoodsManager();
$save_file_res = $goods_manager->saveFile(explode(',', $file_id_str), $model, $old_id_arr);
$save_file_res = $goods_manager->saveFile(explode(',', $file_id_str), $model, explode(',', $old_id_arr));
if($save_file_res['status']){ if($save_file_res['status']){
$model->image = $save_file_res['first_file_id']; $model->image = $save_file_res['first_file_id'];
$model->save(); $model->save();

Loading…
Cancel
Save