<div id="candidate_modal" class="modal fade in">
	<div class="modal-dialog modal-dialog-60">
		<div class="modal-content">
			<form action="<?php echo base_url() ?>candidate/saveCandidate" enctype="multipart/form-data" method="POST">
				<input type="hidden" id="candidateID" name="candidateID" value="" />
				
				<div class="modal-header">
					<button type="button" class="modal-close" data-dismiss="modal" aria-label="Close"><span></span><span></span></button>
					<h3 class="modal-title"><b><?php echo $this->lang->line('title') ?></b></h3>
				</div>


				<div class="modal-body">
												
					<div class="row">
						<div class="col-md-3">
							<div class="form-group">
								<label class="col-xs-12 registration-form-label"><?php echo $this->lang->line('candidateImg'); ?></label>
								<div class="col-xs-12">									
									<div class="uploader">
										<input type="file" id="userfile" name="userfile" accept="image/*" />
										<input type="hidden" id="resetuserfile" name="resetuserfile" value="0" />
										<img src="" id="userfileimage" class="img-responsive" />
									</div>
									
									<div class="helper">
										<ul>
											<li><?php echo $this->lang->line('candidateImgHelper1'); ?></li>
											<li><a href="javascript:void(0);" onclick="return clearImage(this);"><?php echo $this->lang->line('candidateImgHelper2'); ?></a></li>
										</ul>
									</div>
								</div>
							</div>							
						</div>
					
						<div class="col-md-8">
							<div class="form-group row">
								<label class="required col-xs-12"><?php echo $this->lang->line('candidateName') ?></label>
								<div class="col-xs-12">
									<input type="text" placeholder="" id="candidateName" name="candidateName" class="form-control" required="required" /><div class="helper">
									<ul>
										<li><?php echo $this->lang->line('req1'); ?></li>
										<li><?php echo $this->lang->line('req1Ex'); ?></li>
									</ul>
								</div>
								</div>
							</div>

							<div class="row form-group">
								<div class="col-md-9">
									<label class="required"><?php echo $this->lang->line('designation') ?></label>
									<select id="positionID" name="positionID" class="form-control">
									<?php
									if($positionList) {
										foreach($positionList as $row){
											echo "<option value='".$row->positionID."'>".$row->positionName."</option>";
										}
									}
									?>
									</select>
									<div class="helper">
										<ul>
											<li><?php echo $this->lang->line('req2'); ?></li>
										</ul>
									</div>
								</div>
								
								<div class="col-md-3">
									<label class="col-md-12 hidden-xs">&nbsp;</label>
									<button type="button" onclick="return newPosition();" class="btn btn-primary"
													title="<?php echo $this->lang->line('newDesignation'); ?>">
													<i class="fa fa-plus"></i> <?php echo $this->lang->line('newDesignation'); ?></button>
								</div>
							</div>
							
							<div class="row p-1 m-1-l m-xs-0 border-1 border-dark form-group" id="new_position_wrapper" style="display: none;">
								<div class="row">
									<div class="col-md-8"><strong><?php echo $this->lang->line('addNewDes'); ?></strong></div>
									<div class="col-md-4">
										<div class="flex-btn-group">
											<button type="button" class="btn btn-success" onclick="return saveNewPosition();"><i class="fa fa-check"></i></button>
											<button type="button" class="btn btn-danger" onclick="return cancelAddPosition();"><i class="fa fa-times"></i></button>
										</div>
									</div>
								</div>
								
								<div class="form-group row">
									<label class="required col-xs-12"><?php echo $this->lang->line('designationName') ?></label>
									<div class="col-xs-12">
										<input type="text" placeholder="<?php echo $this->lang->line('designationName') ?>" id="add_position_name" class="form-control" value="" />
										<div class="helper">
											<ul>
												<li><?php echo $this->lang->line('req3'); ?></li>
												<li><?php echo $this->lang->line('req3Ex'); ?></li>
											</ul>
										</div>
									</div>
								</div>
								
								<div class="row">
									<div class="col-md-6">						
										<div class="form-group row">
											<label class="required col-xs-12"><?php echo $this->lang->line('noOfCandidate') ?></label>
											<div class="col-xs-12">
												<input type="number" min="0" placeholder="<?php echo $this->lang->line('noOfCandidate') ?>"
																id="add_position_elected" class="form-control" onkeypress="return isNumberKey(event)" value="" />
												<div class="helper">
													<ul>
														<li><?php echo $this->lang->line('req4'); ?></li>
													</ul>
												</div>
											</div>
										</div>
									</div>
									
									<div class="col-md-6">								
										<div class="form-group row">
											<label class="required col-xs-12"><?php echo $this->lang->line('designationRank') ?></label>
											<div class="col-xs-12">
												<input type="number" min="0" placeholder="<?php echo $this->lang->line('designationRank') ?>"
																id="add_position_ordering" class="form-control" onkeypress="return isNumberKey(event)" value="" />
												<div class="helper">
													<ul>
														<li><?php echo $this->lang->line('rankHelper1'); ?></li>
														<li><?php echo $this->lang->line('rankHelper2'); ?></li>
														<li><?php echo $this->lang->line('rankHelper3'); ?></li>
													</ul>
												</div>
											</div>
										</div>
									</div>
								</div>
								
							</div>

							<div class="row form-group">
								<div class="col-md-9">
									<label class=""><?php echo $this->lang->line('companyName') ?></label>
									<select id="companyID" name="companyID" class="form-control">
									<option value="0">...</option>
									<?php
									if($companyList) {
										foreach($companyList as $row){
											echo "<option value=".$row->companyID.">".$row->companyName."</option>";
										}
									}
									?>
									</select>
									<div class="helper">
										<ul>
											<li><?php echo $this->lang->line('opt1') ?></li>
										</ul>
									</div>
								</div>
								
								<div class="col-md-3">
									<label class="col-md-12 hidden-xs">&nbsp;</label>
									<button type="button" onclick="return newCompany();" class="btn btn-primary"
													title="<?php echo $this->lang->line('newCompany'); ?>">
													<i class="fa fa-plus"></i> <?php echo $this->lang->line('newCompany'); ?></button>
								</div>
							</div>
						
							<div class="row p-1 m-1-l m-xs-0 border-1 border-dark form-group" id="new_company_wrapper" style="display: none;">
								<div class="row">
									<div class="col-md-8"><strong><?php echo $this->lang->line('newEntity'); ?></strong></div>
									<div class="col-md-4">
										<div class="flex-btn-group">
											<button type="button" class="btn btn-success" onclick="return saveNewCompany();"><i class="fa fa-check"></i></button>
											<button type="button" class="btn btn-danger" onclick="return cancelAddCompany();"><i class="fa fa-times"></i></button>
										</div>
									</div>
								</div>
								
								<div class="form-group row">
									<label class="required col-xs-12"><?php echo $this->lang->line('companyName') ?></label>
									<div class="col-xs-12">
										<input type="text" placeholder="<?php echo $this->lang->line('companyName') ?>" id="add_company_name" class="form-control" value="" />
										<div class="helper">
											<ul>
												<li><?php echo $this->lang->line('entityHelper1') ?></li>
												<li><?php echo $this->lang->line('entityHelper2') ?></li>
											</ul>
										</div>
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
								
				<div class="modal-footer">
					<button type="button" class="btn btn-danger" data-dismiss="modal">
						<i class="fa fa-times"></i>&nbsp;<?php echo $this->lang->line('close') ?>
					</button>
					<button type="submit" id="saveCandidate" class="btn btn-success">
						<i class="fa fa-check"></i>&nbsp;<?php echo $this->lang->line('save') ?>
					</button>
				</div>
			</form>
		</div>
	</div>
</div>
                

                

<!-- DELETE MODAL -->
<div id="delete_modal" class="modal fade in">
	<div class="modal-dialog">
		<div class="modal-content">
			<div class="modal-header">
				<h3 class="modal-title"><?php echo $this->lang->line('delete') ?></h3>
			</div>
			
			<div class="modal-body">
				<input type="text" placeholder="" id="deleteID" name="deleteID" class="form-control" style="display:none">
				<?php echo $this->lang->line('confirmdelete') ?>
			</div>
			
			<div class="modal-footer">
				<button type="button" class="btn btn-danger" data-dismiss="modal"><i class="fa fa-times"></i>&nbsp;<?php echo $this->lang->line('close') ?></button>
				<button type="button" id="deleteCandidate" name="deleteCandidate" class="btn btn-success" onclick="deleteCandidate()"><i class="fa fa-check"></i> <?php echo $this->lang->line('delete') ?></button>
			</div>
		</div>
	</div>
</div>


