diff options
| author | qsm-odoo <qsm@odoo.com> | 2018-05-25 17:43:04 +0200 |
|---|---|---|
| committer | qsm-odoo <qsm@odoo.com> | 2018-07-27 12:36:54 +0200 |
| commit | ee65b44d9e51f380e1b6978485e466b5720df215 (patch) | |
| tree | 21eb0acaadea0c87cb4bc4de88c481d38b273001 | |
| parent | f7cee83cb890b5f4fea7c1c2399082df2bd3fb66 (diff) | |
[REF] *: BS4, adapt the label component structure
The '.label' elements have been replaced by '.badge' elements without
the 'badge-pill' class.
54 files changed, 167 insertions, 167 deletions
diff --git a/addons/account/views/account_payment_view.xml b/addons/account/views/account_payment_view.xml index c39c1d3c68e..51c26e49583 100644 --- a/addons/account/views/account_payment_view.xml +++ b/addons/account/views/account_payment_view.xml @@ -70,7 +70,7 @@ <field name="amount" widget='monetary'/> </div> <div class="col-6"> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state" widget="kanban_label_selection" options="{'classes': {'draft': 'default', 'sent': 'success'}}"/> </span> </div> diff --git a/addons/account/views/account_portal_templates.xml b/addons/account/views/account_portal_templates.xml index f5501228169..543f2b5a9f7 100644 --- a/addons/account/views/account_portal_templates.xml +++ b/addons/account/views/account_portal_templates.xml @@ -48,13 +48,13 @@ <td class='d-none d-md-table-cell'><span t-field="invoice.date_due"/></td> <td class="tx_status"> <t t-if="invoice.state == 'open'"> - <span class="label label-info"><i class="fa fa-fw fa-clock-o" aria-label="Opened" title="Opened" role="img"></i><span class="d-none d-md-inline"> Waiting for Payment</span></span> + <span class="badge badge-info"><i class="fa fa-fw fa-clock-o" aria-label="Opened" title="Opened" role="img"></i><span class="d-none d-md-inline"> Waiting for Payment</span></span> </t> <t t-if="invoice.state == 'paid'"> - <span class="label label-default"><i class="fa fa-fw fa-check" aria-label="Paid" title="Paid" role="img"></i><span class="d-none d-md-inline"> Paid</span></span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-check" aria-label="Paid" title="Paid" role="img"></i><span class="d-none d-md-inline"> Paid</span></span> </t> <t t-if="invoice.state == 'cancel'"> - <span class="label label-default"><i class="fa fa-fw fa-remove" aria-label="Cancelled" title="Cancelled" role="img"></i><span class="d-none d-md-inline"> Cancelled</span></span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-remove" aria-label="Cancelled" title="Cancelled" role="img"></i><span class="d-none d-md-inline"> Cancelled</span></span> </t> </td> <td><span t-esc="-invoice.residual if invoice.type == 'out_refund' else invoice.residual" t-options='{"widget": "monetary", "display_currency": invoice.currency_id}'/></td> diff --git a/addons/account_payment/views/account_portal_templates.xml b/addons/account_payment/views/account_portal_templates.xml index 16c471649b7..3f1270a124a 100644 --- a/addons/account_payment/views/account_portal_templates.xml +++ b/addons/account_payment/views/account_portal_templates.xml @@ -17,19 +17,19 @@ <t t-set="last_tx" t-value="invoice.get_portal_last_transaction()"/> <td class="tx_status"> <t t-if="invoice.state == 'open' and (last_tx.state not in ['pending', 'authorized', 'done', 'cancel'] or (last_tx.state == 'pending' and last_tx.acquirer_id.provider in ('transfer', 'manual')))"> - <span class="label label-info"><i class="fa fa-fw fa-clock-o"></i><span class="d-none d-md-inline"> Waiting for Payment</span></span> + <span class="badge badge-info"><i class="fa fa-fw fa-clock-o"></i><span class="d-none d-md-inline"> Waiting for Payment</span></span> </t> <t t-if="invoice.state == 'open' and last_tx.state == 'authorized'"> - <span class="label label-success"><i class="fa fa-fw fa-check"/><span class="d-none d-md-inline"> Authorized</span></span> + <span class="badge badge-success"><i class="fa fa-fw fa-check"/><span class="d-none d-md-inline"> Authorized</span></span> </t> <t t-if="invoice.state == 'open' and last_tx.state == 'pending' and last_tx.acquirer_id.provider not in ('transfer', 'manual')"> - <span class="label label-warning"><span class="d-none d-md-inline"> Pending</span></span> + <span class="badge badge-warning"><span class="d-none d-md-inline"> Pending</span></span> </t> <t t-if="invoice.state == 'paid' or last_tx.state == 'done'"> - <span class="label label-default"><i class="fa fa-fw fa-check"></i><span class="d-none d-md-inline"> Paid</span></span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-check"></i><span class="d-none d-md-inline"> Paid</span></span> </t> <t t-if="invoice.state == 'cancel'"> - <span class="label label-default"><i class="fa fa-fw fa-remove"></i><span class="d-none d-md-inline"> Cancelled</span></span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-remove"></i><span class="d-none d-md-inline"> Cancelled</span></span> </t> </td> </xpath> diff --git a/addons/calendar/views/calendar_templates.xml b/addons/calendar/views/calendar_templates.xml index 987d7ef1cb6..828245f4951 100644 --- a/addons/calendar/views/calendar_templates.xml +++ b/addons/calendar/views/calendar_templates.xml @@ -35,7 +35,7 @@ </div> <div class="card-body"> <div class="clearfix mb16" t-if="attendee.state != 'needsAction'"> - <span class="float-right label label-info"> + <span class="float-right badge badge-info"> <t t-if="attendee.state == 'accepted'">Yes I'm going.</t> <t t-if="attendee.state == 'declined'">No I'm not going.</t> </span> diff --git a/addons/crm/views/crm_lead_views.xml b/addons/crm/views/crm_lead_views.xml index 6a3b3b4c505..42d899b77f1 100644 --- a/addons/crm/views/crm_lead_views.xml +++ b/addons/crm/views/crm_lead_views.xml @@ -52,7 +52,7 @@ <field name="active" widget="boolean_button" options='{"terminology": "archive"}'/> </button> </div> - <div class="label label-success float-right" attrs="{'invisible': [('probability', '<', 100)]}">Won</div> + <div class="badge badge-success float-right" attrs="{'invisible': [('probability', '<', 100)]}">Won</div> <div class="oe_title"> <label for="name" class="oe_edit_only" string="Lead"/> <h1><field name="name" placeholder="Describe the lead..."/></h1> @@ -461,8 +461,8 @@ <field name="active" widget="boolean_button" options='{"terminology": "archive"}'/> </button> </div> - <div class="label label-danger float-right" attrs="{'invisible': ['|', ('probability', '>', 0), ('active', '=', True)]}">Lost</div> - <div class="label label-success float-right" attrs="{'invisible': [('probability', '<', 100)]}">Won</div> + <div class="badge badge-danger float-right" attrs="{'invisible': ['|', ('probability', '>', 0), ('active', '=', True)]}">Lost</div> + <div class="badge badge-success float-right" attrs="{'invisible': [('probability', '<', 100)]}">Won</div> <div class="oe_title"> <label for="name" class="oe_edit_only"/> <h1><field name="name" placeholder="e.g. Product Pricing"/></h1> diff --git a/addons/fleet/views/fleet_vehicle_cost_views.xml b/addons/fleet/views/fleet_vehicle_cost_views.xml index 429b1bfdfcd..9070a00ed2a 100644 --- a/addons/fleet/views/fleet_vehicle_cost_views.xml +++ b/addons/fleet/views/fleet_vehicle_cost_views.xml @@ -297,7 +297,7 @@ <div> <strong> <field name="vehicle_id"/> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state"/> </span> </strong> diff --git a/addons/hr/views/hr_views.xml b/addons/hr/views/hr_views.xml index e462be7fcc4..1b332ec5f18 100644 --- a/addons/hr/views/hr_views.xml +++ b/addons/hr/views/hr_views.xml @@ -426,7 +426,7 @@ </div> <div> <span>Vacancies : <field name="expected_employees"/></span> - <span t-att-class="'float-right label label-success' if record.state.raw_value == 'recruit' else 'float-right label label-danger'"> + <span t-att-class="'float-right badge badge-success' if record.state.raw_value == 'recruit' else 'float-right badge badge-danger'"> <field name="state"/> </span> </div> diff --git a/addons/hr_payroll/views/hr_payslip_views.xml b/addons/hr_payroll/views/hr_payslip_views.xml index cc90db513b6..4970b637716 100644 --- a/addons/hr_payroll/views/hr_payslip_views.xml +++ b/addons/hr_payroll/views/hr_payslip_views.xml @@ -96,7 +96,7 @@ <strong><field name="employee_id"/></strong> </div> <div class="col-6"> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state"/> </span> </div> @@ -341,7 +341,7 @@ <strong><field name="name"/></strong> </div> <div class="col-6"> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state"/> </span> </div> diff --git a/addons/hr_timesheet/views/project_views.xml b/addons/hr_timesheet/views/project_views.xml index 3efe8b9942b..a98fd8e4624 100644 --- a/addons/hr_timesheet/views/project_views.xml +++ b/addons/hr_timesheet/views/project_views.xml @@ -151,7 +151,7 @@ </templates> <div class="oe_kanban_bottom_left" position="inside"> <t t-if="record.progress.raw_value > 80 and record.progress.raw_value < 100"> - <div t-att-class="'oe_kanban_align label label-' + (record.progress.raw_value >= 99 ? 'danger': 'warning')" title="Remaining hours"> + <div t-att-class="'oe_kanban_align badge badge-' + (record.progress.raw_value >= 99 ? 'danger': 'warning')" title="Remaining hours"> <field name="remaining_hours" widget="float_time" /> </div> </t> diff --git a/addons/mail/static/src/xml/activity.xml b/addons/mail/static/src/xml/activity.xml index 93732a20505..ef6eb31a593 100644 --- a/addons/mail/static/src/xml/activity.xml +++ b/addons/mail/static/src/xml/activity.xml @@ -6,9 +6,9 @@ <i class="fa fa-fw fa-caret-down"/> Planned activities <small class="o_chatter_planned_activities_summary ml8"> - <span class="label rounded-circle label-danger"><t t-esc="nbOverdueActivities"/></span> - <span class="label rounded-circle label-warning"><t t-esc="nbTodayActivities"/></span> - <span class="label rounded-circle label-success"><t t-esc="nbPlannedActivities"/></span> + <span class="badge rounded-circle badge-danger"><t t-esc="nbOverdueActivities"/></span> + <span class="badge rounded-circle badge-warning"><t t-esc="nbTodayActivities"/></span> + <span class="badge rounded-circle badge-success"><t t-esc="nbPlannedActivities"/></span> </small> </a> </div> diff --git a/addons/maintenance/views/maintenance_views.xml b/addons/maintenance/views/maintenance_views.xml index a12bc655da8..b411b73504f 100644 --- a/addons/maintenance/views/maintenance_views.xml +++ b/addons/maintenance/views/maintenance_views.xml @@ -62,7 +62,7 @@ </header> <sheet> <div attrs="{'invisible': [('archive', '=', False)]}"> - <span class="label label-warning float-right">Canceled</span> + <span class="badge badge-warning float-right">Canceled</span> </div> <div class="oe_right"> <field name="kanban_state" class="oe_inline" widget="state_selection"/> @@ -451,10 +451,10 @@ </div> <div class="o_kanban_record_bottom"> <div class="oe_kanban_bottom_left"> - <div class="label label-danger" t-if="record.maintenance_open_count.raw_value" > + <div class="badge badge-danger" t-if="record.maintenance_open_count.raw_value" > <t t-raw="record.maintenance_open_count.raw_value"/> Request </div> - <div class="label label-default" t-if="record.next_action_date.raw_value" > + <div class="badge badge-secondary" t-if="record.next_action_date.raw_value" > <t t-raw="moment(record.next_action_date.raw_value).format('MMMM Do')"/> </div> </div> diff --git a/addons/mrp/static/src/js/mrp.js b/addons/mrp/static/src/js/mrp.js index ea6a06fc5e3..154b65ce473 100644 --- a/addons/mrp/static/src/js/mrp.js +++ b/addons/mrp/static/src/js/mrp.js @@ -38,7 +38,7 @@ var SetBulletStatus = AbstractField.extend({ var title = this.value === 'waiting' ? _t('Waiting Materials') : _t('Ready to produce'); this.$el.attr({'title': title, 'style': 'display:inline'}); this.$el.removeClass('text-success text-danger text-default'); - this.$el.html($('<span>' + title + '</span>').addClass('label label-' + bullet_class)); + this.$el.html($('<span>' + title + '</span>').addClass('badge badge-' + bullet_class)); } } }); diff --git a/addons/mrp/static/tests/mrp_tests.js b/addons/mrp/static/tests/mrp_tests.js index d86adf842c5..9d4e82ede12 100644 --- a/addons/mrp/static/tests/mrp_tests.js +++ b/addons/mrp/static/tests/mrp_tests.js @@ -45,8 +45,8 @@ QUnit.module('mrp', { assert.strictEqual(form.$('.o_field_widget').text(), "Waiting Materials", "the widget should be correctly named"); - assert.strictEqual(form.$('.o_field_widget .label-danger').length, 1, - "the label should be danger"); + assert.strictEqual(form.$('.o_field_widget .badge-danger').length, 1, + "the badge should be danger"); form.destroy(); }); diff --git a/addons/mrp/views/mrp_production_views.xml b/addons/mrp/views/mrp_production_views.xml index 592bf8f155b..5687f10c605 100644 --- a/addons/mrp/views/mrp_production_views.xml +++ b/addons/mrp/views/mrp_production_views.xml @@ -46,7 +46,7 @@ <button name="action_cancel" type="object" string="Cancel" attrs="{'invisible': ['|', '|', ('is_locked', '=', False), ('state', 'in', ('done','cancel')), ('check_to_done', '=', True)]}"/> <button name="button_scrap" type="object" string="Scrap" attrs="{'invisible': ['|', '|', ('availability', '=', 'none'), ('state', 'in', ('cancel')), ('is_locked', '=', False)]}"/> <button name="button_unreserve" type="object" string="Unreserve" attrs="{'invisible': [('unreserve_visible', '=', False)]}"/> - <span class="label label-danger" attrs="{'invisible': ['|',('availability', 'in', ('assigned', 'none')), ('state', 'not in', ('confirmed','progress'))]}">Raw materials not available!</span> + <span class="badge badge-danger" attrs="{'invisible': ['|',('availability', 'in', ('assigned', 'none')), ('state', 'not in', ('confirmed','progress'))]}">Raw materials not available!</span> <field name="state" widget="statusbar" statusbar_visible="confirmed,progress,done"/> <button name="action_toggle_is_locked" attrs="{'invisible': ['|', '|', ('state', '=', 'cancel'), ('id', '=', False), ('is_locked', '=', False)]}" string="Unlock" groups="mrp.group_mrp_manager" type="object" help="Unlock the manufacturing order to correct what has been consumed or produced."/> <button name="action_toggle_is_locked" attrs="{'invisible': [('is_locked', '=', True)]}" string="Lock" class="oe_highlight" groups="mrp.group_mrp_manager" type="object"/> @@ -144,7 +144,7 @@ </tree> </field> <p attrs="{'invisible': [('finished_move_line_ids', '!=', [])]}"> - Use the Produce button or process the work orders to create some finished products. + Use the Produce button or process the work orders to create some finished products. </p> </page> <page string="Miscellaneous" groups="stock.group_stock_multi_locations, base.group_no_one"> @@ -195,7 +195,7 @@ <span><t t-esc="record.name.value"/> <t t-esc="record.date_planned_start.value and record.date_planned_start.value.split(' ')[0] or False"/></span> </div> <div class="oe_kanban_bottom_right"> - <span t-attf-class="label #{['draft', 'cancel'].indexOf(record.state.raw_value) > -1 ? 'label-default' : ['none'].indexOf(record.state.raw_value) > -1 ? 'label-danger' : ['confirmed'].indexOf(record.state.raw_value) > -1 ? 'label-warning' : ['done'].indexOf(record.state.raw_value) > -1 ? 'label-success' : 'label-primary'}"><t t-esc="record.state.value"/></span> + <span t-attf-class="badge #{['draft', 'cancel'].indexOf(record.state.raw_value) > -1 ? 'badge-secondary' : ['none'].indexOf(record.state.raw_value) > -1 ? 'badge-danger' : ['confirmed'].indexOf(record.state.raw_value) > -1 ? 'badge-warning' : ['done'].indexOf(record.state.raw_value) > -1 ? 'badge-success' : 'badge-primary'}"><t t-esc="record.state.value"/></span> </div> </div> </div> diff --git a/addons/mrp/views/mrp_workorder_views.xml b/addons/mrp/views/mrp_workorder_views.xml index e9b2de8cec1..5287da4f0bf 100644 --- a/addons/mrp/views/mrp_workorder_views.xml +++ b/addons/mrp/views/mrp_workorder_views.xml @@ -193,7 +193,7 @@ </div> <label for="duration"/> <div> - <button style="pointer-events: none;" class="oe_inline label label-default"> + <button style="pointer-events: none;" class="oe_inline badge badge-secondary"> <field name="duration" widget="mrp_time_counter" help="Time the currently logged user spent on this workorder."/> </button> </div> diff --git a/addons/point_of_sale/static/src/xml/pos.xml b/addons/point_of_sale/static/src/xml/pos.xml index 75c0aecdcac..3c412db694d 100644 --- a/addons/point_of_sale/static/src/xml/pos.xml +++ b/addons/point_of_sale/static/src/xml/pos.xml @@ -1317,7 +1317,7 @@ <div class="summary clearfix"> <div class="line"> <div class='entry total'> - <span class="label">Total: </span> <span class="value">0.00 €</span> + <span class="badge">Total: </span> <span class="value">0.00 €</span> <div class='subentry'>Taxes: <span class="value">0.00€</span></div> </div> </div> diff --git a/addons/point_of_sale/views/point_of_sale_dashboard.xml b/addons/point_of_sale/views/point_of_sale_dashboard.xml index fb27f0d6d12..c45bc2e19cf 100644 --- a/addons/point_of_sale/views/point_of_sale_dashboard.xml +++ b/addons/point_of_sale/views/point_of_sale_dashboard.xml @@ -64,16 +64,16 @@ <t t-esc="record.name.value"/> </div> <t t-if="record.pos_session_state.raw_value == 'opening_control'"> - <div class="label label-info o_kanban_inline_block">Opening Control</div> + <div class="badge badge-info o_kanban_inline_block">Opening Control</div> </t> <t t-if="record.pos_session_state.raw_value == 'opened'"> - <div class="label label-success o_kanban_inline_block">In Progress</div> + <div class="badge badge-success o_kanban_inline_block">In Progress</div> </t> <t t-if="record.pos_session_state.raw_value == 'closing_control'"> - <div class="label label-info o_kanban_inline_block">Closing Control</div> + <div class="badge badge-info o_kanban_inline_block">Closing Control</div> </t> <t t-if="record.pos_session_state.raw_value == 'opened' and record.pos_session_duration.raw_value > 1"> - <div t-attf-class="label label-#{record.pos_session_duration.raw_value > 3 and 'danger' or 'warning'} o_kanban_inline_block" + <div t-attf-class="badge badge-#{record.pos_session_duration.raw_value > 3 and 'danger' or 'warning'} o_kanban_inline_block" title="The session has been opened for an unusually long period. Please consider closing."> To Close </div> diff --git a/addons/product_expiry/views/production_lot_views.xml b/addons/product_expiry/views/production_lot_views.xml index fba0da8607f..e13ec58bdb2 100644 --- a/addons/product_expiry/views/production_lot_views.xml +++ b/addons/product_expiry/views/production_lot_views.xml @@ -19,7 +19,7 @@ </xpath> <xpath expr="//div[hasclass('oe_title')]" position="inside"> <field name="product_expiry_alert" invisible="1"/> - <span class="label label-danger" attrs="{'invisible': [('product_expiry_alert', '=', False)]}">Expiration Alert</span> + <span class="badge badge-danger" attrs="{'invisible': [('product_expiry_alert', '=', False)]}">Expiration Alert</span> </xpath> </field> </record> @@ -43,7 +43,7 @@ </xpath> <xpath expr="//div[hasclass('oe_title')]" position="inside"> <field name="product_expiry_alert" invisible="1"/> - <span class="label label-danger" attrs="{'invisible': [('product_expiry_alert', '=', False)]}">Expiration Alert</span> + <span class="badge badge-danger" attrs="{'invisible': [('product_expiry_alert', '=', False)]}">Expiration Alert</span> </xpath> </field> </record> diff --git a/addons/project/views/project_portal_templates.xml b/addons/project/views/project_portal_templates.xml index 8c3f4cdfafe..2750f0734e4 100644 --- a/addons/project/views/project_portal_templates.xml +++ b/addons/project/views/project_portal_templates.xml @@ -143,7 +143,7 @@ <a t-attf-href="/my/task/#{task.id}?{{ keep_query() }}"><span t-field="task.name"/></a> </td> <td> - <span class="label label-info" title="Current stage of the task" t-esc="task.stage_id.name" /> + <span class="badge badge-info" title="Current stage of the task" t-esc="task.stage_id.name" /> </td> <td> <span t-esc="task.id"/> @@ -169,7 +169,7 @@ <div class="col-lg-12"> <h4> Task - <span t-field="task.name"/> (#<span t-esc="task.id"/>) - <span t-field="task.stage_id.name" class="float-right label label-info" title="Current stage of this task"/> + <span t-field="task.stage_id.name" class="float-right badge badge-info" title="Current stage of this task"/> <a role="button" class="btn btn-info" t-att-href="'/web#return_label=Website&model=project.task&id=%s&view_type=form' % (task.id)" groups="project.group_project_user">Edit Task</a> </h4> </div> diff --git a/addons/project/views/project_rating_templates.xml b/addons/project/views/project_rating_templates.xml index da741eecb2f..dbf995814ad 100644 --- a/addons/project/views/project_rating_templates.xml +++ b/addons/project/views/project_rating_templates.xml @@ -24,7 +24,7 @@ <div class="card"> <div class="card-body"> <div class="caption"> - <span class="label label-default float-right"><t t-esc="project.privacy_visibility"/></span> + <span class="badge badge-secondary float-right"><t t-esc="project.privacy_visibility"/></span> <h4><t t-esc="project.name"/></h4> <p t-if="project.date" class="text-muted"> <i class="fa fa-calendar"/> End date : <t t-esc="project.date"/> diff --git a/addons/purchase/views/portal_templates.xml b/addons/purchase/views/portal_templates.xml index d849861f397..5646dbf1f67 100644 --- a/addons/purchase/views/portal_templates.xml +++ b/addons/purchase/views/portal_templates.xml @@ -45,10 +45,10 @@ <td><span t-field="order.date_order"/></td> <td> <t t-if="order.invoice_status == 'to invoice'"> - <span class="label label-info"><i class="fa fa-fw fa-file-text"/> Waiting for Bill</span> + <span class="badge badge-info"><i class="fa fa-fw fa-file-text"/> Waiting for Bill</span> </t> <t t-if="order.state == 'cancel'"> - <span class="label label-default"><i class="fa fa-fw fa-remove"/> Cancelled</span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-remove"/> Cancelled</span> </t> </td> <td><span t-field="order.amount_total" t-options='{"widget": "monetary", "display_currency": order.currency_id}'/> diff --git a/addons/repair/views/repair_views.xml b/addons/repair/views/repair_views.xml index 7476d054b10..005dca2936c 100644 --- a/addons/repair/views/repair_views.xml +++ b/addons/repair/views/repair_views.xml @@ -206,7 +206,7 @@ <strong><span><t t-esc="record.name.value"/></span></strong> </div> <div class="col-6 text-right"> - <span class="label label-default"><field name="state" widget="kanban_label_selection" options="{'classes': {'draft': 'info', 'cancel': 'danger', 'done': 'success', 'under_repair': 'dafault'}}"/></span> + <span class="badge badge-secondary"><field name="state" widget="kanban_label_selection" options="{'classes': {'draft': 'info', 'cancel': 'danger', 'done': 'success', 'under_repair': 'dafault'}}"/></span> </div> </div> <div class="row"> diff --git a/addons/sale/views/sale_portal_templates.xml b/addons/sale/views/sale_portal_templates.xml index f1ac9d6a7dd..176735ef01d 100644 --- a/addons/sale/views/sale_portal_templates.xml +++ b/addons/sale/views/sale_portal_templates.xml @@ -58,10 +58,10 @@ <td><span t-field="quotation.validity_date"/></td> <td> <t t-if="quotation.state == 'cancel'"> - <span class="label label-default"><i class="fa fa-fw fa-remove"/> Cancelled</span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-remove"/> Cancelled</span> </t> <t t-if="quotation.is_expired"> - <span class="label label-default"><i class="fa fa-fw fa-clock-o"/> Expired</span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-clock-o"/> Expired</span> </t> </td> <td><span t-field="quotation.amount_total" t-options='{"widget": "monetary", "display_currency": quotation.pricelist_id.currency_id}'/> @@ -108,7 +108,7 @@ </td> <td> <t t-if="order.state == 'done'"> - <span class="label label-success d-none d-md-inline-block"><i class="fa fa-fw fa-check" role="img" aria-label="Done" title="Done"></i><span class="d-none d-md-inline"> Done</span></span> + <span class="badge badge-success d-none d-md-inline-block"><i class="fa fa-fw fa-check" role="img" aria-label="Done" title="Done"></i><span class="d-none d-md-inline"> Done</span></span> </t> </td> <td><span t-field="order.amount_total" t-options='{"widget": "monetary", "display_currency": order.pricelist_id.currency_id}'/></td> @@ -138,10 +138,10 @@ <t t-else="">Order</t> <span t-esc="order.name"/> <t t-if="order.state == 'cancel'"> - <span class="label label-default"><i class="fa fa-fw fa-remove"/> Cancelled</span> + <span class="badge badge-secondary"><i class="fa fa-fw fa-remove"/> Cancelled</span> </t> <t t-if="order.state == 'done'"> - <span class="label label-success"><i class="fa fa-fw fa-check" /> Done</span> + <span class="badge badge-success"><i class="fa fa-fw fa-check" /> Done</span> </t> </h4> </div> @@ -192,10 +192,10 @@ <a t-att-href="report_url"><span t-esc="i.number"/></a> <span class="text-muted" t-field="i.date_invoice"/> <t t-if="i.state == 'paid'"> - <span class="label label-success orders_label_text_align"><i class="fa fa-fw fa-check"/> Paid</span> + <span class="badge badge-success orders_label_text_align"><i class="fa fa-fw fa-check"/> Paid</span> </t> <t t-if="i.state != 'paid'"> - <span class="label label-info orders_label_text_align"><i class="fa fa-fw fa-clock-o"/> Waiting</span> + <span class="badge badge-info orders_label_text_align"><i class="fa fa-fw fa-clock-o"/> Waiting</span> </t> </div> </t> diff --git a/addons/sale_payment/views/sale_portal_templates.xml b/addons/sale_payment/views/sale_portal_templates.xml index 75ed89b9145..185a0ebcf32 100644 --- a/addons/sale_payment/views/sale_portal_templates.xml +++ b/addons/sale_payment/views/sale_portal_templates.xml @@ -57,10 +57,10 @@ <span t-esc="tx.reference"/> <span class="text-muted" t-field="tx.create_date"/> <t t-if="tx.state == 'done'"> - <span class="label label-success orders_label_text_align"><i class="fa fa-fw fa-check"/> Done</span> + <span class="badge badge-success orders_label_text_align"><i class="fa fa-fw fa-check"/> Done</span> </t> <t t-if="tx.state != 'done'"> - <span class="label label-info orders_label_text_align"><i class="fa fa-fw fa-clock-o"/> Waiting</span> + <span class="badge badge-info orders_label_text_align"><i class="fa fa-fw fa-clock-o"/> Waiting</span> <t t-if="tx.state_message"><br /><span t-esc="tx.state_message"/></t> </t> </div> diff --git a/addons/sale_stock/views/sale_stock_portal_template.xml b/addons/sale_stock/views/sale_stock_portal_template.xml index 0eca2cdd230..5e31f575c3f 100644 --- a/addons/sale_stock/views/sale_stock_portal_template.xml +++ b/addons/sale_stock/views/sale_stock_portal_template.xml @@ -14,16 +14,16 @@ <a t-att-href="report_url"><span t-field="i.name"/></a> <span class="text-muted" t-field="i.date" t-options='{"widget": "date"}'/> <t t-if="i.state == 'done'"> - <span class="label label-success label-text-align"><i class="fa fa-fw fa-truck"/> Shipped</span> + <span class="badge badge-success label-text-align"><i class="fa fa-fw fa-truck"/> Shipped</span> </t> <t t-if="i.state == 'partially_available'"> - <span class="label label-warning label-text-align"><i class="fa fa-fw fa-clock-o"/> Partially Available</span> + <span class="badge badge-warning label-text-align"><i class="fa fa-fw fa-clock-o"/> Partially Available</span> </t> <t t-if="i.state == 'cancel'"> - <span class="label label-danger label-text-align"><i class="fa fa-fw fa-times"/> Cancelled</span> + <span class="badge badge-danger label-text-align"><i class="fa fa-fw fa-times"/> Cancelled</span> </t> <t t-if="i.state in ['draft', 'waiting', 'confirmed', 'assigned']"> - <span class="label label-info label-text-align"><i class="fa fa-fw fa-clock-o"/> Preparation</span> + <span class="badge badge-info label-text-align"><i class="fa fa-fw fa-clock-o"/> Preparation</span> </t> </div> </t> diff --git a/addons/stock/views/stock_scrap_views.xml b/addons/stock/views/stock_scrap_views.xml index 60c5ff999d9..4727a269ceb 100644 --- a/addons/stock/views/stock_scrap_views.xml +++ b/addons/stock/views/stock_scrap_views.xml @@ -95,7 +95,7 @@ <span t-esc="record.scrap_qty.value"/> </div> <div class="col-6"> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state"/> </span> </div> diff --git a/addons/stock_landed_costs/views/stock_landed_cost_views.xml b/addons/stock_landed_costs/views/stock_landed_cost_views.xml index 643618c8b4f..580d5e468b7 100644 --- a/addons/stock_landed_costs/views/stock_landed_cost_views.xml +++ b/addons/stock_landed_costs/views/stock_landed_cost_views.xml @@ -130,7 +130,7 @@ <span t-esc="record.name.value"/> </strong> <div class="col-6"> - <span class="float-right label label-default"> + <span class="float-right badge badge-secondary"> <field name="state"/> </span> </div> diff --git a/addons/survey/views/survey_result.xml b/addons/survey/views/survey_result.xml index b4a4d0a8c0f..a65b12acc7e 100644 --- a/addons/survey/views/survey_result.xml +++ b/addons/survey/views/survey_result.xml @@ -14,13 +14,13 @@ <div class="card-header"><span class="fa fa-filter"></span> Filters <span t-if="filter_display_data" class="float-right text-primary clear_survey_filter"><i class="fa fa-times"></i> Clear All Filters</span></div> <div class="card-body"> <span t-if="filter_finish == True"> - <span class="label label-default only_left_radius filter-all">All surveys</span><span class="label label-primary only_right_radius filter-finished">Finished surveys</span> + <span class="badge badge-secondary only_left_radius filter-all">All surveys</span><span class="badge badge-primary only_right_radius filter-finished">Finished surveys</span> </span> <span t-if="filter_finish == False"> - <span class="label label-primary only_left_radius filter-all">All surveys</span><span class="label label-default only_right_radius filter-finished">Finished surveys</span> + <span class="badge badge-primary only_left_radius filter-all">All surveys</span><span class="badge badge-secondary only_right_radius filter-finished">Finished surveys</span> </span> <span t-foreach="filter_display_data" t-as="filter_data"> - <span class="label label-primary only_left_radius"><i class="fa fa-filter" role="img" aria-label="Filter" title="Filter"></i></span><span class="label label-primary no_radius" t-esc="filter_data['question_text']"></span><span class="label label-success only_right_radius" t-esc="' > '.join(filter_data['labels'])"></span> + <span class="badge badge-primary only_left_radius"><i class="fa fa-filter" role="img" aria-label="Filter" title="Filter"></i></span><span class="badge badge-primary no_radius" t-esc="filter_data['question_text']"></span><span class="badge badge-success only_right_radius" t-esc="' > '.join(filter_data['labels'])"></span> </span> </div> </div> @@ -38,14 +38,14 @@ <b>Question </b> <span t-field='question.question'></span> <t t-if="question.type == 'matrix'"> - <small><span class="label label-default">Matrix: <span t-field='question.matrix_subtype'/></span></small> + <small><span class="badge badge-secondary">Matrix: <span t-field='question.matrix_subtype'/></span></small> </t> <t t-if="question.type in ['simple_choice', 'multiple_choice']"> - <small><span t-field='question.type' class="label label-default"></span></small> + <small><span t-field='question.type' class="badge badge-secondary"></span></small> </t> <span class="float-right"> - <span class="label label-success"><span t-esc="input_summary['answered']"></span> Answered</span> - <span class="label label-danger"><span t-esc="input_summary['skipped']"></span> Skipped</span> + <span class="badge badge-success"><span t-esc="input_summary['answered']"></span> Answered</span> + <span class="badge badge-danger"><span t-esc="input_summary['skipped']"></span> Skipped</span> </span> </h4> <t t-if="input_summary['answered'] != 0"> @@ -176,7 +176,7 @@ </td> <td class="survey_answer"> <span t-esc="round(user_input['count']*100.0/(input_summary['answered'] or 1),2)"></span> % - <span t-esc="user_input['count']" class="label label-primary">Vote</span> + <span t-esc="user_input['count']" class="badge badge-primary">Vote</span> <i class="fa fa-filter text-primary invisible survey_filter" t-att-data-question_id="question.id" t-att-data-answer_id="user_input['answer_id']" role="img" aria-label="Filter question" title="Filter question"/> </td> </tr> @@ -235,7 +235,7 @@ </td> <td class="survey_answer" t-foreach="matrix_result['answers']" t-as="answer_id"> <span t-esc="round(matrix_result['result'][(row_id,answer_id)]*100.0/(input_summary['answered'] or 1),2)"></span> % - <span class="label label-primary" t-esc="matrix_result['result'][(row_id,answer_id)]"></span><i class="fa fa-filter text-primary invisible survey_filter" t-att-data-question_id="question.id" t-att-data-row_id="row_id" t-att-data-answer_id="answer_id" role="img" aria-label="Survey filter" title="Survey filter"></i> + <span class="badge badge-primary" t-esc="matrix_result['result'][(row_id,answer_id)]"></span><i class="fa fa-filter text-primary invisible survey_filter" t-att-data-question_id="question.id" t-att-data-row_id="row_id" t-att-data-answer_id="answer_id" role="img" aria-label="Survey filter" title="Survey filter"></i> </td> </tr> </tbody> @@ -256,10 +256,10 @@ <t t-set="number_result" t-value="prepare_result"/> <t t-set="text_result" t-value="number_result['input_lines']" /> <span class="float-right mt8"> - <span class="label label-default only_left_radius">Sum </span> <span class="label label-info only_right_radius" t-esc="number_result['sum']"></span> - <span class="label label-default only_left_radius">Maximum </span> <span class="label label-success only_right_radius" t-esc="number_result['max']"></span> - <span class="label label-default only_left_radius">Minimum </span> <span class="label label-danger only_right_radius" t-esc="number_result['min']"></span> - <span class="label label-default only_left_radius">Average </span> <span class="label label-warning only_right_radius" t-esc="number_result['average']"></span> + <span class="badge badge-secondary only_left_radius">Sum </span> <span class="badge badge-info only_right_radius" t-esc="number_result['sum']"></span> + <span class="badge badge-secondary only_left_radius">Maximum </span> <span class="badge badge-success only_right_radius" t-esc="number_result['max']"></span> + <span class="badge badge-secondary only_left_radius">Minimum </span> <span class="badge badge-danger only_right_radius" t-esc="number_result['min']"></span> + <span class="badge badge-secondary only_left_radius">Average </span> <span class="badge badge-warning only_right_radius" t-esc="number_result['average']"></span> </span> <ul class="nav nav-tabs d-print-none" role="tablist"> <li class="nav-item"> diff --git a/addons/survey/views/survey_templates.xml b/addons/survey/views/survey_templates.xml index cd6c795c3f6..1ff77a6ca1e 100644 --- a/addons/survey/views/survey_templates.xml +++ b/addons/survey/views/survey_templates.xml @@ -126,7 +126,7 @@ <div class="container mt16 mb8"> <div class="float-right" t-ignore="true" t-if="not editable"> Create a <a target="_blank" href="https://www.odoo.com/page/website-builder">free website</a> with - <a target="_blank" class="label label-danger" href="https://www.odoo.com/page/website-builder">Odoo</a> + <a target="_blank" class="badge badge-danger" href="https://www.odoo.com/page/website-builder">Odoo</a> </div> <div class="float-left text-muted" itemscope="itemscope" itemtype="https://schema.org/Organization"> Copyright &copy; <span t-field="res_company.name" itemprop="name">Company name</span> diff --git a/addons/web/static/src/js/fields/basic_fields.js b/addons/web/static/src/js/fields/basic_fields.js index edea04e0e48..bd13305df0c 100644 --- a/addons/web/static/src/js/fields/basic_fields.js +++ b/addons/web/static/src/js/fields/basic_fields.js @@ -1783,7 +1783,7 @@ var LabelSelection = AbstractField.extend({ _render: function () { this.classes = this.nodeOptions && this.nodeOptions.classes || {}; var labelClass = this.classes[this.value] || 'primary'; - this.$el.addClass('label label-' + labelClass).text(this._formatValue(this.value)); + this.$el.addClass('badge badge-' + labelClass).text(this._formatValue(this.value)); }, }); diff --git a/addons/web/static/src/js/fields/upgrade_fields.js b/addons/web/static/src/js/fields/upgrade_fields.js index 119a64881e3..dd91ca2efc2 100644 --- a/addons/web/static/src/js/fields/upgrade_fields.js +++ b/addons/web/static/src/js/fields/upgrade_fields.js @@ -94,7 +94,7 @@ var AbstractFieldUpgrade = { this._super.apply(this, arguments); this._insertEnterpriseLabel($("<span>", { text: "Enterprise", - 'class': "label label-primary oe_inline o_enterprise_label" + 'class': "badge badge-primary oe_inline o_enterprise_label" })); }, /** diff --git a/addons/web/static/tests/fields/basic_fields_tests.js b/addons/web/static/tests/fields/basic_fields_tests.js index b9b9e083328..443fb194d87 100644 --- a/addons/web/static/tests/fields/basic_fields_tests.js +++ b/addons/web/static/tests/fields/basic_fields_tests.js @@ -4004,42 +4004,42 @@ QUnit.module('basic_fields', { '<sheet>' + '<group>' + '<field name="selection" widget="label_selection" ' + - ' options="{\'classes\': {\'normal\': \'default\', \'blocked\': \'warning\',\'done\': \'success\'}}"/>' + + ' options="{\'classes\': {\'normal\': \'secondary\', \'blocked\': \'warning\',\'done\': \'success\'}}"/>' + '</group>' + '</sheet>' + '</form>', res_id: 1, }); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').length, 1, "should have a warning status label since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-default').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-secondary').length, 0, "should not have a default status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-success').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-success').length, 0, "should not have a success status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the label should say 'Blocked' since this is the label value for that state"); // // switch to edit mode and check the result form.$buttons.find('.o_form_button_edit').click(); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').length, 1, "should have a warning status label since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-default').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-secondary').length, 0, "should not have a default status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-success').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-success').length, 0, "should not have a success status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the label should say 'Blocked' since this is the label value for that state"); // save form.$buttons.find('.o_form_button_save').click(); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').length, 1, "should have a warning status label since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-default').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-secondary').length, 0, "should not have a default status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-success').length, 0, + assert.strictEqual(form.$('.o_field_widget.badge.badge-success').length, 0, "should not have a success status since selection is the second, blocked state"); - assert.strictEqual(form.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(form.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the label should say 'Blocked' since this is the label value for that state"); form.destroy(); @@ -4055,57 +4055,57 @@ QUnit.module('basic_fields', { arch: '<tree editable="bottom">' + '<field name="foo"/>' + '<field name="selection" widget="label_selection"' + - ' options="{\'classes\': {\'normal\': \'default\', \'blocked\': \'warning\',\'done\': \'success\'}}"/>' + + ' options="{\'classes\': {\'normal\': \'secondary\', \'blocked\': \'warning\',\'done\': \'success\'}}"/>' + '</tree>', }); - assert.strictEqual(list.$('.o_field_widget.label:not(:empty)').length, 3, + assert.strictEqual(list.$('.o_field_widget.badge:not(:empty)').length, 3, "should have three visible status labels"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').length, 1, "should have one warning status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the warning label should read 'Blocked'"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').length, 1, "should have one default status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').text(), 'Normal', + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').text(), 'Normal', "the default label should read 'Normal'"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').length, 1, "should have one success status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').text(), 'Done', + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').text(), 'Done', "the success label should read 'Done'"); // switch to edit mode and check the result list.$('tbody td:not(.o_list_record_selector)').first().click(); - assert.strictEqual(list.$('.o_field_widget.label:not(:empty)').length, 3, + assert.strictEqual(list.$('.o_field_widget.badge:not(:empty)').length, 3, "should have three visible status labels"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').length, 1, "should have one warning status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the warning label should read 'Blocked'"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').length, 1, "should have one default status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').text(), 'Normal', + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').text(), 'Normal', "the default label should read 'Normal'"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').length, 1, "should have one success status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').text(), 'Done', + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').text(), 'Done', "the success label should read 'Done'"); // save and check the result list.$buttons.find('.o_list_button_save').click(); - assert.strictEqual(list.$('.o_field_widget.label:not(:empty)').length, 3, + assert.strictEqual(list.$('.o_field_widget.badge:not(:empty)').length, 3, "should have three visible status labels"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').length, 1, "should have one warning status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-warning').text(), 'Blocked', + assert.strictEqual(list.$('.o_field_widget.badge.badge-warning').text(), 'Blocked', "the warning label should read 'Blocked'"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').length, 1, "should have one default status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-default').text(), 'Normal', + assert.strictEqual(list.$('.o_field_widget.badge.badge-secondary').text(), 'Normal', "the default label should read 'Normal'"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').length, 1, + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').length, 1, "should have one success status label"); - assert.strictEqual(list.$('.o_field_widget.label.label-success').text(), 'Done', + assert.strictEqual(list.$('.o_field_widget.badge.badge-success').text(), 'Done', "the success label should read 'Done'"); list.destroy(); diff --git a/addons/web/static/tests/fields/upgrade_fields_tests.js b/addons/web/static/tests/fields/upgrade_fields_tests.js index 427ec7b54e3..15c32eeeaf0 100644 --- a/addons/web/static/tests/fields/upgrade_fields_tests.js +++ b/addons/web/static/tests/fields/upgrade_fields_tests.js @@ -52,10 +52,10 @@ QUnit.module('upgrade_fields', { '</form>', }); - assert.strictEqual(form.$('.o_field .label').length, 0, - "the upgrade label shouldn't be inside the field section"); - assert.strictEqual(form.$('.o_label .label').length, 1, - "the upgrade label should be inside the label section"); + assert.strictEqual(form.$('.o_field .badge').length, 0, + "the upgrade badge shouldn't be inside the field section"); + assert.strictEqual(form.$('.o_label .badge').length, 1, + "the upgrade badge should be inside the label section"); assert.strictEqual(form.$('.o_label').text(), "Bar EnterpriseCoucou", "the upgrade label should be inside the label section"); form.destroy(); diff --git a/addons/website/static/src/js/menu/seo.js b/addons/website/static/src/js/menu/seo.js index 71d4297cd89..180bd561df1 100644 --- a/addons/website/static/src/js/menu/seo.js +++ b/addons/website/static/src/js/menu/seo.js @@ -18,16 +18,16 @@ var WORD_SEPARATORS_REGEX = '([\\u2000-\\u206F\\u2E00-\\u2E7F\'!"#\\$%&\\(\\)\\* function analyzeKeyword(htmlPage, keyword) { return htmlPage.isInTitle(keyword) ? { - title: 'label label-success', + title: 'badge badge-success', description: "This keyword is used in the page title", } : htmlPage.isInDescription(keyword) ? { - title: 'label label-primary', + title: 'badge badge-primary', description: "This keyword is used in the page description", } : htmlPage.isInBody(keyword) ? { - title: 'label label-info', + title: 'badge badge-info', description: "This keyword is used in the page content." } : { - title: 'label label-default', + title: 'badge badge-secondary', description: "This keyword is not used anywhere on the page." }; } diff --git a/addons/website/static/src/xml/website.seo.xml b/addons/website/static/src/xml/website.seo.xml index 90e6f8fa0b3..d9cb1f38f80 100644 --- a/addons/website/static/src/xml/website.seo.xml +++ b/addons/website/static/src/xml/website.seo.xml @@ -63,10 +63,10 @@ <td/> <td><hr/> <small class="text-muted">Legend:</small> - <span class="label label-default">Not used</span> - <span class="label label-success">In title</span> - <span class="label label-primary">In description</span> - <span class="label label-info">In page's content</span> + <span class="badge badge-secondary">Not used</span> + <span class="badge badge-success">In title</span> + <span class="badge badge-primary">In description</span> + <span class="badge badge-info">In page's content</span> </td> </tr> </tfoot> diff --git a/addons/website/views/website_templates.xml b/addons/website/views/website_templates.xml index 0ab90d44014..0f629788b69 100644 --- a/addons/website/views/website_templates.xml +++ b/addons/website/views/website_templates.xml @@ -225,7 +225,7 @@ <template id="brand_promotion" name="Brand Promotion"> <div class="o_brand_promotion"> Create a <a target="_blank" href="http://www.odoo.com/page/website-builder">free website</a> with - <a target="_blank" class="label label-danger" href="http://www.odoo.com/page/website-builder">Odoo</a> + <a target="_blank" class="badge badge-danger" href="http://www.odoo.com/page/website-builder">Odoo</a> </div> </template> diff --git a/addons/website_blog/views/website_blog_templates.xml b/addons/website_blog/views/website_blog_templates.xml index 1bb88263a11..248cd5dec15 100644 --- a/addons/website_blog/views/website_blog_templates.xml +++ b/addons/website_blog/views/website_blog_templates.xml @@ -65,7 +65,7 @@ </div> <div class="text-muted fa fa-tags"> <span t-field="post.website_meta_keywords"/> - <span t-if="editable and not post.website_meta_keywords" class="label label-danger"> + <span t-if="editable and not post.website_meta_keywords" class="badge badge-danger"> No keywords defined! </span> </div> @@ -149,7 +149,7 @@ <t t-if="blog_post.visits <= 1" >view</t> <t t-if="blog_post.visits > 1">views</t> </span> - <span t-if="not blog_post.website_published" class="label label-danger">unpublished</span> + <span t-if="not blog_post.website_published" class="badge badge-danger">unpublished</span> <span class="fa fa-tags" role="img" aria-label="Tags" title="Tags"/> <!-- To display tags //no options --> @@ -236,7 +236,7 @@ <p class="post-meta text-muted text-center" t-if="len(blog_post.tag_ids)"> <span class="fa fa-tags" role="img" aria-label="Tags" title="Tags"/> <t t-foreach="blog_post.tag_ids" t-as="one_tag"> - <a class="label label-primary mr8" t-attf-href="#{blog_url(tag=one_tag.id)}" t-esc="one_tag.name"/> + <a class="badge badge-primary mr8" t-attf-href="#{blog_url(tag=one_tag.id)}" t-esc="one_tag.name"/> </t> </p> <div t-if="'cover_full' in blog_post_cover_properties.get('resize_class', '')" id="blog_angle_down"> diff --git a/addons/website_crm_partner_assign/views/website_crm_partner_assign_templates.xml b/addons/website_crm_partner_assign/views/website_crm_partner_assign_templates.xml index 1d51eb67f20..3481a9c023f 100644 --- a/addons/website_crm_partner_assign/views/website_crm_partner_assign_templates.xml +++ b/addons/website_crm_partner_assign/views/website_crm_partner_assign_templates.xml @@ -323,7 +323,7 @@ </td> <td><span t-field="opp.contact_name" /></td> <td> - <span class="label label-primary" title="Current stage of the opportunity" t-esc="opp.stage_id.name" /> + <span class="badge badge-primary" title="Current stage of the opportunity" t-esc="opp.stage_id.name" /> </td> </tr> </tbody> @@ -403,7 +403,7 @@ <label class="col-4">Tags</label> <span class="col-8"> <t t-foreach="lead.tag_ids" t-as="tag"> - <span class="label label-info" t-esc="tag.name" /> + <span class="badge badge-info" t-esc="tag.name" /> </t> </span> </div> diff --git a/addons/website_customer/views/website_customer_templates.xml b/addons/website_customer/views/website_customer_templates.xml index 7c44b38161d..d970252a638 100644 --- a/addons/website_customer/views/website_customer_templates.xml +++ b/addons/website_customer/views/website_customer_templates.xml @@ -44,7 +44,7 @@ <span t-field="partner.display_name"/> </a> <t t-if="partner.industry_id"> - <a class="label label-default" t-attf-href="/customers/#{ 'industry/%s/' % slug(partner.industry_id) }#{ current_country_id and 'country/%s' % slug(current_country) or '' }" t-esc="partner.industry_id.name"/> + <a class="badge badge-secondary" t-attf-href="/customers/#{ 'industry/%s/' % slug(partner.industry_id) }#{ current_country_id and 'country/%s' % slug(current_country) or '' }" t-esc="partner.industry_id.name"/> </t> <div t-field="partner.website_short_description"/> </div> @@ -134,7 +134,7 @@ <li class="nav-item"><a class="nav-link mr8" t-attf-href="/customers/#{ current_industry_id and 'industry/%s/' % slug(current_industry) or '' }#{ current_country_id and 'country/%s' % slug(current_country) or '' }"> <span class="fa fa-1x fa-tags"/> All </a></li> <li t-foreach="tags" t-as="o_tag" class="nav-item"> - <a t-attf-class="nav-link label label-#{o_tag.classname}" t-esc="o_tag.name" t-att-style="tag and tag.id==o_tag.id and 'text-decoration: underline'" + <a t-attf-class="nav-link badge badge-#{o_tag.classname}" t-esc="o_tag.name" t-att-style="tag and tag.id==o_tag.id and 'text-decoration: underline'" t-attf-href="/customers/#{ current_industry_id and 'industry/%s/' % slug(current_industry) or '' }#{ current_country_id and 'country/%s' % slug(current_country) or '' }?tag_id=#{slug(o_tag)}"/> </li> </ul> @@ -178,7 +178,7 @@ <template id="partner_detail" inherit_id="website_partner.partner_detail" name="Partner Details"> <xpath expr="//address" position="inside"> <t t-if="partner.industry_id"> - <span class="label label-default"><t t-esc="partner.industry_id.name"/></span> + <span class="badge badge-secondary"><t t-esc="partner.industry_id.name"/></span> </t> </xpath> </template> @@ -225,7 +225,7 @@ <span t-field="reference.self"/> </a> <t t-if="reference.industry_id"> - <span class="label label-default"><t t-esc="reference.industry_id.name"/></span> + <span class="badge badge-secondary"><t t-esc="reference.industry_id.name"/></span> </t> <div t-field='reference.website_short_description'/> </div> diff --git a/addons/website_event/views/event_templates.xml b/addons/website_event/views/event_templates.xml index ef5d285dd1c..73829be73c2 100644 --- a/addons/website_event/views/event_templates.xml +++ b/addons/website_event/views/event_templates.xml @@ -49,9 +49,9 @@ <div itemscope="itemscope" itemtype="http://schema.org/Event" class="media-body"> <h4 class="media-heading"> <a itemprop="url" t-att-class="event.state == 'done' and 'text-success'" t-attf-href="/event/#{ slug(event) }/#{(not event.menu_id) and 'register' or ''}"><span itemprop="name" t-field="event.name"> </span></a> - <small t-if="event.is_participating" class="label label-info">Participating</small> - <small t-if="event.is_online" class="label label-info">Online</small> - <small t-if="not event.website_published" class="label label-danger">unpublished</small> + <small t-if="event.is_participating" class="badge badge-info">Participating</small> + <small t-if="event.is_online" class="badge badge-info">Online</small> + <small t-if="not event.website_published" class="badge badge-danger">unpublished</small> </h4> <div> <t t-if="event.organizer_id"> @@ -269,7 +269,7 @@ <div itemscope="itemscope" itemtype="http://schema.org/Event" class="container"> <h1 itemprop="name" class="text-center" t-field="event.name"></h1> <div class="text-center"> - <small t-if="event.is_participating" class="label label-info">Participating</small> + <small t-if="event.is_participating" class="badge badge-info">Participating</small> </div> <h4 class="text-center text-muted"> <i class="fa fa-clock-o" role="img" aria-label="Start date" title="Start date"></i> <span itemprop="startDate" t-field="event.with_context(tz=event.date_tz).date_begin" t-options='{"hide_seconds":"True"}'/> to @@ -378,7 +378,7 @@ </p> <p> <strong>Use this tag:</strong> - <a t-att-href="'http://twitter.com/search?q=%23'+event.twitter_hashtag" target="_blank" class="label label-primary">#<span t-field="event.twitter_hashtag"/></a> + <a t-att-href="'http://twitter.com/search?q=%23'+event.twitter_hashtag" target="_blank" class="badge badge-primary">#<span t-field="event.twitter_hashtag"/></a> </p> </div> </div> @@ -675,7 +675,7 @@ </t> <div t-foreach="events[:5]" t-as="event_dict" class="oe_website_overflow_ellipsis mb8"> <t t-if="not event_dict['event'].website_published"> - <span class="label label-danger" role="img" aria-label="Attention: not published" title="Not published"><i class="fa fa-ban"></i></span> + <span class="badge badge-danger" role="img" aria-label="Attention: not published" title="Not published"><i class="fa fa-ban"></i></span> </t> <t t-if="event_dict['event'].address_id"> <i class="fa fa-map-marker" title="It is a physical event" role="img" aria-label="It is a physical event"></i> @@ -702,7 +702,7 @@ <template id="website_event.brand_promotion" inherit_id="website.brand_promotion"> <xpath expr="//div[hasclass('o_brand_promotion')]" position="replace"> <div class="o_brand_promotion"> - Powered by <a target="_blank" class="label label-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>. + Powered by <a target="_blank" class="badge badge-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>. Try the <a target="_blank" href="http://www.odoo.com/page/website-builder">open source website builder</a>. </div> </xpath> diff --git a/addons/website_event_sale/views/event_templates.xml b/addons/website_event_sale/views/event_templates.xml index f2847c2c9a9..4be278f9620 100644 --- a/addons/website_event_sale/views/event_templates.xml +++ b/addons/website_event_sale/views/event_templates.xml @@ -10,8 +10,8 @@ <template id="index" inherit_id="website_event.index" name="Event's Ticket"> <xpath expr="//li[@t-foreach='event_ids']/div/h4" position="before"> <t t-if="event.state in ['draft', 'confirm'] and event.event_ticket_ids"> - <span t-if="event.seats_availability == 'limited' and not event.seats_available" class="label label-danger float-right">Sold Out</span> - <span t-if="event.seats_availability == 'limited' and event.seats_available and event.seats_available <= ((event.seats_max or 0) / 4)" class="label float-right label-info"> + <span t-if="event.seats_availability == 'limited' and not event.seats_available" class="badge badge-danger float-right">Sold Out</span> + <span t-if="event.seats_availability == 'limited' and event.seats_available and event.seats_available <= ((event.seats_max or 0) / 4)" class="badge float-right badge-info"> Only <t t-esc="event.seats_available"/> Remaining </span> </t> diff --git a/addons/website_event_track/views/event_track_templates.xml b/addons/website_event_track/views/event_track_templates.xml index 8eb4745dc42..7c524d52e13 100644 --- a/addons/website_event_track/views/event_track_templates.xml +++ b/addons/website_event_track/views/event_track_templates.xml @@ -81,7 +81,7 @@ <t t-if="track"> <a t-attf-href="/event/#{ slug(event) }/track/#{ slug(track) }"> <span t-esc="track and track.name"/> - <span t-if="not track.website_published" class="label label-warning">unpublished</span> + <span t-if="not track.website_published" class="badge badge-warning">unpublished</span> </a> <div class="text-muted"> <small t-if="track.partner_id" t-esc="track.partner_id.sudo().name"/> @@ -132,7 +132,7 @@ <div class="col-md-10"> <h3 class="mt0 mb0"> <a t-attf-href="/event/#{ slug(event) }/track/#{ slug(track) }"><span t-field="track.name"> </span></a> - <small t-if="not track.website_published" class="label label-danger">unpublished</small> + <small t-if="not track.website_published" class="badge badge-danger">unpublished</small> </h3> <ul class="list-inline mb0"> <li t-if="track.partner_id" class="list-inline-item text-muted fa fa-user"> @@ -292,7 +292,7 @@ and join the conversation. </p> <p><strong>Use this tag: - <a t-att-href="'http://twitter.com/search?q=#'+event.twitter_hashtag" class="label label-primary">#<span t-field="event.twitter_hashtag"/></a> + <a t-att-href="'http://twitter.com/search?q=#'+event.twitter_hashtag" class="badge badge-primary">#<span t-field="event.twitter_hashtag"/></a> </strong></p> </div> </div> diff --git a/addons/website_forum/static/src/js/website_forum.js b/addons/website_forum/static/src/js/website_forum.js index 0da47e1ba1f..3a14dda6c66 100644 --- a/addons/website_forum/static/src/js/website_forum.js +++ b/addons/website_forum/static/src/js/website_forum.js @@ -357,7 +357,7 @@ odoo.define('website_forum.website_forum', function (require) { }, formatResult: function(term) { if (term.isNew) { - return '<span class="label label-primary">New</span> ' + _.escape(term.text); + return '<span class="badge badge-primary">New</span> ' + _.escape(term.text); } else { return _.escape(term.text); diff --git a/addons/website_forum/views/website_forum.xml b/addons/website_forum/views/website_forum.xml index 007d1a7ef6b..bdda9fcc7ad 100644 --- a/addons/website_forum/views/website_forum.xml +++ b/addons/website_forum/views/website_forum.xml @@ -233,7 +233,7 @@ <div><t t-raw="post_content"/></div> <t t-foreach="question.tag_ids" t-as="question_tag"> <a t-attf-href="/forum/#{ slug(forum) }/tag/#{slug(question_tag)}/questions"> - <span t-attf-class="float-right label #{tag and tag.name == question_tag.name and 'label-primary' or 'label-default'}" t-field="question_tag.name" + <span t-attf-class="float-right badge #{tag and tag.name == question_tag.name and 'badge-primary' or 'badge-secondary'}" t-field="question_tag.name" style="margin-right: 4px;"/> </a> </t> @@ -769,7 +769,7 @@ <div class="float-right"> <div class="text-right"> <t t-foreach="question.tag_ids" t-as="tag"> - <a t-attf-href="/forum/#{ slug(forum) }/tag/#{ tag.id }/questions" class="label label-default" t-field="tag.name"/> + <a t-attf-href="/forum/#{ slug(forum) }/tag/#{ tag.id }/questions" class="badge badge-secondary" t-field="tag.name"/> </t> </div> </div> @@ -1135,7 +1135,7 @@ <div class="col-md-3 mt16 o_js_forum_tag_follow" t-foreach="tags" t-as="tag"> <span><t t-esc="tag.posts_count"/>&nbsp;&nbsp;<i class='fa fa-times' title="Close" role="img" aria-label="Close"/>&nbsp;&nbsp;</span> <a t-attf-href="/forum/#{ slug(forum) }/tag/#{ slug(tag) }/questions?{{ keep_query( filters='tag') }}" - t-attf-class="label #{'label-primary' if tag.message_is_follower else 'label-default'}"> + t-attf-class="badge #{'badge-primary' if tag.message_is_follower else 'badge-secondary'}"> <span t-field="tag.name"/> </a> <div t-attf-class="o_forum_tag_follow_box"> @@ -1475,7 +1475,7 @@ <ul class="list-unstyled"> <li t-foreach="activities" t-as="activity"> <span t-field="activity.date" t-options='{"format": "short"}'/> - <span t-esc="activity.subtype_id.name" class="label label-info"/> + <span t-esc="activity.subtype_id.name" class="badge badge-info"/> <t t-set="post" t-value="posts[activity.res_id]"/> <span t-if="post[1]"> <a t-attf-href="/forum/#{ slug(forum) }/question/#{ slug(post[0]) }#answer-#{ str(post[1].id) }"> diff --git a/addons/website_hr_recruitment/views/website_hr_recruitment_templates.xml b/addons/website_hr_recruitment/views/website_hr_recruitment_templates.xml index 35469c7477f..12957493869 100644 --- a/addons/website_hr_recruitment/views/website_hr_recruitment_templates.xml +++ b/addons/website_hr_recruitment/views/website_hr_recruitment_templates.xml @@ -55,7 +55,7 @@ "fields": ["address"], "no_tag_br": True }'/> - <span t-if="not job.website_published" class="label label-danger">unpublished</span> + <span t-if="not job.website_published" class="badge badge-danger">unpublished</span> <div class="text-muted"> <i class="fa fa-clock-o" title="Publication date" role="img" aria-label="Publication date"/> <span t-field="job.write_date"/> </div> diff --git a/addons/website_links/static/src/xml/recent_link.xml b/addons/website_links/static/src/xml/recent_link.xml index 5e3b328a9a4..c7e0c7ad1e3 100644 --- a/addons/website_links/static/src/xml/recent_link.xml +++ b/addons/website_links/static/src/xml/recent_link.xml @@ -26,9 +26,9 @@ <a class="o_website_links_edit_code" aria-label="Edit code" title="Edit code"><span class="fa fa-pencil gray"></span></a> <br/> - <span class="label label-success"><t t-esc="widget.link_obj.campaign_id[1]"/></span> - <span class="label label-success"><t t-esc="widget.link_obj.medium_id[1]"/></span> - <span class="label label-success"><t t-esc="widget.link_obj.source_id[1]"/></span> + <span class="badge badge-success"><t t-esc="widget.link_obj.campaign_id[1]"/></span> + <span class="badge badge-success"><t t-esc="widget.link_obj.medium_id[1]"/></span> + <span class="badge badge-success"><t t-esc="widget.link_obj.source_id[1]"/></span> </p> <p class='o_website_links_code_error' style='color:red;font-weight:bold;'></p> </div> diff --git a/addons/website_quote/views/website_quote_templates.xml b/addons/website_quote/views/website_quote_templates.xml index b90a060960b..e22f12639db 100644 --- a/addons/website_quote/views/website_quote_templates.xml +++ b/addons/website_quote/views/website_quote_templates.xml @@ -726,7 +726,7 @@ <template id="website_quote.brand_promotion" inherit_id="website.brand_promotion"> <xpath expr="//div[hasclass('o_brand_promotion')]" position="replace"> <div class="o_brand_promotion"> - Powered by <a target="_blank" class="label label-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>, + Powered by <a target="_blank" class="badge badge-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>, an awesome <a target="_blank" href="http://www.odoo.com/page/crm">Open Source CRM</a>. </div> </xpath> diff --git a/addons/website_rating/static/src/xml/website_mail.xml b/addons/website_rating/static/src/xml/website_mail.xml index 7f462ed3926..65464603d33 100644 --- a/addons/website_rating/static/src/xml/website_mail.xml +++ b/addons/website_rating/static/src/xml/website_mail.xml @@ -69,7 +69,7 @@ <i class="fa fa-star-o" role="img" aria-label="Five stars on five" title="Five stars on five"></i> </div> <div class="rate_text"> - <span class="label label-info"></span> + <span class="badge badge-info"></span> </div> <input type="hidden" readonly="readonly" name="rating_value" value="0.0"/> </div> diff --git a/addons/website_sale/views/product_views.xml b/addons/website_sale/views/product_views.xml index 326835da7c9..d2e5c1c4abf 100644 --- a/addons/website_sale/views/product_views.xml +++ b/addons/website_sale/views/product_views.xml @@ -115,7 +115,7 @@ <t t-set="message" t-value="'Huge file size. The image should be optimized/reduced.'" t-elif="size_status == 'warning'"></t> <t t-set="message" t-value="'Optimization required! Reduce the image size or increase your compression settings.'" t-else=""></t> - <span t-attf-class="o_website_sale_image_card_size label label-#{size_status}" t-att-title="message"> + <span t-attf-class="o_website_sale_image_card_size badge badge-#{size_status}" t-att-title="message"> <t t-esc="record.image.value"/> </span> <a role="button" t-if="!read_only_mode" type="delete" class="btn btn-xs btn-secondary o_website_sale_image_card_remove" aria-label="Remove" title="Remove"><i class="fa fa-trash"/></a> diff --git a/addons/website_sale/views/templates.xml b/addons/website_sale/views/templates.xml index a8e63dc8447..30d510f0106 100644 --- a/addons/website_sale/views/templates.xml +++ b/addons/website_sale/views/templates.xml @@ -44,7 +44,7 @@ <li id="my_cart" t-attf-class="nav-item#{'' if website_sale_order and website_sale_order.cart_quantity else ' d-none'}"> <a href="/shop/cart" class="nav-link"> <i class="fa fa-shopping-cart"></i> - My Cart <sup t-attf-class="my_cart_quantity label label-primary" t-esc="website_sale_order and website_sale_order.cart_quantity or ''" /> + My Cart <sup t-attf-class="my_cart_quantity badge badge-primary" t-esc="website_sale_order and website_sale_order.cart_quantity or ''" /> </a> </li> </xpath> @@ -1600,7 +1600,7 @@ <template id="website_sale.brand_promotion" inherit_id="website.brand_promotion"> <xpath expr="//div[hasclass('o_brand_promotion')]" position="replace"> <div class="o_brand_promotion"> - Powered by <a target="_blank" class="label label-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>, + Powered by <a target="_blank" class="badge badge-danger" href="http://www.odoo.com/page/website-builder">Odoo</a>, the #1 <a target="_blank" href="http://www.odoo.com/page/e-commerce">Open Source eCommerce</a>. </div> </xpath> diff --git a/addons/website_sale_comparison/static/src/xml/comparison.xml b/addons/website_sale_comparison/static/src/xml/comparison.xml index 7365db89d30..98d3a2e55ce 100644 --- a/addons/website_sale_comparison/static/src/xml/comparison.xml +++ b/addons/website_sale_comparison/static/src/xml/comparison.xml @@ -6,7 +6,7 @@ <span class="o_product_panel_header"> <span class="o_product_icon"><i class="fa fa-exchange" role="img" aria-label="Product" title="Product"></i></span> <span class="o_product_text">Compare</span> - <span class="o_product_circle o_animate_blink label label-primary">0</span> + <span class="o_product_circle o_animate_blink badge badge-primary">0</span> </span> <span class="o_product_panel_content"> <div class="o_comparelist_products"> diff --git a/addons/website_sale_wishlist/static/src/js/website_sale_tour_wishlist.js b/addons/website_sale_wishlist/static/src/js/website_sale_tour_wishlist.js index 81d79135787..a866d6c6e23 100644 --- a/addons/website_sale_wishlist/static/src/js/website_sale_tour_wishlist.js +++ b/addons/website_sale_wishlist/static/src/js/website_sale_tour_wishlist.js @@ -16,7 +16,7 @@ tour.register('shop_wishlist', { }, { content: "go to wishlist", - extra_trigger: ".label:contains(1)", + extra_trigger: 'a[href="/shop/wishlist"] .badge:contains(1)', trigger: 'a[href="/shop/wishlist"]', }, { @@ -71,7 +71,7 @@ tour.register('shop_wishlist', { }, { content: "check that wishlist contains 2 items and go to wishlist", - extra_trigger: ".label:contains(2)", + extra_trigger: 'a[href="/shop/wishlist"] .badge:contains(2)', trigger: 'a[href="/shop/wishlist"]', }, { diff --git a/addons/website_sale_wishlist/views/website_sale_wishlist_template.xml b/addons/website_sale_wishlist/views/website_sale_wishlist_template.xml index 7f8c824a26a..6aa9bdfa079 100644 --- a/addons/website_sale_wishlist/views/website_sale_wishlist_template.xml +++ b/addons/website_sale_wishlist/views/website_sale_wishlist_template.xml @@ -32,7 +32,7 @@ <li id="my_wish" class="nav-item" t-att-style="not wishcount and 'display:none;'"> <a href="/shop/wishlist" class="nav-link"> <i class="fa fa-heart"/> - Wishlist <sup t-attf-class="my_wish_quantity o_animate_blink label label-primary"><t t-esc='wishcount'/></sup> + Wishlist <sup t-attf-class="my_wish_quantity o_animate_blink badge badge-primary"><t t-esc='wishcount'/></sup> </a> </li> </t> diff --git a/addons/website_slides/views/website_slides.xml b/addons/website_slides/views/website_slides.xml index 760777cb2b2..dfc1c5785f7 100644 --- a/addons/website_slides/views/website_slides.xml +++ b/addons/website_slides/views/website_slides.xml @@ -49,7 +49,7 @@ <h3 class="mt4 mb4 lead" t-att-title="channel.name" style="width:55%"> <a t-attf-href="/slides/#{slug(channel)}" t-esc="channel.name"/> </h3> - <span class="label label-warning" t-if="not channel.can_see_full">Private channel</span> + <span class="badge badge-warning" t-if="not channel.can_see_full">Private channel</span> </div> <div> <p class="text-muted oe_no_empty" t-field="channel.description"/> @@ -221,7 +221,7 @@ </h3> <div class="row mt8 mb8" t-if="channel.promoted_slide_id.tag_ids"> <t t-foreach="channel.promoted_slide_id.tag_ids" t-as="slide_tag"> - <a t-attf-href="/slides/#{slug(channel)}/tag/#{slug(slide_tag)}" t-attf-class="label label-default #{tag and tag.id == slide_tag.id and 'label-primary' ''}" t-field="slide_tag.name"/> + <a t-attf-href="/slides/#{slug(channel)}/tag/#{slug(slide_tag)}" t-attf-class="badge badge-secondary #{tag and tag.id == slide_tag.id and 'badge-primary' ''}" t-field="slide_tag.name"/> </t> </div> <div class="row oe_no_empty" t-esc="channel.promoted_slide_id.description"/> @@ -328,7 +328,7 @@ <a t-attf-href="/slides/slide/#{slug(slide)}"> <img t-attf-src="/web/image/slide.slide/#{slide.id}/image_thumb" class="img-fluid img-thumbnail oe_slides_grid_thumbnail" alt="slide.name"/> </a> - <span t-if="not slide.website_published" class="label label-danger" style="position: absolute;right: 20px;top: 7px;">Unpublished</span> + <span t-if="not slide.website_published" class="badge badge-danger" style="position: absolute;right: 20px;top: 7px;">Unpublished</span> <a t-if="not is_public_user and slide.website_published and slide.channel_id.promote_strategy == 'custom' and slide.channel_id.promoted_slide_id.id != slide.id" groups="base.group_user" t-attf-href="/slides/slide/#{slide.id}/promote" @@ -351,7 +351,7 @@ </div> <p t-if="slide.tag_ids" style="padding-top: 5px;"> <t t-foreach="slide.tag_ids" t-as="att_tag"> - <a t-attf-href="/slides/#{slug(channel)}/tag/#{slug(att_tag)}" t-attf-class="label label-default #{tag and tag.name == att_tag.name and 'label-primary' ''} text-muted" t-field="att_tag.name"/> + <a t-attf-href="/slides/#{slug(channel)}/tag/#{slug(att_tag)}" t-attf-class="badge badge-secondary #{tag and tag.name == att_tag.name and 'badge-primary' ''} text-muted" t-field="att_tag.name"/> </t> </p> </div> @@ -405,7 +405,7 @@ <div clas="row"> <div class="col-lg-8" t-if="slide.tag_ids"> <t t-foreach="slide.tag_ids" t-as="slide_tag"> - <a t-attf-href="/slides/#{slug(slide.channel_id)}/tag/#{slug(slide_tag)}" t-attf-class="label label-default ml4 mb4 float-right #{tag and tag.id == slide_tag.id and 'label-primary' ''}" t-field="slide_tag.name"/> + <a t-attf-href="/slides/#{slug(slide.channel_id)}/tag/#{slug(slide_tag)}" t-attf-class="badge badge-secondary ml4 mb4 float-right #{tag and tag.id == slide_tag.id and 'badge-primary' ''}" t-field="slide_tag.name"/> </t> </div> </div> |
