Show company on CEO client portfolio

This commit is contained in:
metatroncubeswdev 2026-08-31 17:34:23 -04:00
parent 24c4881744
commit 597b1bfddb
3 changed files with 7 additions and 3 deletions

View File

@ -725,11 +725,14 @@ class McsOperatingDashboard(models.Model):
currencies = invoices.mapped("currency_id") or partner.mcs_currency_id
currency_name = " / ".join(currencies.mapped("name")) if currencies else ""
default_currency_ids = currencies.ids
company = invoices[:1].company_id if invoices else projects[:1].company_id
invoice_dates = [date for date in invoices.mapped("invoice_date") if date]
rows.append(
{
"id": partner.id,
"name": partner.display_name,
"company_id": company.id if company else False,
"company": company.name if company else "",
"currency": currency_name,
"health": partner.mcs_account_health,
"active_workstreams": len(projects),

View File

@ -287,10 +287,10 @@
.o_mcs_table_head,
.o_mcs_table_row {
display: grid;
grid-template-columns: 1.3fr 92px 70px 70px 100px 100px 100px 96px minmax(180px, 1.2fr);
grid-template-columns: 1.3fr 1fr 92px 80px 70px 120px 120px 120px 96px minmax(180px, 1.2fr);
gap: 10px;
align-items: center;
min-width: 980px;
min-width: 1180px;
}
.o_mcs_table_head {

View File

@ -89,11 +89,12 @@
</header>
<div class="o_mcs_table">
<div class="o_mcs_table_head">
<span>Client</span><span>Health</span><span>Currency</span><span>Streams</span><span>Invoiced</span><span>Outstanding</span><span>Overdue</span><span>Last Invoice</span><span>Next Action</span>
<span>Client</span><span>Company</span><span>Health</span><span>Currency</span><span>Streams</span><span>Invoiced</span><span>Outstanding</span><span>Overdue</span><span>Last Invoice</span><span>Next Action</span>
</div>
<t t-foreach="state.data.portfolio" t-as="row" t-key="row.id">
<button class="o_mcs_table_row" t-on-click="() => this.openClient(row.id)">
<span t-esc="row.name"/>
<span t-esc="row.company"/>
<span t-attf-class="o_mcs_badge o_mcs_status_{{ row.health }}" t-esc="row.health"/>
<span t-esc="row.currency"/>
<span t-esc="row.active_workstreams"/>