Skip to content

Commit

Permalink
[IMP] hr: improve employee image placeholder
Browse files Browse the repository at this point in the history
task-3568588

closes odoo#139421

Signed-off-by: Sofie Gvaladze (sgv) <[email protected]>
  • Loading branch information
stefanorigano committed Nov 2, 2023
1 parent a2e3edd commit 3fbe3d8
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions addons/hr/views/hr_employee_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -279,14 +279,22 @@
<templates>
<t t-name="kanban-box">
<div class="oe_kanban_global_click o_kanban_record_has_image_fill o_hr_kanban_record">
<t t-if="!record.image_1024.raw_value">
<field name="avatar_128" class="o_kanban_image_fill_left d-block"
<t t-if="record.image_1024.raw_value">
<field name="image_1024" class="o_kanban_image_fill_left d-block" preview_image="image_128"
widget="background_image" options="{'zoom': true, 'zoom_delay': 1000}"/>
</t>
<t t-else="">
<field name="image_1024" class="o_kanban_image_fill_left d-block" preview_image="image_128"
<t t-elif="record.image_128.raw_value">
<field name="avatar_128" class="o_kanban_image_fill_left d-block"
widget="background_image" options="{'zoom': true, 'zoom_delay': 1000}"/>
</t>
<div t-else="" class="o_kanban_image_fill_left d-flex align-items-center justify-content-center bg-100 bg-gradient">
<svg class="w-75 h-75 opacity-50" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<g fill="currentColor">
<path d="M 10 11 C 4.08 11 2 14 2 16 L 2 19 L 18 19 L 18 16 C 18 14 15.92 11 10 11 Z"/>
<circle cx="10" cy="5.5" r="4.5"/>
</g>
</svg>
</div>

<div class="oe_kanban_details">
<div class="o_kanban_record_top">
Expand Down

0 comments on commit 3fbe3d8

Please sign in to comment.