dotnetcore / BootstrapBlazor

A set of enterprise-class UI components based on Bootstrap and Blazor
https://www.blazor.zone
Apache License 2.0
1.86k stars 272 forks source link

DateTimeRange 国际化的问题 #3792

Closed ysjr-2002 closed 3 days ago

ysjr-2002 commented 3 days ago

Is there an existing issue for this?

Describe the bug

基于Bootstrapblazor6.5版本做国际化过程中遇到一个问题, services.AddRequestLocalization<IOptions>((localizerOption, blazorOption) => { var cultures = new[] { "zh-CN" }; localizerOption.AddSupportedCultures(cultures); localizerOption.AddSupportedUICultures(cultures); });

页面使用DateTimeRange控件,<DateTimeRange DateFormat="yyyy-MM-dd" @bind-Value="@context.Range"> 当指定简体中文时工作正常。 但指定英文时 services.AddRequestLocalization<IOptions>((localizerOption, blazorOption) => { var cultures = new[] { "en-US" }; localizerOption.AddSupportedCultures(cultures); localizerOption.AddSupportedUICultures(cultures); }); 出现错误以下错误

1720170428809

请问是什么原因引起的错误?

Expected Behavior

No response

Steps To Reproduce

No response

Exceptions (if any)

No response

.NET Version

5.0

Anything else?

BootstrapBlazor版本是6.5,操作系统Windows 11

bb-auto[bot] commented 3 days ago

@ysjr-2002 Thank you for reporting. We will give triage later.