<form id="calcexp_new_bill_form" action=""  method="POST" onsubmit="{$ok_action}">

    <div class="ui-dialog-left-menu-big ui-corner-all">
        <p style="text-align:center;">
            <span onclick="$('#msgdialogcalcexp_new_bill_dialog').dialog('close');" class="dialog_make_btn32 close smallbtns ui-corner-all" title="{$i.basic_cancel}"></span>
            <span onclick="{$ok_action}" class="dialog_make_btn32 ok smallbtns ui-corner-all" title="{$i.basic_view}"></span>
        </p>
    </div>
    <div class="ui-dialog-main-big">
        <fieldset class="noborder">
            {include file='r/radio.tpl' name="calcexp_invoice_active" title="calcexp_invoice_active"
                list=$invoice_active_list id="id" text="title" default=1}
        </fieldset>
        
        {if $calcexp_add_to_show}
            <fieldset class="bordertop">
                {include file='r/checkbox.tpl' name="calcexp_add_to_offers" title="calcexp_add_to_offers"
                    default=true labelclass='label2 header1 ui-corner-all'
                    add_icons_file='warning' past_span_text=$i.calcexp_add_to_offers1
                    filter_extra="onchange='calculateaccordingexpenditure.toggle_transfer_to_loc();'"}
                <div style="display: none">
                    {include file='r/checkbox.tpl' name="calcexp_add_to_fees" title="calcexp_add_to_fees"
                        default=false labelclass='label2 header2 ui-corner-all'
                        add_icons_file='warning' past_span_text=$i.calcexp_add_to_fees1}
                </div>
            </fieldset>
        {/if}
        
        {if $calcexp_auto_offers}
            {if !empty($calcexp_shall_add_existing_fees_to_offer)}
                <fieldset class="noborder" style="margin-bottom:15px;">
                    {include file='r/select.tpl' name="calcexp_add_existing_fees_to_offer" title="projectadmin_add_fees_to_offer" class="t-long"
                        list=$calcexp_shall_add_existing_fees_to_offer id="id" text="project" default=true labelclass="label2 header1 ui-corner-all"
                        filter_extra='multiple="multiple" size="5"' style="width:650px;"}
                    <div class="warning warningborder ui-corner-all is_calc_from_expenses_info">
                        {$i.projectadmin_auto_offers}<br />
                        {$i.projectadmin_auto_offers2}<br />
                        {$i.projectadmin_auto_offers3}
                    </div>
                </fieldset>
            {/if}
        {/if}
        
        {if $calcexp_add_to_show}
            <fieldset class="bordertop">
                {include file='r/radio.tpl' name="calcexp_round_commercial" title="calcexp_round_commercial"
                    list=$round_commercial_list id="id" text="title" default=1}
            </fieldset>
        {/if}
        
        {if !empty($calcexp_estimations_list)}
        <fieldset class="bordertop" style="margin-top:15px;">
            {include file='r/select.tpl' name="calcexp_replace_offers_estimation" title="calcexp_replace_offers_estimation" class="t-long"
                list=$calcexp_estimations_list id="id" text="estimation_name" default='' labelclass="label2 header1 ui-corner-all"
                filter_extra='multiple="multiple" size="5"' style="width:650px;"}
        </fieldset>
        {/if}
        
        {if $calcexp_auto_loc}
            <fieldset id="calcexp_add_to_loc_container" class="bordertop">
                {include file='r/checkbox.tpl' name="calcexp_add_to_loc" title="calcexp_add_to_loc"
                    default=false labelclass='label2 header2 ui-corner-all'
                    filter_extra="onchange='calculateaccordingexpenditure.toggle_level_of_completion_view();'"}
                <div id="calcexp_add_to_loc_view" style="display: none;">
                    {include file='Calcexp/edit_popform_level_of_completion_headers.tpl'
                        prefix="calcexp_add_to_loc" from_calcexp=true}
                </div>
            </fieldset>
        {/if}

        <fieldset class="bordertop">
            {include file='r/textarea.tpl' name="calcexp_description"
            title="calcexp_description"
            text="name" class="ui-corner-all t-mid"
            style="width:650px;" default=$calcexp_description}
        </fieldset>

    </div>
</form>
