From ae75220b88f7901985bd36ac502fd2e0f7260e35 Mon Sep 17 00:00:00 2001 From: projectsodoo Date: Mon, 8 Mar 2021 19:45:15 +0530 Subject: [PATCH] Start and end time removed in xml file --- cor_custom/models/analytic.py | 5 ++--- cor_custom/views/analytic_view.xml | 6 ------ 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/cor_custom/models/analytic.py b/cor_custom/models/analytic.py index d369386..f2efbc2 100755 --- a/cor_custom/models/analytic.py +++ b/cor_custom/models/analytic.py @@ -16,6 +16,8 @@ class AccountAnalyticLine(models.Model): #start_time = fields.Float(string='Start Time', digits=(16, 2)) #end_time = fields.Float(string='End Time', digits=(16, 2)) + start_datetime = fields.Datetime("Start Time", required=True) + end_datetime = fields.Datetime("End Time", required=True) unit_amount = fields.Float('Duration', default=0.0) parent_project = fields.Many2one('project.project', related='project_id.parent_project', string='Parent Project') @@ -26,9 +28,6 @@ class AccountAnalyticLine(models.Model): def _default_end_datetime(self): return fields.Datetime.to_string(datetime.combine(fields.Datetime.now(), datetime.max.time())) - start_datetime = fields.Datetime("Start Time", required=True) - end_datetime = fields.Datetime("End Time", required=True) - # @api.onchange('project_id') # def _onchange_parent_project_id(self): diff --git a/cor_custom/views/analytic_view.xml b/cor_custom/views/analytic_view.xml index 0ba5947..5957cde 100755 --- a/cor_custom/views/analytic_view.xml +++ b/cor_custom/views/analytic_view.xml @@ -21,8 +21,6 @@ - - @@ -73,8 +71,6 @@ widget="task_with_hours" context="{'default_project_id': project_id}" domain="[('project_id', '=', project_id)]"/> - - - -