From d441977a357b336ab3d68f5b65170fdd2958d525 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Sun, 24 Sep 2017 22:44:20 +0300 Subject: [PATCH] Working on time tracker --- resources/lang/en/texts.php | 1 + resources/views/auth/login.blade.php | 10 +++++-- resources/views/tasks/time_tracker.blade.php | 30 +++++++++++++++++++ .../tasks/time_tracker_knockout.blade.php | 5 +++- 4 files changed, 43 insertions(+), 3 deletions(-) diff --git a/resources/lang/en/texts.php b/resources/lang/en/texts.php index d6bcf0a942..2c96584d62 100644 --- a/resources/lang/en/texts.php +++ b/resources/lang/en/texts.php @@ -2453,6 +2453,7 @@ $LANG = array( 'refresh' => 'Refresh', 'filter_sort' => 'Filter/Sort', 'no_description' => 'No Description', + 'time_tracker_login' => 'Time Tracker Login', ); diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.php index 5347df59fd..0e13c9227d 100644 --- a/resources/views/auth/login.blade.php +++ b/resources/views/auth/login.blade.php @@ -10,7 +10,13 @@ ->rules(['email' => 'required|email', 'password' => 'required']) ->addClass('form-signin') !!} -

{{ trans('texts.account_login') }}

+

+ @if (strstr(session('url.intended'), 'time_tracker')) + {{ trans('texts.time_tracker_login') }} + @else + {{ trans('texts.account_login') }} + @endif +


@if (count($errors->all())) @@ -83,7 +89,7 @@ {!! Former::close() !!} - @if(Utils::allowNewAccounts()) + @if (Utils::allowNewAccounts() && ! strstr(session('url.intended'), 'time_tracker'))

{{trans('texts.not_a_member_yet')}}

diff --git a/resources/views/tasks/time_tracker.blade.php b/resources/views/tasks/time_tracker.blade.php index de9d0506c8..be1a9b7eae 100644 --- a/resources/views/tasks/time_tracker.blade.php +++ b/resources/views/tasks/time_tracker.blade.php @@ -62,6 +62,24 @@ .list-group-item-type7:before { background-color: #a87821; } .list-group-item-type8:before { background-color: #676767; } + body { + /* Margin bottom by footer height */ + margin-bottom: 60px; + } + + .footer { + position: fixed; + bottom: 0; + width: 100%; + height: 60px; + background-color: #313131; + color: white; + border-top-width: 3px; + border-top-color: #aaa; + border-top-style: ridge; + } + + @stop @@ -196,6 +214,12 @@
+ + @include('tasks.time_tracker_knockout') diff --git a/resources/views/tasks/time_tracker_knockout.blade.php b/resources/views/tasks/time_tracker_knockout.blade.php index 3b7f903c1a..f78336809e 100644 --- a/resources/views/tasks/time_tracker_knockout.blade.php +++ b/resources/views/tasks/time_tracker_knockout.blade.php @@ -171,6 +171,10 @@ }, 1000); } + self.statistics = ko.computed(function() { + return 'tst'; + }); + self.showArchive = ko.computed(function() { var task = self.selectedTask(); if (! task) { @@ -521,7 +525,6 @@ } self.age = ko.computed(function() { - model.clock(); // bind to the clock if (! self.time_log().length) { return ''; }