Changeset 16894 for schedule/function/SplitDelete.php
- Timestamp:
- 06/23/13 09:54:35 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
schedule/function/SplitDelete.php
r16873 r16894 33 33 cnt++; 34 34 35 <<<<<<< .mine 36 $('#save').hide(); 37 $('#update').show(); 38 39 var div= document.createElement("div"); 40 div.setAttribute('id','TableHolder'); 41 ======= 35 42 $('#save').hide(); 36 43 $('#update').show(); 37 44 var div= document.createElement("div"); 38 45 div.setAttribute('id','TableHolder'); 46 >>>>>>> .r16893 39 47 var table = document.createElement("table"); 40 48 table.setAttribute('id',"table"+cnt); … … 62 70 63 71 72 <<<<<<< .mine 73 64 74 if($('#Time').val() != ""){ var splitting = $('#Time').val().split(':'); var add = 01; 75 ======= 76 if($('#Time').val() != ""){ var splitting = $('#Time').val().split(':'); var add = 01; 77 >>>>>>> .r16893 65 78 66 79 timeValue = pad((Number(splitting[0]) + Number(add)),2)+':'+splitting[1]; … … 96 109 getTableId =get; 97 110 111 <<<<<<< .mine 112 113 name="name"; value=""; meas = "name"; meas2 = "time"; //getTableId = $(this).attr('name'); 114 split1(); }else{ alert("please enter value for time to add measurement"); } 115 116 ======= 98 117 99 118 name="name"; value=""; meas = "name"; meas2 = "time"; // getTableId = $(this).attr('name'); 100 119 split1(); }else{ alert("please enter value for time to add measurement"); } 101 120 121 >>>>>>> .r16893 102 122 103 123 } … … 178 198 td4.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px; text-align:center;"); 179 199 td4.appendChild( 200 <<<<<<< .mine 201 ======= 180 202 button = document.createElement('input'), 181 203 button.setAttribute("type",'button'), … … 223 245 ); 224 246 td4.appendChild( 247 >>>>>>> .r16893 225 248 button=document.createElement('input'), 226 249 button.setAttribute('type','button'), … … 276 299 button.setAttribute('name','#table2'), 277 300 button.onclick=function(){ 301 <<<<<<< .mine 302 var aa; 303 $('div#TableHolder #table2 #Time').each(function(){ 304 aa = $(this).val(); 305 }); 306 if(aa != ""){ var splitting =aa.split(':'); var add = 01; 307 ======= 278 308 var aa; 279 309 $('div#TableHolder #table2 #Time').each(function(){ … … 281 311 }); 282 312 if(aa != ""){ var splitting =aa.split(':'); var add = 01; 313 >>>>>>> .r16893 283 314 284 315 timeValue = pad((Number(splitting[0]) + Number(add)),2)+':'+splitting[1]; … … 386 417 var td4=document.createElement('td'); 387 418 td4.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px; text-align:center;"); 419 388 420 td4.appendChild( 421 <<<<<<< .mine 422 ======= 389 423 button = document.createElement('input'), 390 424 button.setAttribute("type",'button'), … … 426 460 ); 427 461 td4.appendChild( 462 >>>>>>> .r16893 428 463 button=document.createElement('input'), 429 464 button.setAttribute('type','button'), … … 443 478 tr.appendChild(td4); 444 479 table.appendChild(tr); 480 <<<<<<< .mine 445 481 div.appendChild(table); 446 482 $('#TableH1').append(div); 447 483 448 484 var div= document.createElement("div"); 449 485 div.setAttribute('id','TableHolder'); 486 ======= 487 div.appendChild(table); 488 $('#TableH1').append(div); 489 490 var div= document.createElement("div"); 491 div.setAttribute('id','TableHolder'); 492 >>>>>>> .r16893 450 493 var table = document.createElement("table"); 451 494 table.setAttribute('id',"table1"); … … 471 514 button.setAttribute('name','#table1'), 472 515 button.onclick=function(){ 516 <<<<<<< .mine 517 var aa; 518 $('div#TableHolder #table2 #Time').each(function(){ 519 aa = $(this).val(); 520 }); 521 if(aa !='') { var splitting =aa.split(':'); var add = 01; 522 ======= 473 523 var aa; 474 524 $('div#TableHolder #table1 #Time').each(function(){ … … 477 527 478 528 if(aa != ""){ var splitting = aa.split(':'); var add = 01; 529 >>>>>>> .r16893 479 530 480 531 timeValue = pad((Number(splitting[0]) + Number(add)),2)+':'+splitting[1]; … … 489 540 return str; 490 541 542 <<<<<<< .mine 543 }; 544 545 546 var s = 0; var get; 547 548 $("table").each(function() { 549 if($(this).attr("name")=='#table2'){ 550 get = "#"+$(this).attr("id"); 551 552 s =1; 553 }else{ 554 if(s==0){ 555 get = '#table'+cnt; 556 } 557 } 558 }); 559 getTableId =get; 560 name="name"; value=""; 561 562 name="name"; value=""; meas = "class"; meas2 = "time"; //getTableId = $(this).attr('name'); 563 split2(); }else{ alert("please enter value for time to add measurement"); } 564 ======= 491 565 }; 492 566 … … 506 580 }); 507 581 getTableId =get; 582 >>>>>>> .r16893 508 583 509 584 … … 565 640 button.setAttribute('name','#table1'), 566 641 button.onclick=function(){ 642 <<<<<<< .mine 643 $('div#TableHolder #table1 #Time').each(function(){ 644 aa = $(this).val(); 645 }); 646 647 if(aa != ""){ timeValue = aa; name="name"; value="#table1"; meas = "hidden"; meas2 = true; getTableId = $(this).attr('name'); split2(); }else{ alert("please enter value for time to add measurement"); } 648 ======= 567 649 var aa; 568 650 $('div#TableHolder #table1 #Time').each(function(){ … … 571 653 572 654 if(aa != ""){ timeValue = aa; name="name"; value="#table1"; meas = "hidden"; meas2 = true; getTableId = $(this).attr('name'); split2(); }else{ alert("please enter value for time to add measurement"); } 655 >>>>>>> .r16893 573 656 574 657 … … 585 668 var td4=document.createElement('td'); 586 669 td4.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px; text-align:center;"); 670 587 671 td4.appendChild( 672 <<<<<<< .mine 673 ======= 588 674 button = document.createElement('input'), 589 675 button.setAttribute("type",'button'), … … 632 718 ); 633 719 td4.appendChild( 720 >>>>>>> .r16893 634 721 button=document.createElement('input'), 635 722 button.setAttribute('type','button'), … … 655 742 } 656 743 var meas; 744 <<<<<<< .mine 745 var timeValue; 746 var pad; 747 if(cnt==0){ cnt=2; } 748 function split2() 749 ======= 657 750 var timeValue; 658 751 var pad; 659 752 if(cnt==0){ cnt=2; } 660 753 function split2() 754 >>>>>>> .r16893 661 755 { 662 756 … … 703 797 if(aa != ""){var splitting = aa.split(':'); var add = 01; 704 798 799 705 800 timeValue = pad((Number(splitting[0]) + Number(add)),2)+':'+splitting[1]; 706 801 … … 716 811 } 717 812 813 <<<<<<< .mine 718 814 var s = 0; var get; 719 815 var nn; … … 733 829 734 830 name="name"; value=$(this).attr('name'); 831 meas = "class"; meas2 = "time"; getTableId = get; split1(); }else{ alert("please enter value for time to add measurement"); } 832 833 ======= 834 var s = 0; var get; 835 var nn; 836 nn = $(this).attr('name'); 837 $("table").each(function() { 838 if($(this).attr("name")==nn){ 839 840 get = "#"+$(this).attr("id"); 841 //get = $(this).attr("name"); 842 s =1; 843 }else{ 844 if(s==0){ 845 get = '#table'+cnt; 846 } 847 } 848 }); 849 850 name="name"; value=$(this).attr('name'); 735 851 meas = "class"; meas2 = "time"; getTableId = get; split1(); }else{ alert("please enter value for time to add measurement"); } 736 852 853 >>>>>>> .r16893 737 854 738 855 } … … 762 879 763 880 ); 881 <<<<<<< .mine 882 var td1=document.createElement('td'); 883 td1.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px;text-align:center;"); 884 td1.appendChild( 885 measurementcbo= document.createElement('select'), 886 measurementcbo.setAttribute('id','measurement'), 887 ======= 764 888 var td1=document.createElement('td'); 765 889 td1.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px;text-align:center;"); … … 767 891 measurementcbo= document.createElement('select'), 768 892 measurementcbo.setAttribute('id','measurement'), 893 >>>>>>> .r16893 769 894 <?php 770 895 $measure=mysql_query("SELECT*FROM measurement"); … … 772 897 { 773 898 ?> 774 775 776 777 778 899 measurementcbo.appendChild( 900 option=document.createElement('option'), 901 option.setAttribute('value','<?php echo $rowmeasure['fMeasurementKey']; ?>'), 902 option.setAttribute('selected',true), 903 option.appendChild(document.createTextNode("<?php echo $rowmeasure['fMeasurement']; ?>")) 779 904 ), 780 905 <?php … … 823 948 var td4=document.createElement('td'); 824 949 td4.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px; text-align:center;"); 950 825 951 td4.appendChild( 952 <<<<<<< .mine 953 ======= 826 954 button = document.createElement('input'), 827 955 button.setAttribute("type",'button'), … … 866 994 ); 867 995 td4.appendChild( 996 >>>>>>> .r16893 868 997 button=document.createElement('input'), 869 998 button.setAttribute('type','button'), … … 1017 1146 button.setAttribute('name','#table'+cnt), 1018 1147 button.onclick=function(){ 1148 <<<<<<< .mine 1149 1150 if($('#Time').val() != ""){ timeValue = $('#Time').val(); 1151 name = "name"; value = $(this).attr('name'); meas = "hidden"; meas2 = true; getTableId = $(this).attr('name'); split1(); }else{ alert("please enter value for time to add measurement"); } 1152 ======= 1019 1153 var aa; 1020 1154 $('div#TableHolder #table'+cnt+' #Time').each(function(){ … … 1023 1157 if(aa != ""){ timeValue = aa; 1024 1158 name = "name"; value = $(this).attr('name'); meas = "hidden"; meas2 = true; getTableId = $(this).attr('name'); split1(); }else{ alert("please enter value for time to add measurement"); } 1159 >>>>>>> .r16893 1025 1160 1026 1161 … … 1038 1173 var td4=document.createElement('td'); 1039 1174 td4.setAttribute("style","border:1px solid white; color:#37DFB1; font-size:14px; text-align:center;"); 1175 1040 1176 td4.appendChild( 1177 <<<<<<< .mine 1178 ======= 1041 1179 button = document.createElement('input'), 1042 1180 button.setAttribute("type",'button'), … … 1077 1215 ); 1078 1216 td4.appendChild( 1217 >>>>>>> .r16893 1079 1218 button=document.createElement('input'), 1080 1219 button.setAttribute('type','button'),
Note:
See TracChangeset
for help on using the changeset viewer.