diff --git a/xml/function2.inc b/xml/function2.inc index 76a02090..5957eee2 100644 --- a/xml/function2.inc +++ b/xml/function2.inc @@ -141,20 +141,29 @@ Var popup_discount_hot_show = "Invisible" EndIf If PriceDiscount[1] > 0 Then - Var text_cold_color = "0xFF0000" - Var popup_discount_cold_show = "Enable" + If cold_button_state = "Enable" Then + Var text_cold_color = "0xFF0000" + Var popup_discount_cold_show = "Enable" + Else + Var popup_discount_cold_show = "Invisible" + EndIf Else Var text_cold_color = "0x84776F" Var popup_discount_cold_show = "Invisible" EndIf If PriceDiscount[2] > 0 Then - Var text_blender_color = "0xFF0000" - If text_show_eng = "Enable" Then - Var popup_discount_blend_show_eng = "Enable" - Var popup_discount_blend_show_thai = "Invisible" + If blend_button_state = "Enable" Then + Var text_blender_color = "0xFF0000" + If text_show_eng = "Enable" Then + Var popup_discount_blend_show_eng = "Enable" + Var popup_discount_blend_show_thai = "Invisible" + Else + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Enable" + EndIf Else Var popup_discount_blend_show_eng = "Invisible" - Var popup_discount_blend_show_thai = "Enable" + Var popup_discount_blend_show_thai = "Invisible" EndIf Else Var text_blender_color = "0x84776F" @@ -203,8 +212,12 @@ Var Seeker.NameDrinkTH = menu_name_thai_cold If PriceDiscount[0] > 0 Then - Var text_hot_color = "0xFF0000" - Var popup_discount_hot_show = "Enable" + If hot_button_state = "Enable" Then + Var text_hot_color = "0xFF0000" + Var popup_discount_hot_show = "Enable" + Else + Var popup_discount_hot_show = "Invisible" + EndIf Else Var text_hot_color = "0x84776F" Var popup_discount_hot_show = "Invisible" @@ -214,13 +227,18 @@ Var popup_discount_cold_show = "Invisible" EndIf If PriceDiscount[2] > 0 Then - Var text_blender_color = "0xFF0000" - If text_show_eng = "Enable" Then - Var popup_discount_blend_show_eng = "Enable" - Var popup_discount_blend_show_thai = "Invisible" + If blend_button_state = "Enable" Then + Var text_blender_color = "0xFF0000" + If text_show_eng = "Enable" Then + Var popup_discount_blend_show_eng = "Enable" + Var popup_discount_blend_show_thai = "Invisible" + Else + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Enable" + EndIf Else Var popup_discount_blend_show_eng = "Invisible" - Var popup_discount_blend_show_thai = "Enable" + Var popup_discount_blend_show_thai = "Invisible" EndIf Else Var text_blender_color = "0x84776F" @@ -277,15 +295,23 @@ Var Seeker.NameDrinkTH = menu_name_thai_blender If PriceDiscount[0] > 0 Then - Var text_hot_color = "0xFF0000" - Var popup_discount_hot_show = "Enable" + If hot_button_state = "Enable" Then + Var text_hot_color = "0xFF0000" + Var popup_discount_hot_show = "Enable" + Else + Var popup_discount_hot_show = "Invisible" + EndIf Else Var text_hot_color = "0x84776F" Var popup_discount_hot_show = "Invisible" EndIf If PriceDiscount[1] > 0 Then - Var text_cold_color = "0xFF0000" - Var popup_discount_cold_show = "Enable" + If cold_button_state = "Enable" Then + Var text_cold_color = "0xFF0000" + Var popup_discount_cold_show = "Enable" + Else + Var popup_discount_cold_show = "Invisible" + EndIf Else Var text_cold_color = "0x84776F" Var popup_discount_cold_show = "Invisible" diff --git a/xml/page_topping_select7.xml b/xml/page_topping_select7.xml index c710915e..8bc33e75 100644 --- a/xml/page_topping_select7.xml +++ b/xml/page_topping_select7.xml @@ -414,6 +414,7 @@ If hot_button_state = "Disable2" Then Var text_price_d1 = "" Var text_price_original_d1 = "" + Var popup_discount_hot_show = "Invisible" Else Var text_price_d1 !assigned StringFmt( PriceD1 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d1 !assigned StringFmt( PriceMain[0] , DisplayFormat, PreScaleConvertShow) @@ -428,6 +429,7 @@ If cold_button_state = "Disable2" Then Var text_price_d2 = "" Var text_price_original_d2 = "" + Var popup_discount_cold_show = "Invisible" Else Var text_price_d2 !assigned StringFmt( PriceD2 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d2 !assigned StringFmt( PriceMain[1] , DisplayFormat, PreScaleConvertShow) @@ -442,6 +444,8 @@ If blend_button_state = "Disable2" Then Var text_price_d3 = "" Var text_price_original_d3 = "" + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Invisible" Else Var text_price_d3 !assigned StringFmt( PriceD3 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d3 !assigned StringFmt( PriceMain[2] , DisplayFormat, PreScaleConvertShow) @@ -7832,20 +7836,29 @@ Var popup_discount_hot_show = "Invisible" EndIf If PriceDiscount[1] > 0 Then - Var text_cold_color = "0xFF0000" - Var popup_discount_cold_show = "Enable" + If cold_button_state = "Enable" Then + Var text_cold_color = "0xFF0000" + Var popup_discount_cold_show = "Enable" + Else + Var popup_discount_cold_show = "Invisible" + EndIf Else Var text_cold_color = "0x84776F" Var popup_discount_cold_show = "Invisible" EndIf If PriceDiscount[2] > 0 Then - Var text_blender_color = "0xFF0000" - If text_show_eng = "Enable" Then - Var popup_discount_blend_show_eng = "Enable" - Var popup_discount_blend_show_thai = "Invisible" + If blend_button_state = "Enable" Then + Var text_blender_color = "0xFF0000" + If text_show_eng = "Enable" Then + Var popup_discount_blend_show_eng = "Enable" + Var popup_discount_blend_show_thai = "Invisible" + Else + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Enable" + EndIf Else Var popup_discount_blend_show_eng = "Invisible" - Var popup_discount_blend_show_thai = "Enable" + Var popup_discount_blend_show_thai = "Invisible" EndIf Else Var text_blender_color = "0x84776F" @@ -7890,8 +7903,12 @@ Var Seeker.NameDrinkPOS = menu_name_for_aot_eng_cold If PriceDiscount[0] > 0 Then - Var text_hot_color = "0xFF0000" - Var popup_discount_hot_show = "Enable" + If hot_button_state = "Enable" Then + Var text_hot_color = "0xFF0000" + Var popup_discount_hot_show = "Enable" + Else + Var popup_discount_hot_show = "Invisible" + EndIf Else Var text_hot_color = "0x84776F" Var popup_discount_hot_show = "Invisible" @@ -7901,13 +7918,18 @@ Var popup_discount_cold_show = "Invisible" EndIf If PriceDiscount[2] > 0 Then - Var text_blender_color = "0xFF0000" - If text_show_eng = "Enable" Then - Var popup_discount_blend_show_eng = "Enable" - Var popup_discount_blend_show_thai = "Invisible" + If blend_button_state = "Enable" Then + Var text_blender_color = "0xFF0000" + If text_show_eng = "Enable" Then + Var popup_discount_blend_show_eng = "Enable" + Var popup_discount_blend_show_thai = "Invisible" + Else + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Enable" + EndIf Else Var popup_discount_blend_show_eng = "Invisible" - Var popup_discount_blend_show_thai = "Enable" + Var popup_discount_blend_show_thai = "Invisible" EndIf Else Var text_blender_color = "0x84776F" @@ -7960,15 +7982,23 @@ Var Seeker.NameDrinkPOS = menu_name_for_aot_eng_blender If PriceDiscount[0] > 0 Then - Var text_hot_color = "0xFF0000" - Var popup_discount_hot_show = "Enable" + If hot_button_state = "Enable" Then + Var text_hot_color = "0xFF0000" + Var popup_discount_hot_show = "Enable" + Else + Var popup_discount_hot_show = "Invisible" + EndIf Else Var text_hot_color = "0x84776F" Var popup_discount_hot_show = "Invisible" EndIf If PriceDiscount[1] > 0 Then - Var text_cold_color = "0xFF0000" - Var popup_discount_cold_show = "Enable" + If cold_button_state = "Enable" Then + Var text_cold_color = "0xFF0000" + Var popup_discount_cold_show = "Enable" + Else + Var popup_discount_cold_show = "Invisible" + EndIf Else Var text_cold_color = "0x84776F" Var popup_discount_cold_show = "Invisible" diff --git a/xml/page_topping_select8.xml b/xml/page_topping_select8.xml index 7a7e70d2..7d323f87 100644 --- a/xml/page_topping_select8.xml +++ b/xml/page_topping_select8.xml @@ -785,6 +785,7 @@ If hot_button_state = "Disable2" Then Var text_price_d1 = "" Var text_price_original_d1 = "" + Var popup_discount_hot_show = "Invisible" Else Var text_price_d1 !assigned StringFmt( PriceD1 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d1 !assigned StringFmt( PriceMain[0] , DisplayFormat, PreScaleConvertShow) @@ -799,6 +800,7 @@ If cold_button_state = "Disable2" Then Var text_price_d2 = "" Var text_price_original_d2 = "" + Var popup_discount_cold_show = "Invisible" Else Var text_price_d2 !assigned StringFmt( PriceD2 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d2 !assigned StringFmt( PriceMain[1] , DisplayFormat, PreScaleConvertShow) @@ -813,6 +815,8 @@ If blend_button_state = "Disable2" Then Var text_price_d3 = "" Var text_price_original_d3 = "" + Var popup_discount_blend_show_eng = "Invisible" + Var popup_discount_blend_show_thai = "Invisible" Else Var text_price_d3 !assigned StringFmt( PriceD3 , DisplayFormat, PreScaleConvertShow) Var text_price_original_d3 !assigned StringFmt( PriceMain[2] , DisplayFormat, PreScaleConvertShow)