mirror of
https://github.com/crater-invoice/crater.git
synced 2026-06-04 18:12:43 -04:00
Merge pull request #405 from itsaboutcode/show_field_min_length
Showing length error for Payment, Note and ItemUnit Model Views
This commit is contained in:
Regular → Executable
+8
@@ -68,6 +68,14 @@ export default {
|
|||||||
if (!this.$v.formData.name.required) {
|
if (!this.$v.formData.name.required) {
|
||||||
return this.$tc('validation.required')
|
return this.$tc('validation.required')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!this.$v.formData.name.minLength) {
|
||||||
|
return this.$tc(
|
||||||
|
'validation.name_min_length',
|
||||||
|
this.$v.formData.name.$params.minLength.min,
|
||||||
|
{ count: this.$v.formData.name.$params.minLength.min }
|
||||||
|
)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
validations: {
|
validations: {
|
||||||
|
|||||||
Regular → Executable
+8
@@ -105,6 +105,14 @@ export default {
|
|||||||
if (!this.$v.formData.name.required) {
|
if (!this.$v.formData.name.required) {
|
||||||
return this.$tc('validation.required')
|
return this.$tc('validation.required')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!this.$v.formData.name.minLength) {
|
||||||
|
return this.$tc(
|
||||||
|
'validation.name_min_length',
|
||||||
|
this.$v.formData.name.$params.minLength.min,
|
||||||
|
{ count: this.$v.formData.name.$params.minLength.min }
|
||||||
|
)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
noteError() {
|
noteError() {
|
||||||
if (!this.$v.formData.notes.$error) {
|
if (!this.$v.formData.notes.$error) {
|
||||||
|
|||||||
Regular → Executable
+8
@@ -62,6 +62,14 @@ export default {
|
|||||||
if (!this.$v.formData.name.required) {
|
if (!this.$v.formData.name.required) {
|
||||||
return this.$tc('validation.required')
|
return this.$tc('validation.required')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!this.$v.formData.name.minLength) {
|
||||||
|
return this.$tc(
|
||||||
|
'validation.name_min_length',
|
||||||
|
this.$v.formData.name.$params.minLength.min,
|
||||||
|
{ count: this.$v.formData.name.$params.minLength.min }
|
||||||
|
)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
validations: {
|
validations: {
|
||||||
|
|||||||
Reference in New Issue
Block a user