{extends file="layout.html"} {block name=title}LMS: {$layout.pagetitle|striphtml}{/block} {block name=module_content}

{$layout.pagetitle}

{$speed_unit_type = ConfigHelper::getConfig('phpui.speed_unit_type', 1000)} {$speed_unit_aggregation_threshold = ConfigHelper::getConfig('phpui.speed_unit_aggregation_threshold', 5)} {function bitrate_restrictions} {if $day}{convert_to_units($day * $speed_unit_type, $speed_unit_aggregation_threshold, $speed_unit_type)}/s{else}{trans("no limits")}{/if} ({trans("night:")} {if $night}{convert_to_units($night * $speed_unit_type, $speed_unit_aggregation_threshold, $speed_unit_type)}/s{else}{trans("not defined")}{/if}) {/function} {function restrictions} {if $day}{$day}{else}{trans("no limits")}{/if} ({trans("night:")} {if $night}{$night|default:0}{else}{trans("not defined")}{/if}) {/function} {function burst_time_restrictions} {if $day}{$day} s{else}{trans("not defined")}{/if} ({trans("night:")} {if $night}{$night|default:"0"} s{else}{trans("not defined")}{/if}) {/function} {function burst_restrictions} {if $day}{$day} kbit/s{else}{trans("not defined")}{/if} ({trans("night:")} {if $night}{$night|default:"0"} kbit/s{else}{trans("not defined")}{/if}) {/function} {function user_restrictions} {if !isset($limit) || !$limit} {trans("no limit")} {else} {$limit} {/if} {/function} {if $tariff.type != $smarty.const.SERVICE_PHONE && $tariff.type != $smarty.const.SERVICE_TV && $tariff.type != $smarty.const.SERVICE_INTERNET} {else if $tariff.type == $smarty.const.SERVICE_PHONE} {/if}
{$tariff.name} ({$tariff.id|string_format:"%04d"})
{if $tariff.type != $smarty.const.SERVICE_PHONE} {/if}
{if isset($tariff.numberplan)} {/if} {if $tariff.datefrom || $tariff.dateto} {/if} {if !empty($tariff.prodid)} {/if} {if ConfigHelper::checkConfig('privileges.superuser') || !ConfigHelper::checkConfig('privileges.hide_summaries')} {/if} {if $tariff.authtype} {/if} {if $tariff.description} {/if} {if $tariff.promotions} {/if}
{trans("Value:")} {moneyf($tariff.value, $tariff.currency)} {if $tariff.period} {assign var=tperiod value=$tariff.period}({$_PERIODS.$tperiod}) {else} ({trans("period undefined")}) {/if}
{trans("Split payment:")} {if $tariff.splitpayment}{trans("yes")}{else}{trans("no")}{/if}
{trans("Tax category:")} {if $tariff.taxcategory} {$_TAX_CATEGORIES[$tariff.taxcategory].label} {else} {trans("- none -")} {/if}
{trans("Tax:")} {$tariff.tax}
{trans("Type:")} {$_SERVICETYPES[$tariff.type]}
{trans("Tags:")} {foreach $tariff.tags as $tarifftag} {$tarifftag.name} {if !$tarifftag@last} / {/if} {foreachelse} - {/foreach}
{trans("Numbering Plan:")} {$tariff.numberplan.template} ({$_NUM_PERIODS[$tariff.numberplan.period]})
{trans("Period:")} {if $tariff.datefrom} {trans("from:")} {$tariff.datefrom|date_format:"%Y/%m/%d"} {/if} {if $tariff.dateto} {trans("to:")} {$tariff.dateto|date_format:"%Y/%m/%d"} {/if}
{trans("Product ID:")} {$tariff.prodid}
{trans("Number of customers:")} {$tariff.customerscount|default:0} ({$tariff.count|default:0}, ">{$tariff.activecount|default:0})
{trans("Avg. monthly income:")} {foreach $tariff.totalval as $currency => $totalval} {if !$totalval@first}
{/if} {moneyf($totalval, $currency)} {/foreach}
{trans("Purpose:")}
    {foreach $_SESSIONTYPES as $idx => $sessiontype} {if $tariff.authtype & $idx}
  1. {$sessiontype.label}
  2. {/if} {/foreach}
{trans("Description:")} {$tariff.description|replace:"\n":"
"}
{trans("Promotions:")} {foreach from=$tariff.promotions item=promo} {$promo.name}  {/foreach}
{trans("Upload rate:")} {bitrate_restrictions day=$tariff.uprate night=$tariff.uprate_n}
{trans("Upload ceil:")} {bitrate_restrictions day=$tariff.upceil night=$tariff.upceil_n}
{trans("Upload burst time:")} {burst_time_restrictions day=$tariff.up_burst_time night=$tariff.up_burst_time_n}
{trans("Upload burst threshold:")} {burst_restrictions day=$tariff.up_burst_threshold night=$tariff.up_burst_threshold_n}
{trans("Upload burst limit:")} {burst_restrictions day=$tariff.up_burst_limit night=$tariff.up_burst_limit_n}
{trans("Download rate:")} {bitrate_restrictions day=$tariff.downrate night=$tariff.downrate_n}
{trans("Download ceil:")} {bitrate_restrictions day=$tariff.downceil night=$tariff.downceil_n}
{trans("Download burst time:")} {burst_time_restrictions day=$tariff.down_burst_time night=$tariff.down_burst_time_n}
{trans("Download burst threshold:")} {burst_restrictions day=$tariff.down_burst_threshold night=$tariff.down_burst_threshold_n}
{trans("Download burst limit:")} {burst_restrictions day=$tariff.down_burst_limit night=$tariff.down_burst_limit_n}
{trans("Connection limit:")} {restrictions day=$tariff.climit night=$tariff.climit_n}
{trans("Packet limit:")} {restrictions day=$tariff.plimit night=$tariff.plimit_n}
{trans("Data limit:")} {if $tariff.dlimit}{$tariff.dlimit}{else}{trans("no limits")}{/if}
{foreach $_ACCOUNTTYPES as $typeidx => $type} {$alias=$type.alias|cat:"_limit"} {/foreach} {foreach $_ACCOUNTTYPES as $typeidx => $type} {$alias="quota_"|cat:$type.alias|cat:"_limit"} {/foreach}
{trans("Limit of domains:")} {user_restrictions limit=$tariff.domain_limit}
{trans("Limit of account aliases:")} {user_restrictions limit=$tariff.alias_limit}
{$type.accountlimitlabel}{user_restrictions limit=$tariff[$alias]}
{$type.accountquotalabel}{user_restrictions limit=$tariff[$alias]}
{trans("VoIP pricelist:")} {if $voip_fields.pricelist} {$voip_fields.pricelist} {else} {trans("not defined")} {/if}
{trans("Tariff rule:")} {if $voip_fields.rule_name} {$voip_fields.rule_name} {else} {trans("not defined")} {/if}
{trans("Edit")} {if $tariff.count == 0} {trans("Delete")} {/if}
{cycle values="light,lucid" print=false} {section name=l1 loop=$tariff.customers max=$tariff.rows} {section name=l2 loop=$tariff.customers start=$smarty.section.l1.index step=$tariff.rows} {/section}{cycle print=false} {sectionelse} {/section}
{trans("Customers in Subscription:")} {trans("Network:")}
({$tariff.customers[l2].id|string_format:"%04d"}) {$tariff.customers[l2].customername|truncate:50:" ..."} {if $tariff.customers[l2].cnt > 1}({$tariff.customers[l2].cnt}){/if}

{trans("No such customers with that subscription.")}

{trans("Move customers to subscription:")}
{/block}