Skip to main content

DxScheduler.AppointmentFormLayout Property

Specifies the layout of the extended form that appears when you create an appointment and click the expand button, or when you edit an appointment.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v23.2.dll

NuGet Package: DevExpress.Blazor

Declaration

[Parameter]
public RenderFragment<SchedulerAppointmentFormInfo> AppointmentFormLayout { get; set; }

Property Value

Type Description
RenderFragment<SchedulerAppointmentFormInfo>

The form content.

Remarks

Use the following properties to create a custom appointment edit form:

  • AppointmentCompactFormLayout - the layout of the compact form that appears when a user creates or edits an appointment.
  • AppointmentFormLayout - the layout of the pop-up (detailed) form that opens when a user clicks the expand button in the compact form.

The edit forms are implemented internally as the DxFormLayout component. You can create the form based on layout items in the same way as in the form layout. The Scheduler ships with a set of predefined layout items that correspond to items of the default edit form (DxSchedulerSubjectFormLayoutItem, DxSchedulerStartDateFormLayoutItem, etc.). You can also add a custom item (DxSchedulerCustomFormLayoutItem) and use the Template property to define item content.

For more information, refer to the following help topic: Custom Appointment Form.

<DxScheduler StartDate="@DateTime.Today"
             DataStorage="@DataStorage"
             ActiveViewType="SchedulerViewType.WorkWeek">
    <Views>
        <DxSchedulerWorkWeekView VisibleTime="@(new DxSchedulerTimeSpanRange(TimeSpan.FromHours(8), 
                                 TimeSpan.FromHours(19)))">
            @*...*@
        </DxSchedulerWorkWeekView>
    </Views>
    <AppointmentFormLayout Context="formInfo">
        <DxFormLayoutTabPages>
            <DxFormLayoutTabPage Caption="General Information">
                <DxSchedulerSubjectFormLayoutItem></DxSchedulerSubjectFormLayoutItem>
                <DxSchedulerStartDateFormLayoutItem></DxSchedulerStartDateFormLayoutItem>
                <DxSchedulerStartTimeFormLayoutItem></DxSchedulerStartTimeFormLayoutItem>
                <DxSchedulerEndDateFormLayoutItem></DxSchedulerEndDateFormLayoutItem>
                <DxSchedulerEndTimeFormLayoutItem></DxSchedulerEndTimeFormLayoutItem>
                <DxSchedulerAllDayFormLayoutItem ColSpanMd="6"></DxSchedulerAllDayFormLayoutItem>
                <DxSchedulerCustomFormLayoutItem ColSpanMd="6">
                    <Template>
                        <div style="margin-left: auto; margin-top: 14px;">
                            <DxCheckBox @bind-Checked="@(((CustomAppointmentFormInfo)formInfo).IsAccepted)" 
                                        Alignment="CheckBoxContentAlignment.Right">Accept</DxCheckBox>
                        </div>
                    </Template>
                </DxSchedulerCustomFormLayoutItem>
            </DxFormLayoutTabPage>
            <DxFormLayoutTabPage Caption="Additional Information">
                <DxSchedulerLocationFormLayoutItem></DxSchedulerLocationFormLayoutItem>
                <DxSchedulerDescriptionFormLayoutItem></DxSchedulerDescriptionFormLayoutItem>
            </DxFormLayoutTabPage>
        </DxFormLayoutTabPages>
    </AppointmentFormLayout>
</DxScheduler>

Custom Edit Form

Run Demo: Scheduler - Custom Fields and Appointment Form

Watch Video: Scheduler - Customization

See Also