作者 王智

daima

... ... @@ -67,8 +67,17 @@ class Renwu extends Backend
$row->getRelation('user')->visible(['nickname', 'mobile', 'address', 'address_con', 'car_num', 'color', 'car_type', 'vip']);
$row->getRelation('vip')->visible(['title']);
$row['xi_id']=111;
$row['zhao_id']=222;
$OrderInfo = Db::name('renwu')->where('order_sn', $row['order_sn'])->find();
if ($OrderInfo['xi_id'] == null || $OrderInfo['xi_id'] == '' || $OrderInfo['xi_id'] == "") {
$row['xi_id'] = '';
} else {
$row['xi_id'] = Db::name('user')->where('id', $OrderInfo['xi_id'])->value('nickname');
}
if ($OrderInfo['zhao_id'] == null || $OrderInfo['zhao_id'] == '' || $OrderInfo['zhao_id'] == "") {
$row['zhao_id'] = '';
} else {
$row['zhao_id'] = Db::name('user')->where('id', $OrderInfo['zhao_id'])->value('nickname');
}
}
$list = collection($list)->toArray();
$result = array("total" => $total, "rows" => $list);
... ...