2016-03-25 01:18:05 -07:00
|
|
|
|
<?php
|
|
|
|
|
|
2022-01-13 21:27:29 -08:00
|
|
|
|
return [
|
2016-03-25 01:18:05 -07:00
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| Validation Language Lines
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
| The following language lines contain the default error messages used by
|
|
|
|
|
| the validator class. Some of these rules have multiple versions such
|
|
|
|
|
| such as the size rules. Feel free to tweak each of these messages.
|
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'accepted' => ':attribute 必須接受',
|
|
|
|
|
'active_url' => '屬性不是有效的URL',
|
|
|
|
|
'after' => ':attribute 必須在 :date 之後',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'after_or_equal' => ':attribute 必須在 :date 之後',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'alpha' => ':attribute 只能包含字母',
|
|
|
|
|
'alpha_dash' => ':attribute 只能包含字母,數字和\'-\'',
|
|
|
|
|
'alpha_num' => ':attribute 只允許字母和數字',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'array' => ':attribute 必須是陣列',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'before' => ':attribute 必須在 :date 之前',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'before_or_equal' => ':attribute 必須在 :date 之前',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'between' => [
|
|
|
|
|
'numeric' => ':attribute 必須在 :min - :max 之間',
|
|
|
|
|
'file' => ':attribute 必須在 :min - :max KB 之間',
|
|
|
|
|
'string' => ':attribute 必須在 :min - :max 字元之間',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'array' => ':attribute 必須在 :min 和 :max 之間',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
],
|
|
|
|
|
'boolean' => ':attribute 必須是 true 或 false',
|
|
|
|
|
'confirmed' => ':attribute 屬性不相符',
|
|
|
|
|
'date' => ':attribute 不是有效日期',
|
|
|
|
|
'date_format' => ':attribute 不符合 :format 的格式',
|
|
|
|
|
'different' => ':attribute 和 :other 不能相同',
|
|
|
|
|
'digits' => ':attribute 必須是 :digits 數字',
|
|
|
|
|
'digits_between' => ':attribute 必須在 :min 和 :max 之间',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'dimensions' => ':attribute 屬性具有不正確圖像尺寸。',
|
|
|
|
|
'distinct' => ':attribute 具有重複值',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'email' => ':attribute 格式不正確',
|
|
|
|
|
'exists' => '選擇的 :attribute 無效',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'file' => ':attribute 必須是檔案',
|
|
|
|
|
'filled' => ':attribute 欄位必須有值。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'image' => ':attribute 必須是圖片格式',
|
2023-08-15 05:21:35 -07:00
|
|
|
|
'import_field_empty' => ':fieldname 的值不能為空。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'in' => '選擇的 :attribute 無效',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'in_array' => ':attribute 屬性欄位不存在 :other。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'integer' => ':attribute 必須是整數',
|
|
|
|
|
'ip' => ':attribute 必須是有效 IP',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'ipv4' => ':attribute 必須是有效的 IPv4 位址',
|
|
|
|
|
'ipv6' => ':attribute 必須是有效的 IPv6 位址',
|
2023-08-15 05:21:35 -07:00
|
|
|
|
'is_unique_department' => ':attribute 必須對此公司位置具有唯一性',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'json' => ':attribute 必須是有效的 JSON 字串',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'max' => [
|
|
|
|
|
'numeric' => ':attribute 不可大於 :max',
|
|
|
|
|
'file' => ':attribute 不可大於 :max KB',
|
|
|
|
|
'string' => ':attribute 不可大於 :max 個字元',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'array' => ':attribute 不可大於 :max 個項目',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
],
|
|
|
|
|
'mimes' => ':attribute 檔案類型必須是 :values',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'mimetypes' => ':attribute 檔案類型必須是 :values',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'min' => [
|
|
|
|
|
'numeric' => ':attribute 最少 :min',
|
|
|
|
|
'file' => ':attribute 最小 :min KB',
|
|
|
|
|
'string' => ':attribute 最少要有 :min 個字元',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'array' => ':attribute 最少要有 :min 個項目',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
],
|
2022-01-13 21:27:29 -08:00
|
|
|
|
'starts_with' => ':attribute 必須以下列之一做為開頭: :values.',
|
2023-08-15 05:21:35 -07:00
|
|
|
|
'ends_with' => ':attribute 必須以以下之一做為結尾: :values。',
|
2023-06-13 09:12:01 -07:00
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'not_in' => '選擇的 :attribute 無效',
|
|
|
|
|
'numeric' => ':attribute 必須是數字',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'present' => ':屬性字段必須存在。',
|
2018-01-20 04:53:04 -08:00
|
|
|
|
'valid_regex' => '這不是一個有效的正則表達式。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'regex' => ':attribute 格式不正確',
|
|
|
|
|
'required' => ':attribute 欄位必填',
|
|
|
|
|
'required_if' => ':attribute 欄位在 :other 是 :value 時是必填的',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'required_unless' => '需要:屬性字段,除非:other is in:values。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'required_with' => '當設定 :value 時,:attribute 欄位必填',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'required_with_all' => '當:值存在時,需要:屬性字段。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'required_without' => '當設定非 :value 時,:attribute 欄位必填',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'required_without_all' => '當不存在:值時,需要:屬性字段。',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'same' => ':attribute 和 :other 必需相符',
|
|
|
|
|
'size' => [
|
|
|
|
|
'numeric' => ':attribute 必須是 :size',
|
|
|
|
|
'file' => ':attribute 必須是 :size KB',
|
|
|
|
|
'string' => ':attribute 必須是 :size 個字元',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'array' => ':attribute 必須包含 :size 個項目',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
],
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'string' => ':attribute 必須是字串',
|
|
|
|
|
'timezone' => ':屬性必須是有效區域。',
|
2023-11-27 06:43:16 -08:00
|
|
|
|
'two_column_unique_undeleted' => 'The :attribute must be unique across :table1 and :table2. ',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'unique' => ':attribute 已被採用',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'uploaded' => ':attribute 上傳失敗',
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'url' => ':attribute 格式不正確',
|
2022-01-13 21:27:29 -08:00
|
|
|
|
'unique_undeleted' => ':attribute 必須是唯一值',
|
2022-10-04 17:48:43 -07:00
|
|
|
|
'non_circular' => ':attribule 屬性不能建立一個循環參考',
|
2024-01-24 07:29:39 -08:00
|
|
|
|
'not_array' => ':attribute cannot be an array.',
|
2022-10-04 17:48:43 -07:00
|
|
|
|
'disallow_same_pwd_as_user_fields' => '密碼不可以和使用者名稱相同',
|
|
|
|
|
'letters' => '密碼至少必須包含 1 個字母。',
|
|
|
|
|
'numbers' => '密碼至少必須包含 1 個數字。',
|
|
|
|
|
'case_diff' => '密碼必須使用大小寫混合',
|
|
|
|
|
'symbols' => '密碼必須包含符號',
|
2022-05-24 15:07:14 -07:00
|
|
|
|
'gte' => [
|
2022-10-04 17:48:43 -07:00
|
|
|
|
'numeric' => '值不能為負'
|
2022-05-24 15:07:14 -07:00
|
|
|
|
],
|
2024-03-27 11:59:28 -07:00
|
|
|
|
'checkboxes' => ':attribute contains invalid options.',
|
|
|
|
|
'radio_buttons' => ':attribute is invalid.',
|
2022-05-24 15:07:14 -07:00
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
|
2016-03-25 01:18:05 -07:00
|
|
|
|
/*
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| Custom Validation Language Lines
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
| Here you may specify custom validation messages for attributes using the
|
|
|
|
|
| convention "attribute.rule" to name the lines. This makes it quick to
|
|
|
|
|
| specify a specific custom language line for a given attribute rule.
|
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'custom' => [
|
2022-01-13 21:27:29 -08:00
|
|
|
|
'alpha_space' => ':attribute 含有無效字元',
|
|
|
|
|
'email_array' => '一個或多個郵件地址不正確',
|
|
|
|
|
'hashed_pass' => '當前密碼不正確!',
|
2017-10-17 18:52:20 -07:00
|
|
|
|
'dumbpwd' => '該密碼太常見。',
|
2022-01-13 21:27:29 -08:00
|
|
|
|
'statuslabel_type' => '您必須選擇一個有效的狀態標籤',
|
2023-02-21 03:54:55 -08:00
|
|
|
|
|
|
|
|
|
// date_format validation with slightly less stupid messages. It duplicates a lot, but it gets the job done :(
|
|
|
|
|
// We use this because the default error message for date_format is reflects php Y-m-d, which non-PHP
|
|
|
|
|
// people won't know how to format.
|
2023-08-15 05:21:35 -07:00
|
|
|
|
'purchase_date.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
|
|
|
|
'last_audit_date.date_format' => ':attribute 必須是 YYYY-MM-DD hh:mm:ss 格式的有效日期',
|
|
|
|
|
'expiration_date.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
|
|
|
|
'termination_date.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
|
|
|
|
'expected_checkin.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
|
|
|
|
'start_date.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
|
|
|
|
'end_date.date_format' => ':attribute 必須是 YYYY-MM-DD 格式的有效日期',
|
2023-02-21 03:54:55 -08:00
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
],
|
2016-03-25 01:18:05 -07:00
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| Custom Validation Attributes
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
| The following language lines are used to swap attribute place-holders
|
|
|
|
|
| with something more reader friendly such as E-Mail Address instead
|
|
|
|
|
| of "email". This simply helps us make messages a little cleaner.
|
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
2017-09-06 18:05:32 -07:00
|
|
|
|
'attributes' => [],
|
2016-03-25 01:18:05 -07:00
|
|
|
|
|
2024-03-27 11:59:28 -07:00
|
|
|
|
/*
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| Generic Validation Messages
|
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
*/
|
|
|
|
|
'invalid_value_in_field' => 'Invalid value included in this field',
|
2022-01-13 21:27:29 -08:00
|
|
|
|
];
|