ZIS0500.js
2.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
//文字コードはEUCで保存すること
function move_navi(flg){
if(flg == 0){
document.frm.start_y.value = "";
document.frm.start_m.value = "";
document.frm.end_y.value = "";
document.frm.end_m.value = "";
}else if(flg == 1){
document.frm.start_y.value = eval(document.frm.start_y.value) - 5;
document.frm.end_y.value = eval(document.frm.end_y.value) - 5;
}else if(flg == 2){
document.frm.start_y.value = eval(document.frm.start_y.value) + 5;
document.frm.end_y.value = eval(document.frm.end_y.value) + 5;
}else if(flg == 3){
document.frm.start_y.value = eval(document.frm.start_y.value) - 1;
document.frm.end_y.value = eval(document.frm.end_y.value) - 1;
}else if(flg == 4){
document.frm.start_y.value = eval(document.frm.start_y.value) + 1;
document.frm.end_y.value = eval(document.frm.end_y.value) + 1;
}
document.frm.action = "ZIS0500.php";
document.frm.method="POST";
document.frm.submit();
}
function uriage_calc(){
var cnt = document.getElementsByName("txtUriage").length;
var val = 0;
var hdnval = 0;
if(!cnt){
cnt = 0;
}
for(i=0; i<cnt; i++){
val = 0;
hdnval = 0;
resval = 0;
if(document.getElementsByName("txtUriage")[i].value){
val = document.getElementsByName("txtUriage")[i].value;
hdnval = document.getElementsByName("hdnUriage")[i].value;
resval = parseFloat(val) - parseFloat(hdnval);
}
document.getElementsByName("txtUriageRes")[i].value = resval;
}
}
function genka_calc(){
var cnt = document.getElementsByName("txtGenka").length;
var val = 0;
var hdnval = 0;
if(!cnt){
cnt = 0;
}
for(i=0; i<cnt; i++){
val = 0;
hdnval = 0;
resval = 0;
if(document.getElementsByName("txtGenka")[i].value){
val = document.getElementsByName("txtGenka")[i].value;
hdnval = document.getElementsByName("hdnGenka")[i].value;
resval = parseFloat(val) + parseFloat(hdnval);
}
document.getElementsByName("txtGenkaRes")[i].value = resval;
}
}
function zan_calc(id){
var hdnval = document.getElementById("hdnzan"+id).value;
var zanval = document.getElementById("zan"+id).value;
document.getElementById("dspzan"+id).value = parseFloat(hdnval) + parseFloat(zanval);
}
function show_print(){
window.print();
}
//*** エクセル出力 ***//
function show_excel(){
document.frm.action = "ZIS0600.php";
document.frm.method = "POST";
document.frm.submit();
}