first commit

This commit is contained in:
ExtraNetwork
2026-05-12 17:04:54 +03:00
commit e5c4b6aa13
1425 changed files with 284735 additions and 0 deletions

View File

@@ -0,0 +1,52 @@
<?php
namespace App\Core\Validator\PropertyWebContent;
use Illuminate\Contracts\Container\Container;
use Illuminate\Contracts\Translation\Translator;
use Exception;
use App\Core\Validator\BaseValidator;
class PropertyWebContentCreateValidator extends BaseValidator
{
public function __construct
(
Translator $translator,
Container $container
)
{
parent::__construct($translator, $container);
}
public function rules($params = null)
{
return
[
"property_id" => 'required|numeric',
"content_category_id" => 'required|numeric',
"title" => 'required|min:2|max:250',
"language_code" => 'required|min:2|max:10',
"image" => 'nullable',
"content" => 'nullable',
];
}
public function messages()
{
$thisMessages =
[
"checkDomain.accepted" => "This domain added before",
"hasDomain.accepted" => "This property have added other domain before",
"isValidDomain.accepted" => "Not validate domain name.",
];
return array_merge(parent::messages(), $thisMessages);
}
public function validate(array $params, array $rules = [], array $messages = [], array $customAttributes = [])
{
return $this->make($params, $this->rules($params), $this->messages());
}
}