The "dp" variable used in example is a reference to DayPilot.Scheduler object.
In Vue, you can get it using the "ref" attribute:
<template>
<DayPilotScheduler id="dp" :config="config" ref="scheduler"/>
</template>
<script>
import {DayPilot, DayPilotScheduler} from 'daypilot-pro-vue'
import {onMounted, reactive, ref} from 'vue';
export default {
components: {
DayPilotScheduler
},
setup() {
const scheduler = ref(null);
const config = reactive({
timeHeaders: [{groupBy: "Month"}, {groupBy: "Day", format: "d"}],
scale: "Day",
days: DayPilot.Date.today().daysInMonth(),
startDate: DayPilot.Date.today().firstDayOfMonth(),
// ...
});
onMounted(() => {
scheduler.value.control.message("Welcome!");
});
return {
scheduler,
config
};
},
};
</script>
To call the rows.find() method, use the "scheduler" constant:
const parentId = scheduler.value.control.rows.find("A").parent().id;
See also:
https://doc.daypilot.org/scheduler/vue-js/