Working on time tracker

This commit is contained in:
Hillel Coren 2017-09-26 09:43:19 +03:00
parent e1581cfc94
commit aa31a03d7b

View File

@ -428,16 +428,14 @@
toastr.options.timeOut = 3000; toastr.options.timeOut = 3000;
toastr.options.positionClass = 'toast-bottom-right'; toastr.options.positionClass = 'toast-bottom-right';
/*
$(window).on('beforeunload', function () { $(window).on('beforeunload', function () {
console.log('beforeunload'); if (navigator.userAgent == 'Time Tracker') {
return undefined;
}
if (model.selectedTask() && model.formChanged()) { if (model.selectedTask() && model.formChanged()) {
console.log('changed'); return "{{ trans('texts.save_or_discard') }}";
swal("{{ trans('texts.save_or_discard') }}");
return false;
//return trans('texts.save_or_discard');
} else { } else {
console.log('not changed');
return undefined; return undefined;
} }
}); });