I’ve implemented a comprehensive solution for this across multiple TrackWise installations. You need to address all three focus areas systematically:
Locale-Specific Date Parsing:
Replace your hardcoded validation with locale-aware parsing. Create a custom validation function that retrieves the user’s locale from their TrackWise profile (stored in session context) and applies the appropriate date format pattern:
function validateLocalizedDate(dateValue, userLocale) {
const formats = {'en_US':'MM/DD/YYYY','de_DE':'DD.MM.YYYY','fr_FR':'DD/MM/YYYY','es_ES':'DD/MM/YYYY'};
return moment(dateValue, formats[userLocale], true).isValid();
}
You’ll need to pass the user locale from server-side context to client JavaScript during form initialization.
UI Label Length and Layout:
For the truncation issue, implement responsive label containers in your form CSS. Add these style overrides in your custom CSS file:
.incident-form .field-label {
min-width: 200px;
max-width: 300px;
word-wrap: break-word;
}
Additionally, review your translation pack entries - sometimes translators create unnecessarily verbose labels. Work with your translation team to create concise German labels that convey the same meaning in fewer characters where possible.
Translation Pack Deployment:
Verify your deployment process is complete:
- Admin Console > Translation Management > verify all packs show ‘Active’ status
- User profiles must have explicit locale assignment (Admin > Users > Locale field)
- Clear browser cache and session storage after translation pack updates
- Restart TrackWise application services to ensure translation cache refresh
- Test with actual user accounts, not admin accounts (admins sometimes bypass locale settings)
For date fields specifically, also update your form’s field-level validation rules in Form Designer > Field Properties > Validation tab. Set the validation type to ‘Date (Locale-Aware)’ instead of ‘Date’ if that option is available in your version. If not available, you’ll need to implement custom validation via JavaScript as shown above.
One critical gotcha: TrackWise caches form validation rules aggressively. After making changes, you may need to increment the form version number (Form Properties > Version) to force clients to reload the updated validation logic. Otherwise users will continue getting the cached English validation even after your fixes are deployed.
For the German label length issue specifically, consider using tooltip help text for detailed explanations rather than putting everything in the label. This keeps labels concise while still providing necessary context in all languages.