demo增加边扫边上传功能
This commit is contained in:
parent
8b4aae4c0b
commit
b3a929c4e5
|
@ -50,7 +50,8 @@
|
|||
}
|
||||
else if ("upload_local_file" == message['func'])
|
||||
{
|
||||
alert(msg.data);
|
||||
if (message['iden'] != "111")
|
||||
alert(msg.data);
|
||||
}
|
||||
else if ("merge_local_image" == message['func'])
|
||||
{
|
||||
|
@ -170,9 +171,13 @@
|
|||
req1.image_path = message['image_path'];
|
||||
socket.send(JSON.stringify(req1));
|
||||
|
||||
var req2 = {'func':'delete_local_file', 'file_path':''};
|
||||
var req2 = {'func':'upload_local_file', 'iden':'111', 'file_path':'', 'upload_mode':'http', 'http_host':'192.168.100.148', 'http_port':8001};
|
||||
req2.file_path = message['image_path'];
|
||||
socket.send(JSON.stringify(req2));
|
||||
|
||||
var req3 = {'func':'delete_local_file', 'file_path':''};
|
||||
req3.file_path = message['image_path'];
|
||||
socket.send(JSON.stringify(req3));
|
||||
}
|
||||
else if ("stop_scan" == message['func'])
|
||||
{
|
||||
|
@ -330,7 +335,7 @@
|
|||
{
|
||||
socket.send(JSON.stringify({
|
||||
'func':'set_global_config',
|
||||
'image_format':'bmp'
|
||||
'image_format':'jpg'
|
||||
}));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue