Update inbox.tpl

This commit is contained in:
Ahmad Husein 2025-02-16 19:51:03 +07:00 committed by GitHub
parent 569d5e3670
commit 0b52d3eb35
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4,17 +4,17 @@
<div class="box box-primary">
<div class="box-body no-padding">
<div class="mailbox-read-info">
<h3>{$mail['subject']}</h3>
<h5>From: {$mail['from']}
<h3>{$mail.subject|escape:'html':'UTF-8'}</h3>
<h5>From: {$mail.from|escape:'html':'UTF-8'}
<span class="mailbox-read-time pull-right" data-toggle="tooltip" data-placement="top"
title="Read at {Lang::dateTimeFormat($mail['date_read'])}">{Lang::dateTimeFormat($mail['date_created'])}</span>
title="Read at {Lang::dateTimeFormat($mail.date_read)}">{Lang::dateTimeFormat($mail.date_created)}</span>
</h5>
</div>
<div class="mailbox-read-message">
{if Text::is_html($mail['body'])}
{$mail['body']}
{if Text::is_html($mail.body)}
{$mail.body}
{else}
{nl2br(htmlspecialchars_decode($mail['body']))}
{nl2br($mail.body|htmlspecialchars_decode)}
{/if}
</div>
</div>
@ -30,10 +30,10 @@
{/if}
</div>
<a href="{Text::url('mail')}" class="btn btn-primary"><i class="fa fa-arrow-left"></i> {Lang::T("Back")}</a>
<a href="{Text::url('mail/delete/')}{$mail['id']}" class="btn btn-danger"
<a href="{Text::url('mail/delete/')}{$mail.id}" class="btn btn-danger"
onclick="return ask(this, '{Lang::T("Delete")}?')"><i class="fa fa-trash-o"></i>
{Lang::T("Delete")}</a>
<a href="https://api.whatsapp.com/send?text={if Text::is_html($mail['body'])}{urlencode(strip_tags($mail['body']))}{else}{urlencode($mail['body'])}{/if}"
<a href="https://api.whatsapp.com/send?text={if Text::is_html($mail.body)}{urlencode(strip_tags($mail.body))}{else}{urlencode($mail.body)}{/if}"
class="btn btn-success"><i class="fa fa-share"></i> {Lang::T("Share")}</a>
</div>
<!-- /.box-footer -->
@ -44,7 +44,7 @@
<form method="post">
<div class="box-tools pull-right">
<div class="input-group">
<input type="text" name="q" class="form-control" placeholder="{Lang::T('Search')}..." value="{$q}">
<input type="text" name="q" class="form-control" placeholder="{Lang::T('Search')}..." value="{$q|escape:'html':'UTF-8'}">
<div class="input-group-btn">
<button type="submit" class="btn btn-success"><span
class="glyphicon glyphicon-search"></span></button>
@ -73,22 +73,27 @@
{foreach $mails as $mail}
<tr>
<td class="mailbox-subject">
<a href="{Text::url('mail/view/')}{$mail['id']}">
<a href="{Text::url('mail/view/')}{$mail.id}">
<div>
{if $mail['date_read'] == null}
{if $mail.date_read == null}
<i class="fa fa-envelope text-yellow" title="unread"></i>
{else}
<i class="fa fa-envelope-o text-yellow" title="read"></i>
{/if}
<b>{$mail['subject']}</b>
<b>{$mail.subject|escape:'html':'UTF-8'}</b>
</div>
</a>
</td>
<td class="mailbox-name">{$mail['from']}</td>
<td class="mailbox-name">{$mail.from|escape:'html':'UTF-8'}</td>
<td class="mailbox-attachment"></td>
<td class="mailbox-date">{Lang::dateTimeFormat($mail['date_created'])}</td>
<td class="mailbox-date">{Lang::dateTimeFormat($mail.date_created)}</td>
</tr>
{/foreach}
{if empty($mails)}
<tr>
<td colspan="4">{Lang::T("No email found.")}</td>
</tr>
{/if}
</tbody>
</table>
</div>
@ -109,7 +114,6 @@
</div>
</div>
</div>
{/if}
{include file="customer/footer.tpl"}