<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jqueryui/1.7.2/jquery-ui.js"></script>
<link rel="stylesheet" type="text/css" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.7.1/themes/base/jquery-ui.css"/>
<link href="//fonts.googleapis.com/css?family=Patrick+Hand" rel="stylesheet">
<script src="//rawgit.com/jackmoore/autosize/master/dist/autosize.min.js"></script>
<style>
.form-control {
	border: none !important;
	background-color: transparent !important;
	resize: none !important;
	outline: none !important;
}
</style>
<div class="inner-wrapper">
	<!-- start: sidebar -->
	<aside id="sidebar-left" class="sidebar-left">
		
		<div class="sidebar-header">
			<div class="sidebar-title">
				Menu
			</div>
			<div class="sidebar-toggle hidden-xs" data-toggle-class="sidebar-left-collapsed" data-target="html" data-fire-event="sidebar-left-toggle">
				<i class="fa fa-bars" aria-label="Toggle sidebar"></i>
			</div>
		</div>
		
		<?php include('menu.php');?>
	</aside>
	<!-- end: sidebar -->
	<section role="main" class="content-body card-margin">
		<header class="page-header">
			<h2><span style="text-transform:capitalize;"><?php echo $sdil[68]; //Notlar?> </span> <?php echo $sdil[207]; //İşlemleri?></h2>
			<div class="right-wrapper text-right">
				<ol class="breadcrumbs">
					<li>
						<a href=".">
							<i class="fa fa-home"></i>
						</a>
					</li>
					<li><span><span style="text-transform:capitalize;"><?php echo $sdil[68]; //Notlar?> </span> <?php echo $sdil[207]; //İşlemleri?></span></li>
				</ol>
				<a class="sidebar-right-toggle" data-open="sidebar-right"><i class="fa fa-chevron-left"></i></a>
			</div>
		</header>
		<!-- start: page -->
		<div class="row">
			<div class="col">
				<section class="card">
					<?php if($_GET["durum"]=="ok"){?>
						<?php echo saveok();?>
						<ul class="alert alert-success">
							<li><?php echo $sdil[212]; //islem Basariyla Gerçeklestirilmistir !?></li>
							<li class="close-bt"></li>
						</ul>
					<?php }elseif($_GET["durum"]=="err"){?>
						<ul class="alert alert-danger">
							<li><?php echo $sdil[9]; //Hata Oluştu !?></li>
							<li class="close-bt"></li>
						</ul>
					<?php }?>
					<div class="v8-columns">
						<div class="v8-col200pxL-left">
							<ul class="v8-side-tabs v8-js-tabs v8-same-height">
								<li class="v8-urrent"><a href="#tab-A" title=""><i class="fa fa-sticky-note"></i><span> <?php echo $sdil[68]; //Notlar?></span></a></li>
								<div style="clear:both;"></div>
								<a class="v3-btn v3-btn-warning v3-btn-xs mfrm" data-toggle="modal" data-target="#myModal" data-url="modules/events/note.php?ne=<?php echo $_GET["ne"]?>&islem=<?php echo $_GET["islem"]?>&durum=nekle" style="margin-top:5px; float:right" title=""><i class="fa fa-plus" aria-hidden="true" style="font-size:16px;"></i></a>
							</ul>
						</div>
						<div class="v8-col200pxL-right">
							<div id="tab-A" class="v8-tabs-content" style="min-height:800px;position: relative;">
								<?php
								$properties="";
								$position="";
								$k=0;
								$sql=mysqli_query($conn, "select * from genel where ne='not' and t3='keep' order by id desc"); while($rs=mysqli_fetch_assoc($sql)){
									$k++; $position = explode(',',$rs["n2"]);
									$properties = explode(',',$rs["n3"]);
									$sqlu=mysqli_query($conn, "select * from t5 where id=".$_SESSION["s19"]." order by id desc"); $rsu=mysqli_fetch_assoc($sqlu);
									?>
									<style>
									.k<?php echo $rs["id"]?>{
										margin-bottom:20px;
										margin-right:10px;
										min-height:275px;
										<?php
										if($rs["n4"]=="" or $rs["n4"]=="#ffff8d"){
											echo "background:#ffff8d;";
										}elseif($rs["n4"]=="#ffd180"){
											echo "background:".$rs["n4"].";";
										}elseif($rs["n4"]=="#ccff90"){
											echo "background:".$rs["n4"].";";
										}elseif($rs["n4"]=="#b388ff"){
											echo "background:".$rs["n4"].";";
										}
										?>
										color: rgba(0,0,0,.87);
										display: inline-table;
										padding:10px;
										font-size:14px;
										font-family: 'Patrick Hand', cursive;
									}
									.form-control {
										color: rgba(0,0,0,.87);
									}
								</style>
								<div data-id="m<?php echo $rs["id"]?>" class="hdiv k<?php echo $rs["id"]?> v3-col-md-2" onmouseover="show('m<?php echo $rs["id"]?>');" onmouseout="hide('m<?php echo $rs["id"]?>')" style="">
									<form id="k<?php echo $rs["id"]?>" method="post" style="margin-top:10px;">
										<input type="text" class="form-control" name="t1" id="t<?php echo $rs["id"]?>" value="<?php echo $rs["t1"];?>">
										<input type="hidden" class="form-control" name="position" id="d<?php echo $rs["id"]?>p" value="<?php echo $rs["n2"]?>">
										<input type="hidden" class="form-control" name="height" id="d<?php echo $rs["id"]?>h" value="">
										<input type="hidden" class="form-control" name="width" id="d<?php echo $rs["id"]?>w" value="">
										<input type="hidden" class="form-control" name="color"  id="d<?php echo $rs["id"]?>c" value="<?php echo $rs["n4"]?>">
										<textarea class="form-control" name="n1" id="n<?php echo $rs["id"]?>"><?php echo $rs["n1"];?></textarea>
										<span style="position: absolute; bottom: 25px; right: 10px; font-size:10px" title="Düzenlenme Tarihi"><?php if(mysqli_num_rows($sqlu)>0){echo $rsu["t1"];}else{echo "Admin";}?> <?php echo $rs["ts2"];?></span>
										<div style="clear:both; height:20px"></div>
										<div id="m<?php echo $rs["id"]?>" style="display:none;position:absolute; bottom:30px; width:95%;">
											<a class="btn btn-danger btn-xs btn-delete-div" style="color:#fff;" data-href="modules/events/note.php?ne=<?php echo $_GET["ne"]?>&islem=<?php echo $_GET["islem"]?>&id=<?php echo $rs["id"];?>&durum=snot"><i class="fa fa-trash"></i></a>
											<a class="btn btn-default btn-xs mfrm" onclick="show('mc<?php echo $rs["id"]?>');hide('cm<?php echo $rs["id"]?>')"><i class="fa fa-calendar" style="color:#000;"></i>
												<div id="mc<?php echo $rs["id"]?>" style="position:absolute; z-index:999; width:95%; left: -3px; bottom: 30px; display:none; border: 1px solid #ccc; background: #e6e6e6; border-radius: 5px; padding-top: 2px;">
													<select name="s3" class="form-control" style="float:left; width:36%; margin-right:5px; height:30px; padding:5px;">
														<option value="0" <?php if($rs["s3"]==0){?>selected<?php }?>><?php echo $sdil[69]; //Tekrar Seçiniz?></option>
														<option value="1" <?php if($rs["s3"]==1){?>selected<?php }?>><?php echo $sdil[70]; //Aylık?></option>
														<option value="2" <?php if($rs["s3"]==2){?>selected<?php }?>><?php echo $sdil[71]; //Yıllık?></option>
													</select>
													<input type="number" value="<?php echo $rs["s6"];?>" name="s6" class="form-control" style="float:left; width: 17%; margin-right:3px; padding:5px;">
													<input type="number" value="<?php echo $rs["s7"];?>" name="s7" class="form-control" style="float:left; width: 17%; margin-right:3px; padding:5px;">
													<input type="number" value="<?php echo $rs["s8"];?>" name="s8" class="form-control" style="float:left; width: 20%; padding:5px;">
												</div>
											</a>
											<a class="btn btn-default btn-xs mfrm" onclick="show('cm<?php echo $rs["id"]?>');hide('mc<?php echo $rs["id"]?>')"><i class="fa fa-paint-brush" style="color:#000;"></i>
												<div id="cm<?php echo $rs["id"]?>" style="position:absolute; z-index:999; width:100px;left: -3px; bottom: 30px; display:none; border: 1px solid #ccc; background: #e6e6e6; border-radius: 5px; padding-top: 2px;">
													<i data-id="#ffd180" class="fa fa-circle c<?php echo $rs["id"]?>" style="color:#ffd180; font-size:18px; margin-right:5px;"></i>
													<i data-id="#ffff8d" class="fa fa-circle c<?php echo $rs["id"]?>" style="color:#ffff8d; font-size:18px; margin-right:5px;"></i>
													<i data-id="#ccff90" class="fa fa-circle c<?php echo $rs["id"]?>" style="color:#ccff90; font-size:18px; margin-right:5px;"></i>
													<i data-id="#b388ff" class="fa fa-circle c<?php echo $rs["id"]?>" style="color:#b388ff; font-size:18px; margin-right:5px;"></i>
												</div>
											</a>
											<a class="btn btn-success btn-xs mfrm" style="color:#fff; float:right;" id="u<?php echo $rs["id"]?>">kapat</a>
										</div>
									</form>
								</div>
								<script>
									jQuery('#t<?php echo $rs["id"]?>,#n<?php echo $rs["id"]?>').click(function() {
										show('m<?php echo $rs["id"]?>');
										jQuery('.k<?php echo $rs["id"]?>').css({ position: 'fixed', top: '50%', left: '50%', right: '50%', bottom: '50%', height: '50%', zIndex: 999 });
									});
									jQuery(function(){
										jQuery('#u<?php echo $rs["id"]?>').click(function(){
											var t<?php echo $rs["id"]?>v = jQuery("#t<?php echo $rs["id"]?>").val();
											var n<?php echo $rs["id"]?>v = jQuery("#n<?php echo $rs["id"]?>").val();
											jQuery.ajax({
												type: "POST",
												url: "fonksiyon.php?durum=mkeep&id=<?php echo $rs["id"]?>",
												data: jQuery('#k<?php echo $rs["id"]?>').serialize(),
												success: function () {
													jQuery('.k<?php echo $rs["id"]?>').css({ position: 'relative', height: 'auto' });
													hide('m<?php echo $rs["id"]?>');
												}
											});
										});
									});
									jQuery('.c<?php echo $rs["id"]?>').click(function(){
										var _this=$s(this);
										var color = _this.attr('data-id');
										document.getElementById("d<?php echo $rs["id"]?>c").value = color;
										jQuery('.k<?php echo $rs["id"]?>').css({ background: color});
									});
								</script>
							<?php }?>
						</div>
					</div>
				</div>
				<ul class="alert alert-info">
					<li>...</li>
				</ul>
				
			</section>
		</div>
	</div>
</section>
<aside id="sidebar-right" class="sidebar-right">
	<div class="nano">
		<div class="nano-content">
			<a href="#" class="mobile-close d-md-none">
				Collapse <i class="fa fa-chevron-right"></i>
			</a>
			<div class="sidebar-right-wrapper">
				...
			</div>
		</div>
	</div>
</aside>
</div>
</section>