Initial commit

This commit is contained in:
shopkeeperdev
2025-10-07 18:31:07 -04:00
commit 20786161b7
11 changed files with 272 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="order_additional_info">
<block class="Shopkeeper\VendorNotes\Block\Adminhtml\Order\View\VendorNotes" name="vendor_notes" template="Shopkeeper_VendorNotes::order/view/vendor_notes.phtml" />
</referenceBlock>
</body>
</page>

View File

@@ -0,0 +1,28 @@
<?php
/** @var \Shopkeeper\VendorNotes\Block\Adminhtml\Order\View\VendorNotes $block */
$notes = $block->getVendorNotes();
?>
<?php if (!empty($notes)): ?>
<section class="admin__page-section">
<div class="admin__page-section-title">
<span class="title"><?php echo __('Vendor Notes'); ?></span>
</div>
<div class="admin__page-section-content">
<div class="admin__page-section-item order-information">
<?php foreach ($notes as $index => $note): ?>
<div class="admin__page-section-item-content">
<div class="admin__page-section-item-title">
<span class="title"><?php echo __('Vendor Note %1', $index + 1); ?></span>
</div>
<div class="vendor-note-content" style="padding: 10px 0; line-height: 1.6;">
<?php echo $note; // Output as HTML for links and multi-lines ?>
</div>
</div>
<?php if ($index < count($notes) - 1): ?>
<div style="border-top: 1px solid #e3e3e3; margin: 15px 0;"></div>
<?php endif; ?>
<?php endforeach; ?>
</div>
</div>
</section>
<?php endif; ?>

View File

@@ -0,0 +1,16 @@
<?php
/** @var \Shopkeeper\VendorNotes\Block\Adminhtml\Order\View\VendorNotes $block */
$notes = $block->getVendorNotes();
?>
<?php if (!empty($notes)): ?>
<div class="admin__field">
<label class="label"><?php echo __('Vendor Notes'); ?>:</label>
<div class="control">
<ul>
<?php foreach ($notes as $note): ?>
<?php echo $note; // Output as HTML for links and multi-lines ?>
<?php endforeach; ?>
</ul>
</div>
</div>
<?php endif; ?>