-
Notifications
You must be signed in to change notification settings - Fork 0
/
bundle.js.map
1 lines (1 loc) · 20.5 KB
/
bundle.js.map
1
{"version":3,"sources":["cities.js","functions.js","layout.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AC/KA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;ACvMA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","file":"bundle.js","sourcesContent":["/**\r\n * Data for side menu\r\n * \r\n * @author Yauheni Svirydzenka <[email protected]>\r\n * @version 0.0.1\r\n * @copyright Yauheni Svirydzenka 2017\r\n */\r\n \r\nvar citiesData = [\r\n\t{\r\n\t\tid: \"asipovichi\", \r\n\t\tvalue: \"Asipovichi\",\r\n\t\ticon: \"retweet\"\r\n\t},\r\n\t{\r\n\t\tid: \"baranavichy\", \r\n\t\tvalue: \"Baranavichy\",\r\n\t\ticon: \"train\"\r\n\t},\r\n\t{\r\n\t\tid: \"barysaw\", \r\n\t\tvalue: \"Barysaw\",\r\n\t\ticon: \"futbol-o\"\r\n\t},\r\n\t{\r\n\t\tid: \"bobruysk\", \r\n\t\tvalue: \"Bobruysk\",\r\n\t\ticon: \"gear\"\r\n\t},\r\n\t{\r\n\t\tid: \"braslav\", \r\n\t\tvalue: \"Braslav\",\r\n\t\ticon: \"road\"\r\n\t},\r\n\t{\r\n\t\tid: \"brest\", \r\n\t\tvalue: \"Brest\",\r\n\t\ticon: \"arrows-v\"\r\n\t},\r\n\t{\r\n\t\tid: \"gorki\", \r\n\t\tvalue: \"Gorki\", \r\n\t\ticon: \"university\"\r\n\t},\r\n\t{\r\n\t\tid: \"grodno\", \r\n\t\tvalue: \"Grodno\", \r\n\t\ticon: \"building\"\r\n\t},\r\n\t{\r\n\t\tid: \"homyel\", \r\n\t\tvalue: \"Homyel\", \r\n\t\ticon: \"truck\"\r\n\t},\r\n\t{\r\n\t\tid: \"kalinkavichi\", \r\n\t\tvalue: \"Kalinkavichi\", \r\n\t\ticon: \"save\"\r\n\t},\r\n\t{\r\n\t\tid: \"kobrin\", \r\n\t\tvalue: \"Kobrin\", \r\n\t\ticon: \"bed\"\r\n\t},\r\n\t{\r\n\t\tid: \"krichev\", \r\n\t\tvalue: \"Krichev\", \r\n\t\ticon: \"dashboard\"\r\n\t},\r\n\t{\r\n\t\tid: \"lida\", \r\n\t\tvalue: \"Lida\", \r\n\t\ticon: \"key\"\r\n\t},\r\n\t{\r\n\t\tid: \"lyepyel'\", \r\n\t\tvalue: \"Lyepyel'\", \r\n\t\ticon: \"leaf\"\r\n\t},\r\n\t{\r\n\t\tid: \"mahilyow\", \r\n\t\tvalue: \"Mahilyow\", \r\n\t\ticon: \"tty\"\r\n\t},\r\n\t{\r\n\t\tid: \"maladzyechna\", \r\n\t\tvalue: \"Maladzyechna\", \r\n\t\ticon: \"cloud\"\r\n\t},\r\n\t{\r\n\t\tid: \"mazyr\", \r\n\t\tvalue: \"Mazyr\", \r\n\t\ticon: \"fire-extinguisher\"\r\n\t},\r\n\t{\r\n\t\tid: \"minsk\", \r\n\t\tvalue: \"Minsk\", \r\n\t\ticon: \"send\"\r\n\t},\r\n\t{\r\n\t\tid: \"navapolatsk\", \r\n\t\tvalue: \"Navapolatsk\", \r\n\t\ticon: \"bank\"\r\n\t},\r\n\t{\r\n\t\tid: \"niasvizh\", \r\n\t\tvalue: \"Niasvizh\", \r\n\t\ticon: \"certificate\"\r\n\t},\r\n\t{\r\n\t\tid: \"orsha\", \r\n\t\tvalue: \"Orsha\", \r\n\t\ticon: \"plus\"\r\n\t},\r\n\t{\r\n\t\tid: \"pinsk\", \r\n\t\tvalue: \"Pinsk\", \r\n\t\ticon: \"arrows-h\"\r\n\t},\r\n\t{\r\n\t\tid: \"polatsk\", \r\n\t\tvalue: \"Polatsk\", \r\n\t\ticon: \"anchor\"\r\n\t},\r\n\t{\r\n\t\tid: \"rechytsa\", \r\n\t\tvalue: \"Rechytsa\", \r\n\t\ticon: \"random\"\r\n\t},\r\n\t{\r\n\t\tid: \"rogachev\", \r\n\t\tvalue: \"Rogachev\", \r\n\t\ticon: \"tag\"\r\n\t},\r\n\t{\r\n\t\tid: \"salihorsk\", \r\n\t\tvalue: \"Salihorsk\", \r\n\t\ticon: \"signal\"\r\n\t},\r\n\t{\r\n\t\tid: \"slutsk\", \r\n\t\tvalue: \"Slutsk\", \r\n\t\ticon: \"stop\"\r\n\t},\r\n\t{\r\n\t\tid: \"smarhon\", \r\n\t\tvalue: \"Smarhon\", \r\n\t\ticon: \"inbox\"\r\n\t},\r\n\t{\r\n\t\tid: \"svetlagorsk\", \r\n\t\tvalue: \"Svetlagorsk\", \r\n\t\ticon: \"sun-o\"\r\n\t},\r\n\t{\r\n\t\tid: \"vaukavysk\", \r\n\t\tvalue: \"Vaukavysk\", \r\n\t\ticon: \"camera\"\r\n\t},\r\n\t{\r\n\t\tid: \"vitsyebsk\", \r\n\t\tvalue: \"Vitsyebsk\", \r\n\t\ticon: \"user\"\r\n\t},\r\n\t{\r\n\t\tid: \"zhlobin\", \r\n\t\tvalue: \"Zhlobin\", \r\n\t\ticon: \"bullhorn\"\r\n\t},\r\n\t{\r\n\t\tid: \"zhodzina\", \r\n\t\tvalue: \"Zhodzina\", \r\n\t\ticon: \"tags\"\r\n\t}\r\n];\r\n","/**\r\n * Main app logic\r\n * \r\n * @author Yauheni Svirydzenka <[email protected]>\r\n * @version 0.0.1\r\n * @copyright Yauheni Svirydzenka 2017\r\n */\r\n\r\n/**\r\n * Set data for google map\r\n *\r\n * @param {object} weatherData Whole data from server\r\n */\r\nfunction setDataForGoogleMap(weatherData) {\r\n var lat = weatherData.item.lat;\r\n var long = weatherData.item.long;\r\n \r\n var center = [];\r\n center.push(lat);\r\n center.push(long);\r\n $$(\"googleMap\").define(\"center\", center);\r\n \r\n\r\n var marker = {\r\n lat: lat,\r\n lng: long,\r\n title: \"<b>City:</b> \" + weatherData.location.city + \"<br/><b>Country:</b> \" + weatherData.location.country\r\n };\r\n $$(\"googleMap\").add(marker);\r\n}\r\n\r\n/**\r\n * Choose arrow class for rendering wind direction\r\n *\r\n * @param {object} weatherData Whole data from server\r\n * @return {string} arrowClass Class name for arrow image\r\n */\r\nfunction getClassForWindDirection(weatherData) {\r\n var arrowClass = \"\";\r\n var degrees = weatherData.wind.direction * 1;\r\n\r\n if (degrees <= 23 && degrees > 338) {\r\n arrowClass = \"north\";\r\n } else if (degrees > 23 && degrees <= 68) {\r\n arrowClass = \"north-east\";\r\n } else if (degrees > 68 && degrees <= 113) {\r\n arrowClass = \"east\";\r\n } else if (degrees > 113 && degrees <= 158) {\r\n arrowClass = \"south-east\";\r\n } else if (degrees > 158 && degrees <= 203) {\r\n arrowClass = \"south\";\r\n } else if (degrees > 203 && degrees <= 248) {\r\n arrowClass = \"south-west\";\r\n } else if (degrees > 248 && degrees <= 293) {\r\n arrowClass = \"west\";\r\n } else if (degrees > 293 && degrees <= 338) {\r\n arrowClass = \"north-west\";\r\n } else {\r\n arrowClass = \"north\";\r\n }\r\n\r\n return arrowClass;\r\n}\r\n\r\n/**\r\n * Set data and render page components\r\n *\r\n * @param {object} weatherData Whole data from server\r\n * @param {string} cityName City name\r\n */\r\nfunction setDataToPageComponents(weatherData, cityName) {\r\n var placeCountry = \"<div class=\\\"alert alert-info\\\">Country: <b>\" + weatherData.location.country + \"</b></div>\";\r\n var placeRegion = \"<div class=\\\"alert alert-info\\\">Region: <b>\" + weatherData.location.region + \"</b></div>\";\r\n var placeCity = \"<div class=\\\"alert alert-info\\\">City: <b>\" + weatherData.location.city + \"</b></div>\";\r\n var wholePlaceInfo = placeCountry + placeRegion + placeCity;\r\n $$(\"placeInfo\").define(\"template\", wholePlaceInfo);\r\n $$(\"placeInfo\").refresh();\r\n\r\n var geoInfoSunrise = \"<div class=\\\"alert alert-success\\\">Sunrise: <b>\" + weatherData.astronomy.sunrise + \"</b></div>\";\r\n var geoInfoSunset = \"<div class=\\\"alert alert-success\\\">Sunset: <b>\" + weatherData.astronomy.sunset + \"</b></div>\";\r\n var geoInfoMood = \"<div class=\\\"alert alert-success\\\">Mood: <b>\" + weatherData.item.condition.text + \"</b></div>\";\r\n var wholeGeoInfo = geoInfoSunrise + geoInfoSunset + geoInfoMood;\r\n $$(\"geoInfo\").define(\"template\", wholeGeoInfo);\r\n $$(\"geoInfo\").refresh();\r\n \r\n var visibility = \"<div class=\\\"alert alert-warning\\\">Visibility: <b>\" + weatherData.atmosphere.visibility + \" km</b></div>\";\r\n var humidity = \"<div class=\\\"alert alert-warning\\\">Humidity: <b>\" + weatherData.atmosphere.humidity + \" %</b></div>\";\r\n var windSpeedMS = (weatherData.wind.speed * 1000 / 3600).toFixed(1);\r\n var windDirectionClass = getClassForWindDirection(weatherData);\r\n var windDirectionImageName = \"arrow\";\r\n var windDirectionImageTemplate = '<img src=\"images/' + windDirectionImageName + '.png\" class=\"' + windDirectionClass + '\"/>';\r\n var wind = \"<div class=\\\"alert alert-warning\\\">Wind: <b>\" + windSpeedMS + \" m/s</b> \" + windDirectionImageTemplate + \"</div>\";\r\n var wholeMeteoInfo = visibility + humidity + wind;\r\n $$(\"meteoInfo\").define(\"template\", wholeMeteoInfo);\r\n $$(\"meteoInfo\").refresh();\r\n\r\n var cityPhotoTemplate = '<img src=\"images/' + cityName + '.jpg\"/>';\r\n $$(\"cityPhoto\").define(\"template\", cityPhotoTemplate);\r\n $$(\"cityPhoto\").refresh();\r\n\r\n var labelLatTemplate = \"<span class=\\\"label label-info\\\">Latitude: \" + weatherData.item.lat + \"</span>\";\r\n $$(\"labelLat\").define(\"label\", labelLatTemplate);\r\n $$(\"labelLat\").refresh();\r\n\r\n var labelLongTemplate = \"<span class=\\\"label label-info\\\">Longitude: \" + weatherData.item.long + \"</span>\";\r\n $$(\"labelLong\").define(\"label\", labelLongTemplate);\r\n $$(\"labelLong\").refresh();\r\n \r\n setDataForGoogleMap(weatherData);\r\n\r\n var chartForecast = $$(\"chartForecast\").$view;\r\n chartForecast.setAttribute(\"id\", \"chartForecastContainer\");\r\n setChartData(weatherData.item.forecast, weatherData.location.city);\r\n}\r\n\r\n/**\r\n * Handle choosing item in side menu and get data from Yahoo server\r\n *\r\n * @param {string} cityName City name\r\n * @param {object} e Event\r\n * @param {object} node Element\r\n */\r\nfunction getWeatherByCityWoeid(cityName, e, node) {\r\n webix.ajax().headers({\r\n \"Content-Type\": \"application/json\"\r\n }).post(\"http://localhost:4488/data\", {\"cityName\": cityName},\r\n function(text, data, XmlHttpRequest) {\r\n var data = JSON.parse(text);\r\n weatherData = data.query.results.channel;\r\n console.log(weatherData);\r\n setDataToPageComponents(weatherData, cityName);\r\n });\r\n}\r\n\r\n/**\r\n * Set data and render chart\r\n *\r\n * @param {object} forecastData Data for chart\r\n * @param {string} city City name\r\n */\r\nfunction setChartData(forecastData, city) {\r\n\tvar categories = [];\r\n\tvar highTemp = [];\r\n\tvar lowTemp = [];\r\n\r\n\tforecastData.forEach(function(item, i, arr) {\r\n\t \tcategories.push(item.day + \" \" + item.date);\r\n\t \thighTemp.push(+item.high);\r\n\t \tlowTemp.push(+item.low);\r\n\t});\r\n\r\n\t$('#chartForecastContainer').highcharts({\r\n chart: {\r\n type: 'column'\r\n },\r\n title: {\r\n text: '10 days weather forecast for ' + city\r\n },\r\n subtitle: {\r\n text: 'Source: Yahoo Weather'\r\n },\r\n xAxis: {\r\n categories: categories\r\n },\r\n yAxis: {\r\n tickInterval: 1,\r\n title: {\r\n text: 'Temperature °C'\r\n }\r\n },\r\n tooltip: {\r\n headerFormat: '<span style=\"font-size:10px\">{point.key}</span><table>',\r\n pointFormat: '<tr><td style=\"color:{series.color};padding:0\">{series.name}: </td>' +\r\n '<td style=\"padding:0\"><b>{point.y:.1f} °C</b></td></tr>',\r\n footerFormat: '</table>',\r\n shared: true,\r\n useHTML: true\r\n },\r\n plotOptions: {\r\n column: {\r\n pointPadding: 0.2,\r\n borderWidth: 0\r\n }\r\n },\r\n series: [\r\n\t {\r\n\t name: 'Highest',\r\n\t color: '#F00',\r\n\t data: highTemp\r\n\r\n\t }, {\r\n\t name: 'Lowest',\r\n\t color: '#00F',\r\n\t data: lowTemp\r\n\r\n\t }\r\n ]\r\n });\r\n}\r\n","/**\r\n * Main app structure\r\n * \r\n * @author Yauheni Svirydzenka <[email protected]>\r\n * @version 0.0.1\r\n * @copyright Yauheni Svirydzenka 2017\r\n */\r\n\r\n/**\r\n * Create main layout\r\n */\r\nwebix.ready(function(){\r\n\twebix.ui({\r\n\t\trows:[\r\n\t\t\t{\r\n\t\t\t\tview: \"toolbar\",\r\n\t\t\t\tid: \"toolbar\",\r\n\t\t\t\telements: [\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tview: \"icon\", \r\n\t\t\t\t\t\ticon: \"bars\",\r\n\t\t\t\t\t\tclick: function() {\r\n\t\t\t\t\t\t\tif( $$(\"menu\").config.hidden) {\r\n\t\t\t\t\t\t\t\t$$(\"menu\").show();\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\t$$(\"menu\").hide();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tview: \"label\",\r\n\t\t\t\t\t\tlabel: \"Weather forecast\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tview: \"label\",\r\n\t\t\t\t\t\tid: \"labelLat\",\r\n\t\t\t\t\t\talign: \"right\",\r\n\t\t\t\t\t\twidth: 180,\r\n\t\t\t\t\t\tlabel: \"\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{width: 10},\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tview: \"label\",\r\n\t\t\t\t\t\tid: \"labelLong\",\r\n\t\t\t\t\t\talign: \"right\",\r\n\t\t\t\t\t\twidth: 180,\r\n\t\t\t\t\t\tlabel: \"\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\t{width: 20},\r\n\t\t\t\t\t{\r\n\t\t\t\t view: \"button\",\r\n\t\t\t\t id: \"resetPins\",\r\n\t\t\t\t type: \"iconButton\",\r\n\t\t\t\t label: \"Remove map markers\",\r\n\t\t\t\t icon: \"flag\",\r\n\t\t\t\t width: 185,\r\n\t\t\t\t click: function() {\r\n\t\t\t\t $$(\"googleMap\").clearAll();\r\n\t\t\t }\r\n\t\t\t },\r\n\t\t\t\t\t{\r\n\t\t\t\t view: \"button\",\r\n\t\t\t\t id: \"exportToPNG\",\r\n\t\t\t\t type: \"iconButton\",\r\n\t\t\t\t label: \"Export to PNG\",\r\n\t\t\t\t icon: \"image\",\r\n\t\t\t\t width: 140,\r\n\t\t\t\t click: function() {\r\n\t\t\t\t webix.toPNG($$(\"infoContainer\"), \"current_weather.png\");\r\n\t\t\t }\r\n\t\t\t }\r\n\r\n\t\t\t\t]\r\n\t\t\t},\r\n\t\t\t{\r\n\t\t\t\tview: \"layout\",\r\n\t\t\t cols:[\r\n\t {\r\n\t \ttemplate: \"<img src=\\\"images/snow.jpg\\\"/>\",\r\n\t \tcss:\"underMenu\",\r\n\t\t width: 200\r\n\t\t },\r\n\t {\r\n\t \trows:[\r\n\t \t\t{\r\n\t \t\t\tgravity: 3,\r\n\t \t\t\tminHeight: 250,\r\n\t \t\t\tcols:[\r\n\t\t\t \t\t\t\t\t{\r\n\t\t\t \t\t\tview: \"layout\",\r\n\t\t\t \t\t\tid: \"infoContainer\",\r\n\t\t\t \t\t\tminWidth: 300,\r\n\t\t\t \t\t\tgravity: 3,\r\n\t\t\t \t\t\trows:[\r\n\t\t\t \t\t\t\t{\r\n\t\t\t\t\t \t\t\tview: \"layout\",\r\n\t\t\t\t\t \t\t\tid: \"meteoInfoContainer\",\r\n\t\t\t\t\t \t\t\tgravity: 1,\r\n\t\t\t\t\t \t\t\tcols:[\r\n\t\t\t\t\t\t\t \t\t{\r\n\t\t\t\t\t \t\t\t\t\tid: \"meteoInfo\",\r\n\t\t\t\t\t \t\t\t\t\tgravity: 1,\r\n\t\t\t\t\t \t\t\t\t\ttemplate: \"<div class=\\\"alert alert-warning\\\">Visibility: </div><div class=\\\"alert alert-warning\\\">Humidity: </div><div class=\\\"alert alert-warning\\\">Wind: </div>\",\r\n\t\t\t\t\t \t\t\t\t\tcss:\"underMenu\",\r\n\t\t\t\t\t \t\t\t\t\tborderless: true\r\n\t\t\t\t\t \t\t\t\t},\r\n\t\t\t\t\t\t\t \t\t{\r\n\t\t\t\t\t \t\t\t\t\tid: \"geoInfo\",\r\n\t\t\t\t\t \t\t\t\t\tgravity: 1,\r\n\t\t\t\t\t \t\t\t\t\ttemplate: \"<div class=\\\"alert alert-success\\\">Sunrise: </div><div class=\\\"alert alert-success\\\">Sunset: </div><div class=\\\"alert alert-danger\\\">Mood:</div>\",\r\n\t\t\t\t\t \t\t\t\t\tcss:\"underMenu\",\r\n\t\t\t\t\t \t\t\t\t\tborderless: true\r\n\t\t\t\t\t \t\t\t\t}\r\n\t\t\t\t\t \t\t\t]\t\r\n\t\t\t\t\t \t\t},\r\n\t\t\t\t\t \t\t{\r\n\t\t\t\t\t \t\t\tview: \"layout\",\r\n\t\t\t\t\t \t\t\tid: \"cityInfoContainer\",\r\n\t\t\t\t\t \t\t\tgravity: 2,\r\n\t\t\t\t\t \t\t\tcols:[\r\n\t\t\t\t\t \t\t\t\t{\r\n\t\t\t\t\t\t\t \t\t\tid: \"placeInfo\",\r\n\t\t\t\t\t\t\t \t\t\ttemplate: \"<div class=\\\"alert alert-info\\\">Place info: </div>\",\r\n\t\t\t\t\t\t\t \t\t\tgravity: 1,\r\n\t\t\t\t\t\t\t \t\t\tcss:\"underMenu\",\r\n\t\t\t\t\t\t\t \t\t\tborderless: true\r\n\t\t\t\t\t\t\t \t\t},\r\n\t\t\t\t\t \t\t\t\t{\r\n\t\t\t\t\t \t\t\t\t\tid: \"cityPhoto\",\r\n\t\t\t\t\t \t\t\t\t\tgravity: 2,\r\n\t\t\t\t\t \t\t\t\t\ttemplate: \"<img src=\\\"images/placeimg_arch.jpg\\\"/>\",\r\n\t\t\t\t\t \t\t\t\t\tcss:\"underMenu\",\r\n\t\t\t\t\t \t\t\t\t\tborderless: true\r\n\t\t\t\t\t \t\t\t\t},\r\n\t\t\t\t\t \t\t\t\t{width: 5, css:\"underMenu\"}\r\n\t\t\t\t\t \t\t\t]\t\r\n\t\t\t\t\t \t\t},\r\n\t\t\t\t\t \t\t{height: 1}\r\n\t\t\t \t\t\t]\r\n\t\t\t \t\t},\r\n\t\t\t \t\t{view:\"resizer\"},\r\n\t\t\t \t\t{\r\n\t\t\t\t\t\t\t\t\t\tkey: \"AIzaSyAi0oVNVO-e603aUY8SILdD4v9bVBkmiTg\",\r\n\t\t\t\t\t\t\t \t\tview: \"google-map\",\r\n\t\t\t\t\t\t\t \t\tid: \"googleMap\",\r\n\t\t\t\t\t\t\t \t\tgravity: 2,\r\n\t\t\t\t\t\t\t \t\tminWidth: 200,\r\n\t\t\t\t\t\t\t\t\t\tzoom: 7,\r\n\t\t\t\t\t\t\t\t\t\tcenter: [53.9, 27.5667]\r\n\t\t\t \t\t}\r\n\t\t\t \t]\r\n\t \t\t},\r\n\t \t\t{view:\"resizer\"},\r\n\t \t\t{\r\n\t \t\t\tgravity: 2,\r\n\t \t\t\tview: \"layout\",\r\n\t \t\t\tid: \"chartForecastContainer\",\r\n\t \t\t\tminHeight: 150,\r\n\t\t\t \t\t\t\tcols:[\r\n\t\t\t \t\t{\r\n\t\t\t \t\t\tid: \"chartForecast\",\r\n\t\t\t \t\t\ttemplate: \"\",\r\n\t\t\t \t\t\tcss:\"underMenu\"\r\n\t\t\t \t\t}\r\n\t\t\t \t\t\t\t]\r\n\t \t\t}\r\n\t \t]\r\n\t }\r\n\t ]\r\n\t\t\t}\r\n\t\t]\r\n\t});\r\n\r\n\twebix.ui({\r\n\t\tview: \"sidemenu\",\r\n\t\tid: \"menu\",\r\n\t\twidth: 200,\r\n\t\tposition: \"left\",\r\n\t\tstate: function(state){\r\n\t\t\tvar toolbarHeight = $$(\"toolbar\").$height;\r\n\t\t\tstate.top = toolbarHeight;\r\n\t\t\tstate.height -= toolbarHeight;\r\n\t\t},\r\n\t\tcss: \"my_menu\",\r\n\t\tbody:{\r\n\r\n\t\t\tview: \"list\",\r\n\t\t\tborderless: true,\r\n\t\t\tselect: true,\r\n\t\t\ttype: {\r\n\t\t\t\theight: 40\r\n\t\t\t},\r\n\t\t\ton: {\r\n\t\t\t \"onItemClick\": getWeatherByCityWoeid\r\n\t\t\t},\t\r\n\t\t\ttemplate: \"<span class='webix_icon fa-#icon#'></span> #value#\",\r\n\t\t\tdata: citiesData\r\n\t\t}\r\n\t}).show();\r\n});\r\n"]}