diff options
| -rw-r--r-- | addons/project/project.py | 6 | ||||
| -rw-r--r-- | addons/project/project_view.xml | 46 | ||||
| -rw-r--r-- | addons/project/static/src/css/project.css | 6 | ||||
| -rw-r--r-- | addons/project_issue/project_issue.py | 2 | ||||
| -rw-r--r-- | addons/project_issue/project_issue_view.xml | 4 | ||||
| -rw-r--r-- | addons/sale_service/models/sale_service.py | 2 | ||||
| -rw-r--r-- | addons/sale_service/views/sale_service_view.xml | 2 | ||||
| -rw-r--r-- | addons/web_kanban/static/src/js/kanban.js | 11 |
8 files changed, 55 insertions, 24 deletions
diff --git a/addons/project/project.py b/addons/project/project.py index 1e76378d5b7..3fe33fbf5c1 100644 --- a/addons/project/project.py +++ b/addons/project/project.py @@ -40,12 +40,12 @@ class project_task_type(osv.osv): _order = 'sequence' _columns = { 'name': fields.char('Stage Name', required=True, translate=True), - 'description': fields.text('Description'), + 'description': fields.text('Description', translate=True), 'sequence': fields.integer('Sequence'), 'case_default': fields.boolean('Default for New Projects', help="If you check this field, this stage will be proposed by default on each new project. It will not assign this stage to existing projects."), 'project_ids': fields.many2many('project.project', 'project_task_type_rel', 'type_id', 'project_id', 'Projects'), - 'legend_priority': fields.text( + 'legend_priority': fields.char( 'Priority Management Explanation', translate=True, help='Explanation text to help users using the star and priority mechanism on stages or issues that are in this stage.'), 'legend_blocked': fields.char( @@ -1245,7 +1245,7 @@ class account_analytic_account(osv.osv): _inherit = 'account.analytic.account' _description = 'Analytic Account' _columns = { - 'use_tasks': fields.boolean('Tasks', help="If checked, this contract will be available in the project menu and you will be able to manage tasks or track issues"), + 'use_tasks': fields.boolean('Tasks', help="Check this box to manage internal activities through this project"), 'company_uom_id': fields.related('company_id', 'project_time_mode_id', string="Company UOM", type='many2one', relation='product.uom'), } diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 8dcf62483f0..5546fa76644 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -93,15 +93,17 @@ <h1> <field name="name" string="Project Name"/> </h1> - <div name="options_active"> + <div name="options_active" class="oe_edit_only"> <div> <field name="use_tasks" class="oe_inline" string="Use Tasks"/> - <label for="use_tasks" class="oe_inline"/> as <field name="label_tasks" class="oe_inline"/> + <label for="use_tasks" class="oe_inline"/> + <span attrs="{'invisible':[('use_tasks', '=', False)]}">as</span> + <field name="label_tasks" class="oe_inline oe_input_align" attrs="{'invisible': [('use_tasks', '=', False)]}"/> </div> </div> </div> <div class="oe_right oe_button_box" name="buttons" groups="base.group_user"> - <button class="oe_inline oe_stat_button" type="action" attrs="{'invisible':[('use_tasks','=', 0)]}" + <button class="oe_inline oe_stat_button" type="action" attrs="{'invisible':[('use_tasks','=', False)]}" name="%(act_project_project_2_project_task_all)d" icon="fa-tasks"> <field string="Tasks" name="task_count" widget="statinfo" options="{'label_field': 'label_tasks'}"/> </button> @@ -501,7 +503,7 @@ <kanban default_group_by="stage_id"> <field name="color"/> <field name="priority"/> - <field name="stage_id" options='{"group_by_tooltip": {"description": "Description", "legend_priority": "Use of stars"}}'/> + <field name="stage_id" options='{"group_by_tooltip": {"description": "Stage Description", "legend_priority": "Use of stars"}}'/> <field name="user_id"/> <field name="user_email"/> <field name="description"/> @@ -720,18 +722,37 @@ <group> <group> <field name="name"/> - <field name="sequence"/> <field name="case_default"/> - <field name="fold"/> + <field name="sequence" groups="base.group_no_one"/> </group> <group> - <field name="legend_blocked"/> - <field name="legend_done"/> - <field name="legend_normal"/> - <field name="legend_priority"/> + <field name="fold"/> </group> </group> - <field name="description" placeholder="Add a description..."/> + <group string="Stage Description and Tooltips"> + <p class="text-muted" colspan="2"> + At each stage employees can block or make task/issue ready for next stage. + You can define here labels that will be displayed for the state instead + of the default labels. + </p> + <label for="legend_normal" string=" " class="oe_kanban_status oe_project_kanban_legend"/> + <field name="legend_normal" nolabel="1"/> + <label for="legend_blocked" string=" " class="oe_kanban_status oe_kanban_status_red oe_project_kanban_legend"/> + <field name="legend_blocked" nolabel="1"/> + <label for="legend_done" string=" " class="oe_kanban_status oe_kanban_status_green oe_project_kanban_legend"/> + <field name="legend_done" nolabel="1"/> + + <p class="text-muted" colspan="2"> + You can also give a tooltip about the use of the stars available in the kanban and form views. + </p> + <label for="legend_priority" string="7" class="oe_e oe_star_on oe_project_kanban_legend"/> + <field name="legend_priority" nolabel="1"/> + + <p class="text-muted" colspan="2"> + You can also add a description to help your coworkers understanding the meaning and purpose of the stage. + </p> + <field name="description" placeholder="Add a description..." nolabel="1" colspan="2"/> + </group> </form> </field> </record> @@ -741,9 +762,10 @@ <field name="model">project.task.type</field> <field name="arch" type="xml"> <tree string="Task Stage"> - <field name="sequence" widget="handle"/> + <field name="sequence" widget="handle" groups="base.group_no_one"/> <field name="name"/> <field name="fold"/> + <field name="description"/> </tree> </field> </record> diff --git a/addons/project/static/src/css/project.css b/addons/project/static/src/css/project.css index 9200e0ebf36..a53ae0d0754 100644 --- a/addons/project/static/src/css/project.css +++ b/addons/project/static/src/css/project.css @@ -41,3 +41,9 @@ .openerp .oe_margin_top_8 { margin-top: 8px; } + +.openerp label.oe_project_kanban_legend { + min-width: inherit !important; + margin-top: 6px; + margin-right: 8px; +} diff --git a/addons/project_issue/project_issue.py b/addons/project_issue/project_issue.py index 8898272b744..87a152a7d4f 100644 --- a/addons/project_issue/project_issue.py +++ b/addons/project_issue/project_issue.py @@ -525,7 +525,7 @@ class account_analytic_account(osv.Model): _description = 'Analytic Account' _columns = { - 'use_issues': fields.boolean('Issues', help="Check this field if this project manages issues"), + 'use_issues': fields.boolean('Issues', help="Check this box to manage customer activities through this project"), } def on_change_template(self, cr, uid, ids, template_id, date_start=False, context=None): diff --git a/addons/project_issue/project_issue_view.xml b/addons/project_issue/project_issue_view.xml index d280981cbcd..b60f09247dc 100644 --- a/addons/project_issue/project_issue_view.xml +++ b/addons/project_issue/project_issue_view.xml @@ -317,7 +317,9 @@ <div> <field name="use_issues" class="oe_inline" string="Use Issues" on_change="on_change_use_tasks_or_issues(use_tasks, use_issues)"/> - <label for="use_issues" class="oe_inline"/> as <field name="label_issues" class="oe_inline"/> + <label for="use_issues" class="oe_inline"/> + <span attrs="{'invisible':[('use_issues', '=', False)]}">as</span> + <field name="label_issues" class="oe_inline oe_input_align" attrs="{'invisible': [('use_issues', '=', False)]}"/> </div> </xpath> <xpath expr='//div[@name="buttons"]' position='inside'> diff --git a/addons/sale_service/models/sale_service.py b/addons/sale_service/models/sale_service.py index 25670b90658..74540d43547 100644 --- a/addons/sale_service/models/sale_service.py +++ b/addons/sale_service/models/sale_service.py @@ -107,7 +107,7 @@ class ProjectTaskStageMrp(osv.Model): _inherit = 'project.task.type' _columns = { - 'closed': fields.boolean('Close', help="Tasks in this stage are considered as closed."), + 'closed': fields.boolean('Is a close stage', help="Tasks in this stage are considered as closed."), } _defaults = { diff --git a/addons/sale_service/views/sale_service_view.xml b/addons/sale_service/views/sale_service_view.xml index d8672579ef0..cd7f5ce5824 100644 --- a/addons/sale_service/views/sale_service_view.xml +++ b/addons/sale_service/views/sale_service_view.xml @@ -29,7 +29,7 @@ <field name="model">project.task.type</field> <field name="inherit_id" ref="project.task_type_edit"/> <field name="arch" type="xml"> - <field name="case_default" position="after"> + <field name="fold" position="after"> <field name="closed"/> </field> </field> diff --git a/addons/web_kanban/static/src/js/kanban.js b/addons/web_kanban/static/src/js/kanban.js index aae0316ecb4..0d9af48e34d 100644 --- a/addons/web_kanban/static/src/js/kanban.js +++ b/addons/web_kanban/static/src/js/kanban.js @@ -728,11 +728,12 @@ instance.web_kanban.KanbanGroup = instance.web.Widget.extend({ }; recurse(this.view.fields_view.arch); if (options && options.group_by_tooltip) { - this.tooltip = _.union( - [this.title], - _.map( - options.group_by_tooltip, - function (key, value, list) { return self.values && self.values[value] || ''; }) + this.tooltip = _.compact( + _.union( + [this.title], + _.map( + options.group_by_tooltip, + function (key, value, list) { return self.values && self.values[value] && (key + "\n" + self.values[value]) || ''; })) ).join('\n\n'); this.$(".oe_kanban_group_title_text").attr("title", this.tooltip || this.title || ""); } |
