on 2023 Jan 02 9:08 AM
Hello everyone,
My question about planning calendar,
If i create new appointment, calendar is refreshing and going current day.
Selected key is 'week'. And i want to if i create new appointment stay that week and refresh appointment.
Can you experts help me ?
Request clarification before answering.
Hi Doğukan
You can set the calendar's singleRow property to true. This will cause the calendar to stay on the current week when a new appointment is created.
<mvc:View
controllerName="my.app.controller.Calendar"
xmlns:mvc="sap.ui.core.mvc"
xmlns="sap.m">
<PlanningCalendar
id="calendar"
startDate="{path: '/startDate'}"
rows="{path: '/people'}"
singleRow="true"
appointmentSelect="handleAppointmentSelect"
>
<rows>
<PlanningCalendarRow
text="{name}"
appointments="{path: 'appointments'}">
<appointments>
<Appointment
startDate="{start}"
endDate="{end}"
title="{title}"
type="{type}"
icon="{icon}"
>
</Appointment>
</appointments>
</PlanningCalendarRow>
</rows>
</PlanningCalendar>
</mvc:View>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shreyash,
Thanks for reply but it doesn't work for me.
My view code is,
<PlanningCalendar id="PC1" startDate="{path: 'oModel>/Tarih'}" minDate="{path: 'oModel>/MinTarih'}" rows="{path: 'oModel>/PlanHeader'}"
appointmentSelect="onPressPlan" viewKey="Week" rowSelectionChange="onRowSelectionChange" viewChange="onViewChange"
showEmptyIntervalHeaders="false" intervalSelect="onAddPlan" startDateChange="onStartDateChange" singleRow="true">
<toolbarContent>
<Title text="İş Planı" titleStyle="H4"/>
<Button id="addButton" type="Emphasized" icon="sap-icon://add" press="onPressAddButton" tooltip="Plan Ekle"/>
</toolbarContent>
<rows>
<PlanningCalendarRow icon="{oModel>Link}" class="" key="{oModel>Uname}" title="{oModel>Tname}" text="{oModel>Statu}"
appointments="{path : 'oModel>PlanNav', templateShareable: true}" intervalHeaders="{path: 'headers', templateShareable: false}">
<appointments>
<unified:CalendarAppointment key="{oModel>PlanId}" startDate="{oModel>BasTarih}" endDate="{oModel>BitTarih}" icon="{pic}"
title="{oModel>Proje}" text="{oModel>Baslik}" type="{oModel>ColorType}"></unified:CalendarAppointment>
</appointments>
<intervalHeaders>
<unified:CalendarAppointment startDate="{start}" endDate="{end}" icon="{pic}" title="{title}" type="{type}"></unified:CalendarAppointment>
</intervalHeaders>
</PlanningCalendarRow>
</rows>
</PlanningCalendar>
User | Count |
---|---|
84 | |
29 | |
9 | |
9 | |
8 | |
8 | |
7 | |
6 | |
6 | |
6 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.