<div id="voter_modal" class="modal fade">
	<div class="modal-dialog">
		<div class="modal-content">
			<form action="<?php echo base_url() ?>voter/saveVoter" enctype="multipart/form-data" method="POST" id="voter_form">
				<input type="hidden" id="userID" name="userID" />
				
				<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" id="basicModal">
					<div class="m-1-b font-14 border-dark border-1-b border-b-only"><strong><?php echo $this->lang->line('voterDet') ?></strong></div>
				
					<div class="form-group">
						<label class="col-xs-12 required" for=""><?php echo $this->lang->line('voterNo') ?></label>
						<div class="col-xs-12">
							<input type="text" placeholder="" id="noAhli" name="noAhli" class="form-control validate[required]" required="required"
								onkeyup="return checkVoterID();">
							<div class="helper"><?php echo $this->lang->line('voterNoHelper') ?></div>
						</div>
					</div>
					
					<div class="form-group">
						<label class="col-xs-12" for=""><?php echo $this->lang->line('voterName') ?></label>
						<div class="col-xs-12">
							<input type="text" placeholder="NA" id="voterName" name="voterName" class="form-control">
							<div class="helper"><?php echo $this->lang->line('voterNameHelper') ?></div>
						</div>
					</div>					
					
					<div class="form-group">
						<label class="col-xs-12" for=""><?php echo $this->lang->line('companyName') ?></label>
						<div class="col-xs-12">
							<div class="row p-0">
								<div class="col-sm-9">
									<select id="companyID" name="companyID" class="form-control">
									<option selected value="">NA</option>
									<?php
									if($companyList) {
										foreach($companyList as $row){
											echo"<option value=".$row->companyID.">".$row->companyName."</option>";
										}
									}
									?>
									</select>
									<div class="helper"><?php echo $this->lang->line('companyNameHelper') ?></div>
								</div>
								
								<div class="col-sm-3">
									<button type="button" style="width: 100%;" onclick="newEntity()" class="btn btn-primary btn-sm text-left" title="<?php echo $this->lang->line('newCompany'); ?>"><span class="glyphicon glyphicon glyphicon-edit text-left"></span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<?php echo $this->lang->line('newCompany'); ?></button>
								</div>	
							</div>
						</div>
					</div>					
					
					<div class="form-group" id="quickAddEntity" style="display: none;">
						<div class="row m-1-t p-md-0 p-xs-2-x">
							<div class="col-md-offset-1 col-md-10">
								<div class="row p-0">
									<label class="col-xs-12"><?php echo $this->lang->line('qAddEntity') ?></label>
								</div>
								
								<div class="row p-0">
									<div class="col-xs-10">
										<input type="text" placeholder="" id="qEntity" class="form-control">
									</div>
									<div class="col-xs-2">
										<button type="button" id="qEntityBtn" onclick="saveEntity()" class="btn btn-success btn-sm" title="<?php echo $this->lang->line('newCompany'); ?>">
											<span class="fa fa-check"></span> <?php echo $this->lang->line('add'); ?>
										</button>
									</div>
								</div>
							</div>
						</div>
					</div>
					
					<div class="row"><div class="col"></div></div>
					<div class="m-1-t m-1-b font-14 border-dark border-1-b border-b-only"><strong><?php echo $this->lang->line('voterAccessInfo') ?></strong></div>
					
					<div class="form-group">
						<label class="col-xs-12" for=""><?php echo $this->lang->line('password') ?></label>
						<div class="col-xs-12">
							<input type="password" placeholder="<?php echo $this->lang->line('password') ?>" id="userPassword" name="userPassword" class="form-control" onkeyup="checkpassword()">
							<div class="helper"><?php echo $this->lang->line('ignorePwd') ?></div>
						</div>
					</div>
					
					<div class="form-group">
						<label class="col-xs-12" for=""><?php echo $this->lang->line('confirmpassword') ?></label>
						<div class="col-xs-12">
							<input type="password" placeholder="<?php echo $this->lang->line('confirmpassword') ?>" id="confirmuserPassword" name="confirmuserPassword" class="form-control" onkeyup="checkpassword()">
							<div class="helper"><?php echo $this->lang->line('ignorePwd') ?></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="saveVoter" name="saveVoter" class="btn btn-success"><i class="fa fa-check"></i> <?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="deletePosition" name="deletePosition" class="btn btn-success" onclick="deleteVoter()"><i class="fa fa-check"></i> <?php echo $this->lang->line('delete') ?></button>
			</div>
		</div>
	</div>
</div>