validation.php 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285
  1. <?php
  2. declare(strict_types=1);
  3. return [
  4. 'accepted' => 'The :attribute field must be accepted.',
  5. 'accepted_if' => 'The :attribute field must be accepted when :other is :value.',
  6. 'active_url' => 'The :attribute field must be a valid URL.',
  7. 'after' => 'The :attribute field must be a date after :date.',
  8. 'after_or_equal' => 'The :attribute field must be a date after or equal to :date.',
  9. 'alpha' => 'The :attribute field must only contain letters.',
  10. 'alpha_dash' => 'The :attribute field must only contain letters, numbers, dashes, and underscores.',
  11. 'alpha_num' => 'The :attribute field must only contain letters and numbers.',
  12. 'any_of' => 'The :attribute field is invalid.',
  13. 'array' => 'The :attribute field must be an array.',
  14. 'ascii' => 'The :attribute field must only contain single-byte alphanumeric characters and symbols.',
  15. 'before' => 'The :attribute field must be a date before :date.',
  16. 'before_or_equal' => 'The :attribute field must be a date before or equal to :date.',
  17. 'between' => [
  18. 'array' => 'The :attribute field must have between :min and :max items.',
  19. 'file' => 'The :attribute field must be between :min and :max kilobytes.',
  20. 'numeric' => 'The :attribute field must be between :min and :max.',
  21. 'string' => 'The :attribute field must be between :min and :max characters.',
  22. ],
  23. 'boolean' => 'The :attribute field must be true or false.',
  24. 'can' => 'The :attribute field contains an unauthorized value.',
  25. 'confirmed' => 'The :attribute field confirmation does not match.',
  26. 'contains' => 'The :attribute field is missing a required value.',
  27. 'current_password' => 'The password is incorrect.',
  28. 'date' => 'The :attribute field must be a valid date.',
  29. 'date_equals' => 'The :attribute field must be a date equal to :date.',
  30. 'date_format' => 'The :attribute field must match the format :format.',
  31. 'decimal' => 'The :attribute field must have :decimal decimal places.',
  32. 'declined' => 'The :attribute field must be declined.',
  33. 'declined_if' => 'The :attribute field must be declined when :other is :value.',
  34. 'different' => 'The :attribute field and :other must be different.',
  35. 'digits' => 'The :attribute field must be :digits digits.',
  36. 'digits_between' => 'The :attribute field must be between :min and :max digits.',
  37. 'dimensions' => 'The :attribute field has invalid image dimensions.',
  38. 'distinct' => 'The :attribute field has a duplicate value.',
  39. 'doesnt_contain' => 'The :attribute field must not contain any of the following: :values.',
  40. 'doesnt_end_with' => 'The :attribute field must not end with one of the following: :values.',
  41. 'doesnt_start_with' => 'The :attribute field must not start with one of the following: :values.',
  42. 'email' => 'The :attribute field must be a valid email address.',
  43. 'ends_with' => 'The :attribute field must end with one of the following: :values.',
  44. 'enum' => 'The selected :attribute is invalid.',
  45. 'exists' => 'The selected :attribute is invalid.',
  46. 'extensions' => 'The :attribute field must have one of the following extensions: :values.',
  47. 'file' => 'The :attribute field must be a file.',
  48. 'filled' => 'The :attribute field must have a value.',
  49. 'gt' => [
  50. 'array' => 'The :attribute field must have more than :value items.',
  51. 'file' => 'The :attribute field must be greater than :value kilobytes.',
  52. 'numeric' => 'The :attribute field must be greater than :value.',
  53. 'string' => 'The :attribute field must be greater than :value characters.',
  54. ],
  55. 'gte' => [
  56. 'array' => 'The :attribute field must have :value items or more.',
  57. 'file' => 'The :attribute field must be greater than or equal to :value kilobytes.',
  58. 'numeric' => 'The :attribute field must be greater than or equal to :value.',
  59. 'string' => 'The :attribute field must be greater than or equal to :value characters.',
  60. ],
  61. 'hex_color' => 'The :attribute field must be a valid hexadecimal color.',
  62. 'image' => 'The :attribute field must be an image.',
  63. 'in' => 'The selected :attribute is invalid.',
  64. 'in_array' => 'The :attribute field must exist in :other.',
  65. 'in_array_keys' => 'The :attribute field must contain at least one of the following keys: :values.',
  66. 'integer' => 'The :attribute field must be an integer.',
  67. 'ip' => 'The :attribute field must be a valid IP address.',
  68. 'ipv4' => 'The :attribute field must be a valid IPv4 address.',
  69. 'ipv6' => 'The :attribute field must be a valid IPv6 address.',
  70. 'json' => 'The :attribute field must be a valid JSON string.',
  71. 'list' => 'The :attribute field must be a list.',
  72. 'lowercase' => 'The :attribute field must be lowercase.',
  73. 'lt' => [
  74. 'array' => 'The :attribute field must have less than :value items.',
  75. 'file' => 'The :attribute field must be less than :value kilobytes.',
  76. 'numeric' => 'The :attribute field must be less than :value.',
  77. 'string' => 'The :attribute field must be less than :value characters.',
  78. ],
  79. 'lte' => [
  80. 'array' => 'The :attribute field must not have more than :value items.',
  81. 'file' => 'The :attribute field must be less than or equal to :value kilobytes.',
  82. 'numeric' => 'The :attribute field must be less than or equal to :value.',
  83. 'string' => 'The :attribute field must be less than or equal to :value characters.',
  84. ],
  85. 'mac_address' => 'The :attribute field must be a valid MAC address.',
  86. 'max' => [
  87. 'array' => 'The :attribute field must not have more than :max items.',
  88. 'file' => 'The :attribute field must not be greater than :max kilobytes.',
  89. 'numeric' => 'The :attribute field must not be greater than :max.',
  90. 'string' => 'The :attribute field must not be greater than :max characters.',
  91. ],
  92. 'max_digits' => 'The :attribute field must not have more than :max digits.',
  93. 'mimes' => 'The :attribute field must be a file of type: :values.',
  94. 'mimetypes' => 'The :attribute field must be a file of type: :values.',
  95. 'min' => [
  96. 'array' => 'The :attribute field must have at least :min items.',
  97. 'file' => 'The :attribute field must be at least :min kilobytes.',
  98. 'numeric' => 'The :attribute field must be at least :min.',
  99. 'string' => 'The :attribute field must be at least :min characters.',
  100. ],
  101. 'min_digits' => 'The :attribute field must have at least :min digits.',
  102. 'missing' => 'The :attribute field must be missing.',
  103. 'missing_if' => 'The :attribute field must be missing when :other is :value.',
  104. 'missing_unless' => 'The :attribute field must be missing unless :other is :value.',
  105. 'missing_with' => 'The :attribute field must be missing when :values is present.',
  106. 'missing_with_all' => 'The :attribute field must be missing when :values are present.',
  107. 'multiple_of' => 'The :attribute field must be a multiple of :value.',
  108. 'not_in' => 'The selected :attribute is invalid.',
  109. 'not_regex' => 'The :attribute field format is invalid.',
  110. 'numeric' => 'The :attribute field must be a number.',
  111. 'password' => [
  112. 'letters' => 'The :attribute field must contain at least one letter.',
  113. 'mixed' => 'The :attribute field must contain at least one uppercase and one lowercase letter.',
  114. 'numbers' => 'The :attribute field must contain at least one number.',
  115. 'symbols' => 'The :attribute field must contain at least one symbol.',
  116. 'uncompromised' => 'The given :attribute has appeared in a data leak. Please choose a different :attribute.',
  117. ],
  118. 'present' => 'The :attribute field must be present.',
  119. 'present_if' => 'The :attribute field must be present when :other is :value.',
  120. 'present_unless' => 'The :attribute field must be present unless :other is :value.',
  121. 'present_with' => 'The :attribute field must be present when :values is present.',
  122. 'present_with_all' => 'The :attribute field must be present when :values are present.',
  123. 'prohibited' => 'The :attribute field is prohibited.',
  124. 'prohibited_if' => 'The :attribute field is prohibited when :other is :value.',
  125. 'prohibited_if_accepted' => 'The :attribute field is prohibited when :other is accepted.',
  126. 'prohibited_if_declined' => 'The :attribute field is prohibited when :other is declined.',
  127. 'prohibited_unless' => 'The :attribute field is prohibited unless :other is in :values.',
  128. 'prohibits' => 'The :attribute field prohibits :other from being present.',
  129. 'regex' => 'The :attribute field format is invalid.',
  130. 'required' => 'The :attribute field is required.',
  131. 'required_array_keys' => 'The :attribute field must contain entries for: :values.',
  132. 'required_if' => 'The :attribute field is required when :other is :value.',
  133. 'required_if_accepted' => 'The :attribute field is required when :other is accepted.',
  134. 'required_if_declined' => 'The :attribute field is required when :other is declined.',
  135. 'required_unless' => 'The :attribute field is required unless :other is in :values.',
  136. 'required_with' => 'The :attribute field is required when :values is present.',
  137. 'required_with_all' => 'The :attribute field is required when :values are present.',
  138. 'required_without' => 'The :attribute field is required when :values is not present.',
  139. 'required_without_all' => 'The :attribute field is required when none of :values are present.',
  140. 'same' => 'The :attribute field must match :other.',
  141. 'size' => [
  142. 'array' => 'The :attribute field must contain :size items.',
  143. 'file' => 'The :attribute field must be :size kilobytes.',
  144. 'numeric' => 'The :attribute field must be :size.',
  145. 'string' => 'The :attribute field must be :size characters.',
  146. ],
  147. 'starts_with' => 'The :attribute field must start with one of the following: :values.',
  148. 'string' => 'The :attribute field must be a string.',
  149. 'timezone' => 'The :attribute field must be a valid timezone.',
  150. 'ulid' => 'The :attribute field must be a valid ULID.',
  151. 'unique' => 'The :attribute has already been taken.',
  152. 'uploaded' => 'The :attribute failed to upload.',
  153. 'uppercase' => 'The :attribute field must be uppercase.',
  154. 'url' => 'The :attribute field must be a valid URL.',
  155. 'uuid' => 'The :attribute field must be a valid UUID.',
  156. 'attributes' => [
  157. 'address' => 'address',
  158. 'affiliate_url' => 'affiliate URL',
  159. 'age' => 'age',
  160. 'amount' => 'amount',
  161. 'announcement' => 'announcement',
  162. 'area' => 'area',
  163. 'audience_prize' => 'audience prize',
  164. 'audience_winner' => 'audience winner',
  165. 'available' => 'available',
  166. 'birthday' => 'birthday',
  167. 'body' => 'body',
  168. 'city' => 'city',
  169. 'company' => 'company',
  170. 'compilation' => 'compilation',
  171. 'concept' => 'concept',
  172. 'conditions' => 'conditions',
  173. 'content' => 'content',
  174. 'contest' => 'contest',
  175. 'country' => 'country',
  176. 'cover' => 'cover',
  177. 'created_at' => 'created at',
  178. 'creator' => 'creator',
  179. 'currency' => 'currency',
  180. 'current_password' => 'current password',
  181. 'customer' => 'customer',
  182. 'date' => 'date',
  183. 'date_of_birth' => 'date of birth',
  184. 'dates' => 'dates',
  185. 'day' => 'day',
  186. 'deleted_at' => 'deleted at',
  187. 'description' => 'description',
  188. 'display_type' => 'display type',
  189. 'district' => 'district',
  190. 'duration' => 'duration',
  191. 'email' => 'email',
  192. 'excerpt' => 'excerpt',
  193. 'filter' => 'filter',
  194. 'finished_at' => 'finished at',
  195. 'first_name' => 'first name',
  196. 'gender' => 'gender',
  197. 'grand_prize' => 'grand prize',
  198. 'group' => 'group',
  199. 'hour' => 'hour',
  200. 'image' => 'image',
  201. 'image_desktop' => 'desktop image',
  202. 'image_main' => 'main image',
  203. 'image_mobile' => 'mobile image',
  204. 'images' => 'images',
  205. 'is_audience_winner' => 'is audience winner',
  206. 'is_hidden' => 'is hidden',
  207. 'is_subscribed' => 'is subscribed',
  208. 'is_visible' => 'is visible',
  209. 'is_winner' => 'is winner',
  210. 'items' => 'items',
  211. 'key' => 'key',
  212. 'last_name' => 'last name',
  213. 'lesson' => 'lesson',
  214. 'line_address_1' => 'line address 1',
  215. 'line_address_2' => 'line address 2',
  216. 'login' => 'login',
  217. 'message' => 'message',
  218. 'middle_name' => 'middle name',
  219. 'minute' => 'minute',
  220. 'mobile' => 'mobile',
  221. 'month' => 'month',
  222. 'name' => 'name',
  223. 'national_code' => 'national code',
  224. 'number' => 'number',
  225. 'password' => 'password',
  226. 'password_confirmation' => 'password confirmation',
  227. 'phone' => 'phone',
  228. 'photo' => 'photo',
  229. 'portfolio' => 'portfolio',
  230. 'postal_code' => 'postal code',
  231. 'preview' => 'preview',
  232. 'price' => 'price',
  233. 'product_id' => 'product ID',
  234. 'product_uid' => 'product UID',
  235. 'product_uuid' => 'product UUID',
  236. 'promo_code' => 'promo code',
  237. 'province' => 'province',
  238. 'quantity' => 'quantity',
  239. 'reason' => 'reason',
  240. 'recaptcha_response_field' => 'recaptcha response field',
  241. 'referee' => 'referee',
  242. 'referees' => 'referees',
  243. 'reject_reason' => 'reject reason',
  244. 'remember' => 'remember',
  245. 'restored_at' => 'restored at',
  246. 'result_text_under_image' => 'result text under image',
  247. 'role' => 'role',
  248. 'rule' => 'rule',
  249. 'rules' => 'rules',
  250. 'second' => 'second',
  251. 'sex' => 'sex',
  252. 'shipment' => 'shipment',
  253. 'short_text' => 'short text',
  254. 'size' => 'size',
  255. 'skills' => 'skills',
  256. 'slug' => 'slug',
  257. 'specialization' => 'specialization',
  258. 'started_at' => 'started at',
  259. 'state' => 'state',
  260. 'status' => 'status',
  261. 'street' => 'street',
  262. 'student' => 'student',
  263. 'subject' => 'subject',
  264. 'tag' => 'tag',
  265. 'tags' => 'tags',
  266. 'teacher' => 'teacher',
  267. 'terms' => 'terms',
  268. 'test_description' => 'test description',
  269. 'test_locale' => 'test locale',
  270. 'test_name' => 'test name',
  271. 'text' => 'text',
  272. 'time' => 'time',
  273. 'title' => 'title',
  274. 'type' => 'type',
  275. 'updated_at' => 'updated at',
  276. 'user' => 'user',
  277. 'username' => 'username',
  278. 'value' => 'value',
  279. 'winner' => 'winner',
  280. 'work' => 'work',
  281. 'year' => 'year',
  282. ],
  283. ];