Dashticz - Module - Calendar

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: robgeerts, htilburgs

User avatar
Cletus
Posts: 80
Joined: Wednesday 17 August 2016 9:32
Target OS: Raspberry Pi
Domoticz version: Latest
Location: Purmerend, Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by Cletus » Tuesday 20 February 2018 14:13

Indeed! I tried the following:

Internal IP from Internal PC on port 8080 (http) works
FQDN from Internal PC on port 8080 (http) works
FQDN from Internal PC on port 443 (https) does not work

Probably because dashticz.nl is http? I am using domoticz with https and official certificate as i prefer https over http without any safety warnings :) is there a way to get this working or does this require @robgeerts to change the dashticz.nl url to https?
This is our world now... the world of the electron and the switch, the beauty of the baud.

User avatar
DewGew
Posts: 270
Joined: Thursday 21 April 2016 12:01
Target OS: Raspberry Pi
Domoticz version: V4.9741
Location: Sweden
Contact:

Re: Dashticz - Module - Calendar

Post by DewGew » Tuesday 20 February 2018 14:29

Cletus wrote:
Tuesday 20 February 2018 14:13
Indeed! I tried the following:

Internal IP from Internal PC on port 8080 (http) works
FQDN from Internal PC on port 8080 (http) works
FQDN from Internal PC on port 443 (https) does not work

Probably because dashticz.nl is http? I am using domoticz with https and official certificate as i prefer https over http without any safety warnings :) is there a way to get this working or does this require @robgeerts to change the dashticz.nl url to https?
I started an issue on github. @robgeerts have to take a look at this. But he seems busy nowdays .. :?
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

geertvercamer
Posts: 18
Joined: Friday 12 May 2017 20:03
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by geertvercamer » Tuesday 20 February 2018 17:15

weird.
My dashticz is working fine after modifying the calendar.js to use the dashticz.nl version.
However, when I launch curl http://dashticz.nl/.... on a raspberry pi, there's a 404 error. When launching in Chrome on W10, I get the data...???

Timmi1993
Posts: 5
Joined: Tuesday 13 February 2018 8:45
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by Timmi1993 » Wednesday 21 February 2018 9:09

Hi,

I edited the code again. It still doesn't work. No matter if internal or external, no matter if formula or something else, only loading.....

Do you use calendars. combined?

geertvercamer
Posts: 18
Joined: Friday 12 May 2017 20:03
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by geertvercamer » Wednesday 21 February 2018 11:13

No, I want 3 separate blocks.

Code: Select all

var calendars = {};
calendars.private = {key:'private', width:12, maxitems: 5, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.google.com/calendar/ical/xxx%40gmail.com/private-xxx/basic.ics' };
calendars.wasteFromGarden = {key:'wasteFromGarden', width:12, maxitems: 1, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.google.com/calendar/ical/yyy%40group.calendar.google.com/public/basic.ics' };
calendars.justForMe = {key:'justForMe', width:3, maxitems: 153, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.google.com/calendar/ical/zzz0%40group.calendar.google.com/private-zzz/basic.ics' };
...
columns[3]['blocks'] = [calendars.private, calendars.justForMeColoured, calendars.wasteFromGardenColoured, 'garbage', 'streamplayer', 28, 'chromecast']; //, 45, 'spotify'];

User avatar
htilburgs
Posts: 509
Joined: Tuesday 03 November 2015 12:01
Target OS: Raspberry Pi
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by htilburgs » Wednesday 21 February 2018 15:15

calendars.private = {key:'private', width:12, maxitems: 5, icalurl: _CROSS_ORIGINE_URL + .... };
I was wondering what these options do?

Code: Select all

key:'private'
width: 12
I can't seem to find them in the code and no text about it on the wiki.

The same for _CROSS_ORIGINE_URL, have you modified the code yourself somewhere?
Hardware:
RPi3 - Aeon Labs Z-Stick GEN5 - Fibaro Dimmer 2 - Fibaro Roller Shutter 2 - Fibaro Smoke Sensor - Yeelight RGBW Led bulb - Yeelight Smart LED Light Strip - Neo Coolcam PIR Motion Sensor - Neo Coolcam PowerPlug - Nest Thermostat v3

geertvercamer
Posts: 18
Joined: Friday 12 May 2017 20:03
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by geertvercamer » Wednesday 21 February 2018 17:21

only barely.

If I remember correctly, in the past some settings used crossorigin.me, other cors-anywhere.herokuapp.com, maybe one in the master, another in the beta.

it's just a constant I use wherever this technique is necessary:
var _CROSS_ORIGINE_URL = 'https://cors-anywhere.herokuapp.com/'; // https://crossorigin.me/

the key and width options are probably remnants of previous versions, I don't see anything in the wiki neither.
I found some other settings not exactly up to date. Thanks for pointing this out!


And I must correct my previous remark about the combined.
As a matter of fact I am using it as I want each caledar block to have a different colour. I don't know how to handle this otherwise.
So I have:

Code: Select all

var calendars = {};
calendars.private = {maxitems: 5, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.googl.../basic.ics' };
calendars.wasteFromGarden = {maxitems: 1, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.google.c.../basic.ics' };
calendars.justForMe = {maxitems: 3, icalurl: _CROSS_ORIGINE_URL + 'https://calendar.google.c.../basic.ics' };
calendars.justForMeColoured = {};
calendars.justForMeColoured.calendars =	[	{ color: '#cefad9', calendar:calendars.justForMe } ];
calendars.justForMeColoured.maxitems = 3;
calendars.wasteFromGardenColoured = {};
calendars.wasteFromGardenColoured.calendars =	[	{ color: '#00aa00', calendar:calendars.wasteFromGarden }	];
calendars.wasteFromGardenColoured.maxitems = 1;
...
columns[3] = {};
columns[3]['blocks'] = [calendars.private, calendars.justForMeColoured, calendars.wasteFromGardenColoured, 'garbage', 'streamplayer', 28, 'chromecast']; //, 45, 'spotify'];
columns[3]['width'] = 3;


User avatar
htilburgs
Posts: 509
Joined: Tuesday 03 November 2015 12:01
Target OS: Raspberry Pi
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by htilburgs » Wednesday 21 February 2018 19:27

Strange. I'm using the latest beta and for me everything is working.

Code: Select all

var calendars = {}
calendars.f1 = {maxitems: 5, title:'', image:'', icalurl:'webcal://p28-calendars.icloud.com/published/2/xxxxxxxx'}
calendars.prive = {maxitems: 5, title: '', image: '', icalurl:'webcal://p04-calendarws.icloud.com/ca/subscribe/1/xxxxxxx'}
Schermafbeelding 2018-02-21 om 18.27.00.png
Schermafbeelding 2018-02-21 om 18.27.00.png (222.21 KiB) Viewed 1889 times
Hardware:
RPi3 - Aeon Labs Z-Stick GEN5 - Fibaro Dimmer 2 - Fibaro Roller Shutter 2 - Fibaro Smoke Sensor - Yeelight RGBW Led bulb - Yeelight Smart LED Light Strip - Neo Coolcam PIR Motion Sensor - Neo Coolcam PowerPlug - Nest Thermostat v3

User avatar
Cletus
Posts: 80
Joined: Wednesday 17 August 2016 9:32
Target OS: Raspberry Pi
Domoticz version: Latest
Location: Purmerend, Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by Cletus » Wednesday 21 February 2018 20:21

I think important here is do you use HTTP or HTTPS ?
This is our world now... the world of the electron and the switch, the beauty of the baud.

axel2906
Posts: 6
Joined: Wednesday 21 February 2018 21:38
Target OS: Raspberry Pi
Domoticz version: V3.8926
Location: Brussels
Contact:

Re: Dashticz - Module - Calendar

Post by axel2906 » Wednesday 21 February 2018 21:57

it doesn't work with chrome firefox edge or Internet Explorer on my Win 10 computer. I try beta or stable version but nothing for the calendar

Code: Select all

calendars.F1 = { maxitems: 5, image: 'calendar.png', url: 'webcal://xxxx2018-formula-1-calendar/calendar.ics', icalurl: 'webcal://xxxx2018-formula-1-calendar/calendar.ics'};
The attachment stable.PNG is no longer available


but if i try it on my smartphone with the browser "Samsung internet", chrome on external lan (4G), it works.

to resume no calendar in internal network but well in external network (i use a no-ip adress for the external)

no https
Attachments
stable.PNG
stable.PNG (68.46 KiB) Viewed 1869 times
RPi3 - RfxComm - Milight - OWL160

User avatar
htilburgs
Posts: 509
Joined: Tuesday 03 November 2015 12:01
Target OS: Raspberry Pi
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by htilburgs » Wednesday 21 February 2018 22:46

Cletus wrote:
Wednesday 21 February 2018 20:21
I think important here is do you use HTTP or HTTPS ?
Http. I don’t have any ports open to the outerworld, except for VPN.
Hardware:
RPi3 - Aeon Labs Z-Stick GEN5 - Fibaro Dimmer 2 - Fibaro Roller Shutter 2 - Fibaro Smoke Sensor - Yeelight RGBW Led bulb - Yeelight Smart LED Light Strip - Neo Coolcam PIR Motion Sensor - Neo Coolcam PowerPlug - Nest Thermostat v3

Timmi1993
Posts: 5
Joined: Tuesday 13 February 2018 8:45
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by Timmi1993 » Wednesday 21 February 2018 23:12

axel2906 wrote:
Wednesday 21 February 2018 21:57
it doesn't work with chrome firefox edge or Internet Explorer on my Win 10 computer. I try beta or stable version but nothing for the calendar

Code: Select all

calendars.F1 = { maxitems: 5, image: 'calendar.png', url: 'webcal://xxxx2018-formula-1-calendar/calendar.ics', icalurl: 'webcal://xxxx2018-formula-1-calendar/calendar.ics'};
stable.PNG



but if i try it on my smartphone with the browser "Samsung internet", chrome on external lan (4G), it works.

to resume no calendar in internal network but well in external network (i use a no-ip adress for the external)

no https


Yes, thats true.
I have an Fire HD 10 with Silk-Browser and it works.
Chrome, firefox, ... = Loading

Edit: I have installed the silk browser on my other tablet and it doesn't work

Mads
Posts: 32
Joined: Thursday 18 January 2018 21:57
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by Mads » Thursday 22 February 2018 20:10

hi.

i also got a problem. The calender just keep loading.

this i my code
Spoiler: show
var calendars = {}
calendars.private = { maxitems: 5, icalurl: 'https://cors-anywhere.herokuapp.com/web ... MCzfvbZ44/' }
The calender has worked, but now i wont :/

geertvercamer
Posts: 18
Joined: Friday 12 May 2017 20:03
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by geertvercamer » Friday 23 February 2018 15:59

Hi all,
I've just noticed another problem. I have my calendars showing up all right. I have a 'common' calendar and a 'private' one (tasks/appointments just for me) and I show them in their own block. Both are wrapped in a calendars.x.calendars 'object' to set their own colour.
There is a problem with the items shown in the 'private' calendar.
next Tuesday I have 2 appointmnts
- an appointment A repeating every first Tuesday of the month at 17:45
- an appointment B repeating every first Tuesday of 2 months at 18:15.
The agenda block is setup to show 3 items.
I see 3 items of appointment B...

when I combine them into one calendar all items appear correctly.

User avatar
htilburgs
Posts: 509
Joined: Tuesday 03 November 2015 12:01
Target OS: Raspberry Pi
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Dashticz - Module - Calendar

Post by htilburgs » Friday 23 February 2018 20:57

Mads wrote:
Thursday 22 February 2018 20:10
hi.

i also got a problem. The calender just keep loading.

this i my code
Spoiler: show
var calendars = {}
calendars.private = { maxitems: 5, icalurl: 'https://cors-anywhere.herokuapp.com/web ... MCzfvbZ44/' }
The calender has worked, but now i wont :/
Try to remove the https://cors-anywhere.herokuapp.com/ part in the url.
Hardware:
RPi3 - Aeon Labs Z-Stick GEN5 - Fibaro Dimmer 2 - Fibaro Roller Shutter 2 - Fibaro Smoke Sensor - Yeelight RGBW Led bulb - Yeelight Smart LED Light Strip - Neo Coolcam PIR Motion Sensor - Neo Coolcam PowerPlug - Nest Thermostat v3

axel2906
Posts: 6
Joined: Wednesday 21 February 2018 21:38
Target OS: Raspberry Pi
Domoticz version: V3.8926
Location: Brussels
Contact:

Re: Dashticz - Module - Calendar

Post by axel2906 » Sunday 25 February 2018 13:48

i've found a workaround

I changed the calendar.js file to this :

before :

Code: Select all

var cache = new Date().getTime();
		curUrl = http://dashticz.nl/ical/?time=' + cache + '&url=' + curUrl;
		moment.locale(settings['calendarlanguage']);
		$.getJSON(curUrl,function(data,textstatus,jqXHR){
i add this before dashticz.nl :

Code: Select all

'https://cors-anywhere.herokuapp.com/
after :

Code: Select all

var cache = new Date().getTime();
		curUrl = 'https://cors-anywhere.herokuapp.com/http://dashticz.nl/ical/?time=' + cache + '&url=' + curUrl;
		moment.locale(settings['calendarlanguage']);
		$.getJSON(curUrl,function(data,textstatus,jqXHR){
and now it's work as expected
RPi3 - RfxComm - Milight - OWL160

Timmi1993
Posts: 5
Joined: Tuesday 13 February 2018 8:45
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by Timmi1993 » Monday 26 February 2018 9:06

axel2906 wrote:
Sunday 25 February 2018 13:48
i've found a workaround

I changed the calendar.js file to this :

before :

Code: Select all

var cache = new Date().getTime();
		curUrl = http://dashticz.nl/ical/?time=' + cache + '&url=' + curUrl;
		moment.locale(settings['calendarlanguage']);
		$.getJSON(curUrl,function(data,textstatus,jqXHR){
i add this before dashticz.nl :

Code: Select all

'https://cors-anywhere.herokuapp.com/
after :

Code: Select all

var cache = new Date().getTime();
		curUrl = 'https://cors-anywhere.herokuapp.com/http://dashticz.nl/ical/?time=' + cache + '&url=' + curUrl;
		moment.locale(settings['calendarlanguage']);
		$.getJSON(curUrl,function(data,textstatus,jqXHR){
and now it's work as expected
You're my hero.
Thank you, everything works great now. ;)

Mads
Posts: 32
Joined: Thursday 18 January 2018 21:57
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by Mads » Monday 26 February 2018 15:47

Didnt help me. The loading text just disapered now :/

axel2906
Posts: 6
Joined: Wednesday 21 February 2018 21:38
Target OS: Raspberry Pi
Domoticz version: V3.8926
Location: Brussels
Contact:

Re: Dashticz - Module - Calendar

Post by axel2906 » Monday 26 February 2018 18:50

Mads wrote:
Monday 26 February 2018 15:47
Didnt help me. The loading text just disapered now :/
try with the ical for F1 (it's a public ical so everybody can use this) can you can get it from here https://www.gpupdate.net/en/calendar/27 ... -calendar/

Code: Select all

calendars.F1 = { maxitems: 5, image: 'calendar.png', icalurl: 'webcal://www.gpupdate.net/en/calendar/273/2018-formula-1-calendar/calendar.ics'};
if it doesn"t work check the error from google (F12)
RPi3 - RfxComm - Milight - OWL160

GuidoP18
Posts: 4
Joined: Monday 11 December 2017 21:10
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Dashticz - Module - Calendar

Post by GuidoP18 » Tuesday 27 February 2018 1:59

Thanks Axel2906 you're code fixed it.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests