Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIG] business_requirement: Migration to v12 #315

Merged
merged 44 commits into from Jul 23, 2019

Conversation

victormmtorres
Copy link
Collaborator

victor and others added 30 commits June 26, 2019 19:23
	new file:   business_requirement/README.rst
	new file:   business_requirement/__init__.py
	new file:   business_requirement/__openerp__.py
	new file:   business_requirement/data/business_data.xml
	new file:   business_requirement/models/__init__.py
	new file:   business_requirement/models/business.py
	new file:   business_requirement/security/ir.model.access.csv
	new file:   business_requirement/security/security.xml
	new file:   business_requirement/static/description/icon.png
	new file:   business_requirement/static/img/bus_req.png
	new file:   business_requirement/static/img/bus_req_alias.png
	new file:   business_requirement/static/img/bus_req_approved.png
	new file:   business_requirement/static/img/bus_req_cancel.png
	new file:   business_requirement/static/img/bus_req_confirmed.png
	new file:   business_requirement/static/img/bus_req_cust_story.png
	new file:   business_requirement/static/img/bus_req_done.png
	new file:   business_requirement/static/img/bus_req_drop.png
	new file:   business_requirement/static/img/bus_req_module_diag.png
	new file:   business_requirement/static/img/bus_req_tags.png
	new file:   business_requirement/static/img/bus_req_tags2.png
	new file:   business_requirement/static/img/bus_req_tree.png
	new file:   business_requirement/static/img/module_diag.graphml
	new file:   business_requirement/tests/__init__.py
	new file:   business_requirement/tests/test_br.py
	new file:   business_requirement/views/business_view.xml
	new file:   business_requirement/wizards/__init__.py
	new file:   business_requirement/wizards/mail_compose_message.py

[FIX] Comments lines and Rst File
	modified:   business_requirement/README.rst
	modified:   business_requirement/models/business.py
Improved README and removed the part that is to be in repo README
GitHub comments for inheritance message_post method to modify subject.
New fields for the review and request BR meaning.
Improve the message meaning for the status to be useful for internal projects
and not only for customer oriented projects.
	modified:   business_requirement/__init__.py
	modified:   business_requirement/models/business.py
	modified:   business_requirement/views/business_view.xml

[REM] business_requirement: Cause it's not longer necessary to inherit
the wizard I remove from the repository.
	deleted:    business_requirement/wizards/__init__.py
	deleted:    business_requirement/wizards/mail_compose_message.py
If confirmed the user can't modify the first tab (story/scenario/gap)
but can still change the second one (Other information).
If approved, the user can't change the first and second tab.
	modified:   business_requirement/models/business.py

[IMP] business_requirement: Modify business requirement categories
to be simplify the name to "Categories".
Change business requirement "description" to full screen wide.
	modified:   business_requirement/models/business.py
	modified:   business_requirement/views/business_view.xml

[IMP] business_requirement: Change Text field by Html to avoid use Html widget on the view.
Remove sequence field on the Tree view. Next version will use sequence for the Kanban view.
	modified:   business_requirement/models/business.py
	modified:   business_requirement/views/business_view.xml

[FIX] business_requirement: Change some model functions name to follow guideline
and remove not necessary isolated functions.
	modified:   business_requirement/models/business.py
[FIX] business_requirement: Update README to correct runbot address + figure
…BR. (OCA#17)

* [IMP] business_requirement: Improvement on master project related to BR.
	modified:   business_requirement/__openerp__.py
	modified:   business_requirement/models/__init__.py
	new file:   business_requirement/models/project.py
	new file:   business_requirement/views/project.xml

* [FIX] business_requirement: Increase Coverall regards the new model inherited.
	modified:   business_requirement/tests/__init__.py
	new file:   business_requirement/tests/test_project.py

* [FIX] business_requirement: Modify style and format for python and xml files.
	modified:   business_requirement/models/project.py
	modified:   business_requirement/views/project.xml

* [FIX] business_requirement: Fix version number.
	modified:   business_requirement/__openerp__.py

* [FIX] business_requirement: Fix format on XML attributes for views.
	modified:   business_requirement/views/project.xml
[IMP] business_requirement

* Improved and unified the README for the br_deliverable module
* Modified the openerp.py too remove unused images
* Finetuning
* Remove oca.cfg

Update image link as they where not visible in app

link to this issue: OCA/maintainer-tools#221
@ pedro can we FT this one?

Added double image handling

testing OCA/maintainer-tools#221
This PR only updates module business_requirement.
Other affected modules will be fixed with separate PRs.
Fixes OCA#36 (business_requirement).

[8.0] business-requirement: fix link in README.rst

[IMP] Added reference and name_get for Business Requirement

In tests use / for the default ref value
[FIX] fix the business_requirement super method message_post didnt pass parameters
Need to add Stakeholder Group for this State Approval.
	modified:   business_requirement/__openerp__.py
	modified:   business_requirement/security/security.xml
	modified:   business_requirement/views/business_view.xml
* [FIX]Move when button to generate the project appears. It should get displayed when the stage is set to Stakeholder approval (rename to Approved by Stakeholders)

* [FIX]Move when button to generate the project appears. It should get displayed when the stage is set to Stakeholder approval (rename to Approved by Stakeholders)

* [Fix] Fix unit test

* [IMP] Improved the UT to fix the Travis.

* [IMP] Improved UT for increase Code Coverage.

* [IMP] Added UT to increase coveralls.

* [IMP] Added UT to increase coveralls.

* [IMP] Added UT to increase coveralls.

* [FIX] stakeholder_approval

* [FIX] stakeholder_approval
[IMP] Changed Workflow.
Need to add reponsible and reviewers.
Responsible should be required and populate on upgrade version
Reviewers are users who are involved on the BR process

[FIX][business_requirement] Name formating improvement (OCA#116)

* [FIX] business_requirement
To fix OCA#114

* [FIX] business_requirement
Fix name_get method as peer code review comments
Need to force string to unicode before replace
…CA#105)

* [IMP] Transfer the Gross Profit fields to the Deliverable lines

* [IMP] Changed calculation for Gross Profit.

* [IMP]Transfer the Gross Profit fields to the Deliverable lines

* [ADD]Added Description field

* [IMP] Improved code as per comment.

* [IMP]changed the position of the fields.

* [IMP] Improved code as per comment.

* [IMP]Improved pivot views.

* [FIX] Fixed Travis & Changed code as per comments.

* [FIX] made requested changes.

[ADD][business_requirement] Added To be reviewed field in BR (OCA#120)

* [ADD]Added To be reviewed field in BR

* [IMP] Improved form view as per requirement.

* [IMP] Improved code as per comment.

* [FIX] Fixed issues.

* [IMP]Improved Code.

* [IMP] IMproved code.
[IMP]Improved BR-fields position (OCA#166)

* [IMP]Improved BR-fields position

* exchanged requested and responsible

[IMP]default sort on BR list (OCA#167)

[FIX] kanban state editable in BR (OCA#169)

[IMP][BR1030][22333]-Modify layout of BR Form view (OCA#210)
* [FIX] Fixed order in tree view.

* [FIX] Fixed order
* [8.0][BR1030][ADD][Reference field improvements]

* [IMP]Improved code
…e or Description in m2o fields (OCA#203)

* [IMP] Added code to search BR based on Name or Description in m2o fields.

* [IMP] Added UT to improved code coverage.

* [IMP] Modified the variables names as per GIT review.

[8.0-i190] [ADD] Added filter in BR search to allow user to search BR from Name or Description. (OCA#220)
…CA#192)

* [IMP][8.0][22070][ISSUE#115]-Improved code as per changes

* [IMP]Improved domain and added copy=False in linked_project

* [ADD/IMP]Linked Project with BR and DL with Smartbutton

* [IMP]Improved code

* [IMP]Count number of linked project in BR,removed count function and veriable from project

* [IMP]Improved method name

* [FIX]Fix Travis

* [IMP]Improved code

* [IMP]Improved code

* [IMP] Improved method name to field
* [IMP][I215][BR1030]Set Default Values

* [IMP]Improved test-cases
* [WIP]:Added Demo Data.

* [ADD]:Added demo data.

* [ADD]Added demo datas for BR modules

* [REM]Removed unnecessary demo data

* [IMP]Improved Demo datas

* [WIP/IMP]Improved demo data code

* [IMP]Improved code as per commments

* [IMP]Improved demo data

* [IMP/ADD]Improved Code and Added Products Demo data for Resource lines

* [IMP]Update noupdate = 1

* [IMP]Demo data improvements.

* [IMP]Improved demo data

* [IMP]Improved demo data as per comment

* [IMP]Improved code

* [IMP]Sale order on draft stage

* [IMP]Improved code

* [IMP]Modified Demo data file name

* [IMP]Improved Identation
* [8.0][IMP]-Improved Origin field

* [IMP]Improved field Type for Origin field

[8.0]-IMP-Stages as clickable in BR (OCA#227)

* [IMP]Added Stages as clickble removed buttons

* [IMP]Improved code

* [IMP]Improved code

* [IMP]Improved code

* [Added docstring in readgroup method]
moved to __manifest__.py
* [MIG]Migrated Business requirement module from 8.0 to 10.0

* [FIX]Fix Pylint

* [IMP]Added new blankline in security file

* [IMP]Added Test-Cases for Coverage

* [IMP]Added report,improved fields in py and xml

* [IMP]Improved code

* [IMP] Removed default dimensions from pivot view

* [FIX]Fixed Pylint

* [IMP]Improved code

* [IMP]Improved code

* [FIX]Fixed Travis

* [IMP]Test-cases Improved

* [IMP]Improved view as per OCA standards

* [IMP]Improved assert in test-cases

* [IMP]-Added assertEqual in test-cases

* [IMP]Improved Test-cases

* [IMP]Improved Code as per OCA Standard in XML

* [IMP/REM]Cover whole BR-code and removed unnecessary test-cases.

* [IMP]Cover test-cases default_comany function
@pedrobaeza
Copy link
Member

Please install locally first before proposing here, as the module doesn't install.

@victormmtorres
Copy link
Collaborator Author

@pedrobaeza sorry but that. Indeed I had to change and test quite before push force again

@victormmtorres
Copy link
Collaborator Author

@Tardo @pedrobaeza please review

grps = self.env.user.groups_id.ids
date = fields.Datetime.now()
if vals['state'] == 'confirmed':
vals.update({'confirmed_user_id': user,
Copy link
Member

Choose a reason for hiding this comment

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

'user' is an model object, not a record.

business_requirement/models/business.py Outdated Show resolved Hide resolved
return super(BusinessRequirement, self).write(vals)

@api.model
def _selection_get_states(self):
Copy link
Member

Choose a reason for hiding this comment

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

I don't understand why need this having 'selection_add' on fields.Selection?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@Tardo I never used this. I tried and is not working. I checked where is used on others examples and always for inherited models so it's to add states as the name suggest.

The point of have a function is split states definition from field definition but no necessary to do it for sure

Copy link
Member

Choose a reason for hiding this comment

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

Please remove this method and put directly selection=[('draft', 'Draft'), ...]

@victormmtorres
Copy link
Collaborator Author

Changes done @Tardo

business_requirement/__init__.py Outdated Show resolved Hide resolved
business_requirement/__manifest__.py Outdated Show resolved Hide resolved
business_requirement/models/__init__.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/tests/__init__.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
@victormmtorres
Copy link
Collaborator Author

Changes done @Tardo

@victormmtorres
Copy link
Collaborator Author

@pedrobaeza Could you do a final review in order to merge?

business_requirement/data/business_requirement_demo.xml Outdated Show resolved Hide resolved
business_requirement/data/business_requirement_demo.xml Outdated Show resolved Hide resolved
business_requirement/data/business_requirement_demo.xml Outdated Show resolved Hide resolved
return super(BusinessRequirement, self).write(vals)

@api.model
def _selection_get_states(self):
Copy link
Member

Choose a reason for hiding this comment

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

Please remove this method and put directly selection=[('draft', 'Draft'), ...]

business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/security/security.xml Show resolved Hide resolved
@victormmtorres
Copy link
Collaborator Author

Changes done @pedrobaeza

business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
business_requirement/models/business.py Outdated Show resolved Hide resolved
@victormmtorres
Copy link
Collaborator Author

Changes done @Tardo @pedrobaeza

@pedrobaeza pedrobaeza merged commit 2098463 into OCA:12.0 Jul 23, 2019
@pedrobaeza pedrobaeza deleted the 12.0-mig-business-requirement branch July 23, 2019 17:51
@OCA-git-bot OCA-git-bot mentioned this pull request Jul 23, 2019
5 tasks
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.

None yet