Skip to content
Permalink
Browse files

[IMP]

  • Loading branch information...
msh-odoo committed Apr 15, 2019
1 parent 0e0a25c commit 016bb1a21ff5796e18ae84dc14592a3309926bd0
@@ -2040,7 +2040,6 @@ var FieldMany2ManyTags = AbstractField.extend({
elements: elements,
hasDropdown: this.hasDropdown,
readonly: this.mode === "readonly",
title: _t('Tag color:'),
};
},
/**
@@ -20,7 +20,6 @@ var core = require('web.core');
var mvc = require('web.mvc');

var QWeb = core.qweb;
var _t = core._t;

var AbstractController = mvc.Controller.extend(ActionMixin, {
custom_events: {
@@ -381,7 +380,6 @@ var AbstractController = mvc.Controller.extend(ActionMixin, {
var $switchButtons = $(QWeb.render(template, {
viewType: this.viewType,
views: views,
title: _t('View'),
}));
// create bootstrap tooltips
_.each(views, function (view) {
@@ -209,6 +209,7 @@
</t>

<t t-name="ControlPanel.SwitchButton">
<t t-set="title">View</t>
<button type="button" t-att-accesskey="view.accessKey"
t-attf-class="btn btn-secondary fa fa-lg #{view.icon} o_cp_switch_#{view.type} #{viewType === view.type ? ' active' : ''}"
t-attf-aria-label="#{title} #{view.displayName}"
@@ -845,6 +846,7 @@
<t t-name="FieldMany2ManyTag">
<t t-foreach="elements" t-as="el">
<t t-set="color" t-value="el[colorField] || 0"/>
<t t-set="title">Tag color:</t>
<div t-attf-class="badge badge-pill #{hasDropdown ? 'dropdown' : ''} o_tag_color_#{color}" t-att-data-color="color" t-att-data-index="el_index" t-att-data-id="el.id" t-attf-title="#{title} #{colornames[color]}">
<t t-set="_badge_text">
<span class="o_badge_text" t-att-title="el.display_name"><span role="img" t-attf-aria-label="#{title} #{colornames[color]}"/><t t-esc="el.display_name"/></span>
@@ -922,17 +924,20 @@
</t>
<t t-name="FieldStatus.content.button">
<t t-set="disabled" t-value="!clickable"/>
<t t-set="aria_label">is current state</t>
<button type="button" t-att-data-value="i.id" disabled="disabled" title="Current state" aria-pressed="true"
t-attf-class="btn o_arrow_button btn-primary disabled #{is_dropdown ? 'dropdown-item bg-primary text-white': ''}" t-if="i.selected" aria-current="step">
<t t-esc="i.display_name" role="img" t-attf-aria-label="#{i.display_name} is current state"/>
t-attf-class="btn o_arrow_button btn-primary disabled #{is_dropdown ? 'dropdown-item bg-primary text-white': ''}" t-if="i.selected" aria-current="step" t-attf-aria-label="#{i.display_name} #{aria_label}">
<t t-esc="i.display_name" role="img"/>
</button>
<t t-set="aria_label">is not current state</t>
<button type="button" t-att-data-value="i.id" disabled="disabled" title="Not active state" aria-pressed="false"
t-attf-class="btn o_arrow_button btn-secondary disabled #{is_dropdown ? 'dropdown-item': ''}" t-if="!i.selected and disabled">
<t t-esc="i.display_name" role="img" t-attf-aria-label="#{i.display_name} is not current state"/>
t-attf-class="btn o_arrow_button btn-secondary disabled #{is_dropdown ? 'dropdown-item': ''}" t-if="!i.selected and disabled" t-attf-aria-label="#{i.display_name} #{aria_label}">
<t t-esc="i.display_name" role="img"/>
</button>
<t t-set="aria_label">Click to change current state to </t>
<button type="button" t-att-data-value="i.id" title="Not active state, click to change it" aria-pressed="false"
t-attf-class="btn o_arrow_button btn-secondary #{is_dropdown ? 'dropdown-item': ''}" t-if="!i.selected and !disabled">
<t t-esc="i.display_name" role="img" t-attf-aria-label="Click to change current state to #{i.display_name}"/>
t-attf-class="btn o_arrow_button btn-secondary #{is_dropdown ? 'dropdown-item': ''}" t-if="!i.selected and !disabled" t-attf-aria-label="#{aria_label} #{i.display_name}">
<t t-esc="i.display_name" role="img"/>
</button>
</t>
<t t-name="FieldBinaryImage">

0 comments on commit 016bb1a

Please sign in to comment.
You can’t perform that action at this time.