Today in DateTimePicker is hidden in Scheduler CustomEditor
Today in DateTimePicker becomes hidden in Scheduler custom editor as below Cannot investigate CSS conflict as the source code is hidden when clicked.
But it isn't in a regular Dialog.
<SfDataForm ID="scheduleForm" Model="@Content" ColumnCount="9" ColumnSpacing="3px" OnUpdate="OnUpdate" OnSubmit="OnSubmitAsync" ValidationDisplayMode="FormValidationDisplay.Inline">
<FormValidator>
<FluentValidationValidator @ref="_fluentValidator" DisableAssemblyScanning="false" />
</FormValidator>
<FormItems>
<FormItem Field="Subject" ColumnSpan="5">
<Template>
<SfTextBox Placeholder="Subject" FloatLabelType="FloatLabelType.Always" @bind-Value="@Content.Subject" Readonly="@ReadOnly" />
</Template>
</FormItem>
<FormItem Field="ReservedBy" ColumnSpan="4">
<Template>
<SfTextBox Placeholder="Reserved By" FloatLabelType="FloatLabelType.Always" @bind-Value="@Content.ReservedBy" Readonly="true" />
</Template>
</FormItem>
<FormItem Field="EqupmentIds" ColumnSpan="6">
<Template>
@if (ReadOnly)
{
<SfTextBox Placeholder="Equpment" FloatLabelType="FloatLabelType.Always" Value="@(string.Join(',', Content.Equpment?.Select(e => e.AssetId)))" Readonly="true" />
}
else
{
<SfMultiSelect @bind-Value="@_equpmentIds" TItem="Equpment" TValue="string[]" Placeholder="Equpment" DataSource="@Equpment" Mode="VisualMode.Default" AllowFiltering="true" FilterType="FilterType.Contains" FloatLabelType="FloatLabelType.Always" >
<MultiSelectTemplates TItem="Equpment">
<ItemTemplate>
@{
var equpment = context as Equpment;
<span class="e-badge bg-warning text-white ps-0">@(equpment.AssetId)</span> <span class='destination'>@($"{equpment.Manufacturer} {equpment.ModelNumber}")</span>
<span class="e-badge ms-2">@(equpment.Location)</span>
}
</ItemTemplate>
</MultiSelectTemplates>
<MultiSelectFieldSettings Text="AssetId" Value="Id"></MultiSelectFieldSettings>
<MultiSelectEvents TItem="Equpment" TValue="string[]" OnValueSelect="@OnEqupmentSelected" OnValueRemove="@OnEqupmentDeselected" Cleared="OnEqupmentCleared" />
</SfMultiSelect>
}
</Template>
</FormItem>
<FormItem Field="Location" ColumnSpan="3">
<Template>
<SfTextBox Placeholder="Location" FloatLabelType="FloatLabelType.Always" Value="@Content.Location" Readonly="true" />
</Template>
</FormItem>
<FormItem Field="BenchIds" ColumnSpan="4">
<Template>
@if (ReadOnly)
{
<SfTextBox Placeholder="Benches" FloatLabelType="FloatLabelType.Always" Value="@(string.Join(',', Content.Benches?.Select(b => b.Barcode)))" Readonly="true" />
}
else
{
<SfMultiSelect @bind-Value="@_benchIds" TItem="Bench" TValue="string[]" Placeholder="Benches" DataSource="@_availableBenches" Mode="VisualMode.Default" AllowFiltering="true" FilterType="FilterType.Contains" FloatLabelType="FloatLabelType.Always">
<MultiSelectTemplates TItem="Bench">
<ItemTemplate>
@{
var bench = context as Bench;
<span class="e-badge bg-info text-white ps-0">@(bench.Barcode)</span> <span class='destination'>@(bench.Name)</span>
}
</ItemTemplate>
</MultiSelectTemplates>
<MultiSelectFieldSettings Text="Barcode" Value="Id"></MultiSelectFieldSettings>
</SfMultiSelect>
}
</Template>
</FormItem>
<FormItem Field="BioSafetyCabinets" ColumnSpan="5">
<Template>
@if (ReadOnly)
{
<SfTextBox Placeholder="Biosafety Cabinets" FloatLabelType="FloatLabelType.Always" Value="@(string.Join(',', Content.BioSafetyCabinets?.Select(c => c.AssetId)))" Readonly="true" />
}
else
{
<SfMultiSelect @bind-Value="@_bioSafetyCabinetIds" TItem="Equpment" TValue="string[]" Placeholder="Biosafety Cabinets" DataSource="@_availableBioSafetyCabinets" Mode="VisualMode.Default" AllowFiltering="true" FilterType="FilterType.Contains" FloatLabelType="FloatLabelType.Always">
<MultiSelectTemplates TItem="Equpment">
<ItemTemplate>
@{
var equpment = context as Equpment;
<span class="e-badge bg-danger text-white ps-0">@(equipment.AssetId)</span> <span class='destination'>@($"{equpment.Manufacturer} {equpment.ModelNumber}")</span>
<span class="e-badge ms-2">@(equpment.Location)</span>
}
</ItemTemplate>
</MultiSelectTemplates>
<MultiSelectFieldSettings Text="AssetId" Value="Id"></MultiSelectFieldSettings>
</SfMultiSelect>
}
</Template>
</FormItem>
<FormItem Field="IsAllDay" ColumnSpan="1">
<Template>
<div style="margin-top:0px; text-align: center">
<span class="e-float-text e-label-top" style="font-weight: 500; font-size: 9pt; color: #777;">All day</span>
<SfCheckBox @bind-Checked="@Content.IsAllDay" CssClass="mt-2" Disabled="true"></SfCheckBox>
</div>
</Template>
</FormItem>
<FormItem Field="StartTime" ColumnSpan="4">
<Template>
@if (Content.IsAllDay.HasValue && Content.IsAllDay.Value)
{
<SfDatePicker Placeholder="Start" FloatLabelType="FloatLabelType.Always" TValue="DateTime" @bind-Value="@Content.StartTime" Readonly="@ReadOnly" />
}
else
{
<SfDateTimePicker Placeholder="Start" FloatLabelType="FloatLabelType.Always" TValue="DateTime" @bind-Value="@Content.StartTime" Readonly="@ReadOnly" />
}
</Template>
</FormItem>
<FormItem Field="EndTime" ColumnSpan="4">
<Template>
@if (Content.IsAllDay.HasValue && Content.IsAllDay.Value)
{
<SfDatePicker Placeholder="End" FloatLabelType="FloatLabelType.Always" TValue="DateTime" @bind-Value="@Content.EndTime" Readonly="@ReadOnly" />
}
else
{
<SfDateTimePicker Placeholder="End" FloatLabelType="FloatLabelType.Always" TValue="DateTime" @bind-Value="@Content.EndTime" Readonly="@ReadOnly" />
}
</Template>
</FormItem>
<AuthorizeView Context="_" Policy="Operators">
<Authorized>
@if (!ReadOnly || !string.IsNullOrEmpty(Content.RecurrenceRule))
{
<FormItem Field="RecurrenceRule" ColumnSpan="9">
<Template>
<SfRecurrenceEditor @bind-Value="@Content.RecurrenceRule" />
</Template>
</FormItem>
}
</Authorized>
</AuthorizeView>
<FormItem Field="Description" ColumnSpan="9">
<Template>
<SfTextBox Multiline="true" Placeholder="Description" FloatLabelType="FloatLabelType.Always" @bind-Value="@Content.Description" Readonly="@ReadOnly" />
</Template>
</FormItem>
</FormItems>
<FormButtons />
</SfDataForm>
SIGN IN To post a reply.
2 Replies
YC
Yongkee Cho
March 6, 2025 05:18 PM UTC
No worries. I found why. I changed the CSS
.e-today {
display: none !important;
}with
.e-toolbar .e-toolbar-item .e-today {
display: none !important;
}and it's gone.
SS
Shereen Shajahan
Syncfusion Team
March 7, 2025 06:24 AM UTC
Hi Yongkee,
Glad to know the issue has been resolved. Please get back to us for assistance in the future.
Regards,
Shereen
SIGN IN To post a reply.
- 2 Replies
- 2 Participants
-
YC Yongkee Cho
- Mar 6, 2025 12:09 PM UTC
- Mar 7, 2025 06:24 AM UTC