Skip to content

Adminhtml: improved info for order sent status #4623

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -19,21 +19,16 @@
<?php
$orderAdminDate = $this->formatDate($_order->getCreatedAtDate(), 'medium', true);
$orderStoreDate = $this->formatDate($_order->getCreatedAtStoreDate(), 'medium', true);
$emailSentInfo = $_order->getEmailSent() ? Mage::helper('sales')->__('Sent') : Mage::helper('sales')->__('Not sent');
?>
<div class="box-left">
<!--Order Information-->
<div class="entry-edit">
<?php if ($_order->getEmailSent()):
$_email = Mage::helper('sales')->__('the order confirmation email was sent');
else:
$_email = Mage::helper('sales')->__('the order confirmation email is not sent');
endif; ?>
<div class="entry-edit-head">
<?php if ($this->getNoUseOrderLink()): ?>
<h4 class="icon-head head-account" data-copy-text="<?php echo $_order->getRealOrderId() ?>"><?php echo Mage::helper('sales')->__('Order # %s', $this->escapeHtml($_order->getRealOrderId())) ?> (<?php echo $_email ?>)</h4>
<h4 class="icon-head head-account" data-copy-text="<?php echo $_order->getRealOrderId() ?>"><?php echo Mage::helper('sales')->__('Order # %s', $this->escapeHtml($_order->getRealOrderId())) ?></h4>
<?php else: ?>
<a href="<?php echo $this->getViewUrl($_order->getId()) ?>"><?php echo Mage::helper('sales')->__('Order # %s', $this->escapeHtml($_order->getRealOrderId())) ?></a>
<strong>(<?php echo $_email ?>)</strong>
<?php endif ?>
</div>
<div class="fieldset">
@@ -52,6 +47,10 @@ $orderStoreDate = $this->formatDate($_order->getCreatedAtStoreDate(), 'medium',
<td class="label"><label><?php echo Mage::helper('sales')->__('Order Status') ?></label></td>
<td class="value"><strong><span id="order_status"><?php echo $_order->getStatusLabel() ?></span></strong></td>
</tr>
<tr>
<td class="label"><label><?php echo Mage::helper('sales')->__('Order Confirmation Email') ?></label></td>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would prefer a two-word label. These two variants are more appropriate.

Variant 1

Suggested change
<td class="label"><label><?php echo Mage::helper('sales')->__('Order Confirmation Email') ?></label></td>
<td class="label"><label><?php echo Mage::helper('sales')->__('Email Confirmation') ?></label></td>

Variant 2

Suggested change
<td class="label"><label><?php echo Mage::helper('sales')->__('Order Confirmation Email') ?></label></td>
<td class="label"><label><?php echo Mage::helper('sales')->__('Order Confirmation') ?></label></td>

I asked Copilot and Chatgpt for their opinions, both argued that "Order Confirmation" is more appropriate, as it covers confirmations sent by email, SMS, phone. Personally, I would prefer Email Confirmation because it specifies the confirmation method available in OpenMage.

If we are analyzing the label names in that block that obviously refer to the order, then the word "Order" should be removed from the "Order Date" and "Order Status" forms. Here is what it would look like in my opinion

order_block

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I disagree on that.

  • "Email" suffix ... its no SMS, fax, ...
  • "Order" prefix ... this block is displayed for orders, invoices, shippings ... so it could be missleading w/o it.

I really thought about how to name it - and it was also named "order confirmation email" before.

<td class="value"><strong><?php echo $emailSentInfo ?></strong></td>
</tr>
<tr>
<td class="label"><label><?php echo Mage::helper('sales')->__('Purchased From') ?></label></td>
<td class="value"><strong><?php echo $this->getOrderStoreName(); ?></strong></td>
@@ -75,7 +74,8 @@ $orderStoreDate = $this->formatDate($_order->getCreatedAtStoreDate(), 'medium',
<?php if($_order->getRemoteIp() && $this->shouldDisplayCustomerIp()): ?>
<tr>
<td class="label"><label><?php echo Mage::helper('sales')->__('Placed from IP') ?></label></td>
<td class="value"><strong><?php echo $this->escapeHtml($_order->getRemoteIp()); echo ($_order->getXForwardedFor())?' (' . $this->escapeHtml($_order->getXForwardedFor()) . ')':''; ?></strong></td>
<td class="value"><strong><?php echo $this->escapeHtml($_order->getRemoteIp());
echo ($_order->getXForwardedFor()) ? ' (' . $this->escapeHtml($_order->getXForwardedFor()) . ')' : ''; ?></strong></td>
</tr>
<?php endif ?>
<?php if($_order->getGlobalCurrencyCode() != $_order->getBaseCurrencyCode()): ?>
@@ -107,7 +107,7 @@ $orderStoreDate = $this->formatDate($_order->getCreatedAtStoreDate(), 'medium',
<tr>
<td class="label"><label><?php echo Mage::helper('sales')->__('Customer Name') ?></label></td>
<td class="value">
<?php if ($_customerUrl=$this->getCustomerViewUrl()) : ?>
<?php if ($_customerUrl = $this->getCustomerViewUrl()) : ?>
<a href="<?php echo $_customerUrl ?>" target="_blank"><strong><?php echo $this->escapeHtml($_order->getCustomerName()) ?></strong></a>
<?php else: ?>
<strong><?php echo $this->escapeHtml($_order->getCustomerName()) ?></strong>
3 changes: 3 additions & 0 deletions app/locale/en_US/Mage_Sales.csv
Original file line number Diff line number Diff line change
@@ -885,3 +885,6 @@
"the order confirmation email was sent","the order confirmation email was sent"
"the shipment email is not sent","the shipment email is not sent"
"the shipment email was sent","the shipment email was sent"
"Order Confirmation Email","Order Confirmation Email"
"Sent","Sent"
"Not sent","Not sent"
10 changes: 8 additions & 2 deletions skin/adminhtml/default/default/boxes.css
Original file line number Diff line number Diff line change
@@ -232,10 +232,16 @@ tr.dynamic-grid input.input-text { width:154px; }
cursor: pointer;
width: 12px;
height: 12px;
margin: 2px 0 0 2px;
margin-left: 4px;
}

.entry-edit-head .icon-copy { width: 11px; height: 11px; margin: 0 0 0 5px; filter: hue-rotate(0) brightness(0) contrast(1) saturate(0) invert(1); }
.entry-edit-head .icon-copy {
width: 11px;
height: 11px;
margin: 5px 0;
filter: hue-rotate(0) brightness(0) contrast(1) saturate(0) invert(1);
float: right;
}

.icon-copy-copied { background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 30 30"><path d="M26.98 5.99a1 1 0 0 0-.687.303L11 21.586l-6.293-6.293a1 1 0 1 0-1.414 1.414l7 7a1 1 0 0 0 1.414 0l16-16a1 1 0 0 0-.727-1.717z"/></svg>'); }

1 change: 1 addition & 0 deletions skin/adminhtml/default/openmage/override.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion skin/adminhtml/default/openmage/override.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions skin/adminhtml/default/openmage/scss/override.scss
Original file line number Diff line number Diff line change
@@ -192,6 +192,7 @@ small {
height: 16px;
margin: 8px 0 0 5px;
filter: revert;
float: right;
}
}