
 <hr>
  <div class="container">
  	<footer>
        <p>Created by <a href="https://ctb-it.de" target="_blank">Clemens Creutzburg</a></p>
      </footer>
   </div> 

		<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
		<script>window.jQuery || document.write('<script src="js/vendor/jquery-1.9.1.min.js"><\/script>')</script>
    <!-- Bootstrap core JavaScript
    ================================================== -->
    <!-- Placed at the end of the document so the pages load faster  -->
   <!--  <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
   <!-- <script>window.jQuery || document.write('<script src="../../assets/js/vendor/jquery.min.js"><\/script>')</script>-->
    <script src="js/bootstrap.min.js"></script>
	

	<!-- jQuery UI library -->
 	<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/smoothness/jquery-ui.css">
	<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js"></script>
	<script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.11.4/js/jquery.dataTables.js"></script>


	<script src="js/patienten.js"></script>
	<script src="trumbowyg/dist/trumbowyg.min.js"></script>
	<script src="trumbowyg/dist/plugins/colors/trumbowyg.colors.min.js"></script>
	<script src="trumbowyg/dist/plugins/emoji/trumbowyg.emoji.min.js"></script>
	<script src="trumbowyg/dist/plugins/fontfamily/trumbowyg.fontfamily.min.js"></script>
	<script src="trumbowyg/dist/plugins/fontsize/trumbowyg.fontsize.min.js"></script>
	<script src="trumbowyg/dist/plugins/history/trumbowyg.history.min.js"></script>
	<script src="trumbowyg/dist/plugins/lineheight/trumbowyg.lineheight.min.js"></script>
	<script src="trumbowyg/dist/plugins/pasteimage/trumbowyg.pasteimage.min.js"></script>
	
	<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.11.4/css/jquery.dataTables.css">
	<!--<script type="text/javascript" src="js/dist/langs/de.min.js"></script>
	
		<!-- Init Trumbowyg -->
	<script>
		// Doing this in a loaded JS file is better, I put this here for simplicity
		$('#trumbowyg-demo').trumbowyg({
				lang: 'de',
                btns: [ 
                     ['viewHTML'], 
                     ['p', 'blockquote', 'h1', 'h2', 'h3', 'h4'], 
					 ['foreColor', 'backColor'], 
                     ['strong', 'em', 'underline', 'del'], 
                     ['superscript', 'subscript'], 
                     ['createLink', 'unlink'], 
                     ['insertImage'], 
                     ['justifyLeft', 'justifyCenter', 'justifyRight', 'justifyFull'], 
                     ['unorderedList', 'orderedList'], 
                     ['horizontalRule'], 
                     ['removeformat'], 
  
                     ['upload', 'base64', 'noembed'], 
                     ['ruby'], 
                     
                     ['preformatted'], 
                     ['template'], 
                     ['fullscreen', 'close'] 
                 ]		    
		
		});
		
		$(document).ready(function () {
					
			var tableanfragen = $('#tableanfragen').DataTable( {
				"order": [[ 3, "asc" ]],
				language: {
					url: '//cdn.datatables.net/plug-ins/1.11.4/i18n/de_de.json',
					"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "Alle"]]
				}
			} );
			var tableanfragen = $('#tableanfragendesc').DataTable( {
				"order": [[ 3, "desc" ]],
				language: {
					url: '//cdn.datatables.net/plug-ins/1.11.4/i18n/de_de.json',
					"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "Alle"]]
				}
			} );			
			var table = $('#example').DataTable({
				"order": [[ 5, "desc" ]],
				language: {
					url: '//cdn.datatables.net/plug-ins/1.11.4/i18n/de_de.json'
				},
				"columnDefs": [
					{
						"targets": [ 0 ],
						"visible": false,
						"searchable": false
					}
				]	
				
			});

			$('#tablewarte tbody').on('click', 'tr', function () {
				$(this).toggleClass('selected');
			});

		});
		var tablewarte = $('#tablewarte').DataTable( {
			"order": [[ 6, "asc" ]],
			language: {
				url: '//cdn.datatables.net/plug-ins/1.11.4/i18n/de_de.json'
			},
			"columnDefs": [
				{
					"targets": [ 0 ],
					"visible": false,
					"searchable": false
				}
			]	
		} );
		function checkmassenaufgabe() {
			var oData = tablewarte.rows('.selected').data();
			var idausgabe = "";
			//console.log(ids)
			for (var i=0; i < oData.length ;i++){
			   idausgabe = idausgabe  + oData[i][0] + ";";
			}
			//alert(idausgabe);
			document.getElementById("idausgabe").value = idausgabe;
			//document.getElementById("idausgabebox").innerHTML = "Es wurden " +  oData.length + " Zeilen ausgewählt.";
			if( oData.length < 1){
				alert("Keine Zeilen ausgewählt.");
				document.getElementById("auswahlaktion").value == "";
			}else{
				
				if(document.getElementById("auswahlaktion").value == "termin"){
					document.getElementById("massenterminzuweisung").style.display = "inline";
					document.getElementById("massenterminloeschung").style.display = "none";
				}else if(document.getElementById("auswahlaktion").value == "delete"){
					document.getElementById("massenterminloeschung").style.display = "inline";
					document.getElementById("massenterminzuweisung").style.display = "none";
				}else if(document.getElementById("auswahlaktion").value == ""){
					document.getElementById("massenterminloeschung").style.display = "none";
					document.getElementById("massenterminzuweisung").style.display = "none";
				}
				
				
			}
			//alert(table.rows('.selected').data().length + ' row(s) selected.\n\rSo schnell bin ich auch nicht ;)');
		};		
	</script>
  </body>
</html>