restore composer.json, add mysqli extension

This commit is contained in:
2026-04-15 17:02:52 +05:00
commit 77cf56a348
4317 changed files with 1397107 additions and 0 deletions

View File

@@ -0,0 +1,53 @@
<?php
namespace App\Http\Requests\Dashboard\UsefulInfoItemRequest;
use Illuminate\Foundation\Http\FormRequest;
class Store extends FormRequest
{
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
return [
'name_uz' => 'required|string',
'name_ru' => 'required|string',
'description_uz' => 'nullable|string',
'description_ru' => 'nullable|string',
'video_url' => 'nullable|string',
'link_url' => 'nullable|string',
'file' => 'nullable|file|mimes:pdf,doc,docx,xls,xlsx,ppt,pptx',
];
}
/**
* @return array
*/
public function getName(): array|null
{
if ($this->has('name_uz') && $this->has('name_ru')) {
return [
'uz' => $this->get('name_uz'),
'ru' => $this->get('name_ru')
];
}
return null;
}
public function getDescription(): array|null
{
if ($this->get('description_uz') !== null && $this->get('description_ru') !== null) {
return [
'uz' => $this->get('description_uz'),
'ru' => $this->get('description_ru')
];
}
return null;
}
}