Zapomenutý switch podle document.body.class místo podle atributu
This commit is contained in:
		
							parent
							
								
									3e2469fc45
								
							
						
					
					
						commit
						b637aed7ab
					
				
					 1 changed files with 3 additions and 4 deletions
				
			
		|  | @ -67,13 +67,12 @@ function place_comments() { | ||||||
| 
 | 
 | ||||||
| // show comment form, when clicked to image
 | // show comment form, when clicked to image
 | ||||||
| function img_click(element, ev) { | function img_click(element, ev) { | ||||||
| 	var body_class = document.body.className; | 	switch(document.body.dataset.status){ | ||||||
| 	switch(body_class){ | 		case "zanaseni": | ||||||
| 		case "comitting": |  | ||||||
| 			if (!confirm("Právě jsou zanášeny korektury, opravdu chcete přidat novou?")) | 			if (!confirm("Právě jsou zanášeny korektury, opravdu chcete přidat novou?")) | ||||||
| 				return; | 				return; | ||||||
| 			break; | 			break; | ||||||
| 		case "deprecated": | 		case "zastarale": | ||||||
| 			if (!confirm("Toto PDF je již zastaralé, opravdu chcete vytvořit korekturu?")) | 			if (!confirm("Toto PDF je již zastaralé, opravdu chcete vytvořit korekturu?")) | ||||||
| 				return; | 				return; | ||||||
| 			break; | 			break; | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue