master
zhanglingsheng 5 years ago
parent 8d6c547468
commit 0a9efe02ca

@ -124,7 +124,7 @@ unset($_REQUEST['parent_id']);
$re_data = json_decode($re_data,true)['data']; $re_data = json_decode($re_data,true)['data'];
foreach($list_data as $k => $v) foreach($list_data as $k => $v)
{ {
if(in_array($v['account'], $re_data)) if(array_key_exists($v['account'], $re_data))
{ {
$list_data[$k]['oa_associated'] = $re_data[$v['account']]; $list_data[$k]['oa_associated'] = $re_data[$v['account']];
M('promote','tab_')->where(['id' => $v['id']])->setField(['oa_associated' => $re_data[$v['account']]]); M('promote','tab_')->where(['id' => $v['id']])->setField(['oa_associated' => $re_data[$v['account']]]);

Loading…
Cancel
Save