validation.php 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. <?php
  2. return [
  3. /*
  4. |--------------------------------------------------------------------------
  5. | Validation Language Lines
  6. |--------------------------------------------------------------------------
  7. |
  8. | following language lines contain the default error messages used by
  9. | the validator class. Some of these rules have multiple versions such
  10. | as the size rules. Feel free to tweak each of these messages here.
  11. |
  12. */
  13. 'accepted' => ':attribute 必须同意',
  14. 'active_url' => ':attribute 不是有效URL',
  15. 'after' => ':attribute 必须是在 :date 之后',
  16. 'after_or_equal' => ':attribute 必须是等于或在 :date 之后',
  17. 'alpha' => ':attribute may only contain letters.',
  18. 'alpha_dash' => ':attribute may only contain letters, numbers, dashes and underscores.',
  19. 'alpha_num' => ':attribute may only contain letters and numbers.',
  20. 'array' => ':attribute must be an array.',
  21. 'before' => ':attribute must be a date before :date.',
  22. 'before_or_equal' => ':attribute must be a date before or equal to :date.',
  23. 'between' => [
  24. 'numeric' => ':attribute 必须介于 :min 与 :max 之间.',
  25. 'file' => ':attribute must be between :min and :max kilobytes.',
  26. 'string' => ':attribute must be between :min and :max characters.',
  27. 'array' => ':attribute must have between :min and :max items.',
  28. ],
  29. 'boolean' => ':attribute 请选是或否,必须是布尔值',
  30. 'confirmed' => ':attribute confirmation does not match.',
  31. 'date' => ':attribute 不是有效日期',
  32. 'date_equals' => ':attribute must be a date equal to :date.',
  33. 'date_format' => ':attribute does not match the format :format.',
  34. 'different' => ':attribute and :other must be different.',
  35. 'digits' => ':attribute 必须是 :digits 位数.',
  36. 'digits_between' => ':attribute 必须介于 :min 与 :max 位之间.',
  37. 'dimensions' => ':attribute has invalid image dimensions.',
  38. 'distinct' => ':attribute field has a duplicate value.',
  39. 'email' => ':attribute must be a valid email address.',
  40. 'ends_with' => ':attribute must end with one of the following: :values',
  41. 'exists' => ':attribute 选择的相关值不存在',
  42. 'file' => ':attribute must be a file.',
  43. 'filled' => ':attribute field must have a value.',
  44. 'gt' => [
  45. 'numeric' => ':attribute must be greater than :value.',
  46. 'file' => ':attribute must be greater than :value kilobytes.',
  47. 'string' => ':attribute must be greater than :value characters.',
  48. 'array' => ':attribute must have more than :value items.',
  49. ],
  50. 'gte' => [
  51. 'numeric' => ':attribute must be greater than or equal :value.',
  52. 'file' => ':attribute must be greater than or equal :value kilobytes.',
  53. 'string' => ':attribute must be greater than or equal :value characters.',
  54. 'array' => ':attribute must have :value items or more.',
  55. ],
  56. 'image' => ':attribute must be an image.',
  57. 'in' => 'selected :attribute is invalid.',
  58. 'in_array' => ':attribute field does not exist in :other.',
  59. 'integer' => ':attribute must be an integer.',
  60. 'ip' => ':attribute must be a valid IP address.',
  61. 'ipv4' => ':attribute must be a valid IPv4 address.',
  62. 'ipv6' => ':attribute must be a valid IPv6 address.',
  63. 'jsonData' => ':attribute must be a valid JSON string.',
  64. 'lt' => [
  65. 'numeric' => ':attribute must be less than :value.',
  66. 'file' => ':attribute must be less than :value kilobytes.',
  67. 'string' => ':attribute must be less than :value characters.',
  68. 'array' => ':attribute must have less than :value items.',
  69. ],
  70. 'lte' => [
  71. 'numeric' => ':attribute must be less than or equal :value.',
  72. 'file' => ':attribute must be less than or equal :value kilobytes.',
  73. 'string' => ':attribute must be less than or equal :value characters.',
  74. 'array' => ':attribute must not have more than :value items.',
  75. ],
  76. 'max' => [
  77. 'numeric' => ':attribute may not be greater than :max.',
  78. 'file' => ':attribute may not be greater than :max kilobytes.',
  79. 'string' => ':attribute 不能大于 :max 个字符',
  80. 'array' => ':attribute may not have more than :max items.',
  81. ],
  82. 'mimes' => ':attribute must be a file of type: :values.',
  83. 'mimetypes' => ':attribute must be a file of type: :values.',
  84. 'min' => [
  85. 'numeric' => ':attribute must be at least :min.',
  86. 'file' => ':attribute must be at least :min kilobytes.',
  87. 'string' => ':attribute must be at least :min characters.',
  88. 'array' => ':attribute must have at least :min items.',
  89. ],
  90. 'not_in' => 'selected :attribute is invalid.',
  91. 'not_regex' => ':attribute format is invalid.',
  92. 'numeric' => ':attribute 必须是数字',
  93. 'present' => ':attribute field must be present.',
  94. 'regex' => ':attribute format is invalid.',
  95. 'required' => ':attribute 字段不能为空',
  96. 'required_if' => ':attribute field is required when :other is :value.',
  97. 'required_unless' => ':attribute field is required unless :other is in :values.',
  98. 'required_with' => ':attribute field is required when :values is present.',
  99. 'required_with_all' => ':attribute field is required when :values are present.',
  100. 'required_without' => ':values 与 :attribute 至少填写一项',
  101. 'required_without_all' => ':attribute field is required when none of :values are present.',
  102. 'same' => ':attribute 与 :other 必须一致',
  103. 'size' => [
  104. 'numeric' => ':attribute must be :size.',
  105. 'file' => ':attribute must be :size kilobytes.',
  106. 'string' => ':attribute must be :size characters.',
  107. 'array' => ':attribute must contain :size items.',
  108. ],
  109. 'starts_with' => ':attribute must start with one of the following: :values',
  110. 'string' => ':attribute 必须是字符串',
  111. 'timezone' => ':attribute must be a valid zone.',
  112. 'unique' => ':attribute 已经存在,不能重复!',
  113. 'uploaded' => ':attribute failed to upload.',
  114. 'url' => ':attribute format is invalid.',
  115. 'uuid' => ':attribute must be a valid UUID.',
  116. 'identity_cards' => ':attribute 身份证号错误',
  117. /*
  118. |--------------------------------------------------------------------------
  119. | Custom Validation Language Lines
  120. |--------------------------------------------------------------------------
  121. |
  122. | Here you may specify custom validation messages for attributes using the
  123. | convention "attribute.rule" to name the lines. This makes it quick to
  124. | specify a specific custom language line for a given attribute rule.
  125. |
  126. */
  127. 'custom' => [
  128. 'attribute-name' => [
  129. 'rule-name' => 'custom-message',
  130. ],
  131. ],
  132. /*
  133. |--------------------------------------------------------------------------
  134. | Custom Validation Attributes
  135. |--------------------------------------------------------------------------
  136. |
  137. | following language lines are used to swap our attribute placeholder
  138. | with something more reader friendly such as "E-Mail Address" instead
  139. | of "email". This simply helps us make our message more expressive.
  140. |
  141. */
  142. 'attributes' => [],
  143. ];