From 1d58c6ff923ba355b403db042d20870d10994c31 Mon Sep 17 00:00:00 2001 From: KostyaDanovsky Date: Thu, 12 May 2016 11:08:20 +0300 Subject: [PATCH] fix(dashboard): use variables for line color chart --- .../dashboardLineChart/DashboardLineChartCtrl.js | 8 ++++---- src/app/pages/dashboard/popularApp/popularApp1.js | 15 --------------- 2 files changed, 4 insertions(+), 19 deletions(-) delete mode 100644 src/app/pages/dashboard/popularApp/popularApp1.js diff --git a/src/app/pages/dashboard/dashboardLineChart/DashboardLineChartCtrl.js b/src/app/pages/dashboard/dashboardLineChart/DashboardLineChartCtrl.js index 6b65640..ec60d63 100644 --- a/src/app/pages/dashboard/dashboardLineChart/DashboardLineChartCtrl.js +++ b/src/app/pages/dashboard/dashboardLineChart/DashboardLineChartCtrl.js @@ -9,13 +9,13 @@ .controller('DashboardLineChartCtrl', DashboardLineChartCtrl); /** @ngInject */ - function DashboardLineChartCtrl(layoutColors, layoutPaths) { + function DashboardLineChartCtrl(layoutColors, layoutPaths, baUtil) { + var graphColor = layoutColors.primary; var chartData = [ { date: new Date(2012, 11), value: 0, value0: 0 }, { date: new Date(2013, 0), value: 15000, value0: 19000}, { date: new Date(2013, 1), value: 30000, value0: 20000}, - { date: new Date(2013, 2), value: 25000, value0: 22000}, { date: new Date(2013, 3), value: 21000, value0: 25000}, { date: new Date(2013, 4), value: 24000, value0: 29000}, @@ -69,7 +69,7 @@ id: 'g0', bullet: 'none', useLineColorForBulletBorder: true, - lineColor: 'rgba(0, 0, 0, 0.3)', + lineColor: baUtil.hexToRGB(graphColor, 0.3), lineThickness: 1, negativeLineColor: layoutColors.danger, type: 'smoothedLine', @@ -81,7 +81,7 @@ id: 'g1', bullet: 'none', useLineColorForBulletBorder: true, - lineColor: 'rgba(0, 0, 0, 0.4)', + lineColor: baUtil.hexToRGB(graphColor, 0.5), lineThickness: 1, negativeLineColor: layoutColors.danger, type: 'smoothedLine', diff --git a/src/app/pages/dashboard/popularApp/popularApp1.js b/src/app/pages/dashboard/popularApp/popularApp1.js deleted file mode 100644 index 4ad146f..0000000 --- a/src/app/pages/dashboard/popularApp/popularApp1.js +++ /dev/null @@ -1,15 +0,0 @@ -/** - * @author v.lugovksy - * created on 16.12.2015 - */ -(function () { - 'use strict'; - - angular.module('BlurAdmin.pages.dashboard') - .service('popularApp1', popularApp1); - - /** @ngInject */ - function popularApp1() { - - } -})(); \ No newline at end of file