FareedR
3 months ago
1245
20
Laravel

Validation passed on required_if

Posted 3 months ago by FareedR

My use case is : if user click selection on value " 1:5 " ( accept as a string ), then user required to fill a few input . so my validation as below. how ever, validation still passed eventho i didn't fill the input

type' => 'required',
'time_frame_type'   => 'required_if:type,1:5',
'description_type'  => 'required_if:type,1:5',

Please sign in or create an account to participate in this conversation.