diff --git a/app/data/service/OrderService.php b/app/data/service/OrderService.php index cc1b853bb..158bf75de 100644 --- a/app/data/service/OrderService.php +++ b/app/data/service/OrderService.php @@ -118,13 +118,13 @@ class OrderService extends Service /** * 绑定订单详情数据 * @param array $data - * @param boolean $fromer + * @param boolean $from * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException */ - public function buildData(array &$data = [], $fromer = true): array + public function buildData(array &$data = [], $from = true): array { // 关联发货信息 $nobs = array_unique(array_column($data, 'order_no')); @@ -136,7 +136,7 @@ class OrderService extends Service // 关联用户数据 $fields = 'phone,username,nickname,headimg,status,vip_code,vip_name'; UserAdminService::instance()->buildByUid($data, 'uid', 'user', $fields); - if ($fromer) UserAdminService::instance()->buildByUid($data, 'puid1', 'fromer', $fields); + if ($from) UserAdminService::instance()->buildByUid($data, 'puid1', 'from', $fields); foreach ($data as &$vo) { [$vo['sales'], $vo['truck'], $vo['items']] = [0, $trucks[$vo['order_no']] ?? [], []]; foreach ($items as $item) if ($vo['order_no'] === $item['order_no']) { diff --git a/app/data/view/shop_order_service/index.html b/app/data/view/shop_order_service/index.html index 657809a35..2cfb82846 100644 --- a/app/data/view/shop_order_service/index.html +++ b/app/data/view/shop_order_service/index.html @@ -34,10 +34,10 @@
- img + img
- 推荐用户:{$vo.fromer.nickname|default='--'}
- 推荐手机:{$vo.fromer.phone|default='--'}{notempty name='vo.fromer.vip_level'} [ VIP{$vo.fromer.vip_level} ] {$vo.fromer.vip_title}{/notempty}
+ 推荐用户:{$vo.from.nickname|default='--'}
+ 推荐手机:{$vo.from.phone|default='--'}{notempty name='vo.from.vip_level'} [ VIP{$vo.from.vip_level} ] {$vo.from.vip_title}{/notempty}