mirror of
https://github.com/OCA/manufacture.git
synced 2025-01-28 16:37:15 +02:00
[9.0][ADD] quality_control_team
This commit is contained in:
committed by
Jordi Ballester Alomar
parent
aaf9694b2f
commit
461af3553e
61
quality_control_team/README.rst
Normal file
61
quality_control_team/README.rst
Normal file
@@ -0,0 +1,61 @@
|
||||
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
|
||||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
||||
:alt: License: AGPL-3
|
||||
|
||||
====================
|
||||
Quality Control Team
|
||||
====================
|
||||
|
||||
This module extends the functionality of Quality Control app to support the
|
||||
use of Quality control teams and to allow you to manage different team flows.
|
||||
|
||||
This module by itself does not provide any functionality to QC teams. It
|
||||
provides the teams basic configuration and a dashboard to be used by other
|
||||
modules.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
To configure this module, you need to:
|
||||
|
||||
#. Go to *Quality Control > Configuration > Quality Control Teams*.
|
||||
|
||||
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
|
||||
:alt: Try me on Runbot
|
||||
:target: https://runbot.odoo-community.org/runbot/129/9.0
|
||||
|
||||
Bug Tracker
|
||||
===========
|
||||
|
||||
Bugs are tracked on `GitHub Issues
|
||||
<https://github.com/OCA/manufacture/issues>`_. In case of trouble, please
|
||||
check there if your issue has already been reported. If you spotted it first,
|
||||
help us smash it by providing detailed and welcomed feedback.
|
||||
|
||||
Credits
|
||||
=======
|
||||
|
||||
Images
|
||||
------
|
||||
|
||||
* Odoo Community Association: `Icon <https://github.com/OCA/maintainer-tools/blob/master/template/module/static/description/icon.svg>`_.
|
||||
|
||||
Contributors
|
||||
------------
|
||||
|
||||
* Lois Rilo <lois.rilo@eficent.com>
|
||||
|
||||
Maintainer
|
||||
----------
|
||||
|
||||
.. image:: https://odoo-community.org/logo.png
|
||||
:alt: Odoo Community Association
|
||||
:target: https://odoo-community.org
|
||||
|
||||
This module is maintained by the OCA.
|
||||
|
||||
OCA, or the Odoo Community Association, is a nonprofit organization whose
|
||||
mission is to support the collaborative development of Odoo features and
|
||||
promote its widespread use.
|
||||
|
||||
To contribute to this module, please visit https://odoo-community.org.
|
||||
5
quality_control_team/__init__.py
Normal file
5
quality_control_team/__init__.py
Normal file
@@ -0,0 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from . import models
|
||||
24
quality_control_team/__openerp__.py
Normal file
24
quality_control_team/__openerp__.py
Normal file
@@ -0,0 +1,24 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
{
|
||||
"name": "Quality Control Team",
|
||||
"summary": "Adds quality control teams to handle different quality "
|
||||
"control workflows",
|
||||
"version": "9.0.1.0.0",
|
||||
"category": "Quality Control",
|
||||
"website": "https://odoo-community.org/",
|
||||
"author": "Eficent, Odoo Community Association (OCA)",
|
||||
"license": "AGPL-3",
|
||||
"application": False,
|
||||
"installable": True,
|
||||
"depends": [
|
||||
"quality_control",
|
||||
],
|
||||
"data": [
|
||||
"security/ir.model.access.csv",
|
||||
"views/qc_team_view.xml",
|
||||
"views/qc_team_dashboard.xml",
|
||||
"data/quality_control_team_data.xml",
|
||||
],
|
||||
}
|
||||
14
quality_control_team/data/quality_control_team_data.xml
Normal file
14
quality_control_team/data/quality_control_team_data.xml
Normal file
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
|
||||
|
||||
<odoo>
|
||||
|
||||
<data noupdate="0">
|
||||
<record model="qc.team" id="qc_team_main">
|
||||
<field name="name">Main QC Team</field>
|
||||
<field name="member_ids" eval="[(4, ref('base.user_root'))]"/>
|
||||
</record>
|
||||
</data>
|
||||
|
||||
</odoo>
|
||||
7
quality_control_team/models/__init__.py
Normal file
7
quality_control_team/models/__init__.py
Normal file
@@ -0,0 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from . import qc_team
|
||||
from . import res_partner
|
||||
from . import res_user
|
||||
61
quality_control_team/models/qc_team.py
Normal file
61
quality_control_team/models/qc_team.py
Normal file
@@ -0,0 +1,61 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from openerp import api, fields, models
|
||||
|
||||
|
||||
class QualityControlTeam(models.Model):
|
||||
_name = "qc.team"
|
||||
_inherit = ['mail.thread', 'ir.needaction_mixin']
|
||||
_description = "Quality Control Team"
|
||||
_order = "name"
|
||||
|
||||
@api.model
|
||||
def _get_default_qc_team_id(self, user_id=None):
|
||||
if not user_id:
|
||||
user_id = self.env.uid
|
||||
qc_team_id = None
|
||||
if 'default_qc_team_id' in self.env.context:
|
||||
qc_team_id = self.env['qc.team'].browse(
|
||||
self.env.context.get('default_qc_team_id'))
|
||||
if not qc_team_id or not qc_team_id.exists():
|
||||
company_id = self.sudo(user_id).company_id.id
|
||||
qc_team_id = self.env['qc.team'].sudo().search([
|
||||
'|',
|
||||
('user_id', '=', user_id),
|
||||
('member_ids', '=', user_id),
|
||||
'|',
|
||||
('company_id', '=', False),
|
||||
('company_id', 'child_of', [company_id])
|
||||
], limit=1)
|
||||
if not qc_team_id:
|
||||
default_team_id = self.env.ref(
|
||||
'quality_control_team.qc_team_main', raise_if_not_found=False)
|
||||
if default_team_id:
|
||||
qc_team_id = default_team_id
|
||||
return qc_team_id
|
||||
|
||||
name = fields.Char(
|
||||
string='Quality Control Team', required=True)
|
||||
active = fields.Boolean(default=True)
|
||||
company_id = fields.Many2one(
|
||||
comodel_name='res.company', string='Company',
|
||||
default=lambda self: self.env['res.company']._company_default_get(
|
||||
'qc.team'))
|
||||
user_id = fields.Many2one(
|
||||
comodel_name='res.users', string='Team Leader')
|
||||
member_ids = fields.One2many(
|
||||
comodel_name='res.users', inverse_name='qc_team_id',
|
||||
string='Team Members')
|
||||
reply_to = fields.Char(
|
||||
string='Reply-To',
|
||||
help="The email address put in the 'Reply-To' of all emails sent by "
|
||||
"Odoo about cases in this QC team")
|
||||
color = fields.Integer(string='Color Index', help="The color of the team")
|
||||
|
||||
@api.model
|
||||
def create(self, values):
|
||||
return super(
|
||||
QualityControlTeam,
|
||||
self.with_context(mail_create_nosubscribe=True)).create(values)
|
||||
12
quality_control_team/models/res_partner.py
Normal file
12
quality_control_team/models/res_partner.py
Normal file
@@ -0,0 +1,12 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from openerp import fields, models
|
||||
|
||||
|
||||
class ResPartner(models.Model):
|
||||
_inherit = 'res.partner'
|
||||
|
||||
qc_team_id = fields.Many2one(
|
||||
comodel_name='qc.team', string='Quality Control Team')
|
||||
12
quality_control_team/models/res_user.py
Normal file
12
quality_control_team/models/res_user.py
Normal file
@@ -0,0 +1,12 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||
|
||||
from openerp import fields, models
|
||||
|
||||
|
||||
class ResUsers(models.Model):
|
||||
_inherit = 'res.users'
|
||||
|
||||
qc_team_id = fields.Many2one(
|
||||
comodel_name='qc.team', string='Quality Control Team')
|
||||
3
quality_control_team/security/ir.model.access.csv
Normal file
3
quality_control_team/security/ir.model.access.csv
Normal file
@@ -0,0 +1,3 @@
|
||||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
access_user_qc_team,qc.team.user,quality_control_team.model_qc_team,quality_control.group_quality_control_user,1,0,0,0
|
||||
access_manager_qc_team,qc.team.manager,quality_control_team.model_qc_team,quality_control.group_quality_control_manager,1,1,1,1
|
||||
|
BIN
quality_control_team/static/description/icon.png
Normal file
BIN
quality_control_team/static/description/icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 7.0 KiB |
95
quality_control_team/static/description/icon.svg
Normal file
95
quality_control_team/static/description/icon.svg
Normal file
@@ -0,0 +1,95 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
id="svg2"
|
||||
version="1.1"
|
||||
inkscape:version="0.91 r"
|
||||
width="256"
|
||||
height="256"
|
||||
viewBox="0 0 256 256"
|
||||
sodipodi:docname="icon.svg"
|
||||
inkscape:export-filename="icon.png"
|
||||
inkscape:export-xdpi="45"
|
||||
inkscape:export-ydpi="45">
|
||||
<metadata
|
||||
id="metadata8">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<defs
|
||||
id="defs6" />
|
||||
<sodipodi:namedview
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1"
|
||||
objecttolerance="10"
|
||||
gridtolerance="10"
|
||||
guidetolerance="10"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:window-width="1855"
|
||||
inkscape:window-height="1056"
|
||||
id="namedview4"
|
||||
showgrid="false"
|
||||
showguides="false"
|
||||
inkscape:zoom="2.6074563"
|
||||
inkscape:cx="97.374622"
|
||||
inkscape:cy="132.02575"
|
||||
inkscape:window-x="65"
|
||||
inkscape:window-y="24"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg2" />
|
||||
<path
|
||||
style="fill:#3b4552;fill-opacity:1;stroke:none;stroke-width:1.93276381"
|
||||
d="m 211.33966,96.067802 c 0,5.992928 7.91763,11.579358 6.74724,17.584548 -1.17039,6.00519 -11.48804,8.10481 -13.8219,13.58637 -2.33386,5.48156 3.54667,14.45202 0.2853,19.35834 -3.26137,4.90632 -13.42612,3.16349 -17.72981,7.43515 -4.30369,4.27166 -2.84179,14.82951 -7.85007,18.16415 -5.00827,3.33464 -14.16074,-2.55764 -19.80601,-0.26061 -5.64527,2.29703 -8.12649,12.89205 -13.9027,13.97052 -5.77621,1.07847 -11.48439,-7.0737 -17.64561,-7.0737 -6.16121,0 -12.25109,7.92446 -18.34832,6.62698 -6.09723,-1.29748 -7.59194,-10.41046 -12.762714,-12.66396 -5.170777,-2.2535 -13.376422,2.91752 -18.36,-0.36786 -4.983578,-3.28538 -5.262182,-14.36977 -9.53734,-18.79261 -4.275158,-4.42285 -12.851882,-1.69906 -16.45127,-7.12771 -3.599388,-5.42865 1.214828,-13.41741 -0.770599,-19.03959 -1.985426,-5.62218 -11.704615,-8.69661 -12.692518,-13.74392 -0.987903,-5.04731 7.500299,-12.47926 7.500299,-18.614887 0,-6.135628 -8.588091,-11.321696 -7.392633,-17.238661 C 39.996464,71.953386 50.643513,69.536 52.904546,64.153032 55.165579,58.770064 48.868664,50.58811 52.15073,45.63683 c 3.282066,-4.951281 13.747588,-4.272318 18.076133,-8.582161 4.328545,-4.309842 2.720858,-13.899039 7.694198,-17.198646 4.97334,-3.299607 13.104622,1.205446 18.503316,-1.022051 5.398693,-2.227496 7.894433,-11.1597399 13.714143,-12.3387556 5.81971,-1.1790158 12.1411,6.0407876 18.24461,6.0407876 6.10351,-1e-6 11.68483,-7.3111077 17.42643,-6.2026403 5.7416,1.1084674 8.13974,10.5614813 13.80595,12.8572833 5.6662,2.295802 14.94429,-2.23592 19.8907,1.108078 4.94641,3.343998 2.48246,11.892283 6.64749,15.99066 4.16503,4.098377 14.62827,3.666275 18.01677,8.682357 3.3885,5.016082 -2.02844,13.500558 0.32346,19.125397 2.3519,5.62484 12.47407,8.60159 13.61721,14.510953 1.14314,5.909363 -6.77148,11.466779 -6.77148,17.45971 z"
|
||||
id="circle3368"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz" />
|
||||
<circle
|
||||
r="63.531616"
|
||||
cy="96.067802"
|
||||
cx="128.38313"
|
||||
id="circle3346"
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:1.34354317" />
|
||||
<circle
|
||||
style="fill:#2b78c2;fill-opacity:1;stroke:none;stroke-width:1.09952056"
|
||||
id="path3342"
|
||||
cx="128.38313"
|
||||
cy="96.067802"
|
||||
r="51.992611" />
|
||||
<path
|
||||
style="fill:#2b78c2;fill-rule:evenodd;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;fill-opacity:1"
|
||||
d="m 83.989904,184.28259 8.053826,-1.24642 c 9.05399,16.12754 16.49528,14.24662 24.0656,13.80656 l -10.83431,53.1169 -14.190079,-13.51892 -18.984019,4.79394 z"
|
||||
id="path3338"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="ccccccc" />
|
||||
<path
|
||||
sodipodi:nodetypes="ccccccc"
|
||||
inkscape:connector-curvature="0"
|
||||
id="path3340"
|
||||
d="m 171.81497,184.37847 -8.05383,-1.24642 c -9.05399,16.12754 -16.49528,14.24662 -24.0656,13.80656 l 10.83431,53.1169 14.19008,-13.51892 18.98402,4.79394 z"
|
||||
style="fill:#2b78c2;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:none"
|
||||
inkscape:transform-center-x="-0.016606677"
|
||||
inkscape:transform-center-y="-4.1513637"
|
||||
d="m 147.10763,127.15966 -18.87851,-10.66672 -19.29578,10.61355 c -2.14644,1.18064 -5.60088,-1.48065 -5.11608,-3.87048 l 4.26518,-21.02547 -15.410855,-14.46528 c -1.952657,-1.832846 -1.388891,-6.342484 1.848072,-6.713162 l 20.920483,-2.395688 9.61304,-20.440593 c 0.75725,-1.610169 4.6613,-2.921345 5.96156,-0.04186 l 9.11939,20.195236 22.68645,2.860817 c 3.08062,0.388473 2.79381,4.411669 1.38356,5.705416 l -16.16599,14.830394 4.28375,22.429 c 0.38417,2.01144 -2.29024,4.63697 -5.21427,2.98484 z"
|
||||
id="path3350"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="scsscsscsscsscss" />
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 5.4 KiB |
100
quality_control_team/views/qc_team_dashboard.xml
Normal file
100
quality_control_team/views/qc_team_dashboard.xml
Normal file
@@ -0,0 +1,100 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<!-- Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
|
||||
|
||||
<record id="qc_team_view_kanban" model="ir.ui.view" >
|
||||
<field name="name">qc.team.dashboard</field>
|
||||
<field name="model">qc.team</field>
|
||||
<field name="arch" type="xml">
|
||||
<kanban class="o_kanban_dashboard oe_background_grey" create="0">
|
||||
<field name="name"/>
|
||||
<field name="user_id"/>
|
||||
<field name="member_ids"/>
|
||||
<field name="color"/>
|
||||
<templates>
|
||||
<t t-name="kanban-box">
|
||||
<div t-attf-class="#{kanban_color(record.color.raw_value)}">
|
||||
<div class="o_kanban_card_header">
|
||||
<div class="o_kanban_card_header_title">
|
||||
<div class="o_primary"><field name="name"/></div>
|
||||
</div>
|
||||
<div class="o_kanban_manage_button_section">
|
||||
<a class="o_kanban_manage_toggle_button" href="#">More <i class="fa fa-caret-down"/></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="container o_kanban_card_content o_visible">
|
||||
<div class="row">
|
||||
<div class="col-xs-6 o_kanban_primary_left" name="to_replace_in_qc_issue"/>
|
||||
<div class="col-xs-6 o_kanban_primary_right"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="container o_kanban_card_manage_pane o_invisible">
|
||||
<div class="row">
|
||||
<!--<div class="col-xs-4 o_kanban_card_manage_section o_kanban_manage_view">-->
|
||||
<!--<div class="o_kanban_card_manage_title">-->
|
||||
<!--<span>View</span>-->
|
||||
<!--</div>-->
|
||||
<!--</div>-->
|
||||
<!--<div class="col-xs-4 o_kanban_card_manage_section o_kanban_manage_new">-->
|
||||
<!--<div class="o_kanban_card_manage_title">-->
|
||||
<!--<span>New</span>-->
|
||||
<!--</div>-->
|
||||
<!--</div>-->
|
||||
<!--<div class="col-xs-4 o_kanban_card_manage_section o_kanban_manage_reports">-->
|
||||
<!--<div class="o_kanban_card_manage_title">-->
|
||||
<!--<span>Reports</span>-->
|
||||
<!--</div>-->
|
||||
<!--</div>-->
|
||||
</div>
|
||||
|
||||
<div t-if="widget.editable" class="o_kanban_card_manage_settings row">
|
||||
<div class="col-xs-8">
|
||||
<ul class="oe_kanban_colorpicker" data-field="color"/>
|
||||
</div>
|
||||
<div class="col-xs-4 text-right">
|
||||
<a type="edit">Settings</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
</templates>
|
||||
</kanban>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="qc_team_search" model="ir.ui.view">
|
||||
<field name="name">Case Teams - Search</field>
|
||||
<field name="model">qc.team</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="QC teams Search">
|
||||
<field name="name"/>
|
||||
<field name="user_id"/>
|
||||
<filter name="personal" string="My Teams"
|
||||
domain="['|', ('member_ids', '=', uid), ('user_id', '=', uid)]"/>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Team Leader" domain="[]" context="{'group_by':'user_id'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="qc_team_dashboard_act" model="ir.actions.act_window">
|
||||
<field name="name">Dashboard</field>
|
||||
<field name="res_model">qc.team</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">kanban,form</field>
|
||||
<field name="context">{'search_default_personal':1}</field>
|
||||
<field name="help" type="html">
|
||||
<p>Define a new quality control teams going to <b><i>Configuration >
|
||||
Quality Control Teams</i></b>.
|
||||
</p>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="menu_qc_team_act" action="qc_team_dashboard_act"
|
||||
sequence="1" parent="quality_control.qc_menu" name="Dashboard"/>
|
||||
|
||||
</odoo>
|
||||
108
quality_control_team/views/qc_team_view.xml
Normal file
108
quality_control_team/views/qc_team_view.xml
Normal file
@@ -0,0 +1,108 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<!-- Copyright 2017 Eficent Business and IT Consulting Services S.L.
|
||||
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
|
||||
|
||||
<record id="qc_team_view_form" model="ir.ui.view">
|
||||
<field name="name">qc.team.form</field>
|
||||
<field name="model">qc.team</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Quality Control Team">
|
||||
<sheet>
|
||||
<div class="oe_title">
|
||||
<label for="name" class="oe_edit_only" string="Quality Control team"/>
|
||||
<h1>
|
||||
<field name="name" placeholder="Quality Control Team name..."/>
|
||||
</h1>
|
||||
<div name="options_active"/>
|
||||
</div>
|
||||
<group>
|
||||
<group name="left">
|
||||
<field name="user_id" context="{'default_groups_ref': ['base.group_user', 'base.group_partner_manager']}"/>
|
||||
</group>
|
||||
<group name="right">
|
||||
</group>
|
||||
</group>
|
||||
<notebook>
|
||||
<page name="members" string="Team Members">
|
||||
<field name="member_ids" widget="many2many_kanban" options="{'not_delete': True}">
|
||||
<kanban quick_create="false" create="true" delete="true">
|
||||
<field name="name"/>
|
||||
<templates>
|
||||
<t t-name="kanban-box">
|
||||
<div class="oe_kanban_global_click" style="position: relative">
|
||||
<a t-if="! read_only_mode" type="delete" style="position: absolute; right: 0; padding: 4px; diplay: inline-block">X</a>
|
||||
<div class="oe_module_vignette">
|
||||
<img t-att-src="kanban_image('res.users', 'image_small', record.id.value)" class="oe_avatar oe_kanban_avatar_smallbox"/>
|
||||
<div class="oe_module_desc">
|
||||
<field name="name"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
</templates>
|
||||
</kanban>
|
||||
</field>
|
||||
</page>
|
||||
<page string="More Info" name="more_info" groups="base.group_no_one">
|
||||
<group>
|
||||
<field name="active"/>
|
||||
</group>
|
||||
<group string="Company" groups="base.group_multi_company">
|
||||
<field name="company_id" options="{'no_create': True}"/>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</sheet>
|
||||
<div class="oe_chatter">
|
||||
<field name="message_follower_ids" widget="mail_followers"
|
||||
help="Follow this QC team to automatically track the events associated to users of this team."/>
|
||||
<field name="message_ids" widget="mail_thread"/>
|
||||
</div>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="qc_team_view_tree" model="ir.ui.view">
|
||||
<field name="name">qc.team.tree</field>
|
||||
<field name="model">qc.team</field>
|
||||
<field name="field_parent">child_ids</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Quality Control Team">
|
||||
<field name="name"/>
|
||||
<field name="active" invisible="1"/>
|
||||
<field name="user_id"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="qc_team_config_action" model="ir.actions.act_window">
|
||||
<field name="name">Quality Control Teams</field>
|
||||
<field name="res_model">qc.team</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="help" type="html">
|
||||
<p class="oe_view_nocontent_create">
|
||||
Click here to define a new quality control team.
|
||||
</p><p>
|
||||
Use quality control team to organize your different
|
||||
departments into separate teams. Each team will work in
|
||||
its own list of processes, stages...
|
||||
</p>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<menuitem name="Configuration"
|
||||
id="quality_control.menu_qc_config"
|
||||
groups="base.group_configuration"
|
||||
parent="quality_control.qc_menu"
|
||||
sequence="100"/>
|
||||
|
||||
<menuitem name="Quality Control Teams"
|
||||
id="qc_team_config_menu"
|
||||
groups="base.group_configuration"
|
||||
parent="quality_control.menu_qc_config"
|
||||
action="qc_team_config_action"
|
||||
sequence="10"/>
|
||||
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user