限制体检类型参数值

wenjuan
yanzai 1 year ago
parent 464530d130
commit 363f332708

@ -107,6 +107,9 @@ class OrderController extends Controller
if (!isset($openid)) return \Yz::echoError1('openid不能为空'); if (!isset($openid)) return \Yz::echoError1('openid不能为空');
if (!isset($person_id)) return \Yz::echoError1('person_id不能为空'); if (!isset($person_id)) return \Yz::echoError1('person_id不能为空');
if (!isset($type)) return \Yz::echoError1('type体检类型不能为空'); if (!isset($type)) return \Yz::echoError1('type体检类型不能为空');
if ($type !== '1' && $type !== '2') {
return \Yz::echoError1('type参数体检类型错误');
}
if (!isset($plan_id)) return \Yz::echoError1('号源id不能为空'); if (!isset($plan_id)) return \Yz::echoError1('号源id不能为空');
if ($type == 2 and !isset($group_id)) return \Yz::echoError1('团检group_id不能为空'); if ($type == 2 and !isset($group_id)) return \Yz::echoError1('团检group_id不能为空');
if ($type == 1 and isset($group_id)) return \Yz::echoError1('体检类型:个检 与group_id冲突'); if ($type == 1 and isset($group_id)) return \Yz::echoError1('体检类型:个检 与group_id冲突');
@ -317,7 +320,7 @@ class OrderController extends Controller
public function Finish_test() //删除!!! public function Finish_test() //删除!!!
{ {
$f=self::Finish('20240916144857398k3fL9K'); $f=self::Finish('20240916154519911MbHwIE');
dd($f); dd($f);
} }

Loading…
Cancel
Save