migrate to gtea from bistbucket
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Accounting\Http\Requests\Deposit;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
class DepositStoreRequest extends FormRequest
|
||||
{
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
'fund_id' => 'required|exists:funds,id',
|
||||
'account_id' => 'nullable|exists:accounts,id',
|
||||
'amount' => 'required|numeric|min:0.01',
|
||||
'transaction_date' => 'required|date',
|
||||
'received_from' => 'nullable|string|max:255',
|
||||
'note' => 'nullable|string',
|
||||
'created_by' => 'nullable|exists:users,id',
|
||||
'status' => 'nullable|in:0,1',
|
||||
];
|
||||
}
|
||||
|
||||
public function authorize(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Accounting\Http\Requests\Deposit;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
class DepositUpdateRequest extends FormRequest
|
||||
{
|
||||
public function rules(): array
|
||||
{
|
||||
$depositId = $this->route('deposit');
|
||||
|
||||
return [
|
||||
'fund_id' => 'required|exists:funds,id',
|
||||
'account_id' => 'nullable|exists:accounts,id',
|
||||
'amount' => 'required|numeric|min:0.01',
|
||||
'transaction_date' => 'required|date',
|
||||
'received_from' => 'nullable|string|max:255',
|
||||
'note' => 'nullable|string',
|
||||
'created_by' => 'nullable|exists:users,id',
|
||||
'status' => 'nullable|in:0,1',
|
||||
];
|
||||
}
|
||||
|
||||
public function authorize(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user