{$_title = "[`Create invoice template`]"} {if !empty($template.id)} {$_title = "[`Edit invoice template`]"} {/if}
{* HEADER *}

[`Invoice templates`]

{* TEMPLATES *}
    {if empty($template.id)} {$_new_template = [ "0" => [ "id" => false, "name" => "[`New template`]" ] ]} {if !$templates} {$templates = $_new_template} {else} {$templates = $_new_template + $templates} {/if} {/if} {foreach $templates as $_template} {$_is_selected = ($template.id == $_template.id)}
  • {$_template.name|escape}
  • {/foreach}
{* TEMPLATE *}

[`Custom variables`]

[`Set up custom variables to show extra company-related data on an invoice; e.g., payment details, contact information, business license number, etc. Save appropriate values for your variables in each company’s settings and add the variables to an invoice template.`]

{function _renderParams} {/function} {capture assign="_param_template"}{_renderParams _param=[]}{/capture}
{if !empty($template.params)} {foreach $template.params as $_param} {_renderParams _param=$_param} {/foreach} {elseif empty($template.id)} {foreach $basic_params as $_param} {_renderParams _param=$_param} {/foreach} {/if}
[`Field name`] [`Type`] [`Placeholder`] [`Code`]
{if $template.style_version|default:'2' == '2' && !$wa->crm->isPremium()}

[`Powered by Webasyst CRM`]

{sprintf_wp( 'To hide the link to Webasyst CRM, buy premium ›', sprintf( 'href="%scrm/upgrade/"', $wa_backend_url ) )}

{/if}

HTML + Smarty

{capture assign="_preview_dialog_template"}
{$wa->csrf()}
{/capture}