Our pure JavaScript Scheduler component


Post by melazhadi »

Hello,

i have a problem on timeRangeFeature but i think the problem is caused because the data is late

because when I put the hard data the timeRange is displayed well

but we in our case all the data that appears on the scheduler I rammenes them from the blinds vuex which makes a delay on the arrival of the data

for info the events and the hierarchy of the employees are also data that I read from the store but since I affect the events to the property events and the employees to resources and these properties pass by your watcher the data change as and when as you go

for that my question is what you have a property where I can affect my timeRanges and will be displayed

for info here's what I'm doing now
timeRangesFeature: {
				store: {
			 		modelClass: Holiday
				},
				timeRanges: this.joursf
			},
with
this.joursf
is the variable where I store the return of the store

thanks

Post by mats »

Our API doesn't work like that. You should either use our Store API or set an array with existing data manually.
scheduler.timeRangesFeature.store.data = [....];

Post by melazhadi »

Hello,
I assigned timeranges on
timeRangesFeature.store.data
but nothing is displayed yet


and on the vue inspector I see that the scheduler component is getting the timeRanges on this property
timeRangesFeature.store.data
Attachments
2019-07-12_08h55_42.png
2019-07-12_08h55_42.png (5.49 KiB) Viewed 2062 times

Post by mats »

And you're assigning the array *after* it's populated?

Post by melazhadi »

yes, that's the problem, but I do not encounter this problem on events and resources even if the data arrive late but they are displayed correctly

for information :
the property I use for the resources is:
//app.vue
:resource-store="schedulerConfig.resourceStore"
:resources="resources"
//schedulerConfig.js
resourceStore: {
		modelClass: SmartModel,
		tree: true
	},
the property I use for events is:
//app.vue
:event-store="schedulerConfig.eventStore"
:events="absences"
//schedulerConfig.js
eventStore: {
		modelClass: MyEvent,
	},
so is there a solution for the timeRanges?

Post by mats »

We'll need your test case to understand what's actually going on.

Post by melazhadi »

it's a bit complicated to give you a test case because the data comes from a store that calls webservices what do you have another solution?

Post by mats »

No other solution, you need to provide a test case with dummy data just like our examples.

Post by melazhadi »

https://drive.google.com/file/d/1e5DLpKumeme3ayY7aa_k-Yo47Df0i4wP/view?usp=sharing

here is the drive link to my project

to test

the case where it works well the functionality
1 - remove the comments from line 87 on line 143,
2 - comments line 144 and line 150

what you will find by default is the case where it does not work

Post by pmiklashevich »

Hello,

I've checked your testcase and see you're using 1.2.5 trial there. Could you please download the latest official release and apply to your testcase? When I replace files in `bryntum-lib` folder with the latest sources I get the following error:
webpack-internal:///./node_modules/vue/dist/vue.runtime.esm.js:620 [Vue warn]: Error in callback for watcher "viewPreset": "Error: Invalid time axis configuration or filter, please check your input data."
Please make sure your test case is runnable.
the case where it works well the functionality
1 - remove the comments from line 87 on line 143,
2 - comments line 144 and line 150
Please mention the file where these lines are present. Please provide more detailed steps to reproduce your issue. And let's clarify what exactly the problem is. You're not able to specify timeRanges in your application?

Best regards,
Pavel

Pavlo Miklashevych
Sr. Frontend Developer


Post Reply