Our pure JavaScript Scheduler component


Post by yumibca »

Hi Bryntum,

I want custom editor and it's work when Do not add mounted, but when i add mounted for get api data, listener editor can't show.

<scheduler 
			ref="scheduler"
			min-height="78vh"
			:events="events"
			:resources="resources"
			:start-date="startDate"
			:end-date="endDate"
			:timeRanges="timeRanges"
			:resourceColumns="columns"

		:listeners = "{ beforeEventEdit : beforeEventEditHandler }"

		:config="schedulerConfig"
	
		data-intro="Jadwal meeting yang bisa kamu pantau secara real-time berdasarkan ruangan & jam"
		></scheduler>
mounted() {
		this.getDashboard(this.query);
	},methods: {
		beforeEventEditHandler(event) {
			alert("wakww")
				Object.assign(this, {
						eventStore  : event.source.eventStore,
						resourceId  : event.resourceRecord.id,
						eventRecord : event.eventRecord,
						resourceRecord : event.resourceRecord,
						showEditor  : true
				})
				return true;
		},

Thanks.


Post by saki »

beforeEventEditHandler is defined inside of methods property so it has to be accessed as this.beforeEventEditHandler. Ideally, you can mimic the approach we use in Vue Custom Event Editor demo because it is proven that it works and the event handler is certainly run.


Post by yumibca »

instead I have followed the example, but can't


Post by saki »

Then post please your code according to the general guidelines. We will take a look and help you to make it working.


Post Reply