Files
2026-04-20 20:31:02 -04:00

135 lines
5.8 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2026 Nexa Systems Inc.
License OPL-1 (Odoo Proprietary License v1.0)
Part of the Fusion Plating product family.
-->
<odoo>
<record id="view_fp_value_list" model="ir.ui.view">
<field name="name">fp.value.list</field>
<field name="model">fusion.plating.value</field>
<field name="arch" type="xml">
<list string="Values">
<field name="sequence" widget="handle"/>
<field name="number"/>
<field name="name"/>
<field name="set_id"/>
<field name="recognition_count"/>
<field name="active" widget="boolean_toggle"/>
</list>
</field>
</record>
<record id="view_fp_value_form" model="ir.ui.view">
<field name="name">fp.value.form</field>
<field name="model">fusion.plating.value</field>
<field name="arch" type="xml">
<form string="Value">
<header/>
<sheet>
<widget name="web_ribbon" title="Archived" bg_color="text-bg-danger" invisible="active"/>
<div class="oe_title">
<label for="name"/>
<h1><field name="name" placeholder="e.g. Do What's Best for the Customer"/></h1>
</div>
<group>
<group>
<field name="set_id"/>
<field name="number"/>
<field name="sequence"/>
</group>
<group>
<field name="icon" placeholder="fa-star"/>
<field name="color" widget="color_picker"/>
<field name="recognition_count"/>
<field name="active" widget="boolean_toggle"/>
</group>
</group>
<notebook>
<page string="Description">
<field name="description" placeholder="What does this value mean? How does it show up in daily work?"/>
</page>
<page string="Stories &amp; Examples">
<field name="examples" placeholder="Stories of people living this value."/>
</page>
</notebook>
</sheet>
</form>
</field>
</record>
<record id="view_fp_value_kanban" model="ir.ui.view">
<field name="name">fp.value.kanban</field>
<field name="model">fusion.plating.value</field>
<field name="arch" type="xml">
<kanban default_group_by="set_id" class="o_fp_value_kanban">
<field name="id"/>
<field name="name"/>
<field name="number"/>
<field name="icon"/>
<field name="color"/>
<field name="set_id"/>
<field name="recognition_count"/>
<templates>
<t t-name="card">
<div t-attf-class="o_fp_value_card oe_kanban_color_#{record.color.raw_value}">
<div class="d-flex align-items-start justify-content-between">
<div class="o_fp_value_number">
<t t-if="record.number.raw_value">
#<field name="number"/>
</t>
<t t-else="">
<i t-attf-class="fa #{record.icon.raw_value or 'fa-star'}" aria-hidden="true"/>
</t>
</div>
<i t-attf-class="fa #{record.icon.raw_value or 'fa-star'} o_fp_value_icon text-muted" aria-hidden="true"/>
</div>
<div class="o_fp_value_name mt-2">
<strong><field name="name"/></strong>
</div>
<div class="o_fp_value_meta mt-2 small text-muted">
<i class="fa fa-thumbs-up me-1" aria-hidden="true"/>
<field name="recognition_count"/> recognitions
</div>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<record id="view_fp_value_search" model="ir.ui.view">
<field name="name">fp.value.search</field>
<field name="model">fusion.plating.value</field>
<field name="arch" type="xml">
<search string="Values">
<field name="name"/>
<field name="set_id"/>
<field name="number"/>
<filter string="Archived" name="archived" domain="[('active', '=', False)]"/>
<group>
<filter string="Set" name="group_set" context="{'group_by': 'set_id'}"/>
</group>
</search>
</field>
</record>
<record id="action_fp_value" model="ir.actions.act_window">
<field name="name">Values</field>
<field name="res_model">fusion.plating.value</field>
<field name="view_mode">kanban,list,form</field>
<field name="help" type="html">
<p class="o_view_nocontent_smiling_face">
Add a value to your shop's set
</p>
<p>
Values are your shop's fundamentals — short, memorable
statements of how people are expected to behave. Create a
Value Set first, then add values to it.
</p>
</field>
</record>
</odoo>