优化退款时是否能选择退款类型,用户编辑优化

This commit is contained in:
evoxwht 2023-03-23 14:45:02 +08:00
parent f5c25c78bf
commit 3f26b3dae7
3 changed files with 12 additions and 1 deletions

View File

@ -387,7 +387,7 @@ class User extends AuthController
if ($data['phone']) {
if (!preg_match("/^1[3456789]\d{9}$/", $data['phone'])) return app('json')->fail(400252);
}
if ($this->services->count(['phone' => $data['phone'], 'is_del' => 0])) {
if ($this->services->count(['phone' => $data['phone'], 'is_del' => 0, 'not_uid' => $id])) {
return app('json')->fail(400314);
}
if ($data['card_id']) {

View File

@ -440,4 +440,14 @@ class User extends BaseModel
{
if ($value !== '') $query->where('is_del', $value);
}
/**
* 不等于uid搜索器
* @param $query
* @param $value
*/
public function searchNotUidAttr($query, $value)
{
if ($value !== '') $query->where('uid', '<>', $value);
}
}

View File

@ -2351,6 +2351,7 @@ HTML;
}
}
$data['_status'] = $orderInfo['_status'] ?? [];
$data['_status']['is_back'] = $orderInfo['delivery_type'] == 'fictitious' || $orderInfo['virtual_type'] > 0;
$data['cartInfo'] = $data['cartInfo'] ?? $cartInfo;
return $data;
}