source: schedule/Module/control.php@ 17516

Last change on this file since 17516 was 17516, checked in by tose, 11 years ago
Disabled control when viewing past schedule entries
File size: 27.2 KB
Line 
1<script>
2'use strict';
3var ctr;
4var testdata = "old data";
5var pastdata = false;
6
7 function clearNode(node){
8 var child = node.childNodes[0];
9 while(child != null)
10 {
11 node.removeChild(child);
12 child = node.childNodes[0];
13 }
14 }
15
16 function addRow(table){
17 var targetView = table;
18 var cctr=$('.dataTable tr').length;
19 ctr=cctr+1;
20 var input_data;
21 var select;
22 var option;
23 var selection;
24 // CREATE ELEMENT
25 var newtr = document.createElement("tr");
26 newtr.setAttribute("class","tr");
27 var newtd_c1 = document.createElement("td");
28 newtd_c1.setAttribute("width","147");
29 newtd_c1.setAttribute("align","center");
30 newtd_c1.appendChild(
31 input_data = document.createElement("input"),
32 input_data.setAttribute("type","time"),
33 input_data.setAttribute("size","10"),
34 input_data.setAttribute("autofocus","true"),
35 input_data.setAttribute("hidden","true")
36 );
37 var newtd_c2 = document.createElement("td");
38 newtd_c2.setAttribute("width","138");
39 newtd_c2.setAttribute("align","center");
40 newtd_c2.appendChild(
41 select = document.createElement("select"),
42 select.setAttribute("class","measure"),
43 $.ajax({ //Retrieving Measurement name and id in Database september 13,2013 modify by Jaypee Tanio
44 type:"post",
45 url:"Transaction/measurement.php",
46 success:function(data){
47 var obj=$.parseJSON(data);
48 $.each(obj,function(){
49 select.appendChild(
50 option = document.createElement("option"),
51 option.setAttribute('value',this['fMeasurementKey']),
52 option.appendChild(document.createTextNode(this['fMeasurement']))
53 )
54 })
55 }
56 }) // End of retrieving
57 );
58 newtd_c2.setAttribute("width","115");
59 newtd_c2.setAttribute("align","center");
60 newtd_c2.appendChild(
61 input_data = document.createElement("input"),
62 input_data.setAttribute("type","button"),
63 input_data.setAttribute("value","+"),
64 input_data.onclick = function(){ return addRow(newtr);
65 ctr++;
66 }
67 );
68 var newtd_c3 = document.createElement("td");
69 newtd_c3.setAttribute("width","98");
70 newtd_c3.setAttribute("align","center");
71 newtd_c3.appendChild(
72 selection = document.createElement("select"),
73 selection.setAttribute("class","source"),
74 $.ajax({ //Retrieving Measurement name and id in Database september 13,2013 modify by Jaypee Tanio
75 type:"post",
76 url:"Transaction/source.php",
77 success:function(data)
78 {
79 var obj = $.parseJSON(data);
80 $.each(obj,function(){
81 selection.appendChild(
82 option=document.createElement('option'),
83 option.setAttribute('value',this['fSourceKEY']),
84 option.appendChild(document.createTextNode(this['fSourceName']))
85 )
86 });
87 }
88 }) // End of retrieving
89 );
90 var newtd_c4 = document.createElement("td");
91 newtd_c4.setAttribute("width","119");
92 newtd_c4.setAttribute("align","center");
93 newtd_c4.appendChild(
94 input_data = document.createElement("input"),
95 input_data.setAttribute("type","text"),
96 input_data.setAttribute("class","selected"),
97 input_data.setAttribute("size","12"),
98 input_data.setAttribute("placeholder","Value")
99 );
100 var newtd_c5 = document.createElement("td");
101 newtd_c5.setAttribute("width","115");
102 newtd_c5.setAttribute("align","center");
103 newtd_c5.appendChild(
104 input_data = document.createElement("input"),
105 input_data.setAttribute("type","button"),
106 input_data.setAttribute("value","Delete"),
107 input_data.onclick = function(){ return clearNode(newtr); }
108 );
109
110 newtr.appendChild(newtd_c2);
111 newtr.appendChild(newtd_c3);
112 newtr.appendChild(newtd_c4);
113 newtr.appendChild(newtd_c5);
114
115 $(targetView).after(newtr);
116 }
117function deleteRow(tableID){
118 try{
119 var table = document.getElementById(tableID);
120 var rowCount = table.rows.length;
121
122 for(var i = 0; i < rowCount; i++){
123 var row = table.rows[i];
124 var chkbox = row.cells[0].childNodes[0];
125 if(null != chkbox && true == chkbox.checked){
126 if(rowCount <= 1){
127 alert("Cannot delete all the rows.");
128 break;
129 }
130 table.deleteRow(i);
131 rowCount--;
132 i--;
133 }
134 }
135 }catch(e){
136 alert(e);
137 }
138 }
139
140<?php
141$cnt=0;
142$pastdate = 'false';
143$day=0;
144if(isset($_GET['days']))
145{
146 $day = $_GET['days'];
147?> addRowClone(); <?php
148}
149else
150{
151 $day =date("Y-m-d");
152}
153$prev_time = array();
154?>
155
156function addRowCloneNew(nextrow){
157 var targetView = document.getElementById("Data");
158 // CREATE ELEMENT
159 // COUNT LIST
160 var list = $(".datalisting").length;
161 var newlist = list+1;
162 var cctr=$('.dataTable tr').length;
163 ctr=cctr+1;
164 var input_data;
165 var select;
166 var option;
167 var selection;
168 var newdiv = document.createElement("div");
169 newdiv.setAttribute("id","list_"+newlist);
170 newdiv.setAttribute("class","datalisting");
171 newdiv.setAttribute("style","margin:5px 0;");
172 var newtable = document.createElement("table");
173 newtable.setAttribute("class","dataTable");
174 newtable.setAttribute("width","100%");
175 newtable.setAttribute("border","1");
176 newtable.setAttribute("cellspacing","0");
177 newtable.setAttribute("cellpadding","0");
178 var newInnertable = document.createElement("table");
179 newInnertable.setAttribute("class","dataTable");
180 newInnertable.setAttribute("width","100%");
181 newInnertable.setAttribute("border","1");
182
183 newInnertable.setAttribute("cellspacing","0");
184 newInnertable.setAttribute("cellpadding","0");
185
186 var newtr = document.createElement("tr");
187 newtr.setAttribute('class','tr');
188 var newtd_c1 = document.createElement("td");
189 newtd_c1.setAttribute("width","200");
190 newtd_c1.setAttribute("align","center");
191 newtd_c1.setAttribute("valign", "top");
192 newtd_c1.appendChild(
193 input_data = document.createElement("input"),
194 input_data.setAttribute("type","time"),
195 input_data.setAttribute("class","time"),
196 input_data.setAttribute("size","10"),
197 input_data.setAttribute("autofocus","true")
198 );
199 newtd_c1.appendChild(
200 input_data = document.createElement("input"),
201 input_data.setAttribute("type","button"),
202 input_data.setAttribute("value","+"),
203 input_data.onclick = function(){
204 addRowCloneNew("list_"+newlist);
205 }
206 );
207 var newtd_c2 = document.createElement("td");
208
209 newtd_c2.setAttribute("width","138");
210 newtd_c2.setAttribute("align","center");
211 newtd_c2.appendChild(
212 select = document.createElement("select"),
213 select.setAttribute("class","measure"),
214 $.ajax({ //Retrieving Measurement name and id in Database september 13,2013 modify by Jaypee Tanio
215 type:"post",
216 url:"Transaction/measurement.php",
217 success:function(data){
218 var obj=$.parseJSON(data);
219 $.each(obj,function(){
220 select.appendChild(
221 option = document.createElement("option"),
222 option.setAttribute('value',this['fMeasurementKey']),
223 option.appendChild(document.createTextNode(this['fMeasurement']))
224 )
225 })
226
227 }
228 }) // End of retrieving
229
230 );
231 newtd_c2.setAttribute("width","115");
232 newtd_c2.setAttribute("align","center");
233 newtd_c2.appendChild(
234 input_data = document.createElement("input"),
235 input_data.setAttribute("type","button"),
236 input_data.setAttribute("value","+"),
237 input_data.onclick = function(){
238 return addRow(newtr);
239 ctr++;
240 });
241 var newtd_c3 = document.createElement("td");
242 newtd_c3.setAttribute("width","98");
243 newtd_c3.setAttribute("align","center");
244 newtd_c3.appendChild(
245 selection = document.createElement("select"),
246 selection.setAttribute("class","source"),
247 $.ajax({ //Retrieving Measurement name and id in Database september 13,2013 modify by Jaypee Tanio
248 type:"post",
249 url:"Transaction/source.php",
250 success:function(data)
251 {
252 var obj = $.parseJSON(data);
253 $.each(obj,function(){
254 selection.appendChild(
255 option=document.createElement('option'),
256 option.setAttribute('value',this['fSourceKEY']),
257 option.appendChild(document.createTextNode(this['fSourceName']))
258 )
259 });
260 }
261 }) // End of retrieving
262 );
263 var newtd_c4 = document.createElement("td");
264 newtd_c4.setAttribute("width","119");
265 newtd_c4.setAttribute("align","center");
266 newtd_c4.appendChild(
267 input_data = document.createElement("input"),
268 input_data.setAttribute("type","text"),
269 input_data.setAttribute("class","selected"),
270 input_data.setAttribute("size","12"),
271 input_data.setAttribute("placeholder","Value")
272 );
273 var newtd_c5 = document.createElement("td");
274 newtd_c5.setAttribute("width","115");
275 newtd_c5.setAttribute("align","center");
276 newtd_c5.setAttribute("width","115");
277 newtd_c5.setAttribute("align","center");
278 newtd_c5.appendChild(
279 input_data = document.createElement("input"),
280 input_data.setAttribute("type","button"),
281 input_data.setAttribute("value","Delete"),
282 input_data.onclick = function(){ return clearNode(newtr);
283 }
284 );
285 newtr.appendChild(newtd_c2);
286 newtr.appendChild(newtd_c3);
287 newtr.appendChild(newtd_c4);
288 newtr.appendChild(newtd_c5);
289 newInnertable.appendChild(newtr);
290 var newtd_c6 = document.createElement("td");
291 newtd_c6.appendChild(newInnertable);
292
293 var newtd_c7 = document.createElement("td");
294 newtd_c7.setAttribute("width","115");
295 newtd_c7.setAttribute("align","center");
296 newtd_c7.setAttribute("valign", "top");
297 newtd_c7.appendChild(
298 input_data = document.createElement("input"),
299 input_data.setAttribute("type","button"),
300 input_data.setAttribute("value","Delete Main"),
301 input_data.onclick = function(){ return clearNode(newdiv); }
302 );
303
304 var newOutertr = document.createElement("tr");
305
306 newtable.appendChild(newtd_c1);
307 newtable.appendChild(newtd_c6);
308 newtable.appendChild(newtd_c7);
309
310 newdiv.appendChild(newtable);
311 if(nextrow != null){
312 var doc = document.getElementById(nextrow);
313 $(doc).after(newdiv);
314 }else{
315 targetView.appendChild(newdiv);
316 }
317}
318
319function addRowClone(nextrow){
320<?php
321$fetch = mysql_query("SELECT * FROM schedule WHERE date(fStart) = '$day' ORDER BY fScheduleID ASC, fMeasurementID ASC") or die(mysql_error());
322$observationsTime = mysql_query("SELECT DISTINCT fStart FROM schedule WHERE date(fStart) = '$day'");
323$cnt3=0;
324$cnt2=0;
325$cnt4 = 0;
326$cnt5 = 0;
327$cnt = 0;
328$cntrow = 0;
329$pastdate = 'false' ;
330$pasttime = 'false';
331//$data = array();
332//$counter=0;
333 while($times = mysql_fetch_array($observationsTime))
334 {
335 $timestamp=strtotime($times['fStart']);
336 $curdate = strtotime(date('Y-m-d'));
337 $actualtime = date('Y-m-d H:i:s', $timestamp);
338 $timestamp2 = date('Y-m-d',$timestamp);
339 $date_time = date('H:i',$timestamp);
340 $prev_time[$cnt3]= $date_time;
341 if(strtotime($timestamp2) < strtotime(date('Y-m-d'))) {
342 $pastdate = 'true';
343 }
344 else if(strtotime($timestamp2) == strtotime(date('Y-m-d'))) {
345 if(strtotime($date_time) < strtotime(date('H:i'))) {
346 $pastdate = 'true';
347 }
348 } else {
349 $pastdate = 'false';
350 }
351 ?>
352 $('#save').attr('value','UPDATE');
353 var targetView = document.getElementById("Data");
354 // CREATE ELEMENT
355 // COUNT LIST
356 var list = $(".datalisting").length;
357 var newlist = list+1;
358 <?php $cnt++;?>
359
360 var cctr=$('.dataTable tr').length;
361 ctr=cctr+1;
362 var select;
363 var input_data;
364 var option;
365 var selection;
366
367 var newdiv<?php echo $cnt; ?> = document.createElement("div");
368 newdiv<?php echo $cnt; ?>.setAttribute("id", "list_<?php echo $cnt; ?>");
369 newdiv<?php echo $cnt; ?>.setAttribute("class","datalisting");
370 newdiv<?php echo $cnt; ?>.setAttribute("style","margin:5px 0;");
371
372 var newtable = document.createElement("table");
373 newtable.setAttribute("class","dataTable");
374 newtable.setAttribute("width","100%");
375 newtable.setAttribute("border","1");
376 newtable.setAttribute("cellspacing","0");
377 newtable.setAttribute("cellpadding","0");
378
379
380 var newInnertable = document.createElement("table");
381 newInnertable.setAttribute("class","dataTable");
382 newInnertable.setAttribute("width","100%");
383 newInnertable.setAttribute("border","1");
384
385 newInnertable.setAttribute("cellspacing","0");
386 newInnertable.setAttribute("cellpadding","0");
387
388 var newtd_c1 = document.createElement("td");
389 newtd_c1.setAttribute("width","200");
390 newtd_c1.setAttribute("align","center");
391 newtd_c1.setAttribute("valign", "top");
392 <?php if ($pastdate == 'true') { ?>
393 newtd_c1.appendChild(
394 input_data = document.createElement("input"),
395 input_data.setAttribute("type","time"),
396 input_data.setAttribute("class","time"),
397 input_data.setAttribute("size","10"),
398 input_data.setAttribute("value","<?php echo $date_time; ?>"),
399 input_data.setAttribute("autofocus","true"),
400 input_data.setAttribute("disabled")
401 );
402 newtd_c1.appendChild(
403 input_data = document.createElement("input"),
404 input_data.setAttribute("type","button"),
405 input_data.setAttribute("value","+"),
406 input_data.setAttribute("disabled"),
407 input_data.onclick = function(){
408 addRowCloneNew("list_<?php echo $cnt; ?>");
409 }
410 );
411
412<?php } else { ?>
413 newtd_c1.appendChild(
414 input_data = document.createElement("input"),
415 input_data.setAttribute("type","time"),
416 input_data.setAttribute("class","time"),
417 input_data.setAttribute("size","10"),
418 input_data.setAttribute("value","<?php echo $date_time; ?>"),
419 input_data.setAttribute("autofocus","true")
420 );
421 newtd_c1.appendChild(
422 input_data = document.createElement("input"),
423 input_data.setAttribute("type","button"),
424 input_data.setAttribute("value","+"),
425 input_data.onclick = function(){
426 addRowCloneNew("list_<?php echo $cnt; ?>");
427 }
428 );
429 <?php }
430 $observations = mysql_query("SELECT * FROM schedule WHERE fStart = '$actualtime'");
431
432 while($rows = mysql_fetch_array($observations))
433 {
434 $cntrow++;
435 ?>
436
437 var newtr<?php echo $cntrow; ?> = document.createElement("tr");
438 newtr<?php echo $cntrow; ?>.setAttribute('class','tr');
439
440 <?php if ($pastdate == 'true') { ?>
441 var newtd_c2 = document.createElement("td");
442 newtd_c2.setAttribute("width","138");
443 newtd_c2.setAttribute("align","center");
444 newtd_c2.appendChild(
445 selection = document.createElement("select"),
446 <?php
447 $selectm = mysql_query("SELECT * FROM measurement");
448 while($rowmeasure = mysql_fetch_array($selectm))
449 {
450 ?>
451 selection.appendChild(
452 option = document.createElement("option"),
453 option.setAttribute("value","<?php echo $rowmeasure['fMeasurementKey']; ?>"),
454 <?php if($rows['fMeasurementTypeKey']==$rowmeasure['fMeasurementKey']){ echo "option.setAttribute('selected',true),";} ?>
455 option.appendChild(document.createTextNode("<?php echo $rowmeasure['fMeasurement']; ?>"))
456 ),
457 <?php
458 }
459 ?>
460 selection.setAttribute('id','measure'),
461 selection.setAttribute('class','measure'),
462 selection.setAttribute("disabled")
463 );
464 newtd_c2.setAttribute("width","115");
465 newtd_c2.setAttribute("align","center");
466 newtd_c2.appendChild(
467 input_data = document.createElement("input"),
468 input_data.setAttribute("type","button"),
469 input_data.setAttribute("value","+"),
470 input_data.setAttribute("disabled"),
471 input_data.onclick = function(){
472 return addRow(newtr<?php echo $cntrow; ?>);
473 ctr++;
474 });
475
476 var newtd_c3 = document.createElement("td");
477 newtd_c3.setAttribute("width","98");
478 newtd_c3.setAttribute("align","center");
479 newtd_c3.appendChild(
480 selection = document.createElement("select"),
481 <?php
482 $select = mysql_query("SELECT * FROM source");
483 while($rowsource = mysql_fetch_array($select))
484 {
485 ?>
486 selection.appendChild(
487 option = document.createElement("option"),
488 option.setAttribute('value','<?php echo $rowsource['fSourceKEY']; ?>'),
489 <?php if($rows['fSourceKey'] == $rowsource['fSourceKEY']){ echo "option.setAttribute('selected',true),"; } ?>
490 option.appendChild(document.createTextNode("<?php echo $rowsource['fSourceName']; ?>"))
491 ),
492 <?php
493 }
494 ?>
495 selection.setAttribute('id','source'), // End of retrieving
496 selection.setAttribute('class','source'),
497 selection.setAttribute("disabled")
498 // End of retrieving
499 );
500
501 var newtd_c4 = document.createElement("td");
502 newtd_c4.setAttribute("width","119");
503 newtd_c4.setAttribute("align","center");
504 newtd_c4.appendChild(
505 input_data = document.createElement("input"),
506 input_data.setAttribute("type","text"),
507 input_data.setAttribute("class","selected"),
508 input_data.setAttribute("size","12"),
509 input_data.setAttribute("value","<?php echo $rows['fData']; ?>"),
510 input_data.setAttribute("placeholder","Value"),
511 input_data.setAttribute("disabled")
512 );
513
514 var newtd_c5 = document.createElement("td");
515 newtd_c5.setAttribute("width","115");
516 newtd_c5.setAttribute("align","center");
517 newtd_c5.setAttribute("width","115");
518 newtd_c5.setAttribute("align","center");
519 newtd_c5.appendChild(
520 input_data = document.createElement("input"),
521 input_data.setAttribute("type","button"),
522 input_data.setAttribute("value","Delete"),
523 input_data.setAttribute("disabled"),
524 input_data.onclick = function(){
525 return clearNode(newtr<?php echo $cntrow; ?>);
526 }
527 );
528 <?php } else { ?>
529 var newtd_c2 = document.createElement("td");
530 newtd_c2.setAttribute("width","138");
531 newtd_c2.setAttribute("align","center");
532 newtd_c2.appendChild(
533 selection = document.createElement("select"),
534 <?php
535 $selectm = mysql_query("SELECT * FROM measurement");
536 while($rowmeasure = mysql_fetch_array($selectm))
537 {
538 ?>
539 selection.appendChild(
540 option = document.createElement("option"),
541 option.setAttribute("value","<?php echo $rowmeasure['fMeasurementKey']; ?>"),
542 <?php if($rows['fMeasurementTypeKey']==$rowmeasure['fMeasurementKey']){ echo "option.setAttribute('selected',true),";} ?>
543 option.appendChild(document.createTextNode("<?php echo $rowmeasure['fMeasurement']; ?>"))
544 ),
545 <?php
546 }
547 ?>
548 selection.setAttribute('id','measure'),
549 selection.setAttribute('class','measure')
550 );
551 newtd_c2.setAttribute("width","115");
552 newtd_c2.setAttribute("align","center");
553 newtd_c2.appendChild(
554 input_data = document.createElement("input"),
555 input_data.setAttribute("type","button"),
556 input_data.setAttribute("value","+"),
557 input_data.onclick = function(){
558 return addRow(newtr<?php echo $cntrow; ?>);
559 ctr++;
560 });
561
562 var newtd_c3 = document.createElement("td");
563 newtd_c3.setAttribute("width","98");
564 newtd_c3.setAttribute("align","center");
565 newtd_c3.appendChild(
566 selection = document.createElement("select"),
567 <?php
568 $select = mysql_query("SELECT * FROM source");
569 while($rowsource = mysql_fetch_array($select))
570 {
571 ?>
572 selection.appendChild(
573 option = document.createElement("option"),
574 option.setAttribute('value','<?php echo $rowsource['fSourceKEY']; ?>'),
575 <?php if($rows['fSourceKey'] == $rowsource['fSourceKEY']){ echo "option.setAttribute('selected',true),"; } ?>
576 option.appendChild(document.createTextNode("<?php echo $rowsource['fSourceName']; ?>"))
577 ),
578 <?php
579 }
580 ?>
581 selection.setAttribute('id','source'), // End of retrieving
582 selection.setAttribute('class','source') // End of retrieving
583 );
584
585 var newtd_c4 = document.createElement("td");
586 newtd_c4.setAttribute("width","119");
587 newtd_c4.setAttribute("align","center");
588 newtd_c4.appendChild(
589 input_data = document.createElement("input"),
590 input_data.setAttribute("type","text"),
591 input_data.setAttribute("class","selected"),
592 input_data.setAttribute("size","12"),
593 input_data.setAttribute("value","<?php echo $rows['fData']; ?>"),
594 input_data.setAttribute("placeholder","Value")
595 );
596
597 var newtd_c5 = document.createElement("td");
598 newtd_c5.setAttribute("width","115");
599 newtd_c5.setAttribute("align","center");
600 newtd_c5.setAttribute("width","115");
601 newtd_c5.setAttribute("align","center");
602 newtd_c5.appendChild(
603 input_data = document.createElement("input"),
604 input_data.setAttribute("type","button"),
605 input_data.setAttribute("value","Delete"),
606 input_data.onclick = function(){ return clearNode(newtr<?php echo $cntrow; ?>);
607
608 }
609 );
610 <?php } ?>
611 newtr<?php echo $cntrow; ?>.appendChild(newtd_c2);
612 newtr<?php echo $cntrow; ?>.appendChild(newtd_c3);
613 newtr<?php echo $cntrow; ?>.appendChild(newtd_c4);
614 newtr<?php echo $cntrow; ?>.appendChild(newtd_c5);
615 newInnertable.appendChild(newtr<?php echo $cntrow; ?>);
616
617 <?php
618
619 $prevtimestamp = $timestamp;
620 }
621 ?>
622
623 var newtd_c6 = document.createElement("td");
624 newtd_c6.appendChild(newInnertable);
625
626 var newtd_c7 = document.createElement("td");
627 newtd_c7.setAttribute("width","115");
628 newtd_c7.setAttribute("align","center");
629 newtd_c7.setAttribute("valign", "top");
630 <?php if ($pastdate == 'true') { ?>
631 newtd_c7.appendChild(
632 input_data = document.createElement("input"),
633 input_data.setAttribute("type","button"),
634 input_data.setAttribute("value","Delete Main"),
635 input_data.setAttribute("disabled"),
636 input_data.onclick = function(){ return clearNode(newdiv<?php echo $cnt; ?>); }
637 );
638 <?php } else { ?>
639 newtd_c7.appendChild(
640 input_data = document.createElement("input"),
641 input_data.setAttribute("type","button"),
642 input_data.setAttribute("value","Delete Main"),
643 input_data.onclick = function(){ return clearNode(newdiv<?php echo $cnt; ?>); }
644 );
645 <?php } ?>
646
647 var newOutertr = document.createElement("tr");
648
649 newtable.appendChild(newtd_c1);
650 newtable.appendChild(newtd_c6);
651 newtable.appendChild(newtd_c7);
652
653 newdiv<?php echo $cnt; ?>.appendChild(newtable);
654 if(nextrow != null){
655 var doc = document.getElementById(nextrow);
656 $(doc).after(newdiv<?php echo $cnt;?>);
657 }else{
658 targetView.appendChild(newdiv<?php echo $cnt;?>);
659 //$(targetView).after(newtr<?php echo $cnt; ?>);
660 }
661 <?php
662}
663if(mysql_num_rows($fetch)<1)
664{
665?>
666 $('#save').attr('value','SAVE');
667 addRowCloneNew();
668<?php
669}
670
671?>
672
673
674}
675
676$('#LoadPrev').click(function() {
677
678});
679</script>
680
Note: See TracBrowser for help on using the repository browser.