-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfunction.js~
More file actions
91 lines (75 loc) · 1.87 KB
/
Copy pathfunction.js~
File metadata and controls
91 lines (75 loc) · 1.87 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
//login.html的選擇器
function gopage(choose)
{
if(choose==1)
{
alert("登入");
}
if(choose==2)
{
$('#content').animate({
height:"58%"
},800);
$('#content').load('register.php');
}
}
//register.html的地址轉經緯度程式
function codeAddress()
{
var geocoder;
geocoder= new google.maps.Geocoder();
var address=document.getElementById("StoreAddress").value;
geocoder.geocode({'address':address},
function(results,status)
{
if(status==google.maps.GeocoderStatus.OK)
{
document.getElementById("GPS_Latitude").value=results[0].geometry.location.lat();
document.getElementById("GPS_Longitude").value=results[0].geometry.location.lng();
}
else
{
alert("Geocode was not successful for the following reason: " + status);
}
});
}
function NextValue(SerialNumbers,Item_Id,choose)
{
$.post('next_value.php',
{"SerialNumbers":SerialNumbers,"Item_Id":Item_Id,"choose":choose},
function(data)
{
if(data==(-1))
{
//alert("wait!!");
}
else
{
$('#'+Item_Id+' .InformationBlock .NowValue').html(data);
}
},
"text"
);
}
function UpdateValue(SerialNumbers)
{
var ItemBlock=document.getElementsByClassName("ItemBlock");
for(var i=0;i<ItemBlock.length;i++)
{
var Item_Id=ItemBlock[i].id;
$.post('updatevalue.php',
{"SerialNumbers":SerialNumbers,"Item_Id":Item_Id},
function(data)
{
if($("#"+data.Item_Id+" .WaiNumValue").html()!=data.WaiNumValue)
//$("#"+data.Item_Id+" .WaiNumValue").html(data.WaiNumValue);
if($("#"+data.Item_Id+" .TakenNumValue").html()!=data.Value)
//$("#"+data.Item_Id+" .TakenNumValue").html(data.Value);
if($("#"+data.Item_Id+" .NowValue").html()!=data.Now_Value)
//$("#"+data.Item_Id+" .NowValue").html(data.Now_Value);
},
"json"
);
}
window.setTimeout('UpdateValue(\''+SerialNumbers+'\')', 2000);
}