; Debug DEBUGVAR EnableJsonProfileMode DEBUGVAR IsServerProfileApplyMode ReadProfile "ROOT/xmlprofile/main.json" "XMLProfileFromJson" DEBUGVAR XMLProfile DEBUGVAR XMLProfileFromJson CompareJsonProfileToServerProfile "-" DEBUGVAR IsServerProfileApplyMode ApplyServerProfile "XMLProfileFromJson" IsServerProfileApplyMode DEBUGVAR XMLProfileFromJson DEBUGVAR IsServerProfileApplyMode STRCONTAIN "y18IDCardLive" XMLProfileFromJson Y18IDCARDLIVE_ENABLE STRCONTAIN "y18IDCard" XMLProfileFromJson Y18IDCARD_ENABLE STRCONTAIN "y20IDCard-Liveness" XMLProfileFromJson Y20IDCARDLIVE_ENABLE STRCONTAIN "y20IDCard" XMLProfileFromJson Y20IDCARD_ENABLE STRCONTAIN "SugarBreak" XMLProfileFromJson SugarBreakEnable STRCONTAIN "Discount50" XMLProfileFromJson Discount50 STRCONTAIN "ClossMenu" XMLProfileFromJson ClossMenu STRCONTAIN "AllPrice05" XMLProfile AllPrice05 STRCONTAIN "AllPrice10" XMLProfile AllPrice10 STRCONTAIN "AllPriceUp05" XMLProfile AllPriceUp05 STRCONTAIN "AllPriceUp10" XMLProfile AllPriceUp10 Var SpiralPriceOrigin = "true" STRCONTAIN "SpiralPriceUp15" XMLProfile SpiralPriceUp15 STRCONTAIN "SpiralPriceUp45" XMLProfile SpiralPriceUp45 STRCONTAIN "SpiralPriceRetail" XMLProfile SpiralPriceRetail DEBUGVAR EnableLiveness DEBUGVAR Only18 DEBUGVAR NoSugarStepRight2 DEBUGVAR HalfPrice If Y18IDCARD_ENABLE = "true" Then Var Only18 = "true" Else Var Only18 = "false" EndIf If Y20IDCARDLIVE_ENABLE = "true" Then If EnableLiveness = "true" Then Var Only20 = "true" Else Var Only20 = "false" EndIf Else Var Only20 = "false" EndIf If Y20IDCARD_ENABLE = "true" Then Var Only20 = "true" Else Var Only20 = "false" EndIf ; Only get 1,2,3 If SugarBreakEnable = "true" Then Var NoSugarStepRight2 = "true" Else Var NoSugarStepRight2 = "false" EndIf ; flag for apply all menu. Var price_apply = 0 If Discount50 = "true" Then Var HalfPrice = "true" Var price_apply = 1 __CMD "invoke-discount-50" "-" "-" "-" EndIf If AllPrice05 = "true" Then Var price_apply = 2 __CMD "invoke-all-price-5" "-" "-" "-" EndIf If AllPrice10 = "true" Then Var price_apply = 3 __CMD "invoke-all-price-10" "-" "-" "-" EndIf If AllPriceUp05 = "true" Then Var price_apply = 3 __CMD "invoke-all-up-price-5" "-" "-" "-" EndIf If AllPriceUp10 = "true" Then Var price_apply = 4 __CMD "invoke-all-up-price-10" "-" "-" "-" EndIf ;spiral price If SpiralPriceUp15 = "true" Then Var SpiralPriceOrigin = "false" __CMD "invoke-all-up-priceSpiral-15" "-" "-" "-" EndIf If SpiralPriceUp45 = "true" Then Var SpiralPriceOrigin = "false" __CMD "invoke-all-up-priceSpiral-45" "-" "-" "-" EndIf If SpiralPriceRetail = "true" Then Var SpiralPriceOrigin = "false" __CMD "invoke-all-up-priceSpiral-Retail" "-" "-" "-" EndIf If SpiralPriceOrigin = "true" Then __CMD "invoke-all-up-priceSpiral-Origin" "-" "-" "-" EndIf If price_apply = 0 Then Var HalfPrice = "false" DEBUGVAR Discount50 __CMD "invoke-discount-disable" "-" "-" "-" __CMD "cancel-override-price" "-" "-" "-" EndIf