Merge lp:~openerp-dev/openobject-addons/6.0-task-progressbar-ado into lp:openobject-addons/6.0

Proposed by Amit Dodiya (OpenERP)
Status: Needs review
Proposed branch: lp:~openerp-dev/openobject-addons/6.0-task-progressbar-ado
Merge into: lp:openobject-addons/6.0
Diff against target: 13 lines (+2/-1)
1 file modified
project/project.py (+2/-1)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/6.0-task-progressbar-ado
Reviewer Review Type Date Requested Status
Amit Dodiya (OpenERP) (community) Needs Resubmitting
Jay Vora (Serpent Consulting Services) (community) Needs Fixing
Review via email: mp+68045@code.launchpad.net
To post a comment you must log in.
4711. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4712. By Priyesh (OpenERP)

[MERGE] Merged SKH's branch to fix the format of Email in base_action_rule. Email always has to given in double quotes (). (Case:6122)

4713. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4714. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4715. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4716. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4717. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Valecia's branch for the fix of bad assignation of lot to finished products

4718. By Priyesh (OpenERP)

[MERGE] Merged IRA's branch to fix the 'AttributeError' If pricelist is not present in partner in sale order(case:16233)

4719. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Priyesh' branch for the fix of warning should be displayed when split of lot is done in wrong manner in the context of quantity

4720. By Jay Vora (Serpent Consulting Services)

[MERGE] Merge from Parent branch

4721. By Anup(SerpentCS)

[MERGE] Merged Lorenzo's branch for the fix of Tax Creation of type Balance through chart of accounts

4722. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Anup's branch for the fix of making some accounting reports translatable

4723. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4724. By Priyesh (OpenERP)

[MERGE] Merged ADO's branch to fix the AttributeError in the absence of Analytic account in Payslip(case:16091)

4725. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4726. By Jay Vora (Serpent Consulting Services)

[FIX] Translation conflicts resolved

4727. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4728. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4729. By Jay Vora (Serpent Consulting Services)

[MERGE] Stock : Correction on splitting moves by setting proper UoS qty.

4730. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged from Parent branch

4731. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4732. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged ADO's branch for the fix of call to is_zero() of currency object (case 16227)

4733. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4734. By Priyesh (OpenERP)

[MERGE] Merged OLT's branch to improve few usability issues and to fix the issue of onchange of partner and address(case:6051,16421)

4735. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4736. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4737. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4738. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4739. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4740. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4741. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4742. By Quentin (OpenERP) <email address hidden>

[MERGE] opw 5852

4743. By Anup(SerpentCS)

[Merge]account_vooucher : Merged My Branch to fix the regression in bank statement when importing supplier invoice

4744. By Anup(SerpentCS)

[MERGE] thunderbird : Merged Ravi's branch for fixing thunderbird issue(Case:16137)

4745. By Jay Vora (Serpent Consulting Services)

[FIX] Sale : Set taxes to be null on the onchange of Product

4746. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4747. By Anup(SerpentCS)

[MERGE] sale : Merged Ravi's branch for Picking policy reconfigure issue

4748. By Anup(SerpentCS)

[FIX] account : Merged my branch for account profit loss report fix(Case:5583)

4749. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Priyesh' branch for the fix of onchange() of analytic account inside analytic line while analytic_user_function is installed

4750. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4751. By Priyesh (OpenERP)

[MERGE] Merged my branch to improve _debit_credit_bal_qtty method of analytic account for passing the related field name instead of all fields (case:16550)

4752. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Valencia's branch for the fix of computation of company contribution in Payslip

4753. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Olivier Dony's branch to correct the stock reservation algorithm

4754. By Valencia Rodrigues (OpenERP)

[FIX] Sale_Layout : Corrected the RML and SXW for the layout report which was failing due to wrong conditions note

4755. By Priyesh (OpenERP)

[MERGE] Merged IRA's branch to improve calculation of taxes while invoicing(case:16152)

4756. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4757. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4758. By Priyesh (OpenERP)

[MERGE] Merged ADO's branch to fix the Keyerror: 'Amount' coming when Taxtype is defined as 'None' (case:16655)

4759. By Quentin (OpenERP) <email address hidden>

[FIX] crm_partner_assign: quick and dirty hack to switch latitude and longitude fields, as they are stored in wrong fields and we need to preserve database schema for existing instances. In trunk we will fix that in the right way.

4760. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4761. By Anup(SerpentCS)

[FIX] product : Merged Nehal's branch for UoM warning

4762. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4763. By Marco(Bremskerl)

[MERGE] Merged Marco(Bremskerl)'s branch for Purchase order report fixes(Case:16747)

4764. By Priyesh (OpenERP)

[MERGE] Merged ADO's branch to fetch the correct note of Payment term in Sale order report(case:16743)

4765. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4766. By Quentin (OpenERP) <email address hidden>

[FIX] account_voucher: 'currency_id' field doesn't exist in account.journal object, it's 'currency'

4767. By Anup(SerpentCS)

[MERGE] hr_timesheet : Merged Mohammed's branch for signin/signout wizard view fixes

4768. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4769. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4770. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4771. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4772. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4773. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4774. By Jay Vora (Serpent Consulting Services)

[FIX] Account_voucher : Fixed the onchange_date method which was missing the checking of context initially

4775. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4776. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4777. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Rifakat's branch for the fix of delivery report not printing the name when product has no code

4778. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4779. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4780. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4781. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4782. By Anup(SerpentCS)

[Merge] crm_*,project_*,hr_recruitment,mail_gateway: Merged my branch for the issue of Internal note(Case:16976)

4783. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4784. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4785. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4786. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4787. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4788. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4789. By Priyesh (OpenERP)

[MERGE] Merged My branch to fix the AssertionError of Fields in 'groupby' must appear in the list of fields to read(case:16819)

4790. By Quentin (OpenERP) <email address hidden>

[FIX] account, taxes report: removal of the option to print the report based on payment, as it seems we can't really do it. On the suggestion from fp and luc (c2c)

4791. By Quentin (OpenERP) <email address hidden>

[FIX] sale: backport of revision 3164.118.785 from trunk branch, to fix picked rate on SO

4792. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4793. By Priyesh (OpenERP)

[MERGE] Merged RHA's branch to fix the problem of showing inactive employees in Holidays report per department.(case:17104)

4794. By Anup(SerpentCS)

[MERGE] thunderbird,outlook : Merged Ravi's branch for documentation link fix(Case:17190)

4795. By Anup(SerpentCS)

[MERGE] thunderbird : Merged Ravi's branch for thunderbird push mail with accented chars fix(Case:16766)

4796. By Jay Vora (Serpent Consulting Services)

[MERGE] Merged Valencia's branch for the fix of creation of menu from wiki group(case 17204)

4797. By Jay Vora (Serpent Consulting Services)

[FIX] Hr_payroll,hr_payroll_account : Corrected the views and used xpath tag

4798. By Launchpad Translations on behalf of openerp

Launchpad automatic translations update.

4799. By Priyesh (OpenERP)

[IMP] account_voucher: Fixed AttributeError: 'bool' object has no attribute 'replace' in the absenece of number and activated sequence in payment journal of Voucher(case:17229)

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Amit,

Good catch.

Can you please improve it to look like this?

progress_rate = 100.0 * hours.get(task.id, 0.0) / res[task.id]['total_hours']
progress_rate = round(min(progress_rate, 100.0), 2)

Thanks to you and Olivier Dony for approval.

review: Needs Fixing
4800. By Amit Dodiya (OpenERP)

[FIX]:Project Task Progress Bar's Values

Revision history for this message
Amit Dodiya (OpenERP) (ado-openerp) wrote :

Hello Sir,

I have done the changes as per your suggestion.

Thanks,
Amit

review: Needs Resubmitting

Unmerged revisions

4800. By Amit Dodiya (OpenERP)

[FIX]:Project Task Progress Bar's Values

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'project/project.py'
2--- project/project.py 2011-01-18 22:45:39 +0000
3+++ project/project.py 2011-08-31 10:42:17 +0000
4@@ -327,7 +327,8 @@
5 res[task.id]['delay_hours'] = res[task.id]['total_hours'] - task.planned_hours
6 res[task.id]['progress'] = 0.0
7 if (task.remaining_hours + hours.get(task.id, 0.0)):
8- res[task.id]['progress'] = round(min(100.0 * hours.get(task.id, 0.0) / res[task.id]['total_hours'], 99.99),2)
9+ progress_rate = 100.0 * hours.get(task.id, 0.0) / res[task.id]['total_hours']
10+ res[task.id]['progress'] = round(min(progress_rate, 100.0), 2)
11 if task.state in ('done','cancelled'):
12 res[task.id]['progress'] = 100.0
13 return res