mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-12-11 09:07:18 +01:00
Fix: Allow lowercase letters in monetary currency code field (#6359)
This commit is contained in:
parent
95c24a50f7
commit
10e10f9ff4
1 changed files with 3 additions and 2 deletions
|
|
@ -35,7 +35,8 @@ export class MonetaryComponent extends AbstractInputComponent<string> {
|
|||
|
||||
get currencyCode(): string {
|
||||
const focused = document.activeElement === this.currencyField?.nativeElement
|
||||
if (focused && this.value) return this.value.match(/^([A-Z]{0,3})/)?.[0]
|
||||
if (focused && this.value)
|
||||
return this.value.toUpperCase().match(/^([A-Z]{0,3})/)?.[0]
|
||||
return (
|
||||
this.value
|
||||
?.toString()
|
||||
|
|
@ -45,7 +46,7 @@ export class MonetaryComponent extends AbstractInputComponent<string> {
|
|||
}
|
||||
|
||||
set currencyCode(value: string) {
|
||||
this.value = value + this.monetaryValue?.toString()
|
||||
this.value = value.toUpperCase() + this.monetaryValue?.toString()
|
||||
}
|
||||
|
||||
get monetaryValue(): string {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue