Change component validator to the correct asset id we're passing in the API call
This commit is contained in:
parent
af86c6138d
commit
0a841ddbb8
1 changed files with 1 additions and 1 deletions
|
@ -235,7 +235,7 @@ class ComponentsController extends Controller
|
||||||
$this->authorize('checkout', $component);
|
$this->authorize('checkout', $component);
|
||||||
|
|
||||||
$validator = Validator::make($request->all(), [
|
$validator = Validator::make($request->all(), [
|
||||||
'asset_id' => 'required|exists:assets,id',
|
'assigned_to' => 'required|exists:assets,id',
|
||||||
'assigned_qty' => "required|numeric|min:1|digits_between:1,".$component->numRemaining(),
|
'assigned_qty' => "required|numeric|min:1|digits_between:1,".$component->numRemaining(),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue