<? global $vis_language;?>
<section id="breadcrumb" class="row m-b m-l-none m-r-none">
    <div class="col-sm-6">
        <h3 class="m-b-xs text-black"><? echo $vis_language['TXTLANGUAGE']; ?></h3>
        <ul class="breadcrumb bg-empty no-border m-b-xxs no-padder">
            	<li><a class="link" href="#/home/quick_view/<? echo $vis_language['TXTHOME']; ?>"><?echo $vis_language['TXTHOME'];?></a></li>
			<li><a class="link" href="#/setting/setting_menu/<? echo $vis_language['TXTSETTINGS'];?>" onclick="$('#vis_workpanel_div').visExecution('load_module','<? echo $vis_language['TXTSETTINGS'];?>',{'vis_module':'setting','vis_operation':'setting_menu'});"><?echo $vis_language['TXTSETTINGS'];?></a></li>
			<li><a class="link" href="#/setting/view_language/<? echo $vis_language['TXTLANGUAGE']; ?>" onclick="$('#vis_workpanel_div').visExecution('load_module','<? echo $vis_language['TXTSETTINGS'];?>',{'vis_module':'setting','vis_operation':'view_language'});"><? echo $vis_language['TXTLANGUAGE']; ?> </a></li>
            <li class="active"><?=$vis_language['TXTIMPORT']?></li>
        </ul>
    </div>
</section>
<section class="padder">
    <section class="panel panel-default">
        <header class="panel-heading sub_header"><?=$vis_language['TXTIMPORT']?></header>
        <div class="panel-body">
            <form class="form-horizontal" role="form" id="vis_language_import_form" name="vis_language_import_form" method="post">
				<input type="hidden" name="vis_client_id" id="vis_client_id" value="<? echo $operation['vis_client_id']; ?>" />
				<div class="form-group">
					<label for="vis_domain" class="col-sm-2 control-label"><? echo $vis_language['TXTLANGUAGE']; ?></label>
					<div class="col-sm-10">
						<select class="form-control input-sm selectpicker" name="vis_laguage_id" id="vis_laguage_id">
									<?php if($languageDetails != -1){
									foreach($languageDetails as $row) {?>
         <? if($row['language_id']==$language_id_active){?>
									<option value="<?php echo $row['language_id'];?>" selected="selected" class="alert-warning txt_left m-n no-radius" ><?php echo $row['language_name'];?></option>
         <? }else{?>
         <option value="<?php echo $row['language_id'];?>" class="alert-warning txt_left m-n no-radius" ><?php echo $row['language_name'];?></option>
									<?php } } } ?>
						</select>
					</div>
				</div>

				<div class="form-group">
							<label for="vis_csvfile" class="col-sm-2 control-label"><? echo $vis_language['TXTSELECTCSV']; ?></label>
							<div class="col-sm-10">
								<input type="file" name="files[]" multiple="multiple" onchange="$(this).visExecution('upload_file', {'vis_static_area':'#vis_csv_attachments', 'vis_form':'vis_language_import_form', 'vis_form_attachment_area':'#vis_import_attachments'})" class="filestyle" data-classButton="btn btn-link link"  data-input="false" data-icon="true" data-iconName="vh-chat" data-buttonText="<?=$vis_language['TXTCLICKHERE']?>" data-badge="true"/><input type="hidden" name="vis_location" value="<? echo VIS_DOMAIN; ?>" /><input type="hidden" name="vis_import_attachments" id="vis_import_attachments" value="" /><input type="hidden" name="vis_attachments" id="vis_attachments" value="" /><div id="vis_csv_attachments"></div>
								<input type="hidden" name="vis_parent_type" value="4" />
							</div>
						</div>

            </form>

           <div class="b-2x b-t m-b-md"></div>
				<div class="col-sm col-sm-offset-2">
				<button type="button" class="btn btn-primary" onclick="$('#vis_global_msg_div').visExecution('submit_form', {'vis_module':'setting', 'vis_operation':'import_language_variables',
        'vis_form':'vis_language_import_form','view_title' : '<?php echo $vis_language['TXTCLIENTIMPORT']; ?>'});"><? echo $vis_language['TXTADD']; ?></button>
				</div> <br/>  </div>
    </section>
</section>

</section>
<style>
.wrapper-xxs {
    padding: 7px 5px 0 0!important;
}
</style>
<script src="<?= VIS_PATH_SCRIPT; ?>file-input/bootstrap-filestyle.min.js"></script>
<script language="javascript">
    function vis_remove_attachment(ticket_id, attach_location){
        var loc = '';
        loc = (attach_location != "" && typeof(attach_location) != "undefined") ? attach_location : "vis_image_attachments";
        $("#" + loc).val( $("#" + loc).val().replace(ticket_id + ',', '') );
    }
    $(document).ready(function () {
		$(":file").filestyle({input: false});
	});
</script>
<script src="<?= VIS_PATH_SCRIPT; ?>file-input/bootstrap-filestyle.min.js"></script>

