Input Validation
Enforce consistent formatting for Reference IDs and other fields with built-in and custom validation patterns.
Why Validation Matters
Without validation, reference numbers drift into inconsistent formats over time: WO2026001, WO-2026-1, wo-2026-001. This makes searching, sorting, and reporting unreliable.
GlyphFex validation ensures every Reference ID matches your shop's format before it can be saved. Users get real-time feedback as they type, preventing bad data before it enters the system.
Built-In Patterns
GlyphFex includes several pre-built validation patterns that cover common manufacturing numbering schemes. Open the validation editor from Settings Hub > Validation.
| Pattern Name | Format | Example | Regex |
|---|---|---|---|
| Quote | Q-XXXXX |
Q-00142 | Q-\d{5} |
| Order | O-XXXXX |
O-08734 | O-\d{5} |
| Purchase Order | PO-XXXXXX |
PO-204519 | PO-\d{6} |
| Serial Number | SN-XXXXXXX |
SN-0012847 | SN-\d{7} |
Select any built-in pattern and click Apply to activate it. You can have multiple active patterns — an entry is valid if it matches any active pattern.
Custom Regex Patterns
If the built-in patterns do not match your numbering scheme, create a custom pattern using regular expressions (regex).
Creating a custom pattern
- Open Settings Hub > Validation
- Click "Add Custom Pattern"
- Enter a name — A descriptive label for the pattern (e.g., "Work Order - Year Prefix")
- Enter the regex — The regular expression that valid IDs must match
- Test it — Type sample IDs in the test field to verify the pattern works
- Save
Common custom patterns
| Use Case | Regex | Example Match |
|---|---|---|
| Work Order with year | WO-\d{4}-\d{3} |
WO-2026-001 |
| Job number (4-6 digits) | J\d{4,6} |
J12345 |
| Alpha prefix + digits | [A-Z]{2,3}-\d{4,} |
FAB-0042 |
| Free-form (min length) | .{3,} |
Any 3+ characters |
Template-Specific Validation
Each entry template can be associated with a specific validation pattern. This is useful when different job types have different numbering formats:
- Quote template uses
Q-\d{4}-\d{3} - Work order template uses
WO-\d{4}-\d{4} - NCR template uses
NCR-\d{4}-\d{2}-\d{2}
When a user selects a template on the Entry page, the validation switches to that template's pattern. The validation editor shows which templates use each pattern.
Compatibility check
The template editor displays a compatibility indicator showing whether the template's auto-numbering format matches its associated validation pattern. If they conflict (e.g., the format generates Q-2026-001 but the pattern expects Q-00001), a warning appears so you can fix the mismatch.
How Validation Works in Practice
When a user types a Reference ID on the Entry page, GlyphFex validates the input in real time:
- Green border + checkmark icon — The ID matches an active validation pattern
- Red border — The ID does not match any active pattern
- No border change — No validation patterns are active (any format is accepted)
If the user attempts to save an entry with an invalid Reference ID, the save is blocked and the field is highlighted with an error message showing the expected format.
How Validation Prevents Bad Data
Validation works together with other GlyphFex features to maintain data quality:
- Duplicate detection — GlyphFex checks for duplicate Reference IDs on save, regardless of validation patterns
- Required fields — Custom fields marked as "required" must have a value before saving
- Required categories — Categories made required via conditional rules must have a tag selected
- Auto-numbering — Templates with auto-numbering bypass manual entry entirely, eliminating format errors