|
87 | 87 | function handle(request_rec) |
88 | 88 | local success, result = pcall |
89 | 89 | ( |
90 | | - integrationConfigJson = |
91 | | - [[ |
92 | | - ... INSERT INTEGRATION CONFIG ... |
93 | | - ]] |
| 90 | + function() |
| 91 | + integrationConfigJson = |
| 92 | + [[ |
| 93 | + ... INSERT INTEGRATION CONFIG ... |
| 94 | + ]] |
94 | 95 | |
95 | | - initRequiredHelpers(request_rec) |
| 96 | + initRequiredHelpers(request_rec) |
96 | 97 |
|
97 | | - kuHandler = require("KnownUserApacheHandler") |
| 98 | + kuHandler = require("KnownUserApacheHandler") |
98 | 99 | |
99 | | - return kuHandler.handleByIntegrationConfig( |
100 | | - "... INSERT CUSTOMER ID ...", |
101 | | - "... INSERT SECRET KEY ...", |
102 | | - integrationConfigJson, |
103 | | - request_rec) |
| 100 | + return kuHandler.handleByIntegrationConfig( |
| 101 | + "... INSERT CUSTOMER ID ...", |
| 102 | + "... INSERT SECRET KEY ...", |
| 103 | + integrationConfigJson, |
| 104 | + request_rec) |
| 105 | + end |
104 | 106 | ) |
105 | 107 | |
106 | 108 | if (success) then |
@@ -128,25 +130,27 @@ The following is an example of how the handle function would look if the configu |
128 | 130 | function handle(request_rec) |
129 | 131 | local success, result = pcall |
130 | 132 | ( |
131 | | - local models = require("Models") |
132 | | - eventconfig = models.QueueEventConfig.create() |
133 | | - eventconfig.eventId = ""; -- ID of the queue to use |
134 | | - eventconfig.queueDomain = "xxx.queue-it.net"; -- Domain name of the queue, usually in the format [CustomerId].queue-it.net |
135 | | - -- eventconfig.cookieDomain = ".my-shop.com"; -- Optional, domain name where the Queue-it session cookie should be saved |
136 | | - eventconfig.cookieValidityMinute = 15; -- Optional, validity of the Queue-it session cookie. Default is 10 minutes. |
137 | | - eventconfig.extendCookieValidity = true; -- Optional, should the Queue-it session cookie validity time be extended each time the validation runs? Default is true. |
138 | | - -- eventconfig.culture = "en-US"; -- Optional, culture of the queue ticket layout in the format specified here: https:-- msdn.microsoft.com/en-us/library/ee825488(v=cs.20).aspx Default is to use what is specified on Event |
139 | | - -- eventconfig.layoutName = "NameOfYourCustomLayout"; -- Optional, name of the queue ticket layout e.g. "Default layout by Queue-it". Default is to take what is specified on the Event |
140 | | -
|
141 | | - initRequiredHelpers(request_rec) |
142 | | -
|
143 | | - kuHandler = require("KnownUserApacheHandler") |
| 133 | + function() |
| 134 | + local models = require("Models") |
| 135 | + eventconfig = models.QueueEventConfig.create() |
| 136 | + eventconfig.eventId = ""; -- ID of the queue to use |
| 137 | + eventconfig.queueDomain = "xxx.queue-it.net"; -- Domain name of the queue, usually in the format [CustomerId].queue-it.net |
| 138 | + -- eventconfig.cookieDomain = ".my-shop.com"; -- Optional, domain name where the Queue-it session cookie should be saved |
| 139 | + eventconfig.cookieValidityMinute = 15; -- Optional, validity of the Queue-it session cookie. Default is 10 minutes. |
| 140 | + eventconfig.extendCookieValidity = true; -- Optional, should the Queue-it session cookie validity time be extended each time the validation runs? Default is true. |
| 141 | + -- eventconfig.culture = "en-US"; -- Optional, culture of the queue ticket layout in the format specified here: https:-- msdn.microsoft.com/en-us/library/ee825488(v=cs.20).aspx Default is to use what is specified on Event |
| 142 | + -- eventconfig.layoutName = "NameOfYourCustomLayout"; -- Optional, name of the queue ticket layout e.g. "Default layout by Queue-it". Default is to take what is specified on the Event |
| 143 | +
|
| 144 | + initRequiredHelpers(request_rec) |
| 145 | +
|
| 146 | + kuHandler = require("KnownUserApacheHandler") |
144 | 147 | |
145 | | - return kuHandler.handleByLocalConfig( |
146 | | - "... INSERT CUSTOMER ID ...", |
147 | | - "... INSERT SECRET KEY ...", |
148 | | - eventconfig, |
149 | | - request_rec) |
| 148 | + return kuHandler.handleByLocalConfig( |
| 149 | + "... INSERT CUSTOMER ID ...", |
| 150 | + "... INSERT SECRET KEY ...", |
| 151 | + eventconfig, |
| 152 | + request_rec) |
| 153 | + end |
150 | 154 | ) |
151 | 155 | |
152 | 156 | if (success) then |
|
0 commit comments