{{ header }}
{{ column_left }}
<div id="content">
	<div class="page-header">
		<div class="container-fluid">
			<div class="pull-right">
				<button type="submit" form="form-blog-author" data-toggle="tooltip" title="{{ button_save }}" class="btn btn-primary"><i class="fa fa-save"></i></button>
				<a href="{{ cancel }}" data-toggle="tooltip" title="{{ button_cancel }}" class="btn btn-default"><i class="fa fa-reply"></i></a>
			</div>
			<h1>{{ heading_title }}</h1>
			<ul class="breadcrumb">
				{% for breadcrumb in breadcrumbs %}
					<li><a href="{{ breadcrumb.href }}">{{ breadcrumb.text }}</a></li>
				{% endfor %}
			</ul>
		</div>
	</div>
	<div class="container-fluid">
		{% if error_warning %}
			<div class="alert alert-danger"><i class="fa fa-exclamation-circle"></i> {{ error_warning }}
				<button type="button" class="close" data-dismiss="alert">&times;</button>
			</div>
		{% endif %}
		<div class="panel panel-default">
			<div class="panel-heading">
				<h3 class="panel-title"><i class="fa fa-pencil"></i> {{ text_form }}</h3>
			</div>
			<div class="panel-body">
				<form action="{{ action }}" method="post" enctype="multipart/form-data" id="form-blog-author" class="form-horizontal">
					<div class="form-group required">
						<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label"><span data-toggle="tooltip" title="{{ help_name }}">{{ entry_name }}</label>
						<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
							<input type="text" name="name" value="{{ name }}" class="form-control" />
							{% if error_name %}
								<span class="text-danger">{{ error_name }}</span>
							{% endif %}
						</div>
					</div>
					<div class="form-group required">
						<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label"><span data-toggle="tooltip" title="{{ help_keyword }}">{{ entry_keyword }}</label>
						<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
							<input type="text" name="keyword" value="{{ keyword }}" class="form-control" />
							{% if error_keyword %}
								<span class="text-danger">{{ error_keyword }}</span>
							{% endif %}
						</div>
					</div>
					<div class="form-group">
						<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label">{{ entry_image }}</label>
						<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
							<a href="" id="thumb-image" data-toggle="image" class="img-thumbnail"><img src="{{ thumb }}" alt="" title="" data-placeholder="{{ no_image }}" /></a>
							<input type="hidden" name="image" value="{{ image }}" id="input-image" />
						</div>
					</div>
					<div class="form-group">
						<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label">{{ entry_status }}</label>
						<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
							<select name="status" class="form-control">
								<option value="1" {% if status == 1 %}{{ "selected='selected'" }}{% endif %}>{{ text_enabled }}</option>
								<option value="0" {% if status == 0 %}{{ "selected='selected'" }}{% endif %}>{{ text_disabled }}</option>
							</select>
						</div>
					</div>
					<ul class="nav nav-tabs" id="language">
						{% for language in languages %}
							<li><a href="#language{{ language.language_id }}" data-toggle="tab"><img src="language/{{ language.code }}/{{ language.code }}.png" title="{{ language.name }}" /> {{ language.name }}</a></li>
						{% endfor %}
					</ul>
					<div class="tab-content">
						{% for language in languages %}
							<div class="tab-pane" id="language{{ language.language_id }}">
								<div class="form-group">
									<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label">{{ entry_description }}</label>
									<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
										<textarea name="author_description[{{ language.language_id }}][description]" id="description{{ language.language_id }}" class="form-control">{{ author_description[language.language_id] ? author_description[language.language_id].description : ''}}</textarea>
									</div>
								</div>
								<div class="form-group">
									<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label">{{ entry_meta_description }}</label>
									<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
										<textarea name="author_description[{{ language.language_id }}][meta_description]" class="form-control">{{ author_description[language.language_id] ? author_description[language.language_id].meta_description : ''}} </textarea>
									</div>
								</div>
								<div class="form-group">
									<label class="col-lg-2 col-md-2 col-sm-2 col-xs-12 control-label">{{ entry_meta_keyword }}</label>
									<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12">
										<textarea name="author_description[{{ language.language_id }}][meta_keyword]" class="form-control">{{ author_description[language.language_id] ? author_description[language.language_id].meta_keyword : ''}} </textarea>
									</div>
								</div>
							</div>
						{% endfor %}
					</div>
				</form>
			</div>
		</div>
	</div>
</div>
<script type="text/javascript" src="view/javascript/summernote/summernote.js"></script>
<link href="view/javascript/summernote/summernote.css" rel="stylesheet" />
<script type="text/javascript" src="view/javascript/summernote/summernote-image-attributes.js"></script>
<script type="text/javascript" src="view/javascript/summernote/opencart.js"></script>
<script type="text/javascript">
	{% for language in languages %}
	$('#description{{language.language_id}}').summernote({height: 300});
	{% endfor %}
	$('#language a:first').tab('show');
	$('#option a:first').tab('show');
</script>
{{ footer }}