Hello. I need to set a predefined comment on changing the order status. E.g I have an order status "Out for delivery" , so when i set this status, comment field should populate with a predefined comment.
No OC version posted. Forum rules.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
By default there's no such functionality, so the only way to achieve this is with custom modification. For starters, Try to search the Marketplace for one. Task seems pretty trivial to me.
Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com
Well, for OC v.1.5.6.x Versions, this nice-n-easy VqMod achieved something like
this, and it could possibly be made work in your Version too, if you have a little
knowledge on such.
Good Luck!
Ernie
---
admin_order_status_notify_comment.xml
---
this, and it could possibly be made work in your Version too, if you have a little
knowledge on such.
Good Luck!
Ernie
---
admin_order_status_notify_comment.xml
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<modification>
<id><![CDATA[Admin Order Status Notify Comment]]></id>
<version><![CDATA[OS v.1.5.6.5]]></version>
<vqmver><![CDATA[2.4.1]]></vqmver>
<author><![CDATA[hakim_jz]]></author>
<file name="admin/view/template/sale/order_info.tpl">
<operation error="log">
<search position="after"><![CDATA[<td><textarea name="comment" cols="40" rows="8" style="width: 99%"></textarea>]]></search>
<add><![CDATA[
<div style="margin-top: 10px;">
<a id="button-template-notify-a" class="button">A Comment</a>
<a id="button-template-notify-b" class="button">B Comment</a>
<a id="button-template-notify-c" class="button">C Comment</a>
<a id="button-template-notify-d" class="button">D Comment</a>
<a id="button-template-notify-e" class="button">E Comment</a>
<script type="text/javascript"><!--
$('#button-template-notify-a').live('click', function() {
var template_msg = 'Dear <?php echo $firstname; ?> <?php echo $lastname; ?>,\n\nThis is the message A you need to replace\n\nThank You';
$('textarea[name=\'comment\']').val(template_msg);
});
$('#button-template-notify-b').live('click', function() {
var template_msg = 'Dear <?php echo $firstname; ?> <?php echo $lastname; ?>,\n\nThis is the message B you need to replace\n\nThank You';
$('textarea[name=\'comment\']').val(template_msg);
});
$('#button-template-notify-c').live('click', function() {
var template_msg = 'Dear <?php echo $firstname; ?> <?php echo $lastname; ?>,\n\nThis is the message C you need to replace\n\nThank You';
$('textarea[name=\'comment\']').val(template_msg);
});
$('#button-template-notify-d').live('click', function() {
var template_msg = 'Dear <?php echo $firstname; ?> <?php echo $lastname; ?>,\n\nThis is the message D you need to replace\n\nThank You';
$('textarea[name=\'comment\']').val(template_msg);
});
$('#button-template-notify-e').live('click', function() {
var template_msg = 'Dear <?php echo $firstname; ?> <?php echo $lastname; ?>,\n\nThis is the message E you need to replace\n\nThank You';
$('textarea[name=\'comment\']').val(template_msg);
});
//--></script>
</div>
]]></add>
</operation>
</file>
</modification>
My Github OC Site: https://github.com/IP-CAM
5'200 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.
And with small changes, work on 3.0.2.0
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
Who is online
Users browsing this forum: No registered users and 273 guests