THAI-POS: Added page network down when machine not online
This commit is contained in:
parent
120f0e882d
commit
f992354dd9
3 changed files with 130 additions and 8 deletions
|
|
@ -353,12 +353,4 @@ If BoxID = 176757 Then
|
||||||
Var SaveOrderNameAndPictureEnable = 1
|
Var SaveOrderNameAndPictureEnable = 1
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
; Check POS machine flag
|
|
||||||
Var ConnectWithPOSMachine = 0
|
|
||||||
|
|
||||||
READ_FILE "/mnt/sdcard/coffeevending/app_manager/app_list/king_power_service/enable" POSMachineFlag
|
|
||||||
If POSMachineFlag = 1 Then
|
|
||||||
Var ConnectWithPOSMachine = 1
|
|
||||||
EndIf
|
|
||||||
|
|
||||||
DEBUGVAR SystemDateDayOfWeek
|
DEBUGVAR SystemDateDayOfWeek
|
||||||
|
|
@ -516,6 +516,15 @@
|
||||||
DEBUGVAR LangProcess
|
DEBUGVAR LangProcess
|
||||||
|
|
||||||
|
|
||||||
|
; Check POS machine flag
|
||||||
|
Var ConnectWithPOSMachine = 0
|
||||||
|
If CountryName = "Thailand" Then
|
||||||
|
READ_FILE "/mnt/sdcard/coffeevending/app_manager/app_list/king_power_service/enable" POSMachineFlag
|
||||||
|
DEBUGVAR POSMachineFlag
|
||||||
|
If POSMachineFlag = 1 Then
|
||||||
|
Var ConnectWithPOSMachine = 1
|
||||||
|
EndIf
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
|
||||||
If SELLONLINE = 1 Then
|
If SELLONLINE = 1 Then
|
||||||
|
|
@ -531,6 +540,10 @@
|
||||||
If NetworkStatus = "DOWN" Then
|
If NetworkStatus = "DOWN" Then
|
||||||
Machine NetworkDown
|
Machine NetworkDown
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
|
If ConnectWithPOSMachine = 1 Then
|
||||||
|
Open "ROOT/taobin_project/xml/page_network_down_pos_machine.xml"
|
||||||
|
EndIf
|
||||||
EndIf
|
EndIf
|
||||||
|
|
||||||
DEBUGVAR ButtontoTopupMenu
|
DEBUGVAR ButtontoTopupMenu
|
||||||
|
|
|
||||||
117
xml/page_network_down_pos_machine.xml
Normal file
117
xml/page_network_down_pos_machine.xml
Normal file
|
|
@ -0,0 +1,117 @@
|
||||||
|
<Page>
|
||||||
|
<X> 0 </X>
|
||||||
|
<Y> 608 </Y>
|
||||||
|
<Cache> "Enable" </Cache>
|
||||||
|
<Width> 1080 </Width>
|
||||||
|
<Height> 1312 </Height>
|
||||||
|
<Background> "0xEAE6E1" </Background>
|
||||||
|
<EventOpen>
|
||||||
|
|
||||||
|
OpenInst 2 "/mnt/sdcard/coffeevending/taobin_project/xml/page_list.xml"
|
||||||
|
|
||||||
|
Var DirImage = "ROOT/taobin_project/image/vending_error"
|
||||||
|
Var title_text = "เครือข่ายขัดข้อง ขออภัยในความไม่สะดวก"
|
||||||
|
If show_eng = "true" Then
|
||||||
|
Var DirImage = "ROOT/taobin_project/image/vending_error_en"
|
||||||
|
Var title_text = "Network Error: Sorry for the Inconvenience"
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
Var Timeout = 0
|
||||||
|
</EventOpen>
|
||||||
|
|
||||||
|
<Timeout> 1000 </Timeout>
|
||||||
|
<EventTimeout>
|
||||||
|
If Timeout > 30 Then
|
||||||
|
|
||||||
|
If SELLSTATUS = "SELLONLINE" Then
|
||||||
|
Var SELLONLINE = 1
|
||||||
|
Else
|
||||||
|
If SELLSTATUS = "SELLNOCASH" Then
|
||||||
|
Var SELLONLINE = 1
|
||||||
|
EndIf
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
If SELLONLINE = 1 Then
|
||||||
|
Open "ROOT/taobin_project/xml/page_board.xml"
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
Var Timeout = 0
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
Var Timeout = Timeout + 1
|
||||||
|
</EventTimeout>
|
||||||
|
|
||||||
|
<Button>
|
||||||
|
<X> 990 </X>
|
||||||
|
<Y> 640 </Y>
|
||||||
|
<Filename> show_btn </Filename>
|
||||||
|
<FilenamePress> show_btp </FilenamePress>
|
||||||
|
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
|
||||||
|
<Volume> SoundVolume </Volume>
|
||||||
|
<EventClick>
|
||||||
|
; eng
|
||||||
|
If show_eng = "true" Then
|
||||||
|
Var show_eng = "false"
|
||||||
|
Else
|
||||||
|
Var show_eng = "true"
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
If show_eng = "true" Then
|
||||||
|
Var show_btp = "ROOT/taobin_project/image/bn_thai_lang_press.png"
|
||||||
|
Var show_btn = "ROOT/taobin_project/image/bn_thai_lang.png"
|
||||||
|
Else
|
||||||
|
Var show_btp = "ROOT/taobin_project/image/bn_eng_lang_press.png"
|
||||||
|
Var show_btn = "ROOT/taobin_project/image/bn_eng_lang.png"
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
|
||||||
|
Open "ROOT/taobin_project/xml/page_network_down_pos_machine.xml"
|
||||||
|
</EventClick>
|
||||||
|
</Button>
|
||||||
|
|
||||||
|
|
||||||
|
<Text>
|
||||||
|
<X> 0 </X>
|
||||||
|
<Y> 694 </Y>
|
||||||
|
<Width> 1080 </Width>
|
||||||
|
<Size> 45 </Size>
|
||||||
|
<Font> KanitBoldTTF </Font>
|
||||||
|
<Color> 0x513C2F </Color>
|
||||||
|
<Align> center-vertical-horizontal </Align>
|
||||||
|
<Value> title_text </Value>
|
||||||
|
</Text>
|
||||||
|
|
||||||
|
<Button>
|
||||||
|
<X> 0 </X>
|
||||||
|
<Y> 1860 </Y>
|
||||||
|
<Width> 200 </Width>
|
||||||
|
<Height> 50 </Height>
|
||||||
|
<Sound> "/mnt/sdcard/coffeevending/wav/click.wav" </Sound>
|
||||||
|
<Volume> SoundVolume </Volume>
|
||||||
|
<EventClick>
|
||||||
|
Var countClick = countClick + 1
|
||||||
|
If countClick = 3 Then
|
||||||
|
|
||||||
|
EndIf
|
||||||
|
|
||||||
|
If countClick = 10 Then
|
||||||
|
Var countClick = 0
|
||||||
|
MainMenu
|
||||||
|
EndIf
|
||||||
|
Refresh
|
||||||
|
</EventClick>
|
||||||
|
</Button>
|
||||||
|
|
||||||
|
<Image>
|
||||||
|
<X> 0 </X>
|
||||||
|
<Y> 1685 </Y>
|
||||||
|
<Filename> Var(DirImage + "/text2.png") </Filename>
|
||||||
|
</Image>
|
||||||
|
|
||||||
|
<Image>
|
||||||
|
<X> 0 </X>
|
||||||
|
<Y> 840 </Y>
|
||||||
|
<Filename> "ROOT/taobin_project/image/vending_error/img1.png" </Filename>
|
||||||
|
</Image>
|
||||||
|
|
||||||
|
</Page>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue