Dashticz - Save CONFIG.js automatically with PHP

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: robgeerts, htilburgs

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 11:40

michaelm86 wrote:
Monday 12 February 2018 11:36
Hi DewGew,

I tried this. but is does not work ... :(

when i add the ip and port is does not see it in the config. but when i add the user and ww it sees it.

any other options?
Hi DegGew,

correction.. when i make a change tot the files it work. but whenichange something in the browser the settings are not saved to the file.
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 11:51

I think it is something with the access rights on linux level.

domoticz folder:
drwxrwxrwx 5 domo domo 4096 Feb 9 13:39 domoticz

files in custom:
-rw-r--r-- 1 root root 230 Feb 12 10:32 custom.js
-rw-r--r-- 1 root root 21 Feb 12 10:32 custom.css
-rwxrwxrwx 1 root root 173 Feb 12 10:44 CONFIG.js
-rw-r--r-- 1 root root 2133 Feb 12 10:32 CONFIG_DEFAULT.js

any idea if this is correct?
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 12:01

michaelm86 wrote:
Monday 12 February 2018 11:36
Hi DewGew,

I tried this. but is does not work ... :(

when i add the ip and port is does not see it in the config. but when i add the user and ww it sees it.

any other options?
You only have to peform a chmod 777 on CONFIG.js
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 12:06

michaelm86 wrote:
Monday 12 February 2018 11:51
I think it is something with the access rights on linux level.

domoticz folder:
drwxrwxrwx 5 domo domo 4096 Feb 9 13:39 domoticz

files in custom:
-rw-r--r-- 1 root root 230 Feb 12 10:32 custom.js
-rw-r--r-- 1 root root 21 Feb 12 10:32 custom.css
-rwxrwxrwx 1 root root 173 Feb 12 10:44 CONFIG.js
-rw-r--r-- 1 root root 2133 Feb 12 10:32 CONFIG_DEFAULT.js

any idea if this is correct?
Do have any errors in the browser consol? (hit F12)
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 12:19

webpages with PHP is not working in domoticz webserver. Install apache or nginx, php and run dashticz_v2 in apache/nginx www folder instead
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 12:26

oke, how do i do that? :) is there a manual somewhere?

or is it just a "sudo git clone https://github.com/robgeerts/dashticz_v2 --branch beta" in the /var/www folder?
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 12:39

Yes you can do that..
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 12:47

oke thanks it works. changes are saved now! :D

but..
when i remove the first /* (including the line with text) and last /* to use the default config it stops working :?

message
time out something is wrong check your config.js.

sorry for all the questions. it is the first time using it.
Attachments
dash.png
dash.png (65.91 KiB) Viewed 1489 times
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 13:42

Change :

Code: Select all

columns[1]['blocks'] = ['currentweather_big','weather','garbage']

to

Code: Select all

columns[1]['blocks'] = ['currentweather_big','weather']
You have to define 'garbage' settings before using it.
Then follow http://www.domoticz.com/wiki/Dashticz_V2.
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 14:39

Hi DewGew,

great it works!

do i need to do anything special to see my switches? i created a block with the idx of my light switch but is looks like it does not see it.

blocks[3] = {}
blocks[3]['width'] = 6;
blocks[3]['title'] = 'Spotjes Eettafel'
blocks[3]['hide_data'] = true;
blocks[3]['hide_lastupdate'] = true;
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 15:18

You add you switches (blocks) in the columns like this:

Code: Select all

columns[1]['blocks'] = ['weather', 3, 6, 7, 4];
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 15:51

Hi DewGew,

did i do anything wrong?

The switches and the ping devices aren't showing.

this is my screen:
dash1.jpg
dash1.jpg (218.28 KiB) Viewed 1463 times

this is my config:

Code: Select all

config['garbage_maxitems'] = '7';
config['garbage_width'] = '';
config['loginEnabled'] = 1;
config['no_rgb'] = '0';
config['auto_positioning'] = 1;
config['use_favorites'] = 1;
config['disable_googleanalytics'] = '0';
config['last_update'] = 1;
config['hide_topbar'] = '0';
config['edit_mode'] = '0';
config['hide_seconds'] = '0';
config['hide_seconds_stationclock'] = '0';
config['use_fahrenheit'] = '0';
config['use_beaufort'] = '0';
config['translate_windspeed'] = 1;
config['static_weathericons'] = '0';
config['hide_mediaplayer'] = '0';
config['garbage_hideicon'] = '0';
config['garbage_icon_use_colors'] = 1;
config['garbage_use_colors'] = '0';
config['garbage_use_names'] = '0';
config['garbage_use_cors_prefix'] = 1;

//var trashnames = {}
//trashnames['Gft'] = 'GFT';
//trashnames['Pmd'] = 'Plastic';
//trashnames['Rest'] = 'Rest'; //LEAVE EMPTY IF YOU WANT TO HIDE IT


var tvguide = {}
tvguide.dutch = { key:'dutch', icon: 'fa-television', width:12, channels: [1,2,3,4,31,46,92], maxitems: 8 }

var _STREAMPLAYER_TRACKS  	= [
	{"track":1,"name":"Q-music","file":"http://icecast-qmusic.cdp.triple-it.nl/Qmusic_nl_live_96.mp3"},
	{"track":2,"name":"538 Hitzone","file":"http://vip-icecast.538.lw.triple-it.nl/WEB11_MP3"},
	{"track":3,"name":"Slam! NonStop","file":"http://stream.radiocorp.nl/web10_mp3"},
	{"track":4,"name":"BBC Radio 1","file":"http://radiofeeds.co.uk/bbcradio1.pls"},  ]; 



////////////////////// FRAMES ///////////////////////////
var frames = {}
frames.weather = {refreshiframe:10000,height:230,frameurl:"//forecast.io/embed/#lat=52.1924&lon=5.3901&name=Amersfoort&color=#00aaff&font=Helvetica&fontcolor=#ffffff&units=si&text-color=#fff",width:12}



////////////////////// BUTTONS /////////////////////////
var buttons = {}
buttons.buienradar = {width:12, isimage:true, refreshimage:60000, image:'http://api.buienradar.nl/image/1.0/RadarMapNL?w=285&h=256', url:'https://gadgets.buienradar.nl/gadget/zoommap/?lat=52.06022&lng=4.39288&overname=2&zoom=13&naam=2493bj&size=3&voor=1'}



////////////////////// BLOCK TITLES /////////////////////////
var blocks = {}
blocks['blocktitle_tv'] = {}
blocks['blocktitle_tv']['key'] = 'blocktitle_tv';
blocks['blocktitle_tv']['type'] = 'blocktitle';
blocks['blocktitle_tv']['title'] = 'TV and Nieuws';

blocks['blocktitle_switches'] = {}
blocks['blocktitle_switches']['key'] = 'blocktitle_switches';
blocks['blocktitle_switches']['type'] = 'blocktitle';
blocks['blocktitle_switches']['title'] = 'Schakelaars';

blocks['blocktitle_temp'] = {}
blocks['blocktitle_temp']['key'] = 'blocktitle_temp';
blocks['blocktitle_temp']['type'] = 'blocktitle';
blocks['blocktitle_temp']['title'] = 'Verwarming en Temperatuur';

blocks['blocktitle_vijver'] = {}
blocks['blocktitle_vijver']['key'] = 'blocktitle_vijver';
blocks['blocktitle_vijver']['type'] = 'blocktitle';
blocks['blocktitle_vijver']['title'] = 'Koi Vijver';

blocks['blocktitle_spotify'] = {}
blocks['blocktitle_spotify']['key'] = 'blocktitle_spotify';
blocks['blocktitle_spotify']['type'] = 'blocktitle';
blocks['blocktitle_spotify']['title'] = 'Spotify';



// custom block width for switches

blocks['news_2'] = {}
blocks['news_2']['feed'] = 'http://feeds.bbci.co.uk/news/world/europe/rss.xml';

blocks['s1'] = {} //Scene Front room all off
blocks['s1']['hide_data'] = true;
blocks['s1']['hide_lastupdate'] = true;
blocks['s1']['icon'] = 'fa-times-circle';

blocks['s2'] = {} //Movie scene
blocks['s2']['hide_data'] = true;
blocks['s2']['hide_lastupdate'] = true;
blocks['s2']['icon'] = 'fa-video-camera';

blocks['s3'] = {} //Evening scene
blocks['s3']['hide_data'] = true;
blocks['s3']['hide_lastupdate'] = true;
blocks['s3']['icon'] = 'fa-image';





blocks[3] = {}
blocks[3]['width'] = 6;
blocks[3]['title'] = 'Spotjes Eettafel'
blocks[3]['hide_data'] = true;
blocks[3]['hide_lastupdate'] = true;

blocks[1] = {}
blocks[1]['width'] = 6;
blocks[1]['title'] = 'Woonkamer lampen'
blocks[1]['hide_data'] = true;
blocks[1]['hide_lastupdate'] = true;

blocks[4] = {}
blocks[4]['width'] = 6;
blocks[4]['title'] = 'Vijververlichting'
blocks[4]['hide_data'] = true;
blocks[4]['hide_lastupdate'] = true;

blocks[2] = {}
blocks[2]['width'] = 6;
blocks[2]['title'] = 'Buitenlampe Achterdeur'
blocks[2]['hide_data'] = true;
blocks[2]['hide_lastupdate'] = true;

// DOORBELL
blocks[89] = {}
blocks[89]['width'] = 1;
blocks[89]['title'] = ''
blocks[89]['hide_data'] = true;
blocks[89]['hide_lastupdate'] = true;
blocks[89]['playsound'] = 'sounds/doorbell.mp3';
blocks[89]['protected'] = true;
blocks[89]['icon'] = 'fa-bell-o';

//change temp blocks size
blocks[5] = {}
blocks[5]['width'] = 3;

blocks[52] = {}
blocks[52]['width'] = 3;

blocks[54] = {}
blocks[54]['width'] = 3;

blocks[81] = {}
blocks[81]['width'] = 3;
blocks[81]['title'] = 'Change temp.'

//Device status - ping results
blocks[18] = {}
blocks[18]['width'] = 12;
blocks[18]['title'] = 'Internet'
blocks[18]['hide_data'] = true;
blocks[18]['hide_lastupdate'] = true;
blocks[18]['icon'] = 'fa-circle';
blocks[18]['protected'] = true;

blocks[19] = {}
blocks[19]['width'] = 12;
blocks[19]['title'] = 'QNAP'
blocks[19]['hide_data'] = true;
blocks[19]['hide_lastupdate'] = true;
blocks[19]['icon'] = 'fa-circle';
blocks[19]['protected'] = true;

blocks[22] = {}
blocks[22]['width'] = 12;
blocks[22]['title'] = 'QNAP'
blocks[22]['hide_data'] = true;
blocks[22]['hide_lastupdate'] = true;
blocks[22]['icon'] = 'fa-circle';
blocks[22]['protected'] = true;

blocks[21] = {}
blocks[21]['width'] = 12;
blocks[21]['title'] = 'PC Mike'
blocks[21]['hide_data'] = true;
blocks[21]['hide_lastupdate'] = true;
blocks[21]['icon'] = 'fa-circle';
blocks[21]['protected'] = true;


//blocks['sunrise'] = {}
//blocks['sunrise']['width'] = 1;

//blocks['miniclock'] = {}
//blocks['miniclock']['width'] = 7;


// My IDX list
// 00 = omschrijving


////////////////////// COLUMNS /////////////////////////
var columns = {}
columns['bar'] = {}
columns['bar']['blocks'] = ['sunrise','miniclock',89]

columns[1] = {}
columns[1]['blocks'] = ['blocktitle_switches',4,3,2,1]
columns[1]['width'] = 5;

columns[2] = {}
columns[2]['blocks'] = [frames.weather,'blocktitle_temp',5,82,'54_1','52_1','blocktitle_vijver',104,'news','trafficmap']
columns[2]['width'] = 5;

columns[3] = {}
columns[3]['blocks'] = [18,19,21,22,buttons.buienradar,'news_2',tvguide.dutch,'traffic','blocktitle_spotify','spotify']
columns[3]['width'] = 2;

////////////////////// STANDBY /////////////////////////
var columns_standby = {}
columns_standby[1] = {}
columns_standby[1]['blocks'] = ['clock','weather']
columns_standby[1]['width'] = 12;

Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

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

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by DewGew » Monday 12 February 2018 17:00

michaelm86 wrote:
Monday 12 February 2018 15:51
Hi DewGew,

did i do anything wrong?

The switches and the ping devices aren't showing.

this is my screen:
dash1.jpg


this is my config:

Code: Select all

config['garbage_maxitems'] = '7';
config['garbage_width'] = '';
config['loginEnabled'] = 1;
config['no_rgb'] = '0';
config['auto_positioning'] = 1;
config['use_favorites'] = 1;
config['disable_googleanalytics'] = '0';
config['last_update'] = 1;
config['hide_topbar'] = '0';
config['edit_mode'] = '0';
config['hide_seconds'] = '0';
config['hide_seconds_stationclock'] = '0';
config['use_fahrenheit'] = '0';
config['use_beaufort'] = '0';
config['translate_windspeed'] = 1;
config['static_weathericons'] = '0';
config['hide_mediaplayer'] = '0';
config['garbage_hideicon'] = '0';
config['garbage_icon_use_colors'] = 1;
config['garbage_use_colors'] = '0';
config['garbage_use_names'] = '0';
config['garbage_use_cors_prefix'] = 1;

//var trashnames = {}
//trashnames['Gft'] = 'GFT';
//trashnames['Pmd'] = 'Plastic';
//trashnames['Rest'] = 'Rest'; //LEAVE EMPTY IF YOU WANT TO HIDE IT


var tvguide = {}
tvguide.dutch = { key:'dutch', icon: 'fa-television', width:12, channels: [1,2,3,4,31,46,92], maxitems: 8 }

var _STREAMPLAYER_TRACKS  	= [
	{"track":1,"name":"Q-music","file":"http://icecast-qmusic.cdp.triple-it.nl/Qmusic_nl_live_96.mp3"},
	{"track":2,"name":"538 Hitzone","file":"http://vip-icecast.538.lw.triple-it.nl/WEB11_MP3"},
	{"track":3,"name":"Slam! NonStop","file":"http://stream.radiocorp.nl/web10_mp3"},
	{"track":4,"name":"BBC Radio 1","file":"http://radiofeeds.co.uk/bbcradio1.pls"},  ]; 



////////////////////// FRAMES ///////////////////////////
var frames = {}
frames.weather = {refreshiframe:10000,height:230,frameurl:"//forecast.io/embed/#lat=52.1924&lon=5.3901&name=Amersfoort&color=#00aaff&font=Helvetica&fontcolor=#ffffff&units=si&text-color=#fff",width:12}



////////////////////// BUTTONS /////////////////////////
var buttons = {}
buttons.buienradar = {width:12, isimage:true, refreshimage:60000, image:'http://api.buienradar.nl/image/1.0/RadarMapNL?w=285&h=256', url:'https://gadgets.buienradar.nl/gadget/zoommap/?lat=52.06022&lng=4.39288&overname=2&zoom=13&naam=2493bj&size=3&voor=1'}



////////////////////// BLOCK TITLES /////////////////////////
var blocks = {}
blocks['blocktitle_tv'] = {}
blocks['blocktitle_tv']['key'] = 'blocktitle_tv';
blocks['blocktitle_tv']['type'] = 'blocktitle';
blocks['blocktitle_tv']['title'] = 'TV and Nieuws';

blocks['blocktitle_switches'] = {}
blocks['blocktitle_switches']['key'] = 'blocktitle_switches';
blocks['blocktitle_switches']['type'] = 'blocktitle';
blocks['blocktitle_switches']['title'] = 'Schakelaars';

blocks['blocktitle_temp'] = {}
blocks['blocktitle_temp']['key'] = 'blocktitle_temp';
blocks['blocktitle_temp']['type'] = 'blocktitle';
blocks['blocktitle_temp']['title'] = 'Verwarming en Temperatuur';

blocks['blocktitle_vijver'] = {}
blocks['blocktitle_vijver']['key'] = 'blocktitle_vijver';
blocks['blocktitle_vijver']['type'] = 'blocktitle';
blocks['blocktitle_vijver']['title'] = 'Koi Vijver';

blocks['blocktitle_spotify'] = {}
blocks['blocktitle_spotify']['key'] = 'blocktitle_spotify';
blocks['blocktitle_spotify']['type'] = 'blocktitle';
blocks['blocktitle_spotify']['title'] = 'Spotify';



// custom block width for switches

blocks['news_2'] = {}
blocks['news_2']['feed'] = 'http://feeds.bbci.co.uk/news/world/europe/rss.xml';

blocks['s1'] = {} //Scene Front room all off
blocks['s1']['hide_data'] = true;
blocks['s1']['hide_lastupdate'] = true;
blocks['s1']['icon'] = 'fa-times-circle';

blocks['s2'] = {} //Movie scene
blocks['s2']['hide_data'] = true;
blocks['s2']['hide_lastupdate'] = true;
blocks['s2']['icon'] = 'fa-video-camera';

blocks['s3'] = {} //Evening scene
blocks['s3']['hide_data'] = true;
blocks['s3']['hide_lastupdate'] = true;
blocks['s3']['icon'] = 'fa-image';





blocks[3] = {}
blocks[3]['width'] = 6;
blocks[3]['title'] = 'Spotjes Eettafel'
blocks[3]['hide_data'] = true;
blocks[3]['hide_lastupdate'] = true;

blocks[1] = {}
blocks[1]['width'] = 6;
blocks[1]['title'] = 'Woonkamer lampen'
blocks[1]['hide_data'] = true;
blocks[1]['hide_lastupdate'] = true;

blocks[4] = {}
blocks[4]['width'] = 6;
blocks[4]['title'] = 'Vijververlichting'
blocks[4]['hide_data'] = true;
blocks[4]['hide_lastupdate'] = true;

blocks[2] = {}
blocks[2]['width'] = 6;
blocks[2]['title'] = 'Buitenlampe Achterdeur'
blocks[2]['hide_data'] = true;
blocks[2]['hide_lastupdate'] = true;

// DOORBELL
blocks[89] = {}
blocks[89]['width'] = 1;
blocks[89]['title'] = ''
blocks[89]['hide_data'] = true;
blocks[89]['hide_lastupdate'] = true;
blocks[89]['playsound'] = 'sounds/doorbell.mp3';
blocks[89]['protected'] = true;
blocks[89]['icon'] = 'fa-bell-o';

//change temp blocks size
blocks[5] = {}
blocks[5]['width'] = 3;

blocks[52] = {}
blocks[52]['width'] = 3;

blocks[54] = {}
blocks[54]['width'] = 3;

blocks[81] = {}
blocks[81]['width'] = 3;
blocks[81]['title'] = 'Change temp.'

//Device status - ping results
blocks[18] = {}
blocks[18]['width'] = 12;
blocks[18]['title'] = 'Internet'
blocks[18]['hide_data'] = true;
blocks[18]['hide_lastupdate'] = true;
blocks[18]['icon'] = 'fa-circle';
blocks[18]['protected'] = true;

blocks[19] = {}
blocks[19]['width'] = 12;
blocks[19]['title'] = 'QNAP'
blocks[19]['hide_data'] = true;
blocks[19]['hide_lastupdate'] = true;
blocks[19]['icon'] = 'fa-circle';
blocks[19]['protected'] = true;

blocks[22] = {}
blocks[22]['width'] = 12;
blocks[22]['title'] = 'QNAP'
blocks[22]['hide_data'] = true;
blocks[22]['hide_lastupdate'] = true;
blocks[22]['icon'] = 'fa-circle';
blocks[22]['protected'] = true;

blocks[21] = {}
blocks[21]['width'] = 12;
blocks[21]['title'] = 'PC Mike'
blocks[21]['hide_data'] = true;
blocks[21]['hide_lastupdate'] = true;
blocks[21]['icon'] = 'fa-circle';
blocks[21]['protected'] = true;


//blocks['sunrise'] = {}
//blocks['sunrise']['width'] = 1;

//blocks['miniclock'] = {}
//blocks['miniclock']['width'] = 7;


// My IDX list
// 00 = omschrijving


////////////////////// COLUMNS /////////////////////////
var columns = {}
columns['bar'] = {}
columns['bar']['blocks'] = ['sunrise','miniclock',89]

columns[1] = {}
columns[1]['blocks'] = ['blocktitle_switches',4,3,2,1]
columns[1]['width'] = 5;

columns[2] = {}
columns[2]['blocks'] = [frames.weather,'blocktitle_temp',5,82,'54_1','52_1','blocktitle_vijver',104,'news','trafficmap']
columns[2]['width'] = 5;

columns[3] = {}
columns[3]['blocks'] = [18,19,21,22,buttons.buienradar,'news_2',tvguide.dutch,'traffic','blocktitle_spotify','spotify']
columns[3]['width'] = 2;

////////////////////// STANDBY /////////////////////////
var columns_standby = {}
columns_standby[1] = {}
columns_standby[1]['blocks'] = ['clock','weather']
columns_standby[1]['width'] = 12;

Disable those:
config['auto_positioning'] = 1;
config['use_favorites'] = 1;
Raspberry Pi 2B - domoticz - Aeon Labs Z-Stick GEN5 - RFlink gateway
NanoPi NEO-air - domoticz - REGO6XX interface
Dashticz V2 - Homebridge

michaelm86
Posts: 28
Joined: Friday 02 February 2018 12:36
Target OS: Linux
Domoticz version: 3.8153
Location: Netherlands
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by michaelm86 » Monday 12 February 2018 17:10

Thanks, but that didn't do the trick..

I set both the values to '0'. still nothing to see :P

got some more suggestions?
Domoticz 3.8153 on linux laptop ubuntu 17.10 | Toon Thermostat | RFlink usb gateway

FrankVZ
Posts: 35
Joined: Sunday 27 May 2018 12:01
Target OS: -
Domoticz version:
Contact:

Re: Dashticz - Save CONFIG.js automatically with PHP

Post by FrankVZ » Thursday 21 June 2018 11:11

This is an older thread in the meantime, but did cost me a lot of time to find out.
So I share my information here, it might be usefull for others.
(on a Synology DSM with webserver Apache/PHP7 active):

I got the info and files here: https://github.com/Dashticz/dashticz_v2, but some minor adjustments were needed for me.

Logged in with WinSCP (for me the easiest way)
Moved the content of the /domoticz/www/Dashticz folder to a webfolder (for my webserver) in this case /web/DasticzV2.
Delete the compete Dashticz folder from /domoticz/www/
right-click on the file /<your web dashticz folder>/custom/CONFIG.js and give permissions to other users to write

Logged in with SSH (putty) to my synology, changed to user "root".
Make a simlink with the command
ln -s /volume1/web/DashticzV2/ /volume1/@appstore/domoticz/www/Dashticz
(ln -s <your webfolder> <a new Dashticzfolder for Domoticz to create>)

Now I can change the settings from the Dashticz webpage, with the link
http://<MY WEBSERVER DOMOTICZ IP ADRES>:7000

You can access the Dashticz page like this, but the settings will not be saved then:
http://<MY DOMOTICZ IP>:<DomoticzPORT>/Dashticz/index.html

Anyway, as the settings from the menu will work, the position for the e.g. icons still does not work - the icons jump all over the screen. At the bottom of the screen a remark "save to see the results" (or similar) but no way to save it. The shown red "edit button" gives a code that is almost empty with "undefined" buttons, so there has still to be done some work here :shock:

hth,

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests