Calendar: Difference between revisions
Jump to navigation
Jump to search
Created page with "{{#visualdataform: Calendar |title = edit events |action = edit |edit-page = {{FULLPAGENAME}} |return-page = |view = popup |popup-size = medium |css-class = |pagename-formula = |edit-freetext = true |edit-categories = false |edit-content-model = false |edit-target-slot = false |target-slot = jsondata |default-categories = |default-content-model = wikitext |preload= |preload-data= |layout-align = top |popup-help = false |layout = tabs |submit-button-text = |validate..." Tag: 2017 source edit |
VisualData update |
||
(22 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
{{#visualdataform: Calendar | VisualData's calendar format is based on [https://github.com/vkurko/calendar EventCalendar] and it supports all its options which are not overridden by some other option. See below for an example. | ||
Simply create a schema like [[VisualDataSchema:Calendar]], add events (optionally with resources), query all or some of them with the parserfunction <code>visualdataquery</code> (see below) and navigate the calendar ! | |||
{{#visualdataform: Calendar | |||
|title = edit events | |title = edit events | ||
|action = edit | |action = edit | ||
Line 8: | Line 13: | ||
|css-class = | |css-class = | ||
|pagename-formula = | |pagename-formula = | ||
|edit-freetext = | |edit-freetext = false | ||
|edit-categories = false | |edit-categories = false | ||
|edit-content-model = false | |edit-content-model = false | ||
Line 26: | Line 31: | ||
}} | }} | ||
{{#visualdataquery: [[events/start::+]] | <pre> | ||
{{#visualdataquery: [[{{FULLPAGENAME}}]] [[events/start::+]] | |||
|format=calendar | |||
|schema=Calendar | |||
|title-property=title | |||
|start-property=start | |||
|end-property=end | |||
|resources-property=resources | |||
|simple=false | |||
|view=dayGridMonth | |||
}} | |||
</pre> | |||
Note that events shown in this calendar are associated to this page and filtered with the <code><nowiki>[[{{FULLPAGENAME}}]]</nowiki></code> condition. | |||
{{#visualdataquery: [[{{FULLPAGENAME}}]] [[events/start::+]] | |||
|format=calendar | |format=calendar | ||
|schema=Calendar | |schema=Calendar | ||
|title-property=title | |||
|start-property=start | |||
|end-property=end | |||
|resources-property=resources | |||
|simple=false | |||
|view=dayGridMonth | |||
}} | }} | ||
jsondata | |||
---|---|---|---|
Line 1: | Line 1: | ||
{} | { | ||
"schemas": { | |||
"Calendar": { | |||
"events": [ | |||
{ | |||
"title": "Event a", | |||
"start": "2025-08-11T23:39:55.000+0000", | |||
"end": "2025-11-13T15:38:32.000+0000", | |||
"url": null, | |||
"allDay": false, | |||
"display": "auto", | |||
"resources": [ | |||
"room a" | |||
], | |||
"backgroundColor": "", | |||
"borderColor": "", | |||
"textColor": "", | |||
"classNames": [], | |||
"style": "" | |||
}, | |||
{ | |||
"title": "Event b", | |||
"start": "2025-08-12T20:09:31.000+0000", | |||
"end": "2025-08-12T23:09:31.000+0000", | |||
"url": null, | |||
"allDay": false, | |||
"display": "auto", | |||
"resources": [ | |||
"room b" | |||
], | |||
"backgroundColor": "green", | |||
"borderColor": "", | |||
"textColor": "", | |||
"classNames": [], | |||
"style": "" | |||
} | |||
] | |||
} | |||
}, | |||
"schemas-data": [] | |||
} |
Latest revision as of 23:40, 13 August 2025
VisualData's calendar format is based on EventCalendar and it supports all its options which are not overridden by some other option. See below for an example.
Simply create a schema like VisualDataSchema:Calendar, add events (optionally with resources), query all or some of them with the parserfunction visualdataquery
(see below) and navigate the calendar !
Form is loading...
{{#visualdataquery: [[{{FULLPAGENAME}}]] [[events/start::+]] |format=calendar |schema=Calendar |title-property=title |start-property=start |end-property=end |resources-property=resources |simple=false |view=dayGridMonth }}
Note that events shown in this calendar are associated to this page and filtered with the [[{{FULLPAGENAME}}]]
condition.
Calendar is loading...