Files
odoo_source/addons/project/views/project_milestone_views.xml
T
Rohitkumar (roku) 30f4b615d3 [FIX] project: stat button content align
Before this commit, the content of the stat button not aligned.

So this commit fixes by the stat button's content is aligned to the left and vertically centered.

task-3054386

closes odoo/odoo#108504

X-original-commit: e87284cebe64cc1f5bf31198ca221f14cffdc671
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2022-12-22 09:38:07 +01:00

65 lines
2.9 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="project_milestone_view_form" model="ir.ui.view">
<field name="name">project.milestone.view.form</field>
<field name="model">project.milestone</field>
<field name="arch" type="xml">
<form>
<sheet>
<div class="oe_button_box" name="button_box">
<button name="%(project.action_view_task_from_milestone)d"
type="action"
class="oe_stat_button"
icon="fa-tasks"
attrs="{'invisible': [('task_count', '=', 0)]}"
context="{'default_project_id': project_id}"
groups="project.group_project_milestone"
close="1"
>
<div class="o_form_field o_stat_info">
<span class="o_stat_value">
<field name="task_count" widget="statinfo" nolabel="1"/>
</span>
<span class="o_stat_text">Tasks</span>
</div>
</button>
</div>
<group>
<group name="main_details">
<field name="project_id" invisible="1"/>
<field name="name" placeholder="e.g: Product Launch"/>
<field name="deadline"/>
<field name="is_reached"/>
</group>
</group>
</sheet>
</form>
</field>
</record>
<record id="project_milestone_view_tree" model="ir.ui.view">
<field name="name">project.milestone.view.tree</field>
<field name="model">project.milestone</field>
<field name="arch" type="xml">
<tree decoration-success="can_be_marked_as_done" decoration-danger="is_deadline_exceeded and not can_be_marked_as_done" decoration-muted="is_reached" editable="bottom" sample="1">
<field name="name"/>
<field name="deadline" optional="show"/>
<field name="is_reached" optional="show"/>
<field name="is_deadline_exceeded" invisible="1"/>
<field name="task_count" invisible="1" />
<field name="can_be_marked_as_done" invisible="1"/>
<button name="action_view_tasks"
type="object"
title="View Tasks"
string="View Tasks"
class="btn btn-link float-end"
attrs="{'invisible': [('task_count', '=', 0)]}"
groups="project.group_project_milestone"
/>
</tree>
</field>
</record>
</odoo>