@ -0,0 +1,21 @@ |
|||
Project Task Timer v14 |
|||
====================== |
|||
Task Timer with Start & Stop |
|||
|
|||
Installation |
|||
============ |
|||
- www.odoo.com/documentation/13.0/setup/install.html |
|||
- Install our custom addon |
|||
|
|||
Configuration |
|||
============= |
|||
|
|||
No additional configurations needed |
|||
|
|||
Credits |
|||
======= |
|||
Developer: Jesni Banu v10 @ cybrosys, Contact: odoo@cybrosys.com |
|||
Kavya Raveendran v11 @ cybrosys, Contact: odoo@cybrosys.com |
|||
Kavya Raveendran v12 @ cybrosys, Contact: odoo@cybrosys.com |
|||
Sreejith sasidharan v13 @ cybrosys, Contact: odoo@cybrosys.com |
|||
Minhaj T v14 @ cybrosys, Contact: odoo@cybrosys.com |
@ -0,0 +1,21 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################## |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# Copyright (C) 2017-TODAY Cybrosys Technologies(<http://www.cybrosys.com>). |
|||
# Author: Jesni Banu(<http://www.cybrosys.com>) |
|||
# you can modify it under the terms of the GNU LESSER |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
|
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU LESSER GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE |
|||
# GENERAL PUBLIC LICENSE (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################## |
|||
|
|||
from . import models |
@ -0,0 +1,40 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################## |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# Copyright (C) 2017-TODAY Cybrosys Technologies(<http://www.cybrosys.com>). |
|||
# Author: Jesni Banu(<http://www.cybrosys.com>) |
|||
# you can modify it under the terms of the GNU LESSER |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
|
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU LESSER GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE |
|||
# GENERAL PUBLIC LICENSE (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################## |
|||
{ |
|||
'name': 'Project Task Timer', |
|||
'version': '14.0.1.0.0', |
|||
'summary': """Task Timer With Start & Stop""", |
|||
'description': """"This module helps you to track time sheet in project automatically.""", |
|||
'category': 'Project', |
|||
'author': 'Cybrosys Techno Solutions', |
|||
'company': 'Cybrosys Techno Solutions', |
|||
'website': "http://www.cybrosys.com", |
|||
'depends': ['base', 'project', 'hr_timesheet'], |
|||
'data': [ |
|||
'views/project_task_timer_view.xml', |
|||
'views/project_timer_static.xml', |
|||
], |
|||
'images': ['static/description/banner.png'], |
|||
'license': 'AGPL-3', |
|||
'demo': [], |
|||
'installable': True, |
|||
'auto_install': False, |
|||
'application': False, |
|||
} |
@ -0,0 +1,4 @@ |
|||
## Module <project_task_timer> |
|||
|
|||
#### 03.10.2020 |
|||
#### Version 14.0.1.0.0 |
@ -0,0 +1,21 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################## |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# Copyright (C) 2017-TODAY Cybrosys Technologies(<http://www.cybrosys.com>). |
|||
# Author: Jesni Banu(<http://www.cybrosys.com>) |
|||
# you can modify it under the terms of the GNU LESSER |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
|
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU LESSER GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE |
|||
# GENERAL PUBLIC LICENSE (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################## |
|||
|
|||
from . import project_task_timer |
@ -0,0 +1,84 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################## |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# Copyright (C) 2017-TODAY Cybrosys Technologies(<http://www.cybrosys.com>). |
|||
# Author: Jesni Banu(<http://www.cybrosys.com>) |
|||
# you can modify it under the terms of the GNU LESSER |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
|
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU LESSER GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU LESSER GENERAL PUBLIC LICENSE |
|||
# GENERAL PUBLIC LICENSE (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################## |
|||
from datetime import datetime |
|||
from odoo import models, fields, api |
|||
|
|||
|
|||
class ProjectTaskTimeSheet(models.Model): |
|||
_inherit = 'account.analytic.line' |
|||
|
|||
date_start = fields.Datetime(string='Start Date') |
|||
date_end = fields.Datetime(string='End Date', readonly=1) |
|||
timer_duration = fields.Float(invisible=1, string='Time Duration (Minutes)') |
|||
|
|||
|
|||
class ProjectTaskTimer(models.Model): |
|||
_inherit = 'project.task' |
|||
|
|||
task_timer = fields.Boolean(string='Timer', default=False) |
|||
is_user_working = fields.Boolean( |
|||
'Is Current User Working', compute='_compute_is_user_working', |
|||
help="Technical field indicating whether the current user is working. ") |
|||
duration = fields.Float( |
|||
'Real Duration', compute='_compute_duration', store=True) |
|||
|
|||
def _compute_duration(self): |
|||
self |
|||
|
|||
def _compute_is_user_working(self): |
|||
""" Checks whether the current user is working """ |
|||
for order in self: |
|||
if order.timesheet_ids.filtered(lambda x: (x.user_id.id == self.env.user.id) and (not x.date_end)): |
|||
order.is_user_working = True |
|||
else: |
|||
order.is_user_working = False |
|||
|
|||
@api.model |
|||
@api.constrains('task_timer') |
|||
def toggle_start(self): |
|||
if self.task_timer is True: |
|||
self.write({'is_user_working': True}) |
|||
time_line = self.env['account.analytic.line'] |
|||
for time_sheet in self: |
|||
time_line.create({ |
|||
'name': self.env.user.name + ': ' + time_sheet.name, |
|||
'task_id': time_sheet.id, |
|||
'user_id': self.env.user.id, |
|||
'project_id': time_sheet.project_id.id, |
|||
'date_start': datetime.now(), |
|||
}) |
|||
else: |
|||
self.write({'is_user_working': False}) |
|||
time_line_obj = self.env['account.analytic.line'] |
|||
domain = [('task_id', 'in', self.ids), ('date_end', '=', False)] |
|||
for time_line in time_line_obj.search(domain): |
|||
time_line.write({'date_end': fields.Datetime.now()}) |
|||
if time_line.date_end: |
|||
diff = fields.Datetime.from_string(time_line.date_end) - fields.Datetime.from_string( |
|||
time_line.date_start) |
|||
time_line.timer_duration = round(diff.total_seconds() / 60.0, 2) |
|||
time_line.unit_amount = round(diff.total_seconds() / (60.0 * 60.0), 2) |
|||
else: |
|||
time_line.unit_amount = 0.0 |
|||
time_line.timer_duration = 0.0 |
|||
|
|||
|
|||
|
|||
|
After Width: | Height: | Size: 90 KiB |
After Width: | Height: | Size: 22 KiB |
After Width: | Height: | Size: 58 KiB |
After Width: | Height: | Size: 91 KiB |
After Width: | Height: | Size: 86 KiB |
After Width: | Height: | Size: 67 KiB |
After Width: | Height: | Size: 62 KiB |
After Width: | Height: | Size: 70 KiB |
After Width: | Height: | Size: 15 KiB |
After Width: | Height: | Size: 51 KiB |
After Width: | Height: | Size: 740 KiB |
After Width: | Height: | Size: 84 KiB |
After Width: | Height: | Size: 99 KiB |
After Width: | Height: | Size: 94 KiB |
After Width: | Height: | Size: 88 KiB |
@ -0,0 +1,308 @@ |
|||
<div class="row" style="margin: 0;position: relative;color: #000;background-position: center;background: #ffffff;border-bottom: 1px solid #e4e4e4;text-align: center; margin: auto; display: flex;justify-content: center;"> <a href="https://www.cybrosys.com/" target="_blank"><img src="images/cybrosys.png" style=" width: 293px; padding: 1rem 0rem; margin: auto" alt="cybrosys-logo"></a> </div> |
|||
<div class="row" style="margin:75px 0;position: relative;color: #000;background-position: center;background: #ffffff;border-bottom: 1px solid #e4e4e4; padding-bottom: 30px;"> |
|||
<div class="col-md-7 col-sm-12 col-xs-12" style="padding: 0px"> |
|||
<div style=" margin: 0 0 0px;padding: 20px 0 10;font-size: 23px;line-height: 35px;font-weight: 400;color: #000;border-top: 1px solid rgba(255,255,255,0.1);border-bottom: 1px solid rgba(255,255,255,0.11);text-align: left;"> |
|||
<h1 style="font-size: 39px;font-weight: 600;margin: 0px !important;">Project Task Timer</h1> |
|||
<h3 style="font-size: 21px;margin-top: 8px;position: relative;">Task Timer with Start & Stop</h3> |
|||
</div> |
|||
<h2 style="font-weight: 600;font-size: 1.8rem;margin-top: 15px;">Key Highlights</h2> |
|||
<ul style=" padding: 0 1px; list-style: none; "> |
|||
<li style="display: flex;align-items: center;padding: 8px 0;font-size: 18px;"><i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i>Timer in Task.</li> |
|||
<li style="display: flex;align-items: center;padding: 8px 0;font-size: 18px;"><i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i> Automatic Timesheet Calculation. </li> |
|||
</ul> |
|||
</div> |
|||
<div class="col-md-5 col-sm-12 col-xs-12"> <img src="images/task_timer.gif" class="img-responsive" alt=""> </div> |
|||
</div> |
|||
<div> |
|||
<section class="oe_container" style="padding: 1rem 0rem 1rem; background-color: #ffffff !important;"> |
|||
<div class="row py-4 px-3"> |
|||
<div class="w-100" style="padding-top:30px;padding-bottom:45px;border-radius: 10px;"> |
|||
<ul role="tablist" class="nav nav-pills justify-content-center" data-tabs="tabs" id="pills-tab" style="border: none;background: unset;"> |
|||
<li class="nav-item mr-1 mb-3" style="font-size: 1.05rem;font-weight: 400;transition: all .15s ease;color: #d31c22;background-color: #d31c22;box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);border: 0;font-family: 'Open Sans',sans-serif;width: 140px;border-radius: 0.30rem;"> <a id="pills-home-tab" data-toggle="pill" href="#pills-home" role="tab" aria-controls="pills-home" aria-selected="true" class="nav-link active show" style="color: #000000;line-height: 33px;border: 0;border-radius: .25rem;font-weight: 400;text-align: center; |
|||
color: #fff;">Overview </a> </li> |
|||
<li class="nav-item mr-1 mb-3" style="font-size: 1.05rem;font-weight: 400;transition: all .15s ease;color: #d31c22;background-color: #d31c22;box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);border: 0;font-family: 'Open Sans',sans-serif;width: 140px;border-radius: 0.30rem;"> <a id="pills-home-tab" data-toggle="pill" href="#pills-home1" role="tab" aria-controls="pills-home" aria-selected="true" class="nav-link " style="color: #000000;line-height: 33px;border: 0;border-radius: .25rem;font-weight: 400; text-align: center; |
|||
color: #fff;" >Features </a> </li> |
|||
<li class="nav-item mr-1 mb-3" style="font-size: 1.05rem;font-weight: 400;transition: all .15s ease;color: #ffffff;background-color: #d31c22;box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);border: 0;font-family: 'Open Sans',sans-serif;width: 140px;border-radius: 0.30rem;"> <a class="nav-link" id="pills-profile-tab" data-toggle="pill" href="#pills-profile" role="tab" aria-controls="pills-profile" aria-selected="false" style="color: #000000;line-height: 33px;border: 0;border-radius: .25rem;font-weight: 400; text-align: center; |
|||
color: #fff;">Screenshots </a> </li> |
|||
<li class="nav-item mr-1 mb-3" style="font-size: 1.05rem;font-weight: 400;transition: all .15s ease;color: #ffffff;background-color: #d31c22;box-shadow: 0 4px 6px rgba(50,50,93,.11), 0 1px 3px rgba(0,0,0,.08);border: 0;font-family: 'Open Sans',sans-serif;width: 140px;border-radius: 0.30rem;"> <a class="nav-link" id="pills-profile-tab" data-toggle="pill" href="#pills-video" role="tab" aria-controls="pills-profile" aria-selected="false" style="color: #000000;line-height: 33px;border: 0;border-radius: .25rem;font-weight: 400; text-align: center; |
|||
color: #fff;">Video </a> </li> |
|||
</ul> |
|||
<div class="tab-content" id="pills-tabContent" |
|||
style="padding-top: 30px; padding-bottom: 30px; padding: 30px;"> |
|||
<div class="px-3 pt-1 tab-pane fade active show" id="pills-home" role="tabpanel" aria-labelledby=" |
|||
pills-home-tab"> |
|||
<!-- Overview--> |
|||
<h2 style="font-weight: 600;text-align: center;width: 100%;">Overview</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<h3 class="oe_slogan" style="text-align: center;font-size: 19px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;opacity: 1 !important;line-height: 31px;font-weight: 400;letter-spacing: .5px;margin-bottom: 21px;"> |
|||
You have a toggle button to start & stop your task and record your actual working hours. When you start your task timer, you get a notification, alongside a time sheet entry with starting time that is automatically generated by the timer for that particular task. When you toggle it to stop, the task’s end date shall be updated and the duration gets automatically calculated. |
|||
</h3> |
|||
</div> |
|||
<div class="px-3 pt-1 tab-pane fade " id="pills-home1" role="tabpanel" aria-labelledby=" |
|||
pills-home-tab"> |
|||
<!-- feature tab--> |
|||
<h2 style="font-weight: 600;text-align: center;width: 100%;">Project Task Timer</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<ul> |
|||
<p class="mb8" style="font-family: Roboto;color: #000;list-style-type: square;font-size: 19px;line-height: 50px; background-color: #3a34380d;padding-left: 20px;border-radius: 7px;list-style: none;"> |
|||
<i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i>Timer in Task. |
|||
</p> |
|||
<p class="mb8" style="font-family: Roboto;color: #000;list-style-type: square;font-size: 19px;line-height: 50px; background-color: #3a34380d;padding-left: 20px;border-radius: 7px;list-style: none;"> |
|||
<i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i>Notification when starting the Timer. |
|||
</p> |
|||
<p class="mb8" style="font-family: Roboto;color: #000;list-style-type: square;font-size: 19px;line-height: 50px; background-color: #3a34380d;padding-left: 20px;border-radius: 7px;list-style: none;"> |
|||
<i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i>Automatic Timesheet Calculation. |
|||
</p> |
|||
</ul> |
|||
</div> |
|||
<!-- Screenshot tab--> |
|||
<div class="px-3 tab-pane fade" id="pills-profile" role="tabpanel" aria-labelledby="pills-profile-tab" > |
|||
<div class="tab-pane"> |
|||
<h2 style="font-weight: 600;text-align: center;width: 100%;">Screenshots</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<div> |
|||
<section class="oe_container"> |
|||
<div id="demo" class="row carousel slide mb32" data-ride="carousel"> |
|||
<div class="carousel-inner"> |
|||
<div class="carousel-item active" style="min-height: 0px;"> |
|||
<div class="col-xs-12 col-sm-12 col-md-12 mb16 mt16" style="float: left;"> |
|||
<h3 class="alert" style="font-weight:400;color: #091E42;background: #fff;text-align: left;border-radius: 0; font-size: 18px;"> <i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i> After installation, open Projects and go to any task.</h3> |
|||
<div style=""> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/task_timerV13_1.png"> </div> |
|||
</div> |
|||
</div> |
|||
|
|||
<div class="carousel-item" style="min-height: 0px;"> |
|||
<div class="col-xs-12 col-sm-12 col-md-12 mb16 mt16" style="float: left;"> |
|||
<h3 class="alert" style="font-weight:400;color: #091E42;background: #fff;text-align: left;border-radius: 0; font-size: 18px;"> <i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i> Enable the timer. You can see the timer is running and a notification indicating starting of the timer.</h3> |
|||
<div style=""> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/task_timerV13_2.png"> </div> |
|||
</div> |
|||
</div> |
|||
|
|||
<div class="carousel-item" style="min-height: 0px;"> |
|||
<div class="col-xs-12 col-sm-12 col-md-12 mb16 mt16" style="float: left;"> |
|||
<h3 class="mb32 alert" style="font-weight:400;color: #091E42;background: #fff;text-align: left;border-radius: 0; font-size: 18px; "> <i class="fa fa-check-circle-o" style="width:40px; color:#07B700"></i> While disabling the timer, you can see the automated timesheet entries.</h3> |
|||
<div style=""> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/task_timerV13_3.png"> </div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<a class="carousel-control-prev" href="#demo" data-slide="prev" style="left:-25px;width: 35px;color: #000;"> <span class="carousel-control-prev-icon"><i class="fa fa-chevron-left" style="font-size:24px"></i></span> </a> <a class="carousel-control-next" href="#demo" data-slide="next" style="right:-25px;width: 35px;color: #000;"> <span class="carousel-control-next-icon"><i class="fa fa-chevron-right" style="font-size:24px"></i></span> </a> |
|||
</div> |
|||
</section> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<div class="px-3 pt-1 tab-pane fade" id="pills-video" role="tabpanel" aria-labelledby=" |
|||
pills-home-tab"> |
|||
<!-- Video--> |
|||
<h2 style="font-weight: 600;text-align: center;width: 100%;">Video</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<center> |
|||
<p>Project Task Timer Demo</p> |
|||
<!--<a href="https://www.youtube.com/watch?v=57QWXrMYe84&feature=youtu.be" target="_blank"> <img src="addon-youtube.png" style="width:80%;"></a>--> |
|||
<div class="s_panel_video" data-video-id="7PFB7FpMFyM?rel=0" style="cursor:pointer;"> |
|||
<img class="img-fluid s_tooltip_tabs_tooltip_image s_figure_link pb0" src="images/task_timer_youtube.png" alt="Cybrosys Cover Video" style="max-width:100%;"> |
|||
</div> |
|||
</center> |
|||
</div> |
|||
<!-- faq tab--> |
|||
<div class="px-2 px-lg-4 pt-3 tab-pane fade" id="pills-contact" role="tabpanel" aria-labelledby="pills-contact-tab"> |
|||
<ul class="list-unstyled"> |
|||
</ul> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</section> |
|||
<section class="oe_container" style="padding: 2rem 3rem 1rem;"> |
|||
<h2 style="font-weight: 600;text-align: center;margin-bottom: 25px;width: 100%;">Suggested Products</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<div id="demo1" class="row carousel slide" data-ride="carousel"> |
|||
<!-- The slideshow --> |
|||
<div class="carousel-inner"> |
|||
<div class="carousel-item active" style="min-height: 0px;"> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/12.0/project_report_pdf/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_project_report_xls_pdf.png"> </div> |
|||
</a> |
|||
</div> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/10.0/project_status_level_report/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_project_status_report.png"> </div> |
|||
</a> |
|||
</div> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/10.0/project_lifeline/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_lifeline_for_task.jpeg"> </div> |
|||
</a> |
|||
</div> |
|||
</div> |
|||
<div class="carousel-item" style="min-height: 0px;"> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/10.0/project_subtask/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_subtask.jpeg"> </div> |
|||
</a> |
|||
</div> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/12.0/task_deadline_reminder/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_task_deadline_reminder.jpeg"> </div> |
|||
</a> |
|||
</div> |
|||
<div class="col-xs-12 col-sm-4 col-md-4 mb16 mt16" style="float: left;"> |
|||
<a href="https://apps.odoo.com/apps/modules/10.0/project_time_spend/" target="_blank"> |
|||
<div style="box-shadow: 0 15px 35px rgba(50, 50, 93, 0.1), 0 5px 15px rgba(0, 0, 0, 0.07);border-radius: 10px;"> <img class="img img-responsive center-block" style="border-top-left-radius: 10px;border-top-right-radius: 10px;" src="images/banner_task_statusbar.jpeg"> </div> |
|||
</a> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<!-- Left and right controls --> |
|||
<a class="carousel-control-prev" href="#demo1" data-slide="prev" style="left:-25px;width: 35px;color: #000;"> <span class="carousel-control-prev-icon"><i class="fa fa-chevron-left" style="font-size:24px"></i></span> </a> <a class="carousel-control-next" href="#demo1" data-slide="next" style="right:-25px;width: 35px;color: #000;"> <span class="carousel-control-next-icon"><i class="fa fa-chevron-right" style="font-size:24px"></i></span> </a> |
|||
</div> |
|||
</section> |
|||
<section class="row" style="padding: 2rem 3rem 1rem;margin:0px"> |
|||
<h2 style="font-weight: 600;margin-bottom: 20px;text-align: center;width: 100%;">Our Service</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<div class="row" style=" display: flex; justify-content: center; flex-wrap: wrap;width: 100%; "> |
|||
<!-- <div style="display:flex;padding-top: 20px;justify-content: space-between;"> --> |
|||
<div class="col-md-2 col-sm-6 col-xs-12"> |
|||
<div style="width:75px;height:75px;background:#fff; border-radius:100%;margin: auto;"> <a href="https://www.cybrosys.com/odoo-customization-and-installation/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-customization.png" style="width: 100%;border-radius: 100%;"/> </a> </div> |
|||
<h3 class="oe_slogan" style="font-weight: 800;text-align: center;font-size: 14px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;"> <a href="https://www.cybrosys.com/odoo-customization-and-installation/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Odoo Customization </a> </h3> |
|||
</div> |
|||
<div class="col-md-2 col-sm-6 col-xs-12"> |
|||
<div style="width:75px;height:75px;background:#fff; border-radius:100%;margin: auto;"> <a href="https://www.cybrosys.com/odoo-erp-implementation/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-erp-implementation.png" style="width: 100%;border-radius: 100%;"/> </a> </div> |
|||
<h3 class="oe_slogan" style="font-weight: 800;text-align: center;font-size: 14px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;"> <a href="https://www.cybrosys.com/odoo-erp-implementation/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Odoo Implementation </a> </h3> |
|||
</div> |
|||
<div class="col-md-2 col-sm-6 col-xs-12"> |
|||
<div style="width:75px;height:75px;background:#fff; border-radius:100%;margin: auto;"> <a href="https://www.cybrosys.com/odoo-erp-integration/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-erp-integration.png" style="width: 100%;border-radius: 100%;"/> </a> </div> |
|||
<h3 class="oe_slogan" style="font-weight: 800;text-align: center;font-size: 14px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;"> <a href="https://www.cybrosys.com/odoo-erp-integration/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Odoo Integration </a> </h3> |
|||
</div> |
|||
<div class="col-md-2 col-sm-6 col-xs-12"> |
|||
<div style="width:75px;height:75px;background:#fff; border-radius:100%;margin: auto;"> <a href="https://www.cybrosys.com/odoo-erp-support/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-erp-support.png" style="width: 100%;border-radius: 100%;"/> </a> </div> |
|||
<h3 class="oe_slogan" style="font-weight: 800;text-align: center;font-size: 14px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;"> <a href="https://www.cybrosys.com/odoo-erp-support/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Odoo Support</a> </h3> |
|||
</div> |
|||
<div class="col-md-2 col-sm-6 col-xs-12"> |
|||
<div style="width:75px;height:75px;background:#fff; border-radius:100%;margin: auto;"> <a href="https://www.cybrosys.com/hire-odoo-developer/" target="_blank"> <img src="https://www.cybrosys.com/images/hire-odoo-developer.png" style="width: 100%;border-radius: 100%;"/> </a> </div> |
|||
<h3 class="oe_slogan" style="font-weight: 800;text-align: center;font-size: 14px;width: 100%;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;"> <a href="https://www.cybrosys.com/hire-odoo-developer/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Hire Odoo Developers</a> </h3> |
|||
</a> |
|||
</div> |
|||
<!-- </div> --> |
|||
</div> |
|||
</section> |
|||
<section class="row" style="padding: 2rem 3rem 1rem;margin:0px"> |
|||
<div class="row" style="margin: 0"> |
|||
<h2 style="font-weight: 600;margin-bottom: 20px;text-align: center;width: 100%;">Our Industries</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<!-- <div style="display:flex;justify-content: space-between;flex-wrap:wrap;"> --> |
|||
<div class="row" style="width: 100%"> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/best-trading-erp/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-1.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/best-trading-erp/" target="_blank" style="list-style: none; color:#000; text-decoration: none;font-family: 'Montserrat',sans-serif;"> Trading </a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px; font-family: 'Montserrat',sans-serif;"> Easily procure and sell your products. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/manufacturing-erp-software/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-2.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;" style=" margin-bottom: 10px; "> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/manufacturing-erp-software/" target="_blank" style="list-style: none; color:#000; text-decoration: none;font-family: 'Montserrat',sans-serif;"> Manufacturing</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px;font-family: 'Montserrat',sans-serif;"> Plan, track and schedule your operations. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/restaurant-management/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-3.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/restaurant-management/" target="_blank" style="list-style: none; color:#000; text-decoration: none;font-family: 'Montserrat',sans-serif;"> Restaurant</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px;font-family: 'Montserrat',sans-serif;"> Run your bar or restaurant methodical. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/pos/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-4.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/pos/" target="_blank" style="list-style: none; color:#000; text-decoration: none;font-family: 'Montserrat',sans-serif;"> POS</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px;font-family: 'Montserrat',sans-serif;"> Easy configuring and convivial selling. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/ecommerce-website/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-5.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 0px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/ecommerce-website/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> E-commerce & Website</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px; font-family: 'Montserrat',sans-serif;"> Mobile friendly, awe-inspiring product pages. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/hotel-management-erp/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-6.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/hotel-management-erp/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Hotel Management</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px; font-family: 'Montserrat',sans-serif;"> An all-inclusive hotel management application. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/education-erp-software/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-7.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/education-erp-software/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Education</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px; font-family: 'Montserrat',sans-serif;"> A Collaborative platform for educational management. </h3> |
|||
</div> |
|||
</div> |
|||
<div class="col-md-4 col-sm-6 col-xs-12" style=" margin-bottom: 10px; "> |
|||
<div > |
|||
<div style="width:75px;height:75px;background:#CE2D48; border-radius:100%;float: left;text-align: left;"> <a href="https://www.cybrosys.com/odoo/industries/service-management/" target="_blank"> <img src="https://www.cybrosys.com/images/odoo-index-industry-8.png" alt="Odoo Industry" style=" border-radius: 100%;width:100%;"/> </a> </div> |
|||
</div> |
|||
<div style="width:70%;float:left;"> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 14px;font-weight:800;width: auto;margin: 0;margin-top: 14px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 4px;margin-left: 16px;"> <a href="https://www.cybrosys.com/odoo/industries/service-management/" target="_blank" style="list-style: none; color:#000; text-decoration: none; font-family: 'Montserrat',sans-serif;"> Service Management</a> </h3> |
|||
<h3 class="oe_slogan" style=" text-align: left;font-size: 12px;width: auto;margin: 0;margin-top:5px;color: #000 !important;margin-top: 5px;opacity: 1 !important;line-height: 17px;float: left;margin-top: 5px;margin-left: 16px; font-family: 'Montserrat',sans-serif;"> Keep track of services and invoice accordingly. </h3> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</section> |
|||
<section class="oe_container" style="padding: 0% 0% 6% 0%;"> |
|||
<center> |
|||
<div class="col-md-12" style="margin: auto !important; |
|||
width: 70%; |
|||
padding: 30px;"> |
|||
<h2 style="font-weight: 600;text-align: center;width: 100%;">Need Any Help?</h2> |
|||
<hr style="margin-top: 0px;margin-bottom: 2%;border: 0;text-align: center;border-top: 3px solid #d21c22;width: 5%;"> |
|||
<h4 style="font-size:16px;"> If you have anything to share with us based on your use of this module, please let us know. We are ready to offer our support. </h4> |
|||
<div class="col-md-6" style="float:left; padding:20px;"> |
|||
<h4><i class="fa fa-envelope"></i>Email us </h4> |
|||
<p>odoo@cybrosys.com / info@cybrosys.com</p> |
|||
</div> |
|||
<div class="col-md-6" style="float:left; padding:20px;"> |
|||
<h4><i class="fa fa-phone"></i> Contact Us </h4> |
|||
<a href="https://www.cybrosys.com/contact/" target="_blank"> www.cybrosys.com</a> |
|||
</div> |
|||
</div> |
|||
</center> |
|||
</section> |
|||
<section class="oe_container" style="padding: 0% 0% 6% 0%;"> |
|||
<div class="oe_slogan" style="margin-bottom: 0px;"> |
|||
<div style=" display: flex; justify-content: center; flex-wrap: wrap; "> |
|||
</div> |
|||
<br> |
|||
<img src="https://www.cybrosys.com/images/logo.png" style="width: 190px; margin-bottom: 25px;margin-top: 30px;" class="center-block"> |
|||
<div style=" display: flex; justify-content: center; flex-wrap: wrap; "> <a href="https://twitter.com/cybrosys" target="_blank"><i class="fa fa-2x fa-twitter" style="color:white;background: #00a0d1;width:35px;height: 35px;padding-top: 7px;font-size: 21px;margin-right: 6px;border-radius: 100%;"></i></a> |
|||
</td> |
|||
<a href="https://www.linkedin.com/company/cybrosys-technologies-pvt-ltd" target="_blank"><i class="fa fa-2x fa-linkedin" style="color:white;background: #31a3d6;width:35px;height: 35px;padding-top: 7px;font-size: 21px;margin-right: 6px;border-radius: 100%;"></i></a> |
|||
</td> |
|||
<a href="https://www.facebook.com/cybrosystechnologies" target="_blank"><i class="fa fa-2x fa-facebook" style="color:white;background: #3b5998;width:35px; height: 35px;padding-top: 7px;font-size: 21px;margin-right: 6px;border-radius: 100%;"></i></a> |
|||
</td> |
|||
<a href="https://in.pinterest.com/cybrosys" target="_blank"><i class="fa fa-2x fa-pinterest" style="color:white;background: #ac0f18;width:35px;height: 35px;padding-top: 7px;font-size: 21px;margin-right: 6px;border-radius: 100%;"></i></a> |
|||
</td> |
|||
</div> |
|||
</div> |
|||
</section> |
|||
</div> |
@ -0,0 +1,70 @@ |
|||
odoo.define('project_task_timer.timer', function (require) { |
|||
"use strict"; |
|||
var AbstractField = require('web.AbstractField'); |
|||
var core = require('web.core'); |
|||
var field_registry = require('web.field_registry'); |
|||
var time = require('web.time'); |
|||
var FieldManagerMixin = require('web.FieldManagerMixin'); |
|||
|
|||
var _t = core._t; |
|||
|
|||
// $(document).on('click','#timer', function(){
|
|||
// if ($(this).hasClass('btn-secondary'))
|
|||
// { $(this).removeClass('btn-secondary');
|
|||
// $(this).addClass('btn-primary');
|
|||
// }
|
|||
// });
|
|||
|
|||
var TimeCounter = AbstractField.extend({ |
|||
|
|||
willStart: function () { |
|||
var self = this; |
|||
var def = this._rpc({ |
|||
model: 'account.analytic.line', |
|||
method: 'search_read', |
|||
domain: [['task_id', '=', this.res_id], ['user_id', '=', self.record.context['uid']]], |
|||
}).then(function (result) { |
|||
if (self.mode === 'readonly') { |
|||
var currentDate = new Date(); |
|||
self.duration = 0; |
|||
_.each(result, function (data) { |
|||
self.duration += data.date_end ? |
|||
self._getDateDifference(data.date_start, data.date_end): |
|||
self._getDateDifference(time.auto_str_to_date(data.date_start), currentDate); |
|||
}); |
|||
} |
|||
}); |
|||
return $.when(this._super.apply(this, arguments), def); |
|||
}, |
|||
destroy: function () { |
|||
this._super.apply(this, arguments); |
|||
clearTimeout(this.timer); |
|||
}, |
|||
isSet: function () { |
|||
return true; |
|||
}, |
|||
_getDateDifference: function (dateStart, dateEnd) { |
|||
return moment(dateEnd).diff(moment(dateStart)); |
|||
}, |
|||
|
|||
_render: function () { |
|||
this._startTimeCounter(); |
|||
}, |
|||
_startTimeCounter: function () { |
|||
var self = this; |
|||
clearTimeout(this.timer); |
|||
if (this.record.data.is_user_working) { |
|||
this.timer = setTimeout(function () { |
|||
self.duration += 1000; |
|||
self._startTimeCounter(); |
|||
}, 1000); |
|||
} else { |
|||
clearTimeout(this.timer); |
|||
} |
|||
this.$el.html($('<span>' + moment.utc(this.duration).format("HH:mm:ss") + '</span>')); |
|||
}, |
|||
}); |
|||
field_registry.add('timesheet_uoms', TimeCounter); |
|||
}); |
|||
|
|||
|
@ -0,0 +1,46 @@ |
|||
<?xml version="1.0" encoding="utf-8"?> |
|||
<odoo> |
|||
<data> |
|||
<record id="project_task_timer_inherit_view" model="ir.ui.view"> |
|||
<field name="name">project task timer</field> |
|||
<field name="model">project.task</field> |
|||
<field name="inherit_id" ref="project.view_task_form2"/> |
|||
<field name="arch" type="xml"> |
|||
<xpath expr="//field[@name='tag_ids']" position="after"> |
|||
<label for="task_timer"/> |
|||
<div class="o_row" style="display: inline-block;"> |
|||
<field name="task_timer" widget="boolean_toggle"/> |
|||
</div> |
|||
</xpath> |
|||
<xpath expr="//div[@name='button_box']" position="inside"> |
|||
<div style="margin-top:10px;"> |
|||
<widget name="web_ribbon" text="Started" |
|||
attrs="{'invisible': [('task_timer', '=', False)]}"/> |
|||
</div> |
|||
</xpath> |
|||
</field> |
|||
</record> |
|||
|
|||
<record id="project_task_timer_inherit_view1" model="ir.ui.view"> |
|||
<field name="name">project task timer1</field> |
|||
<field name="model">project.task</field> |
|||
<field name="inherit_id" ref="project_task_timer.project_task_timer_inherit_view"/> |
|||
<field name="arch" type="xml"> |
|||
<xpath expr="//field[@name='timesheet_ids']/tree/field[@name='unit_amount']" position="before"> |
|||
<field name="date_start" required="1"/> |
|||
<field name="date_end"/> |
|||
<field name="timer_duration" invisible="1"/> |
|||
</xpath> |
|||
<xpath expr="//field[@name='progress']" position="after"> |
|||
<field name="is_user_working" invisible="1"/> |
|||
<label for="duration"/> |
|||
<div> |
|||
<button style="pointer-events: none;" class="oe_inline label label-default"> |
|||
<field name="duration" id="duration" widget="timesheet_uoms" style="color: red;" /> |
|||
</button> |
|||
</div> |
|||
</xpath> |
|||
</field> |
|||
</record> |
|||
</data> |
|||
</odoo> |
@ -0,0 +1,8 @@ |
|||
<?xml version="1.0" encoding="UTF-8"?> |
|||
<odoo> |
|||
<template id="assets_backend1" name="web_widget_color assets1" inherit_id="web.assets_backend"> |
|||
<xpath expr="." position="inside"> |
|||
<script type="text/javascript" src="/project_task_timer/static/src/js/timer.js"></script> |
|||
</xpath> |
|||
</template> |
|||
</odoo> |