fix(fusion_clock): keep inline nav bars instead of a shared template
A shared portal_employee_navbar template broke fusion_planning, which xpath-inherits each clock page's inline fclk-nav-bar to inject its Schedule tab (anchored on a[@href='/my/clock/timesheets']). Revert to the original inline-nav pattern on all four pages and append the Payslips item to each — zero changes needed in fusion_planning. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -286,9 +286,42 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- Navigation Bar -->
|
<!-- Navigation Bar -->
|
||||||
<t t-call="fusion_clock.portal_employee_navbar">
|
<div class="fclk-nav-bar">
|
||||||
<t t-set="active" t-value="'clock'"/>
|
<a href="/my/clock" class="fclk-nav-item fclk-nav-active">
|
||||||
</t>
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<circle cx="12" cy="12" r="10"/>
|
||||||
|
<polyline points="12 6 12 12 16 14"/>
|
||||||
|
</svg>
|
||||||
|
<span>Clock</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/timesheets" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
||||||
|
<line x1="16" y1="2" x2="16" y2="6"/>
|
||||||
|
<line x1="8" y1="2" x2="8" y2="6"/>
|
||||||
|
<line x1="3" y1="10" x2="21" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Timesheets</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/reports" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
||||||
|
<polyline points="14 2 14 8 20 8"/>
|
||||||
|
<line x1="16" y1="13" x2="8" y2="13"/>
|
||||||
|
<line x1="16" y1="17" x2="8" y2="17"/>
|
||||||
|
</svg>
|
||||||
|
<span>Reports</span>
|
||||||
|
</a>
|
||||||
|
<t t-if="show_payslips">
|
||||||
|
<a href="/my/clock/payslips" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
||||||
|
<line x1="2" y1="10" x2="22" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Payslips</span>
|
||||||
|
</a>
|
||||||
|
</t>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -47,9 +47,40 @@
|
|||||||
</div>
|
</div>
|
||||||
</t>
|
</t>
|
||||||
|
|
||||||
<t t-call="fusion_clock.portal_employee_navbar">
|
<div class="fclk-nav-bar">
|
||||||
<t t-set="active" t-value="'payslips'"/>
|
<a href="/my/clock" class="fclk-nav-item">
|
||||||
</t>
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<circle cx="12" cy="12" r="10"/>
|
||||||
|
<polyline points="12 6 12 12 16 14"/>
|
||||||
|
</svg>
|
||||||
|
<span>Clock</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/timesheets" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
||||||
|
<line x1="16" y1="2" x2="16" y2="6"/>
|
||||||
|
<line x1="8" y1="2" x2="8" y2="6"/>
|
||||||
|
<line x1="3" y1="10" x2="21" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Timesheets</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/reports" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
||||||
|
<polyline points="14 2 14 8 20 8"/>
|
||||||
|
<line x1="16" y1="13" x2="8" y2="13"/>
|
||||||
|
<line x1="16" y1="17" x2="8" y2="17"/>
|
||||||
|
</svg>
|
||||||
|
<span>Reports</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/payslips" class="fclk-nav-item fclk-nav-active">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
||||||
|
<line x1="2" y1="10" x2="22" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Payslips</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</t>
|
</t>
|
||||||
@@ -118,54 +149,43 @@
|
|||||||
</a>
|
</a>
|
||||||
</t>
|
</t>
|
||||||
|
|
||||||
<t t-call="fusion_clock.portal_employee_navbar">
|
<div class="fclk-nav-bar">
|
||||||
<t t-set="active" t-value="'payslips'"/>
|
<a href="/my/clock" class="fclk-nav-item">
|
||||||
</t>
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<circle cx="12" cy="12" r="10"/>
|
||||||
|
<polyline points="12 6 12 12 16 14"/>
|
||||||
|
</svg>
|
||||||
|
<span>Clock</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/timesheets" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
||||||
|
<line x1="16" y1="2" x2="16" y2="6"/>
|
||||||
|
<line x1="8" y1="2" x2="8" y2="6"/>
|
||||||
|
<line x1="3" y1="10" x2="21" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Timesheets</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/reports" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
||||||
|
<polyline points="14 2 14 8 20 8"/>
|
||||||
|
<line x1="16" y1="13" x2="8" y2="13"/>
|
||||||
|
<line x1="16" y1="17" x2="8" y2="17"/>
|
||||||
|
</svg>
|
||||||
|
<span>Reports</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/payslips" class="fclk-nav-item fclk-nav-active">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
||||||
|
<line x1="2" y1="10" x2="22" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Payslips</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</t>
|
</t>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<!-- Shared employee bottom nav (Clock / Timesheets / Reports / Payslips).
|
|
||||||
`active` = clock|timesheets|reports|payslips. Payslips tab shows only
|
|
||||||
when show_payslips is truthy. -->
|
|
||||||
<template id="portal_employee_navbar" name="Fusion Clock Employee Navbar">
|
|
||||||
<div class="fclk-nav-bar">
|
|
||||||
<a href="/my/clock" t-attf-class="fclk-nav-item#{' fclk-nav-active' if active == 'clock' else ''}">
|
|
||||||
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
||||||
<circle cx="12" cy="12" r="10"/>
|
|
||||||
<polyline points="12 6 12 12 16 14"/>
|
|
||||||
</svg>
|
|
||||||
<span>Clock</span>
|
|
||||||
</a>
|
|
||||||
<a href="/my/clock/timesheets" t-attf-class="fclk-nav-item#{' fclk-nav-active' if active == 'timesheets' else ''}">
|
|
||||||
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
||||||
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
|
||||||
<line x1="16" y1="2" x2="16" y2="6"/>
|
|
||||||
<line x1="8" y1="2" x2="8" y2="6"/>
|
|
||||||
<line x1="3" y1="10" x2="21" y2="10"/>
|
|
||||||
</svg>
|
|
||||||
<span>Timesheets</span>
|
|
||||||
</a>
|
|
||||||
<a href="/my/clock/reports" t-attf-class="fclk-nav-item#{' fclk-nav-active' if active == 'reports' else ''}">
|
|
||||||
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
||||||
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
|
||||||
<polyline points="14 2 14 8 20 8"/>
|
|
||||||
<line x1="16" y1="13" x2="8" y2="13"/>
|
|
||||||
<line x1="16" y1="17" x2="8" y2="17"/>
|
|
||||||
</svg>
|
|
||||||
<span>Reports</span>
|
|
||||||
</a>
|
|
||||||
<t t-if="show_payslips">
|
|
||||||
<a href="/my/clock/payslips" t-attf-class="fclk-nav-item#{' fclk-nav-active' if active == 'payslips' else ''}">
|
|
||||||
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
||||||
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
|
||||||
<line x1="2" y1="10" x2="22" y2="10"/>
|
|
||||||
</svg>
|
|
||||||
<span>Payslips</span>
|
|
||||||
</a>
|
|
||||||
</t>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
</odoo>
|
</odoo>
|
||||||
|
|||||||
@@ -60,9 +60,42 @@
|
|||||||
</t>
|
</t>
|
||||||
|
|
||||||
<!-- Navigation Bar -->
|
<!-- Navigation Bar -->
|
||||||
<t t-call="fusion_clock.portal_employee_navbar">
|
<div class="fclk-nav-bar">
|
||||||
<t t-set="active" t-value="'reports'"/>
|
<a href="/my/clock" class="fclk-nav-item">
|
||||||
</t>
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<circle cx="12" cy="12" r="10"/>
|
||||||
|
<polyline points="12 6 12 12 16 14"/>
|
||||||
|
</svg>
|
||||||
|
<span>Clock</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/timesheets" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
||||||
|
<line x1="16" y1="2" x2="16" y2="6"/>
|
||||||
|
<line x1="8" y1="2" x2="8" y2="6"/>
|
||||||
|
<line x1="3" y1="10" x2="21" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Timesheets</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/reports" class="fclk-nav-item fclk-nav-active">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
||||||
|
<polyline points="14 2 14 8 20 8"/>
|
||||||
|
<line x1="16" y1="13" x2="8" y2="13"/>
|
||||||
|
<line x1="16" y1="17" x2="8" y2="17"/>
|
||||||
|
</svg>
|
||||||
|
<span>Reports</span>
|
||||||
|
</a>
|
||||||
|
<t t-if="show_payslips">
|
||||||
|
<a href="/my/clock/payslips" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
||||||
|
<line x1="2" y1="10" x2="22" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Payslips</span>
|
||||||
|
</a>
|
||||||
|
</t>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -120,9 +120,42 @@
|
|||||||
</t>
|
</t>
|
||||||
|
|
||||||
<!-- Navigation Bar -->
|
<!-- Navigation Bar -->
|
||||||
<t t-call="fusion_clock.portal_employee_navbar">
|
<div class="fclk-nav-bar">
|
||||||
<t t-set="active" t-value="'timesheets'"/>
|
<a href="/my/clock" class="fclk-nav-item">
|
||||||
</t>
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<circle cx="12" cy="12" r="10"/>
|
||||||
|
<polyline points="12 6 12 12 16 14"/>
|
||||||
|
</svg>
|
||||||
|
<span>Clock</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/timesheets" class="fclk-nav-item fclk-nav-active">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"/>
|
||||||
|
<line x1="16" y1="2" x2="16" y2="6"/>
|
||||||
|
<line x1="8" y1="2" x2="8" y2="6"/>
|
||||||
|
<line x1="3" y1="10" x2="21" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Timesheets</span>
|
||||||
|
</a>
|
||||||
|
<a href="/my/clock/reports" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/>
|
||||||
|
<polyline points="14 2 14 8 20 8"/>
|
||||||
|
<line x1="16" y1="13" x2="8" y2="13"/>
|
||||||
|
<line x1="16" y1="17" x2="8" y2="17"/>
|
||||||
|
</svg>
|
||||||
|
<span>Reports</span>
|
||||||
|
</a>
|
||||||
|
<t t-if="show_payslips">
|
||||||
|
<a href="/my/clock/payslips" class="fclk-nav-item">
|
||||||
|
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
||||||
|
<rect x="2" y="5" width="20" height="14" rx="2"/>
|
||||||
|
<line x1="2" y1="10" x2="22" y2="10"/>
|
||||||
|
</svg>
|
||||||
|
<span>Payslips</span>
|
||||||
|
</a>
|
||||||
|
</t>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user