Make bits larger and extra pages

Dashticz, alternative dashboard based on HTML, CSS, jQuery

Moderators: leecollings, htilburgs, robgeerts

Post Reply
alarm_guy1
Posts: 132
Joined: Tuesday 14 January 2014 0:03
Target OS: Linux
Domoticz version:
Contact:

Make bits larger and extra pages

Post by alarm_guy1 »

Hi, sorry for the cryptic title, I have just delved back into Dashticz, as i now have a simple but viable project.

I have created a simple interface, that i'm nearly happy with.

I have several issues i'm trying to address though
1, I would like a 2nd maybe 3rd tab that I can swipe across to, I have seen the reference to it (enable_swiper), but no idea how to go about creating multiple pages

2, The attached image shows the 2 problems I would like to address. I have a URL link to a shopping list site, but the text is small on the Ipad
so I have made 2 entries to give an better chance of getting it when you tap, there must be a better way to increase the size.

3, I have tried adding with no success a Hikvision camera to the bottom left, but all I get is errors and Dashticz wont load, I know the URL certainly for Snapshot as I use it in Domoticz, for several cameras

4, I believe i'm using the latest beta but tbh i'm not 100% sure, I re-installed Friday onto a Pi4.

5, Lastly at the moment, I wanted to add a device turned on / turned off voice when Domoticz idx 298 switches on/off this is our boiler


Here is my Config

Code: Select all

var config = {}
config['language'] = 'en_US'; //or: en_US, de_DE, fr_FR, hu_HU, it_IT, pt_PT, sv_SV
config['domoticz_ip'] = 'http://192.168.xxx.xxx:xxx';
config['domoticz_refresh'] = '1';
config['dashticz_refresh'] = '5';

config['use_favorites'] = 1; //Request all Domoticz Devices, not only favorites
config['auto_positioning'] = 0; // Use 0 this if you have defined your own columns

//Configuring the OWM parameters
config['owm_api'] = 'Working API';
config['owm_city'] = 'My home';
config['owm_name'] = '';
config['owm_country'] = 'uk';
config['owm_lang'] = 'en_US';
config['owm_cnt'] = '7';
config['owm_min'] = true;
config['owm_days'] = true;


blocks[313,336,58,298]= {
    width: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":"U2 Radio Station","file":"http://prod-chrome80-player-popup.s3.eu-central-1.amazonaws.com/popup_player_v1.html?station=u2&tenant=radio.net"},
  ]; //not working as no in right format


var buttons = {}
buttons.Shopping = {key: 'nunl',  width:22, icon: 'fa-newspaper-o', title: 'SHOPPING LIST', newwindow:true, url: 'http://listmoz.com#zYj31GjbVWcjfZb7FJ '}
buttons.nos = {key: 'nos',  width:12, icon: 'fa-newspaper-o', title: 'Nos', url: 'http://www.nos.nl'}






var columns = {}
columns['bar'] = {}
columns['bar']['blocks'] = ['logo','miniclock','settings']
					
columns[1] = {}
columns[1]['blocks'] = [336,58,313,298,buttons.Shopping,buttons.Shopping]
columns[1]['width'] = 7;

columns[2] = {}
columns[2]['blocks'] = []
columns[2]['width'] = 1; 

columns[3] = {}
columns[3]['blocks'] = ['stationclock','streamplayer','currentweather_big_owm','weather_owm']
columns[3]['width'] = 5; 

var columns_standby = {}
columns_standby[1] = {}
columns_standby[1]['blocks'] = ['miniclock','weather']
columns_standby[1]['width'] = 14;

var screens = {}
screens[1] = {}
screens[1]['background'] = 'maldives.jpg';
screens[1]['columns'] = [1,2,3]


//Adding OWM to a column
//columns[3] = {}
//columns[3]['blocks'] = ['currentweather_big_owm','weather_owm']
//columns[3]['width'] = 3;

Many many thanks inadvance
Attachments
Dashticz.jpg
Dashticz.jpg (342.59 KiB) Viewed 338 times
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Make bits larger and extra pages

Post by Lokonli »

The next part doesn't work:

Code: Select all

blocks[313,336,58,298]= {
    width:8

}
You have to set the width for each block individually, like:

Code: Select all

blocks[313] = {
  width: 8
}
The max of the sum of the width of the blocks in a column is 12, so if you want to have 2 blocks on one row width should be 6. With three blocks width should be 4 (or 2,4,6 for instance)

There is something strange with your buttons (shopping list): they should have a background.

To make the text of button titles bigger, add the following to custom.css:

Code: Select all

.button .dt_title {
     font-size: 30px 
 }
To add a second screen add the following to CONFIG.js:

Code: Select all


blocks['col4title'] = {
	type: 'blocktitle',
	title: 'Column 4, column width is 4'
}

blocks['col4block1'] = {
	type: 'blocktitle',
	title: 'block width is 6',
	width: 6

}

blocks['col4block2'] = {
	type: 'blocktitle',
	title: 'block width is 3',
	width: 3

}

blocks['col5title'] = {
	type: 'blocktitle',
	title: 'Column 5, column width is 8'
}

columns[4] = {
	width: 4,
	blocks: ['col4title', 'col4block1','col4block2']
} 

columns[5] = {
	width: 8,
	blocks: ['col5title']
} 

screens[2] = {
	background: 'maldives.jpg',
	columns: [4,5]
}
I've added a few blocktitle blocks in the first column of the second screen. (=column 4)
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Make bits larger and extra pages

Post by Lokonli »

To change the app title add the following to CONFIG.js:

Code: Select all

config['app_title'] = 'Dashticz';
To check your version click on the Dashticz settings icon (upper right), info tab.

Documentation:
https://dashticz.readthedocs.io/en/master/

And for the beta branch:
https://dashticz.readthedocs.io/en/beta/
alarm_guy1
Posts: 132
Joined: Tuesday 14 January 2014 0:03
Target OS: Linux
Domoticz version:
Contact:

Re: Make bits larger and extra pages

Post by alarm_guy1 »

Thankyou ever so much.

I will spend today having a play.

I have V3.03 Beta.

Many thanks
Lokonli
Posts: 2291
Joined: Monday 29 August 2016 22:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Make bits larger and extra pages

Post by Lokonli »

I think you are still using the old dashticzv3 repository. It's better to switch to the new repository to get the latest version.

Check with

Code: Select all

git remote -v
This should give:

Code: Select all

origin  http://github.com/Dashticz/dashticz (fetch)
origin  http://github.com/Dashticz/dashticz (push)
If v2 or v3 is part of the url you are using the old version.

You can start over and do a full install following the instructions:
https://dashticz.readthedocs.io/en/mast ... ation.html

or update manually. In the dashticz folder:

Code: Select all

git remote set-url origin https://github.com/Dashticz/dashticz
cp custom/custom.css custom/custom.css.bak
cp custom/custom.js custom/custom.js.bak
git fetch --all
git checkout beta
git reset --hard origin/beta
mv custom/custom.css.bak custom/custom.css
mv custom/custom.js.bak custom/custom.js
alarm_guy1
Posts: 132
Joined: Tuesday 14 January 2014 0:03
Target OS: Linux
Domoticz version:
Contact:

Re: Make bits larger and extra pages

Post by alarm_guy1 »

Cheers just realised it was old, so have now done a fresh install and kept my CONFIG.js
cheers
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest