Skip to content

Commit a6bae32

Browse files
committed
update manager first and last name label
* use word map to properly display Firstname as First Name, Lastname as Last Name
1 parent 3a79578 commit a6bae32

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

app/javascript/template_builder/field_settings.vue

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -595,10 +595,14 @@ export default {
595595
},
596596
methods: {
597597
formatPrefillFieldName (fieldName) {
598-
// Convert snake_case to Title Case for display
598+
const wordMap = {
599+
firstname: 'First Name',
600+
lastname: 'Last Name'
601+
}
602+
599603
return fieldName
600604
.split('_')
601-
.map(word => word.charAt(0).toUpperCase() + word.slice(1))
605+
.map(word => wordMap[word.toLowerCase()] || (word.charAt(0).toUpperCase() + word.slice(1)))
602606
.join(' ')
603607
},
604608
onChangeValidation (event) {

0 commit comments

Comments
 (0)