Skip to content

[ADD][BR1228][T24770]Extra time application#210

Open
lonelysun wants to merge 16 commits intoElico-Corp:10.0from
lonelysun:extra_time_application
Open

[ADD][BR1228][T24770]Extra time application#210
lonelysun wants to merge 16 commits intoElico-Corp:10.0from
lonelysun:extra_time_application

Conversation

@lonelysun
Copy link

replace #206
@Elico-Corp/odoo-reviewers

Copy link
Contributor

@elicoidal elicoidal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small details

class ProjectTaskInherit(models.Model):
_inherit = 'project.task'

sub_extra_time = fields.Float(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

better total_extra_time?

current_user = log.env.user
remaining = log.remaining_hours
spending_hours = 0
if not log.env.context.get('flag') and \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

flag?

remaining = log.remaining_hours
spending_hours = 0
if not log.env.context.get('flag') and \
not log.env.context.get('flag_remaine'):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

flag_remaine?

if remaining < 0:
raise UserError(
_(
'The task has no enough time left, '
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no ->not

if not is_exist and self.project_id.user_id != current_user:
raise UserError(
_('You do not have permission to '
'create task belong to this project.'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

belong to -> in

default=_get_task_id, readonly="True"
)
reason = fields.Text('Reason', help='the reason of apply')
apply_hours = fields.Float('Apply Hours', help='the length of apply time')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

help='Duration of applied time extension'

Extra Time Application
======================
This module adds functionality to the application time and
will not allow to add new items if the task time is less than 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

item -> timesheets

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add perido

======================
Extra Time Application
======================
This module adds functionality to the application time and
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This module adds functionality of time application to extend the remaining time in tasks and

This module adds functionality to the application time and
will not allow to add new items if the task time is less than 0

Bug Tracker
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add runbot

@elicoidal
Copy link
Contributor

@seb-elico what about this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants