Commit 822cb43a752fbda4c2188dafa02db75ece90db53

Authored by Imanol-Mikel Barba Sabariego
1 parent 3dbfe50c

FINAL CODE BEFORE REFACTOR AND TESTS

Showing 25 changed files with 346 additions and 110 deletions
DUREX Vendor Control/BT Vendor.xcodeproj/project.pbxproj
@@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@
12 3471866518070D9300FA0FB2 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3471866418070D9300FA0FB2 /* UIKit.framework */; }; 12 3471866518070D9300FA0FB2 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3471866418070D9300FA0FB2 /* UIKit.framework */; };
13 347186A618070E7200FA0FB2 /* libEMFramework.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 347186A518070E7200FA0FB2 /* libEMFramework.a */; }; 13 347186A618070E7200FA0FB2 /* libEMFramework.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 347186A518070E7200FA0FB2 /* libEMFramework.a */; };
14 347186AC18070FAB00FA0FB2 /* CoreBluetooth.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 347186AB18070FAB00FA0FB2 /* CoreBluetooth.framework */; }; 14 347186AC18070FAB00FA0FB2 /* CoreBluetooth.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 347186AB18070FAB00FA0FB2 /* CoreBluetooth.framework */; };
15 - 34AAB883189804FF0019860D /* DUREXAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB877189804FF0019860D /* DUREXAppDelegate.m */; }; 15 + 34AAB883189804FF0019860D /* BTAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB877189804FF0019860D /* BTAppDelegate.m */; };
16 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */; }; 16 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */; };
17 34AAB889189804FF0019860D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB880189804FF0019860D /* main.m */; }; 17 34AAB889189804FF0019860D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB880189804FF0019860D /* main.m */; };
18 34AAB88D189805300019860D /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 34AAB88C189805300019860D /* Images.xcassets */; }; 18 34AAB88D189805300019860D /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 34AAB88C189805300019860D /* Images.xcassets */; };
@@ -84,8 +84,8 @@ @@ -84,8 +84,8 @@
84 347186A318070E6500FA0FB2 /* EMTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EMTypes.h; sourceTree = "<group>"; }; 84 347186A318070E6500FA0FB2 /* EMTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = EMTypes.h; sourceTree = "<group>"; };
85 347186A518070E7200FA0FB2 /* libEMFramework.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libEMFramework.a; path = EmmocoMobileFramework/Framework/libEMFramework.a; sourceTree = SOURCE_ROOT; }; 85 347186A518070E7200FA0FB2 /* libEMFramework.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libEMFramework.a; path = EmmocoMobileFramework/Framework/libEMFramework.a; sourceTree = SOURCE_ROOT; };
86 347186AB18070FAB00FA0FB2 /* CoreBluetooth.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreBluetooth.framework; path = System/Library/Frameworks/CoreBluetooth.framework; sourceTree = SDKROOT; }; 86 347186AB18070FAB00FA0FB2 /* CoreBluetooth.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreBluetooth.framework; path = System/Library/Frameworks/CoreBluetooth.framework; sourceTree = SDKROOT; };
87 - 34AAB876189804FF0019860D /* DUREXAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DUREXAppDelegate.h; path = FirstAppExample/DUREXAppDelegate.h; sourceTree = SOURCE_ROOT; };  
88 - 34AAB877189804FF0019860D /* DUREXAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = DUREXAppDelegate.m; path = FirstAppExample/DUREXAppDelegate.m; sourceTree = SOURCE_ROOT; }; 87 + 34AAB876189804FF0019860D /* BTAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BTAppDelegate.h; path = FirstAppExample/BTAppDelegate.h; sourceTree = SOURCE_ROOT; };
  88 + 34AAB877189804FF0019860D /* BTAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BTAppDelegate.m; path = FirstAppExample/BTAppDelegate.m; sourceTree = SOURCE_ROOT; };
89 34AAB879189804FF0019860D /* EMDevicePickerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = EMDevicePickerViewController.h; path = FirstAppExample/EMDevicePickerViewController.h; sourceTree = SOURCE_ROOT; }; 89 34AAB879189804FF0019860D /* EMDevicePickerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = EMDevicePickerViewController.h; path = FirstAppExample/EMDevicePickerViewController.h; sourceTree = SOURCE_ROOT; };
90 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = EMDevicePickerViewController.m; path = FirstAppExample/EMDevicePickerViewController.m; sourceTree = SOURCE_ROOT; }; 90 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = EMDevicePickerViewController.m; path = FirstAppExample/EMDevicePickerViewController.m; sourceTree = SOURCE_ROOT; };
91 34AAB87E189804FF0019860D /* BT Vendor-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "BT Vendor-Info.plist"; path = "FirstAppExample/BT Vendor-Info.plist"; sourceTree = SOURCE_ROOT; }; 91 34AAB87E189804FF0019860D /* BT Vendor-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "BT Vendor-Info.plist"; path = "FirstAppExample/BT Vendor-Info.plist"; sourceTree = SOURCE_ROOT; };
@@ -218,7 +218,7 @@ @@ -218,7 +218,7 @@
218 3471865418070D9300FA0FB2 = { 218 3471865418070D9300FA0FB2 = {
219 isa = PBXGroup; 219 isa = PBXGroup;
220 children = ( 220 children = (
221 - 3471866618070D9300FA0FB2 /* DUREX Vendor Control */, 221 + 3471866618070D9300FA0FB2 /* BT Vendor */,
222 3471865F18070D9300FA0FB2 /* Frameworks */, 222 3471865F18070D9300FA0FB2 /* Frameworks */,
223 3471865E18070D9300FA0FB2 /* Products */, 223 3471865E18070D9300FA0FB2 /* Products */,
224 ); 224 );
@@ -244,7 +244,7 @@ @@ -244,7 +244,7 @@
244 name = Frameworks; 244 name = Frameworks;
245 sourceTree = "<group>"; 245 sourceTree = "<group>";
246 }; 246 };
247 - 3471866618070D9300FA0FB2 /* DUREX Vendor Control */ = { 247 + 3471866618070D9300FA0FB2 /* BT Vendor */ = {
248 isa = PBXGroup; 248 isa = PBXGroup;
249 children = ( 249 children = (
250 F9CED59719BE0863008F3764 /* Toast View */, 250 F9CED59719BE0863008F3764 /* Toast View */,
@@ -254,7 +254,7 @@ @@ -254,7 +254,7 @@
254 3471866718070D9300FA0FB2 /* Supporting Files */, 254 3471866718070D9300FA0FB2 /* Supporting Files */,
255 F9ED745419B89E4600C7298D /* Views */, 255 F9ED745419B89E4600C7298D /* Views */,
256 F9ED745519B89E7700C7298D /* Headers */, 256 F9ED745519B89E7700C7298D /* Headers */,
257 - 34AAB877189804FF0019860D /* DUREXAppDelegate.m */, 257 + 34AAB877189804FF0019860D /* BTAppDelegate.m */,
258 F98356D5192E835F00EA6821 /* InitialViewController.m */, 258 F98356D5192E835F00EA6821 /* InitialViewController.m */,
259 F98356E0192EC84700EA6821 /* MenuTableViewController.m */, 259 F98356E0192EC84700EA6821 /* MenuTableViewController.m */,
260 F9A8EF7B192FE201009E7532 /* Stack.m */, 260 F9A8EF7B192FE201009E7532 /* Stack.m */,
@@ -271,7 +271,7 @@ @@ -271,7 +271,7 @@
271 F9B9100819E59773006D4D06 /* IncidentLog.m */, 271 F9B9100819E59773006D4D06 /* IncidentLog.m */,
272 F95C3F2A19E87B8700C040C0 /* ChildViewController.m */, 272 F95C3F2A19E87B8700C040C0 /* ChildViewController.m */,
273 ); 273 );
274 - name = "DUREX Vendor Control"; 274 + name = "BT Vendor";
275 path = TestAppExample; 275 path = TestAppExample;
276 sourceTree = "<group>"; 276 sourceTree = "<group>";
277 }; 277 };
@@ -374,7 +374,7 @@ @@ -374,7 +374,7 @@
374 F9ED745519B89E7700C7298D /* Headers */ = { 374 F9ED745519B89E7700C7298D /* Headers */ = {
375 isa = PBXGroup; 375 isa = PBXGroup;
376 children = ( 376 children = (
377 - 34AAB876189804FF0019860D /* DUREXAppDelegate.h */, 377 + 34AAB876189804FF0019860D /* BTAppDelegate.h */,
378 F98356D4192E835F00EA6821 /* InitialViewController.h */, 378 F98356D4192E835F00EA6821 /* InitialViewController.h */,
379 F98356DF192EC84700EA6821 /* MenuTableViewController.h */, 379 F98356DF192EC84700EA6821 /* MenuTableViewController.h */,
380 F98356D9192EAFD400EA6821 /* CommunicationProtocol.h */, 380 F98356D9192EAFD400EA6821 /* CommunicationProtocol.h */,
@@ -514,7 +514,7 @@ @@ -514,7 +514,7 @@
514 F989B60219BCE28C00657DD9 /* SalesLog.m in Sources */, 514 F989B60219BCE28C00657DD9 /* SalesLog.m in Sources */,
515 F95C3F2B19E87B8700C040C0 /* ChildViewController.m in Sources */, 515 F95C3F2B19E87B8700C040C0 /* ChildViewController.m in Sources */,
516 F92F567919B75F5E00A1EACA /* PriceChangerViewController.m in Sources */, 516 F92F567919B75F5E00A1EACA /* PriceChangerViewController.m in Sources */,
517 - 34AAB883189804FF0019860D /* DUREXAppDelegate.m in Sources */, 517 + 34AAB883189804FF0019860D /* BTAppDelegate.m in Sources */,
518 F98356DB192EAFD400EA6821 /* CommunicationProtocol.m in Sources */, 518 F98356DB192EAFD400EA6821 /* CommunicationProtocol.m in Sources */,
519 F98356E1192EC84700EA6821 /* MenuTableViewController.m in Sources */, 519 F98356E1192EC84700EA6821 /* MenuTableViewController.m in Sources */,
520 F98446F019B9EAE9005C4992 /* Sensors.m in Sources */, 520 F98446F019B9EAE9005C4992 /* Sensors.m in Sources */,
DUREX Vendor Control/BT Vendor.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate
No preview for this file type
DUREX Vendor Control/BT Vendor.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
@@ -26,11 +26,11 @@ @@ -26,11 +26,11 @@
26 ignoreCount = "0" 26 ignoreCount = "0"
27 continueAfterRunningActions = "No" 27 continueAfterRunningActions = "No"
28 filePath = "MenuTableViewController.m" 28 filePath = "MenuTableViewController.m"
29 - timestampString = "435859231.211213" 29 + timestampString = "436467072.187571"
30 startingColumnNumber = "9223372036854775807" 30 startingColumnNumber = "9223372036854775807"
31 endingColumnNumber = "9223372036854775807" 31 endingColumnNumber = "9223372036854775807"
32 - startingLineNumber = "928"  
33 - endingLineNumber = "928" 32 + startingLineNumber = "1038"
  33 + endingLineNumber = "1038"
34 landmarkName = "-tableView:didSelectRowAtIndexPath:" 34 landmarkName = "-tableView:didSelectRowAtIndexPath:"
35 landmarkType = "5"> 35 landmarkType = "5">
36 </BreakpointContent> 36 </BreakpointContent>
@@ -42,11 +42,11 @@ @@ -42,11 +42,11 @@
42 ignoreCount = "0" 42 ignoreCount = "0"
43 continueAfterRunningActions = "No" 43 continueAfterRunningActions = "No"
44 filePath = "MenuTableViewController.m" 44 filePath = "MenuTableViewController.m"
45 - timestampString = "435859231.211213" 45 + timestampString = "436467072.187571"
46 startingColumnNumber = "9223372036854775807" 46 startingColumnNumber = "9223372036854775807"
47 endingColumnNumber = "9223372036854775807" 47 endingColumnNumber = "9223372036854775807"
48 - startingLineNumber = "830"  
49 - endingLineNumber = "830" 48 + startingLineNumber = "940"
  49 + endingLineNumber = "940"
50 landmarkName = "-tableView:didSelectRowAtIndexPath:" 50 landmarkName = "-tableView:didSelectRowAtIndexPath:"
51 landmarkType = "5"> 51 landmarkType = "5">
52 </BreakpointContent> 52 </BreakpointContent>
@@ -58,11 +58,11 @@ @@ -58,11 +58,11 @@
58 ignoreCount = "0" 58 ignoreCount = "0"
59 continueAfterRunningActions = "No" 59 continueAfterRunningActions = "No"
60 filePath = "MenuTableViewController.m" 60 filePath = "MenuTableViewController.m"
61 - timestampString = "435854984.608419" 61 + timestampString = "436467072.187571"
62 startingColumnNumber = "9223372036854775807" 62 startingColumnNumber = "9223372036854775807"
63 endingColumnNumber = "9223372036854775807" 63 endingColumnNumber = "9223372036854775807"
64 - startingLineNumber = "623"  
65 - endingLineNumber = "623" 64 + startingLineNumber = "733"
  65 + endingLineNumber = "733"
66 landmarkName = "-toggleDropList:" 66 landmarkName = "-toggleDropList:"
67 landmarkType = "5"> 67 landmarkType = "5">
68 </BreakpointContent> 68 </BreakpointContent>
@@ -186,11 +186,11 @@ @@ -186,11 +186,11 @@
186 ignoreCount = "0" 186 ignoreCount = "0"
187 continueAfterRunningActions = "No" 187 continueAfterRunningActions = "No"
188 filePath = "MenuTableViewController.m" 188 filePath = "MenuTableViewController.m"
189 - timestampString = "435859231.211213" 189 + timestampString = "436467072.187571"
190 startingColumnNumber = "9223372036854775807" 190 startingColumnNumber = "9223372036854775807"
191 endingColumnNumber = "9223372036854775807" 191 endingColumnNumber = "9223372036854775807"
192 - startingLineNumber = "1033"  
193 - endingLineNumber = "1033" 192 + startingLineNumber = "1143"
  193 + endingLineNumber = "1143"
194 landmarkName = "-tableView:didSelectRowAtIndexPath:" 194 landmarkName = "-tableView:didSelectRowAtIndexPath:"
195 landmarkType = "5"> 195 landmarkType = "5">
196 </BreakpointContent> 196 </BreakpointContent>
@@ -202,11 +202,11 @@ @@ -202,11 +202,11 @@
202 ignoreCount = "0" 202 ignoreCount = "0"
203 continueAfterRunningActions = "No" 203 continueAfterRunningActions = "No"
204 filePath = "MenuTableViewController.m" 204 filePath = "MenuTableViewController.m"
205 - timestampString = "435854984.608419" 205 + timestampString = "436465076.64059"
206 startingColumnNumber = "9223372036854775807" 206 startingColumnNumber = "9223372036854775807"
207 endingColumnNumber = "9223372036854775807" 207 endingColumnNumber = "9223372036854775807"
208 - startingLineNumber = "212"  
209 - endingLineNumber = "212" 208 + startingLineNumber = "214"
  209 + endingLineNumber = "214"
210 landmarkName = "-generateIncidentListNavLevel" 210 landmarkName = "-generateIncidentListNavLevel"
211 landmarkType = "5"> 211 landmarkType = "5">
212 </BreakpointContent> 212 </BreakpointContent>
@@ -218,12 +218,12 @@ @@ -218,12 +218,12 @@
218 ignoreCount = "0" 218 ignoreCount = "0"
219 continueAfterRunningActions = "No" 219 continueAfterRunningActions = "No"
220 filePath = "MenuTableViewController.m" 220 filePath = "MenuTableViewController.m"
221 - timestampString = "435854984.608419" 221 + timestampString = "436467072.187571"
222 startingColumnNumber = "9223372036854775807" 222 startingColumnNumber = "9223372036854775807"
223 endingColumnNumber = "9223372036854775807" 223 endingColumnNumber = "9223372036854775807"
224 - startingLineNumber = "749"  
225 - endingLineNumber = "749"  
226 - landmarkName = "-tableView:numberOfRowsInSection:" 224 + startingLineNumber = "859"
  225 + endingLineNumber = "859"
  226 + landmarkName = "-tableView:titleForHeaderInSection:"
227 landmarkType = "5"> 227 landmarkType = "5">
228 </BreakpointContent> 228 </BreakpointContent>
229 </BreakpointProxy> 229 </BreakpointProxy>
@@ -234,11 +234,11 @@ @@ -234,11 +234,11 @@
234 ignoreCount = "0" 234 ignoreCount = "0"
235 continueAfterRunningActions = "No" 235 continueAfterRunningActions = "No"
236 filePath = "MenuTableViewController.m" 236 filePath = "MenuTableViewController.m"
237 - timestampString = "435859231.211213" 237 + timestampString = "436467072.187571"
238 startingColumnNumber = "9223372036854775807" 238 startingColumnNumber = "9223372036854775807"
239 endingColumnNumber = "9223372036854775807" 239 endingColumnNumber = "9223372036854775807"
240 - startingLineNumber = "835"  
241 - endingLineNumber = "835" 240 + startingLineNumber = "945"
  241 + endingLineNumber = "945"
242 landmarkName = "-tableView:didSelectRowAtIndexPath:" 242 landmarkName = "-tableView:didSelectRowAtIndexPath:"
243 landmarkType = "5"> 243 landmarkType = "5">
244 </BreakpointContent> 244 </BreakpointContent>
@@ -250,11 +250,11 @@ @@ -250,11 +250,11 @@
250 ignoreCount = "0" 250 ignoreCount = "0"
251 continueAfterRunningActions = "No" 251 continueAfterRunningActions = "No"
252 filePath = "MenuTableViewController.m" 252 filePath = "MenuTableViewController.m"
253 - timestampString = "435859231.211213" 253 + timestampString = "436467072.187571"
254 startingColumnNumber = "9223372036854775807" 254 startingColumnNumber = "9223372036854775807"
255 endingColumnNumber = "9223372036854775807" 255 endingColumnNumber = "9223372036854775807"
256 - startingLineNumber = "1122"  
257 - endingLineNumber = "1122" 256 + startingLineNumber = "1232"
  257 + endingLineNumber = "1232"
258 landmarkName = "-numberOfSectionsInTableView:" 258 landmarkName = "-numberOfSectionsInTableView:"
259 landmarkType = "5"> 259 landmarkType = "5">
260 </BreakpointContent> 260 </BreakpointContent>
@@ -266,13 +266,13 @@ @@ -266,13 +266,13 @@
266 ignoreCount = "0" 266 ignoreCount = "0"
267 continueAfterRunningActions = "No" 267 continueAfterRunningActions = "No"
268 filePath = "MenuTableViewController.m" 268 filePath = "MenuTableViewController.m"
269 - timestampString = "435859231.211213" 269 + timestampString = "436467072.187571"
270 startingColumnNumber = "9223372036854775807" 270 startingColumnNumber = "9223372036854775807"
271 endingColumnNumber = "9223372036854775807" 271 endingColumnNumber = "9223372036854775807"
272 - startingLineNumber = "1123"  
273 - endingLineNumber = "1123"  
274 - landmarkName = "@implementation MenuTableViewController"  
275 - landmarkType = "3"> 272 + startingLineNumber = "1233"
  273 + endingLineNumber = "1233"
  274 + landmarkName = "-numberOfSectionsInTableView:"
  275 + landmarkType = "5">
276 </BreakpointContent> 276 </BreakpointContent>
277 </BreakpointProxy> 277 </BreakpointProxy>
278 <BreakpointProxy 278 <BreakpointProxy
@@ -298,11 +298,11 @@ @@ -298,11 +298,11 @@
298 ignoreCount = "0" 298 ignoreCount = "0"
299 continueAfterRunningActions = "No" 299 continueAfterRunningActions = "No"
300 filePath = "MenuTableViewController.m" 300 filePath = "MenuTableViewController.m"
301 - timestampString = "435859231.211213" 301 + timestampString = "436467072.187571"
302 startingColumnNumber = "9223372036854775807" 302 startingColumnNumber = "9223372036854775807"
303 endingColumnNumber = "9223372036854775807" 303 endingColumnNumber = "9223372036854775807"
304 - startingLineNumber = "1242"  
305 - endingLineNumber = "1242" 304 + startingLineNumber = "1352"
  305 + endingLineNumber = "1352"
306 landmarkName = "-tableView:cellForRowAtIndexPath:" 306 landmarkName = "-tableView:cellForRowAtIndexPath:"
307 landmarkType = "5"> 307 landmarkType = "5">
308 </BreakpointContent> 308 </BreakpointContent>
@@ -314,12 +314,12 @@ @@ -314,12 +314,12 @@
314 ignoreCount = "0" 314 ignoreCount = "0"
315 continueAfterRunningActions = "No" 315 continueAfterRunningActions = "No"
316 filePath = "MenuTableViewController.m" 316 filePath = "MenuTableViewController.m"
317 - timestampString = "435854984.608419" 317 + timestampString = "436467072.187571"
318 startingColumnNumber = "9223372036854775807" 318 startingColumnNumber = "9223372036854775807"
319 endingColumnNumber = "9223372036854775807" 319 endingColumnNumber = "9223372036854775807"
320 - startingLineNumber = "553"  
321 - endingLineNumber = "553"  
322 - landmarkName = "-willRotateToInterfaceOrientation:duration:" 320 + startingLineNumber = "663"
  321 + endingLineNumber = "663"
  322 + landmarkName = "-didRotateFromInterfaceOrientation:"
323 landmarkType = "5"> 323 landmarkType = "5">
324 </BreakpointContent> 324 </BreakpointContent>
325 </BreakpointProxy> 325 </BreakpointProxy>
@@ -330,11 +330,11 @@ @@ -330,11 +330,11 @@
330 ignoreCount = "0" 330 ignoreCount = "0"
331 continueAfterRunningActions = "No" 331 continueAfterRunningActions = "No"
332 filePath = "MenuTableViewController.m" 332 filePath = "MenuTableViewController.m"
333 - timestampString = "435859231.211213" 333 + timestampString = "436467072.187571"
334 startingColumnNumber = "9223372036854775807" 334 startingColumnNumber = "9223372036854775807"
335 endingColumnNumber = "9223372036854775807" 335 endingColumnNumber = "9223372036854775807"
336 - startingLineNumber = "1327"  
337 - endingLineNumber = "1327" 336 + startingLineNumber = "1437"
  337 + endingLineNumber = "1437"
338 landmarkName = "-tableView:cellForRowAtIndexPath:" 338 landmarkName = "-tableView:cellForRowAtIndexPath:"
339 landmarkType = "5"> 339 landmarkType = "5">
340 </BreakpointContent> 340 </BreakpointContent>
@@ -346,11 +346,11 @@ @@ -346,11 +346,11 @@
346 ignoreCount = "0" 346 ignoreCount = "0"
347 continueAfterRunningActions = "No" 347 continueAfterRunningActions = "No"
348 filePath = "MenuTableViewController.m" 348 filePath = "MenuTableViewController.m"
349 - timestampString = "435859231.211213" 349 + timestampString = "436467072.187571"
350 startingColumnNumber = "9223372036854775807" 350 startingColumnNumber = "9223372036854775807"
351 endingColumnNumber = "9223372036854775807" 351 endingColumnNumber = "9223372036854775807"
352 - startingLineNumber = "1319"  
353 - endingLineNumber = "1319" 352 + startingLineNumber = "1429"
  353 + endingLineNumber = "1429"
354 landmarkName = "-tableView:cellForRowAtIndexPath:" 354 landmarkName = "-tableView:cellForRowAtIndexPath:"
355 landmarkType = "5"> 355 landmarkType = "5">
356 </BreakpointContent> 356 </BreakpointContent>
@@ -362,11 +362,11 @@ @@ -362,11 +362,11 @@
362 ignoreCount = "0" 362 ignoreCount = "0"
363 continueAfterRunningActions = "No" 363 continueAfterRunningActions = "No"
364 filePath = "MenuTableViewController.m" 364 filePath = "MenuTableViewController.m"
365 - timestampString = "435859231.211213" 365 + timestampString = "436467072.187571"
366 startingColumnNumber = "9223372036854775807" 366 startingColumnNumber = "9223372036854775807"
367 endingColumnNumber = "9223372036854775807" 367 endingColumnNumber = "9223372036854775807"
368 - startingLineNumber = "1114"  
369 - endingLineNumber = "1114" 368 + startingLineNumber = "1224"
  369 + endingLineNumber = "1224"
370 landmarkName = "-tableView:indentationLevelForRowAtIndexPath:" 370 landmarkName = "-tableView:indentationLevelForRowAtIndexPath:"
371 landmarkType = "5"> 371 landmarkType = "5">
372 </BreakpointContent> 372 </BreakpointContent>
@@ -378,11 +378,11 @@ @@ -378,11 +378,11 @@
378 ignoreCount = "0" 378 ignoreCount = "0"
379 continueAfterRunningActions = "No" 379 continueAfterRunningActions = "No"
380 filePath = "MenuTableViewController.m" 380 filePath = "MenuTableViewController.m"
381 - timestampString = "435859231.211213" 381 + timestampString = "436467072.187571"
382 startingColumnNumber = "9223372036854775807" 382 startingColumnNumber = "9223372036854775807"
383 endingColumnNumber = "9223372036854775807" 383 endingColumnNumber = "9223372036854775807"
384 - startingLineNumber = "1112"  
385 - endingLineNumber = "1112" 384 + startingLineNumber = "1222"
  385 + endingLineNumber = "1222"
386 landmarkName = "-tableView:indentationLevelForRowAtIndexPath:" 386 landmarkName = "-tableView:indentationLevelForRowAtIndexPath:"
387 landmarkType = "5"> 387 landmarkType = "5">
388 </BreakpointContent> 388 </BreakpointContent>
@@ -458,11 +458,11 @@ @@ -458,11 +458,11 @@
458 ignoreCount = "0" 458 ignoreCount = "0"
459 continueAfterRunningActions = "No" 459 continueAfterRunningActions = "No"
460 filePath = "MenuTableViewController.m" 460 filePath = "MenuTableViewController.m"
461 - timestampString = "435859231.211213" 461 + timestampString = "436467072.187571"
462 startingColumnNumber = "9223372036854775807" 462 startingColumnNumber = "9223372036854775807"
463 endingColumnNumber = "9223372036854775807" 463 endingColumnNumber = "9223372036854775807"
464 - startingLineNumber = "1443"  
465 - endingLineNumber = "1443" 464 + startingLineNumber = "1553"
  465 + endingLineNumber = "1553"
466 landmarkName = "-tableView:cellForRowAtIndexPath:" 466 landmarkName = "-tableView:cellForRowAtIndexPath:"
467 landmarkType = "5"> 467 landmarkType = "5">
468 </BreakpointContent> 468 </BreakpointContent>
@@ -474,11 +474,11 @@ @@ -474,11 +474,11 @@
474 ignoreCount = "0" 474 ignoreCount = "0"
475 continueAfterRunningActions = "No" 475 continueAfterRunningActions = "No"
476 filePath = "MenuTableViewController.m" 476 filePath = "MenuTableViewController.m"
477 - timestampString = "435859231.211213" 477 + timestampString = "436467072.187571"
478 startingColumnNumber = "9223372036854775807" 478 startingColumnNumber = "9223372036854775807"
479 endingColumnNumber = "9223372036854775807" 479 endingColumnNumber = "9223372036854775807"
480 - startingLineNumber = "1428"  
481 - endingLineNumber = "1428" 480 + startingLineNumber = "1538"
  481 + endingLineNumber = "1538"
482 landmarkName = "-tableView:cellForRowAtIndexPath:" 482 landmarkName = "-tableView:cellForRowAtIndexPath:"
483 landmarkType = "5"> 483 landmarkType = "5">
484 </BreakpointContent> 484 </BreakpointContent>
@@ -536,11 +536,11 @@ @@ -536,11 +536,11 @@
536 ignoreCount = "0" 536 ignoreCount = "0"
537 continueAfterRunningActions = "No" 537 continueAfterRunningActions = "No"
538 filePath = "MenuTableViewController.m" 538 filePath = "MenuTableViewController.m"
539 - timestampString = "435854984.608419" 539 + timestampString = "436467072.187571"
540 startingColumnNumber = "9223372036854775807" 540 startingColumnNumber = "9223372036854775807"
541 endingColumnNumber = "9223372036854775807" 541 endingColumnNumber = "9223372036854775807"
542 - startingLineNumber = "522"  
543 - endingLineNumber = "522" 542 + startingLineNumber = "625"
  543 + endingLineNumber = "625"
544 landmarkName = "-viewDidLoad" 544 landmarkName = "-viewDidLoad"
545 landmarkType = "5"> 545 landmarkType = "5">
546 </BreakpointContent> 546 </BreakpointContent>
@@ -552,11 +552,11 @@ @@ -552,11 +552,11 @@
552 ignoreCount = "0" 552 ignoreCount = "0"
553 continueAfterRunningActions = "No" 553 continueAfterRunningActions = "No"
554 filePath = "MenuTableViewController.m" 554 filePath = "MenuTableViewController.m"
555 - timestampString = "435854984.608419" 555 + timestampString = "436465076.64059"
556 startingColumnNumber = "9223372036854775807" 556 startingColumnNumber = "9223372036854775807"
557 endingColumnNumber = "9223372036854775807" 557 endingColumnNumber = "9223372036854775807"
558 - startingLineNumber = "158"  
559 - endingLineNumber = "158" 558 + startingLineNumber = "160"
  559 + endingLineNumber = "160"
560 landmarkName = "-generateSaleListNavLevel" 560 landmarkName = "-generateSaleListNavLevel"
561 landmarkType = "5"> 561 landmarkType = "5">
562 </BreakpointContent> 562 </BreakpointContent>
@@ -568,11 +568,11 @@ @@ -568,11 +568,11 @@
568 ignoreCount = "0" 568 ignoreCount = "0"
569 continueAfterRunningActions = "No" 569 continueAfterRunningActions = "No"
570 filePath = "MenuTableViewController.m" 570 filePath = "MenuTableViewController.m"
571 - timestampString = "435854984.608419" 571 + timestampString = "436465076.64059"
572 startingColumnNumber = "9223372036854775807" 572 startingColumnNumber = "9223372036854775807"
573 endingColumnNumber = "9223372036854775807" 573 endingColumnNumber = "9223372036854775807"
574 - startingLineNumber = "137"  
575 - endingLineNumber = "137" 574 + startingLineNumber = "139"
  575 + endingLineNumber = "139"
576 landmarkName = "-generateSaleListNavLevel" 576 landmarkName = "-generateSaleListNavLevel"
577 landmarkType = "5"> 577 landmarkType = "5">
578 </BreakpointContent> 578 </BreakpointContent>
@@ -600,11 +600,11 @@ @@ -600,11 +600,11 @@
600 ignoreCount = "0" 600 ignoreCount = "0"
601 continueAfterRunningActions = "No" 601 continueAfterRunningActions = "No"
602 filePath = "MenuTableViewController.m" 602 filePath = "MenuTableViewController.m"
603 - timestampString = "435859231.211213" 603 + timestampString = "436467072.187571"
604 startingColumnNumber = "9223372036854775807" 604 startingColumnNumber = "9223372036854775807"
605 endingColumnNumber = "9223372036854775807" 605 endingColumnNumber = "9223372036854775807"
606 - startingLineNumber = "1100"  
607 - endingLineNumber = "1100" 606 + startingLineNumber = "1210"
  607 + endingLineNumber = "1210"
608 landmarkName = "-tableView:didSelectRowAtIndexPath:" 608 landmarkName = "-tableView:didSelectRowAtIndexPath:"
609 landmarkType = "5"> 609 landmarkType = "5">
610 </BreakpointContent> 610 </BreakpointContent>
@@ -616,11 +616,11 @@ @@ -616,11 +616,11 @@
616 ignoreCount = "0" 616 ignoreCount = "0"
617 continueAfterRunningActions = "No" 617 continueAfterRunningActions = "No"
618 filePath = "MenuTableViewController.m" 618 filePath = "MenuTableViewController.m"
619 - timestampString = "435855046.616674" 619 + timestampString = "436467072.187571"
620 startingColumnNumber = "9223372036854775807" 620 startingColumnNumber = "9223372036854775807"
621 endingColumnNumber = "9223372036854775807" 621 endingColumnNumber = "9223372036854775807"
622 - startingLineNumber = "780"  
623 - endingLineNumber = "780" 622 + startingLineNumber = "890"
  623 + endingLineNumber = "890"
624 landmarkName = "-tableView:didSelectRowAtIndexPath:" 624 landmarkName = "-tableView:didSelectRowAtIndexPath:"
625 landmarkType = "5"> 625 landmarkType = "5">
626 </BreakpointContent> 626 </BreakpointContent>
@@ -632,11 +632,11 @@ @@ -632,11 +632,11 @@
632 ignoreCount = "0" 632 ignoreCount = "0"
633 continueAfterRunningActions = "No" 633 continueAfterRunningActions = "No"
634 filePath = "MenuTableViewController.m" 634 filePath = "MenuTableViewController.m"
635 - timestampString = "435855046.616674" 635 + timestampString = "436467072.187571"
636 startingColumnNumber = "9223372036854775807" 636 startingColumnNumber = "9223372036854775807"
637 endingColumnNumber = "9223372036854775807" 637 endingColumnNumber = "9223372036854775807"
638 - startingLineNumber = "779"  
639 - endingLineNumber = "779" 638 + startingLineNumber = "889"
  639 + endingLineNumber = "889"
640 landmarkName = "-tableView:didSelectRowAtIndexPath:" 640 landmarkName = "-tableView:didSelectRowAtIndexPath:"
641 landmarkType = "5"> 641 landmarkType = "5">
642 </BreakpointContent> 642 </BreakpointContent>
@@ -648,11 +648,11 @@ @@ -648,11 +648,11 @@
648 ignoreCount = "0" 648 ignoreCount = "0"
649 continueAfterRunningActions = "No" 649 continueAfterRunningActions = "No"
650 filePath = "MenuTableViewController.m" 650 filePath = "MenuTableViewController.m"
651 - timestampString = "435855046.616674" 651 + timestampString = "436467072.187571"
652 startingColumnNumber = "9223372036854775807" 652 startingColumnNumber = "9223372036854775807"
653 endingColumnNumber = "9223372036854775807" 653 endingColumnNumber = "9223372036854775807"
654 - startingLineNumber = "768"  
655 - endingLineNumber = "768" 654 + startingLineNumber = "878"
  655 + endingLineNumber = "878"
656 landmarkName = "-tableView:sectionForSectionIndexTitle:atIndex:" 656 landmarkName = "-tableView:sectionForSectionIndexTitle:atIndex:"
657 landmarkType = "5"> 657 landmarkType = "5">
658 </BreakpointContent> 658 </BreakpointContent>
@@ -721,5 +721,69 @@ @@ -721,5 +721,69 @@
721 landmarkType = "5"> 721 landmarkType = "5">
722 </BreakpointContent> 722 </BreakpointContent>
723 </BreakpointProxy> 723 </BreakpointProxy>
  724 + <BreakpointProxy
  725 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  726 + <BreakpointContent
  727 + shouldBeEnabled = "No"
  728 + ignoreCount = "0"
  729 + continueAfterRunningActions = "No"
  730 + filePath = "MenuTableViewController.m"
  731 + timestampString = "436467072.187571"
  732 + startingColumnNumber = "9223372036854775807"
  733 + endingColumnNumber = "9223372036854775807"
  734 + startingLineNumber = "550"
  735 + endingLineNumber = "550"
  736 + landmarkName = "-handleOpenURL:"
  737 + landmarkType = "5">
  738 + </BreakpointContent>
  739 + </BreakpointProxy>
  740 + <BreakpointProxy
  741 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  742 + <BreakpointContent
  743 + shouldBeEnabled = "No"
  744 + ignoreCount = "0"
  745 + continueAfterRunningActions = "No"
  746 + filePath = "MenuTableViewController.m"
  747 + timestampString = "436467072.187571"
  748 + startingColumnNumber = "9223372036854775807"
  749 + endingColumnNumber = "9223372036854775807"
  750 + startingLineNumber = "557"
  751 + endingLineNumber = "557"
  752 + landmarkName = "-handleOpenURL:"
  753 + landmarkType = "5">
  754 + </BreakpointContent>
  755 + </BreakpointProxy>
  756 + <BreakpointProxy
  757 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  758 + <BreakpointContent
  759 + shouldBeEnabled = "No"
  760 + ignoreCount = "0"
  761 + continueAfterRunningActions = "No"
  762 + filePath = "MenuTableViewController.m"
  763 + timestampString = "436467072.187571"
  764 + startingColumnNumber = "9223372036854775807"
  765 + endingColumnNumber = "9223372036854775807"
  766 + startingLineNumber = "534"
  767 + endingLineNumber = "534"
  768 + landmarkName = "-handleOpenURL:"
  769 + landmarkType = "5">
  770 + </BreakpointContent>
  771 + </BreakpointProxy>
  772 + <BreakpointProxy
  773 + BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
  774 + <BreakpointContent
  775 + shouldBeEnabled = "No"
  776 + ignoreCount = "0"
  777 + continueAfterRunningActions = "No"
  778 + filePath = "MenuTableViewController.m"
  779 + timestampString = "436467072.187571"
  780 + startingColumnNumber = "9223372036854775807"
  781 + endingColumnNumber = "9223372036854775807"
  782 + startingLineNumber = "515"
  783 + endingLineNumber = "515"
  784 + landmarkName = "-alertView:clickedButtonAtIndex:"
  785 + landmarkType = "5">
  786 + </BreakpointContent>
  787 + </BreakpointProxy>
724 </Breakpoints> 788 </Breakpoints>
725 </Bucket> 789 </Bucket>
DUREX Vendor Control/Base.lproj/Localizable.strings
@@ -105,4 +105,12 @@ @@ -105,4 +105,12 @@
105 "Device answer timeout occurred" = "Device answer timeout occurred"; 105 "Device answer timeout occurred" = "Device answer timeout occurred";
106 "Incident log" = "Incident log"; 106 "Incident log" = "Incident log";
107 "Error Code" = "Error Code"; 107 "Error Code" = "Error Code";
108 -"Error Value" = "Error Value";  
109 \ No newline at end of file 108 \ No newline at end of file
  109 +"Error Value" = "Error Value";
  110 +"Error obtaining data from URL" = "Error obtaining data from URL";
  111 +"Missing fields version and/or commands in JSON file" = "Missing fields version and/or commands in JSON file";
  112 +"Version mismatch" = "Version mismatch";
  113 +"Do you want to run batch command file" = "Do you want to run batch command file";
  114 +"WARNING: Machine ID does not match currently connected machine. Do you wish to continue?" = "WARNING: Machine ID does not match currently connected machine. Do you wish to continue?";
  115 +"Confirmation" = "Confirmation";
  116 +"OK" = "OK";
  117 +"Cancel" = "Cancel";
110 \ No newline at end of file 118 \ No newline at end of file
DUREX Vendor Control/ChildViewController.m
@@ -46,4 +46,14 @@ @@ -46,4 +46,14 @@
46 } 46 }
47 */ 47 */
48 48
  49 +- (void) parentViewControllerDidRotateWithOrientation:(UIDeviceOrientation)orientation
  50 +{
  51 + //STUB
  52 +}
  53 +
  54 +- (void) parentViewControllerWillRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration
  55 +{
  56 + //STUB
  57 +}
  58 +
49 @end 59 @end
DUREX Vendor Control/DatePickerViewController.h
@@ -10,7 +10,7 @@ @@ -10,7 +10,7 @@
10 10
11 #import <UIKit/UIKit.h> 11 #import <UIKit/UIKit.h>
12 #import <QuartzCore/QuartzCore.h> 12 #import <QuartzCore/QuartzCore.h>
13 -#import "DUREXAppDelegate.h" 13 +#import "BTAppDelegate.h"
14 14
15 @protocol DatePickerViewControllerDelegate <NSObject> 15 @protocol DatePickerViewControllerDelegate <NSObject>
16 - (void)passDateViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date; 16 - (void)passDateViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date;
DUREX Vendor Control/DateRangePickerViewController.h
@@ -18,7 +18,7 @@ @@ -18,7 +18,7 @@
18 18
19 #import <UIKit/UIKit.h> 19 #import <UIKit/UIKit.h>
20 #import <QuartzCore/QuartzCore.h> 20 #import <QuartzCore/QuartzCore.h>
21 -#import "DUREXAppDelegate.h" 21 +#import "BTAppDelegate.h"
22 #import "ChildViewController.h" 22 #import "ChildViewController.h"
23 23
24 @protocol DateRangePickerViewControllerDelegate <NSObject> 24 @protocol DateRangePickerViewControllerDelegate <NSObject>
DUREX Vendor Control/FirstAppExample/DUREXAppDelegate.h renamed to DUREX Vendor Control/FirstAppExample/BTAppDelegate.h
@@ -8,10 +8,12 @@ @@ -8,10 +8,12 @@
8 8
9 #import <UIKit/UIKit.h> 9 #import <UIKit/UIKit.h>
10 10
11 -@interface DUREXAppDelegate : UIResponder <UIApplicationDelegate> 11 +@interface BTAppDelegate : UIResponder <UIApplicationDelegate>
12 12
13 @property (strong, nonatomic) UIWindow *window; 13 @property (strong, nonatomic) UIWindow *window;
14 @property (nonatomic, strong) IBOutlet UINavigationController *navController; 14 @property (nonatomic, strong) IBOutlet UINavigationController *navController;
  15 +@property (strong, nonatomic) NSURL *handledURL;
  16 +@property (strong,nonatomic) NSString *currentVersion;
15 17
16 18
17 19
DUREX Vendor Control/FirstAppExample/DUREXAppDelegate.m renamed to DUREX Vendor Control/FirstAppExample/BTAppDelegate.m
@@ -6,18 +6,19 @@ @@ -6,18 +6,19 @@
6 // Copyright (c) 2013 Emmoco. All rights reserved. 6 // Copyright (c) 2013 Emmoco. All rights reserved.
7 // 7 //
8 8
9 -#import "DUREXAppDelegate.h" 9 +#import "BTAppDelegate.h"
10 #import "EMFramework.h" 10 #import "EMFramework.h"
11 #import "EMDevicePickerViewController.h" 11 #import "EMDevicePickerViewController.h"
  12 +#import "MenuTableViewController.h"
12 13
13 -@interface DUREXAppDelegate () <UINavigationControllerDelegate> 14 +@interface BTAppDelegate () <UINavigationControllerDelegate>
14 { 15 {
15 16
16 } 17 }
17 18
18 @end 19 @end
19 20
20 -@implementation DUREXAppDelegate 21 +@implementation BTAppDelegate
21 22
22 - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 23 - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
23 { 24 {
@@ -26,6 +27,9 @@ @@ -26,6 +27,9 @@
26 [[self navController] setDelegate:self]; 27 [[self navController] setDelegate:self];
27 28
28 [[EMConnectionListManager sharedManager] startUpdating]; 29 [[EMConnectionListManager sharedManager] startUpdating];
  30 +
  31 + self.handledURL = nil;
  32 + self.currentVersion = @"1.0.0";
29 return YES; 33 return YES;
30 } 34 }
31 35
@@ -74,4 +78,24 @@ @@ -74,4 +78,24 @@
74 } 78 }
75 } 79 }
76 80
  81 +- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url
  82 +{
  83 + NSLog(@"[DUREXAppDelegate.m]: Handling URL %@",url);
  84 + if ([self.navController.topViewController isKindOfClass:[MenuTableViewController class]])
  85 + {
  86 + MenuTableViewController *viewController = (MenuTableViewController*) self.navController.topViewController;
  87 + if (url != nil && [url isFileURL])
  88 + {
  89 + NSLog(@"[DUREXAppDelegate.m]: Pushing URL to MenuTableViewController...");
  90 + [viewController handleOpenURL:url];
  91 + }
  92 + }
  93 + else
  94 + {
  95 + NSLog(@"[DUREXAppDelegate.m]: Storing handled URL...");
  96 + self.handledURL = url;
  97 + }
  98 + return YES;
  99 +}
  100 +
77 @end 101 @end
DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/120 - App Icon_2x.png deleted

8.83 KB

DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/29 - App Icon_2x.png

4.93 KB | W: | H:

12.6 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/40 - App Icon_2x.png

6.25 KB | W: | H:

21.5 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/60 - App Icon_2x.png 0 โ†’ 100644

45 KB

DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/76 - App Icon_1x.png

5.96 KB | W: | H:

19.7 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/76 - App Icon_2x.png

11.1 KB | W: | H:

70.5 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
DUREX Vendor Control/FirstAppExample/Images.xcassets/AppIcon.appiconset/Contents.json
@@ -30,7 +30,7 @@ @@ -30,7 +30,7 @@
30 { 30 {
31 "size" : "60x60", 31 "size" : "60x60",
32 "idiom" : "iphone", 32 "idiom" : "iphone",
33 - "filename" : "120 - App Icon_2x.png", 33 + "filename" : "60 - App Icon_2x.png",
34 "scale" : "2x" 34 "scale" : "2x"
35 }, 35 },
36 { 36 {
DUREX Vendor Control/FirstAppExample/main.m
@@ -8,11 +8,11 @@ @@ -8,11 +8,11 @@
8 8
9 #import <UIKit/UIKit.h> 9 #import <UIKit/UIKit.h>
10 10
11 -#import "DUREXAppDelegate.h" 11 +#import "BTAppDelegate.h"
12 12
13 int main(int argc, char * argv[]) 13 int main(int argc, char * argv[])
14 { 14 {
15 @autoreleasepool { 15 @autoreleasepool {
16 - return UIApplicationMain(argc, argv, nil, NSStringFromClass([DUREXAppDelegate class])); 16 + return UIApplicationMain(argc, argv, nil, NSStringFromClass([BTAppDelegate class]));
17 } 17 }
18 } 18 }
DUREX Vendor Control/MenuTableViewController.h
@@ -22,6 +22,8 @@ @@ -22,6 +22,8 @@
22 22
23 #define num(x) [NSNumber numberWithUnsignedInt:x] 23 #define num(x) [NSNumber numberWithUnsignedInt:x]
24 24
  25 +#define BATCH_ALERT_TAG 200
  26 +
25 #define CELL_CARAT_TAG 100 27 #define CELL_CARAT_TAG 100
26 28
27 #define MENU_ELEMENTS @"[1000]Maintenance",@"[1001]Basic Configuration",@"[1002]Sending a Report" 29 #define MENU_ELEMENTS @"[1000]Maintenance",@"[1001]Basic Configuration",@"[1002]Sending a Report"
@@ -73,6 +75,7 @@ enum { @@ -73,6 +75,7 @@ enum {
73 A6, 75 A6,
74 A7, 76 A7,
75 //A9, 77 //A9,
  78 + BATCH_COMMANDS,
76 INVALID_COMMAND, 79 INVALID_COMMAND,
77 NONE, 80 NONE,
78 } commandTypes; 81 } commandTypes;
@@ -82,8 +85,9 @@ enum { @@ -82,8 +85,9 @@ enum {
82 INCIDENT_LOG, 85 INCIDENT_LOG,
83 } logType; 86 } logType;
84 87
85 -@interface MenuTableViewController : UITableViewController <DatePickerViewControllerDelegate,PriceChangerViewControllerDelegate,NameChangerViewControllerDelegate, DateRangePickerViewControllerDelegate, CommunicationProtocolDelegate, NSURLConnectionDataDelegate, ChildViewControllerDelegate> 88 +@interface MenuTableViewController : UITableViewController <DatePickerViewControllerDelegate,PriceChangerViewControllerDelegate,NameChangerViewControllerDelegate, DateRangePickerViewControllerDelegate, CommunicationProtocolDelegate, NSURLConnectionDataDelegate, ChildViewControllerDelegate,UIAlertViewDelegate>
86 89
87 - (void) navBack; 90 - (void) navBack;
  91 +- (void) handleOpenURL: (NSURL*) url;
88 92
89 @end 93 @end
DUREX Vendor Control/MenuTableViewController.m
@@ -48,8 +48,10 @@ @@ -48,8 +48,10 @@
48 //GENERAL ATTRIBUTES 48 //GENERAL ATTRIBUTES
49 @property (nonatomic,strong) CommunicationProtocol* protocol; 49 @property (nonatomic,strong) CommunicationProtocol* protocol;
50 @property (strong,nonatomic) NSString *machineMACAddr; 50 @property (strong,nonatomic) NSString *machineMACAddr;
  51 +@property (strong,nonatomic) BTAppDelegate *appDelegate;
51 @property (strong,nonatomic) Stack *parentLayout; 52 @property (strong,nonatomic) Stack *parentLayout;
52 @property (strong,nonatomic) NSTimer *timeoutTimer; 53 @property (strong,nonatomic) NSTimer *timeoutTimer;
  54 +@property (strong,nonatomic) NSMutableArray *batchCommands;
53 55
54 @property (strong,nonatomic) Sensors *sensorStatus; 56 @property (strong,nonatomic) Sensors *sensorStatus;
55 @property (strong,nonatomic) SalesLog *salesLog; 57 @property (strong,nonatomic) SalesLog *salesLog;
@@ -459,6 +461,17 @@ @@ -459,6 +461,17 @@
459 [self.view makeToast:NSLocalizedString(@"Product name change returned error", nil) duration:3 position:[NSValue valueWithCGPoint:CGPointMake(self.view.frame.size.width/2,self.view.frame.size.height/2)] title:NSLocalizedString(@"Error", nil) image:[UIImage imageNamed:@"icon_delete"]]; 461 [self.view makeToast:NSLocalizedString(@"Product name change returned error", nil) duration:3 position:[NSValue valueWithCGPoint:CGPointMake(self.view.frame.size.width/2,self.view.frame.size.height/2)] title:NSLocalizedString(@"Error", nil) image:[UIImage imageNamed:@"icon_delete"]];
460 } 462 }
461 } 463 }
  464 + else if(self.sentCommand == BATCH_COMMANDS)
  465 + {
  466 + if(self.batchCommands.count)
  467 + {
  468 + [self processBatchCommands];
  469 + }
  470 + else
  471 + {
  472 + self.sentCommand = NONE;
  473 + }
  474 + }
462 else 475 else
463 { 476 {
464 NSLog(@"[MenuTableViewController]: Unknown response received. Data discarded."); 477 NSLog(@"[MenuTableViewController]: Unknown response received. Data discarded.");
@@ -488,10 +501,99 @@ @@ -488,10 +501,99 @@
488 } 501 }
489 } 502 }
490 503
  504 +
  505 +//BATCH COMMAND PROCESSING
  506 +- (void) processBatchCommands
  507 +{
  508 + NSString *command = [self.batchCommands objectAtIndex:0];
  509 + [self.batchCommands removeObjectAtIndex:0];
  510 + [_protocol writeMessage:command];
  511 + [self setSentCommand:BATCH_COMMANDS];
  512 + [self startTimeoutTimer];
  513 +}
  514 +
  515 +-(void) alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex
  516 +{
  517 + if (alertView.tag == BATCH_ALERT_TAG)
  518 + {
  519 + if (buttonIndex == 1)
  520 + {
  521 + [self processBatchCommands];
  522 + }
  523 + }
  524 +}
  525 +
  526 +- (void) handleOpenURL:(NSURL *)url
  527 +{
  528 + NSData *data = [NSData dataWithContentsOfURL:url];
  529 + NSString *contents = [[NSString alloc] initWithData: data encoding:NSUTF8StringEncoding];
  530 + if(data == nil)
  531 + {
  532 + NSLog(@"[MenuTableViewController.m]: Error obtaining data from URL");
  533 + [self.view makeToast:NSLocalizedString(@"Error obtaining data from URL", nil) duration:3 position:[NSValue valueWithCGPoint:CGPointMake(self.view.frame.size.width/2,self.view.frame.size.height/2)] title:NSLocalizedString(@"Error", nil) image:[UIImage imageNamed:@"icon_delete"]];
  534 + return;
  535 + }
  536 + NSLog(@"[MenuTableViewController.m]: Read file contents from handled URL: %@",contents);
  537 + NSError *error = nil;
  538 + NSDictionary *JSONData = [NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingMutableContainers error: &error];
  539 + if(!JSONData)
  540 + {
  541 + NSLog(@"[MenuTableViewController.m]: %@",error);
  542 + [self.view makeToast:[error localizedDescription] duration:3 position:[NSValue valueWithCGPoint:CGPointMake(self.view.frame.size.width/2,self.view.frame.size.height/2)] title:NSLocalizedString(@"Error", nil) image:[UIImage imageNamed:@"icon_delete"]];
  543 + return;
  544 + }
  545 + NSString *version = [JSONData objectForKey:@"version"];
  546 + NSString *name = [JSONData objectForKey:@"name"];
  547 + NSString *machineID = [JSONData objectForKey:@"machineID"];
  548 + NSArray *commands = [JSONData objectForKey:@"commands"];
  549 + NSString *errorString = nil;
  550 + UIAlertView *alert;
  551 + if(version == nil || commands == nil)
  552 + {
  553 + errorString = NSLocalizedString(@"Missing fields version and/or commands in JSON file",nil);
  554 + }
  555 + else if(![version isEqualToString:self.appDelegate.currentVersion])
  556 + {
  557 + errorString = NSLocalizedString(@"Version mismatch",nil);
  558 + }
  559 + else
  560 + {
  561 + self.batchCommands = [[NSMutableArray alloc] initWithArray:commands];
  562 + if(![machineID isEqualToString:self.machineMACAddr])
  563 + {
  564 + alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Confirmation",nil)
  565 + message:[NSString stringWithFormat:@"%@ \"%@\"?\n\n",NSLocalizedString(@"Do you want to run batch command file",nil),name,NSLocalizedString(@"WARNING: Machine ID does not match currently connected machine. Do you wish to continue?",nil)]
  566 + delegate:self
  567 + cancelButtonTitle:NSLocalizedString(@"Cancel",nil)
  568 + otherButtonTitles:NSLocalizedString(@"OK",nil), nil];
  569 + }
  570 + else
  571 + {
  572 + alert = [[UIAlertView alloc] initWithTitle: NSLocalizedString(@"Confirmation",nil)
  573 + message: [NSString stringWithFormat:@"%@ \"%@\"?",NSLocalizedString(@"Do you want to run batch command file",nil),name]
  574 + delegate:self
  575 + cancelButtonTitle:NSLocalizedString(@"Cancel",nil)
  576 + otherButtonTitles:NSLocalizedString(@"OK",nil), nil];
  577 + }
  578 + }
  579 + if(errorString != nil)
  580 + {
  581 + alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Error",nil)
  582 + message:[NSString stringWithFormat:@"%@",errorString]
  583 + delegate:nil
  584 + cancelButtonTitle:NSLocalizedString(@"OK",nil)
  585 + otherButtonTitles:nil];
  586 + }
  587 + alert.tag = BATCH_ALERT_TAG;
  588 + [alert show];
  589 +}
  590 +
  591 +//UITABLEVIEWCONTROLLER FUNCTIONS
491 - (void)viewDidLoad 592 - (void)viewDidLoad
492 { 593 {
493 [super viewDidLoad]; 594 [super viewDidLoad];
494 [_activityIndicator setHidden:YES]; 595 [_activityIndicator setHidden:YES];
  596 + self.appDelegate = [[UIApplication sharedApplication] delegate];
495 597
496 //Set navigation bar 598 //Set navigation bar
497 UIImage *backImage = [UIImage imageNamed:@"back_arrow.png"]; 599 UIImage *backImage = [UIImage imageNamed:@"back_arrow.png"];
@@ -516,12 +618,22 @@ @@ -516,12 +618,22 @@
516 618
517 //Set navigation level 619 //Set navigation level
518 [self initializeMenuEntries]; 620 [self initializeMenuEntries];
  621 + [self setChildViewControllers:[[NSMutableArray alloc]init]];
519 self.currentNavLevel = 255; 622 self.currentNavLevel = 255;
  623 +
  624 + //Initialize menu view
  625 +
520 [_protocol establishConnection]; 626 [_protocol establishConnection];
521 //[self setSentCommand:HELLO]; 627 //[self setSentCommand:HELLO];
522 //[self startTimeoutTimer]; 628 //[self startTimeoutTimer];
523 - [self changeNavLevel:MENU :FALSE];  
524 - [self setChildViewControllers:[[NSMutableArray alloc]init]]; 629 + [self changeNavLevel:MENU :FALSE]; //HACK!
  630 +
  631 + //Detect handled URL
  632 + if(self.appDelegate.handledURL != nil)
  633 + {
  634 + NSLog(@"[MenuTableViewController.m]: Detected handled URL in appDelegate");
  635 + [self handleOpenURL: self.appDelegate.handledURL];
  636 + }
525 } 637 }
526 638
527 -(void)didReceiveNotification:(NSNotification*) notification 639 -(void)didReceiveNotification:(NSNotification*) notification
@@ -751,7 +863,7 @@ @@ -751,7 +863,7 @@
751 return [[[self currentStructure] objectAtIndex:section] intValue]; 863 return [[[self currentStructure] objectAtIndex:section] intValue];
752 } 864 }
753 865
754 -- (NSArray *)sectionIndexTitlesForTableView:(UITableView *)tableView 866 +- (const NSArray*)sectionIndexTitlesForTableView:(UITableView *)tableView
755 { 867 {
756 if(self.showIndexes) 868 if(self.showIndexes)
757 { 869 {
DUREX Vendor Control/NameChangerViewController.h
@@ -10,7 +10,7 @@ @@ -10,7 +10,7 @@
10 10
11 #import <UIKit/UIKit.h> 11 #import <UIKit/UIKit.h>
12 #import <QuartzCore/QuartzCore.h> 12 #import <QuartzCore/QuartzCore.h>
13 -#import "DUREXAppDelegate.h" 13 +#import "BTAppDelegate.h"
14 14
15 @protocol NameChangerViewControllerDelegate <NSObject> 15 @protocol NameChangerViewControllerDelegate <NSObject>
16 - (void)passNameViewController:(NameChangerViewController*)controller didFinishEnteringItem:(NSArray *)data; 16 - (void)passNameViewController:(NameChangerViewController*)controller didFinishEnteringItem:(NSArray *)data;
DUREX Vendor Control/PriceChangerViewController.h
@@ -10,7 +10,7 @@ @@ -10,7 +10,7 @@
10 10
11 #import <UIKit/UIKit.h> 11 #import <UIKit/UIKit.h>
12 #import <QuartzCore/QuartzCore.h> 12 #import <QuartzCore/QuartzCore.h>
13 -#import "DUREXAppDelegate.h" 13 +#import "BTAppDelegate.h"
14 14
15 @protocol PriceChangerViewControllerDelegate <NSObject> 15 @protocol PriceChangerViewControllerDelegate <NSObject>
16 - (void)passPriceViewController:(PriceChangerViewController*)controller didFinishEnteringItem:(NSArray *)data; 16 - (void)passPriceViewController:(PriceChangerViewController*)controller didFinishEnteringItem:(NSArray *)data;
DUREX Vendor Control/en.lproj/Localizable.strings
@@ -105,4 +105,12 @@ @@ -105,4 +105,12 @@
105 "Device answer timeout occurred" = "Device answer timeout occurred"; 105 "Device answer timeout occurred" = "Device answer timeout occurred";
106 "Incident log" = "Incident log"; 106 "Incident log" = "Incident log";
107 "Error Code" = "Error Code"; 107 "Error Code" = "Error Code";
108 -"Error Value" = "Error Value";  
109 \ No newline at end of file 108 \ No newline at end of file
  109 +"Error Value" = "Error Value";
  110 +"Error obtaining data from URL" = "Error obtaining data from URL";
  111 +"Missing fields version and/or commands in JSON file" = "Missing fields version and/or commands in JSON file";
  112 +"Version mismatch" = "Version mismatch";
  113 +"Do you want to run batch command file" = "Do you want to run batch command file";
  114 +"WARNING: Machine ID does not match currently connected machine. Do you wish to continue?" = "WARNING: Machine ID does not match currently connected machine. Do you wish to continue?";
  115 +"Confirmation" = "Confirmation";
  116 +"OK" = "OK";
  117 +"Cancel" = "Cancel";
110 \ No newline at end of file 118 \ No newline at end of file
DUREX Vendor Control/es.lproj/Localizable.strings
@@ -105,4 +105,12 @@ @@ -105,4 +105,12 @@
105 "Device answer timeout occurred" = "El tiempo de espera de respuesta del dispositivo ha expirado"; 105 "Device answer timeout occurred" = "El tiempo de espera de respuesta del dispositivo ha expirado";
106 "Incident log" = "Registro de incidencias"; 106 "Incident log" = "Registro de incidencias";
107 "Error Code" = "Cรณdigo de error"; 107 "Error Code" = "Cรณdigo de error";
108 -"Error Value" = "Valor del error";  
109 \ No newline at end of file 108 \ No newline at end of file
  109 +"Error Value" = "Valor del error";
  110 +"Error obtaining data from URL" = "Error al obtener los datos de la URL";
  111 +"Missing fields version and/or commands in JSON file" = "Faltan los campos de versiรณn y/o comandos en el fichero JSON";
  112 +"Version mismatch" = "Versiones no coincidentes";
  113 +"Do you want to run batch command file" = "ยฟDesea ejecutar el fichero por lotes";
  114 +"WARNING: Machine ID does not match currently connected machine. Do you wish to continue?" = "ADVERTENCIA: El identificador de mรกquina no coincide con la mรกquina conectada. ยฟDesea continuar?";
  115 +"Confirmation" = "Confirmaciรณn";
  116 +"OK" = "OK";
  117 +"Cancel" = "Cancelar";
110 \ No newline at end of file 118 \ No newline at end of file
1 TESTS: 1 TESTS:
2 - A3 command 2 - A3 command
  3 +- Batch commands
  4 +- Localization
3 5
4 BUGS: 6 BUGS:
5 - On date change, response is overwritten by previous query, trimming needed according to numBytes 7 - On date change, response is overwritten by previous query, trimming needed according to numBytes
6 -- daterangepicker regression on landscape  
7 8
8 TODO: 9 TODO:
9 -- Solve bugs  
10 -  
11 -OPTIONAL:  
12 -- Batch command files, definition, parsing and pushing them to the app  
13 -- Month/Year headers on sale list and incident list  
14 - 10 +- Refactor code
codic.png 0 โ†’ 100644

1.7 MB