Yes correct, but I am not skilled enough to make snipped with conditions if else ..
But probably in same case you should create new snippet for this, because the above language variables used store-wide.
Yes correct, but I am not skilled enough to make snipped with conditions if else ..
But probably in same case you should create new snippet for this, because the above language variables used store-wide.
Before upgrade I had
below
{hook name="orders:invoice_order_status_info"}
{if $doc_id_text}{$doc_id_text}{else}{__("proforma_title")}{/if}
part above looked like
{assign var="order_header" value=__("invoice")}
{if $status_settings.appearance_type == "I" && $order_info.doc_ids[$status_settings.appearance_type]}
{assign var="doc_id_text" value="{__("invoice_vat")} #`$order_info.doc_ids[$status_settings.appearance_type]`"}
{elseif $status_settings.appearance_type == "C" && $order_info.doc_ids[$status_settings.appearance_type]}
{assign var="doc_id_text" value="{__("credit_memo")} #`$order_info.doc_ids[$status_settings.appearance_type]`"}
{assign var="order_header" value=__("credit_memo")}
{elseif $status_settings.appearance_type == "O"}
{assign var="order_header" value=__("order_details")}
{/if}
Could you put code what does {{ o.invoice_id_text }} consist of ? I will put it to snippets with just modified text variables? I really need this one, just went like, hopefully no orders yet :D
Found code location
app\Tygh\Template\Document\Order\Variables\OrderVariable.php
// Invoice header and invoice id text
$this->data['invoice_header'] = __('invoice', array(), $context->getLangCode());
$this->data['invoice_id_text'] = __('order', array(), $context->getLangCode()) . ' #' . $order->getId();
$status_data = $order->getStatusData($context->getLangCode());
if (!empty($status_data['params']['appearance_type'])) {
if ($status_data['params']['appearance_type'] == 'O') {
$this->data['invoice_header'] = __('order_details', array(), $context->getLangCode());
} elseif (!empty($this->data['doc_ids'][$status_data['params']['appearance_type']])) {
$doc_id = $this->data['doc_ids'][$status_data['params']['appearance_type']];
if ($status_data['params']['appearance_type'] == 'I') {
$this->data['invoice_id_text'] = __('invoice', array(), $context->getLangCode()) . ' #' . $doc_id . '
' . $this->data['invoice_id_text'];
} elseif ($status_data['params']['appearance_type'] == 'C') {
$this->data['invoice_header'] = __('credit_memo', array(), $context->getLangCode());
$this->data['invoice_id_text'] = __('credit_memo', array(), $context->getLangCode()) . ' #' . $doc_id . '
' . $this->data['invoice_id_text'];
}
}
}
I want to make a snippet that would do this
$this->data['invoice_id_text'] = __('my_order', array(), $context->getLangCode()) . ' #' . $order->getId();
$this->data['invoice_id_text'] = __('my_invoice', array(), $context->getLangCode()) . ' #' . $doc_id . '
' . $this->data['invoice_id_text'];
$this->data['invoice_id_text'] = __('my_credit_memo', array(), $context->getLangCode()) . ' #' . $doc_id . '
' . $this->data['invoice_id_text'];
This is because I need to have lang variables
'my_order' named "proforma invoice / translation"
'my_invoice' named "Commercial invoice / translation"
I do not want to change value for default order and invoice value that is widely used in backed.
Also I do not think having # built in is good idea.. Better to have something like
__('space') somebody will use "#" others may want to put "Nr" or "No"
Would someone please help me writing a snipped with conditions
if ($status_data['params']['appearance_type'] == 'O') {
print this
__('order', array(), $context->getLangCode()) . ' #' . $order->getId();
else if ($status_data['params']['appearance_type'] == 'I') {
print this
__('invoice', array(), $context->getLangCode()) . ' #' . $doc_id
Ok I thought I'll share my current workaround of how to actually edit and print invoices using tweak and send feature. Installed this free CKeditor full
http://marketplace.cs-cart.com/add-ons/site-management/full-ckeditor.html
In the old system we had a check box on each status to choose whether to send an email notification or not to the customer. Where do i set this in the new email template system ?
It's not part of the "email", but part of the 'notification'. I.e. the 'notification' can use the new or old email methods.
This is set in the Administrion/Order statuses page for each order status and it should show on the order.details page when doing a 'save' as to whether to notify customer, orders department, vendor, etc....
In the old system we had a check box on each status to choose whether to send an email notification or not to the customer. Where do i set this in the new email template system ?
Hello. Please check this article: http://docs.cs-cart.com/4.4.x/user_guide/orders/order_statuses/disable_notifications.html
Basically, with the new email template mode you go to Design > Email templates and change the status of notifications to Disabled. Depending on the tab you're on, that will disable notifications about this status for customers or for orders department. The article contains detailed instructions
Thank you !
Also the info in the email doesnt show my full company address, it only shows the first 2 lines, missing the zip code and county etc.
Where do i look to see where this info is pulled from
Hello. Please check this article: http://docs.cs-cart.com/4.4.x/user_guide/orders/order_statuses/disable_notifications.html
Basically, with the new email template mode you go to Design > Email templates and change the status of notifications to Disabled. Depending on the tab you're on, that will disable notifications about this status for customers or for orders department. The article contains detailed instructions
So now there are 2 places to enable/disable customer notifications on status changes? The Admin/Order Statuses and the Design/Emails pages? That's seems rather awkward. What is the precedence? If status Open has 'notify customer' set in the Order statuses page and disabled in the Design Email, who wins? Also for the reverse?
Why do you want to enable/disable at the Email document level versus the order status level where it's been since cs-cart inception?
Technically, a "notification" could be more than an email method. A notification might be an SMS message, a push to a user's phone, etc. Email is but one form of notification.
So now there are 2 places to enable/disable customer notifications on status changes? The Admin/Order Statuses and the Design/Emails pages? That's seems rather awkward. What is the precedence? If status Open has 'notify customer' set in the Order statuses page and disabled in the Design Email, who wins? Also for the reverse?
Why do you want to enable/disable at the Email document level versus the order status level where it's been since cs-cart inception?
Technically, a "notification" could be more than an email method. A notification might be an SMS message, a push to a user's phone, etc. Email is but one form of notification.
I notice that when appearance>use new email notifications is chosen then the old order statuses are not able to be seen/change so I assume the only place that works then is the new method.
If so, that's a good thing. However, I still contend that an "email" is one form of "notification" and the enable/disable should not be done at that level but should remain at the level of the order status so any type of "notification" would be controlled there.
....."email" is one form of "notification" and the enable/disable should not be done at that level but should remain at the level of the order status so any type of "notification" would be controlled there.
A very important point, I hope the csc team is listening,
Any SMS or other notification medium, 3rd party or otherwise is not part of the eMail template system and should be driven from the Order Status mechanism.
If so, that's a good thing. However, I still contend that an "email" is one form of "notification" and the enable/disable should not be done at that level but should remain at the level of the order status so any type of "notification" would be controlled there.
Id agree
Hi,
where can i edit the design of the email template?
The used colors are terrible.
Grey on grey, are you serious?
Hi,
where can i edit the design of the email template?
The used colors are terrible.
Grey on grey, are you serious?
I second this
It is kind of disappointing that in 451 or 461 {{ o.invoice_id_text }} is hardcoded and not a snipet..
some of the snippets are not working at all
some of the snippets are not working at all
What does not work for you?