From 2a24825e70ddcb8393496f3a4e4d60c247b1d4aa Mon Sep 17 00:00:00 2001 From: Imanol-Mikel Barba Sabariego Date: Wed, 3 Sep 2014 18:54:23 +0000 Subject: [PATCH] --- DUREX Vendor Control/Base.lproj/DatePickerViewController.xib | 75 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/Base.lproj/DatePickerViewController_iPad.xib | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/Base.lproj/Localizable.strings | 5 ++++- DUREX Vendor Control/Base.lproj/NameChangerViewController.xib | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/Base.lproj/NameChangerViewController_iPad.xib | 98 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/Base.lproj/PriceChangerViewController.xib | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/Base.lproj/PriceChangerViewController_iPad.xib | 98 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/CommunicationProtocol.m | 24 ++++++++---------------- DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.pbxproj | 116 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------- DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate | Bin 115868 -> 0 bytes DUREX Vendor Control/DUREX Vendor Control.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist | 42 +++++++++++++++++++++++++++++------------- DUREX Vendor Control/DatePickerViewController.h | 2 +- DUREX Vendor Control/DatePickerViewController.m | 2 +- DUREX Vendor Control/DatePickerViewController.xib | 71 ----------------------------------------------------------------------- DUREX Vendor Control/DatePickerViewController_iPad.xib | 74 -------------------------------------------------------------------------- DUREX Vendor Control/MenuTableViewController.h | 8 ++++++-- DUREX Vendor Control/MenuTableViewController.m | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------- DUREX Vendor Control/NameChangerViewController.h | 33 +++++++++++++++++++++++++++++++++ DUREX Vendor Control/NameChangerViewController.m | 102 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/PriceChangerViewController.h | 33 +++++++++++++++++++++++++++++++++ DUREX Vendor Control/PriceChangerViewController.m | 103 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX Vendor Control/en.lproj/DatePickerViewController.strings | 3 +++ DUREX Vendor Control/en.lproj/DatePickerViewController_iPad.strings | 3 +++ DUREX Vendor Control/en.lproj/Localizable.strings | 5 ++++- DUREX Vendor Control/en.lproj/NameChangerViewController.strings | 12 ++++++++++++ DUREX Vendor Control/en.lproj/NameChangerViewController_iPad.strings | 12 ++++++++++++ DUREX Vendor Control/en.lproj/PriceChangerViewController.strings | 12 ++++++++++++ DUREX Vendor Control/en.lproj/PriceChangerViewController_iPad.strings | 12 ++++++++++++ DUREX Vendor Control/es.lproj/DatePickerViewController.strings | 3 +++ DUREX Vendor Control/es.lproj/DatePickerViewController_iPad.strings | 3 +++ DUREX Vendor Control/es.lproj/Localizable.strings | 5 ++++- DUREX Vendor Control/es.lproj/NameChangerViewController.strings | 12 ++++++++++++ DUREX Vendor Control/es.lproj/NameChangerViewController_iPad.strings | 12 ++++++++++++ DUREX Vendor Control/es.lproj/PriceChangerViewController.strings | 12 ++++++++++++ DUREX Vendor Control/es.lproj/PriceChangerViewController_iPad.strings | 12 ++++++++++++ DUREX tests/Base.lproj/DatePickerViewController.xib | 4 ++-- DUREX tests/Base.lproj/DatePickerViewController_iPad.xib | 4 ++-- DUREX tests/Base.lproj/MainStoryboard.storyboard | 2 +- DUREX tests/Base.lproj/PriceChangerViewController.xib | 96 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX tests/Base.lproj/PriceChangerViewController_iPad.xib | 97 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX tests/DUREX test.xcodeproj/project.pbxproj | 38 ++++++++++++++++++++++++++++++++++++++ DUREX tests/DUREX test.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate | Bin 239115 -> 0 bytes DUREX tests/DUREX test.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist | 18 ++++++++++++++++++ DUREX tests/DatePickerViewController.h | 2 +- DUREX tests/DatePickerViewController.m | 2 +- DUREX tests/MenuTableViewController.h | 6 ++++-- DUREX tests/MenuTableViewController.m | 35 +++++++++++++++++++++++++++-------- DUREX tests/PriceChangerViewController.h | 33 +++++++++++++++++++++++++++++++++ DUREX tests/PriceChangerViewController.m | 103 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ DUREX tests/en.lproj/PriceChangerViewController.strings | 12 ++++++++++++ DUREX tests/en.lproj/PriceChangerViewController_iPad.strings | 12 ++++++++++++ DUREX tests/es.lproj/PriceChangerViewController.strings | 12 ++++++++++++ DUREX tests/es.lproj/PriceChangerViewController_iPad.strings | 12 ++++++++++++ TODO | 4 ++-- 54 files changed, 1621 insertions(+), 216 deletions(-) create mode 100644 DUREX Vendor Control/Base.lproj/DatePickerViewController.xib create mode 100644 DUREX Vendor Control/Base.lproj/DatePickerViewController_iPad.xib create mode 100644 DUREX Vendor Control/Base.lproj/NameChangerViewController.xib create mode 100644 DUREX Vendor Control/Base.lproj/NameChangerViewController_iPad.xib create mode 100644 DUREX Vendor Control/Base.lproj/PriceChangerViewController.xib create mode 100644 DUREX Vendor Control/Base.lproj/PriceChangerViewController_iPad.xib delete mode 100644 DUREX Vendor Control/DatePickerViewController.xib delete mode 100644 DUREX Vendor Control/DatePickerViewController_iPad.xib create mode 100644 DUREX Vendor Control/NameChangerViewController.h create mode 100644 DUREX Vendor Control/NameChangerViewController.m create mode 100644 DUREX Vendor Control/PriceChangerViewController.h create mode 100644 DUREX Vendor Control/PriceChangerViewController.m create mode 100644 DUREX Vendor Control/en.lproj/DatePickerViewController.strings create mode 100644 DUREX Vendor Control/en.lproj/DatePickerViewController_iPad.strings create mode 100644 DUREX Vendor Control/en.lproj/NameChangerViewController.strings create mode 100644 DUREX Vendor Control/en.lproj/NameChangerViewController_iPad.strings create mode 100644 DUREX Vendor Control/en.lproj/PriceChangerViewController.strings create mode 100644 DUREX Vendor Control/en.lproj/PriceChangerViewController_iPad.strings create mode 100644 DUREX Vendor Control/es.lproj/DatePickerViewController.strings create mode 100644 DUREX Vendor Control/es.lproj/DatePickerViewController_iPad.strings create mode 100644 DUREX Vendor Control/es.lproj/NameChangerViewController.strings create mode 100644 DUREX Vendor Control/es.lproj/NameChangerViewController_iPad.strings create mode 100644 DUREX Vendor Control/es.lproj/PriceChangerViewController.strings create mode 100644 DUREX Vendor Control/es.lproj/PriceChangerViewController_iPad.strings create mode 100644 DUREX tests/Base.lproj/PriceChangerViewController.xib create mode 100644 DUREX tests/Base.lproj/PriceChangerViewController_iPad.xib create mode 100644 DUREX tests/PriceChangerViewController.h create mode 100644 DUREX tests/PriceChangerViewController.m create mode 100644 DUREX tests/en.lproj/PriceChangerViewController.strings create mode 100644 DUREX tests/en.lproj/PriceChangerViewController_iPad.strings create mode 100644 DUREX tests/es.lproj/PriceChangerViewController.strings create mode 100644 DUREX tests/es.lproj/PriceChangerViewController_iPad.strings diff --git a/DUREX Vendor Control/Base.lproj/DatePickerViewController.xib b/DUREX Vendor Control/Base.lproj/DatePickerViewController.xib new file mode 100644 index 0000000..47a1085 --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/DatePickerViewController.xib @@ -0,0 +1,75 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +VFppZgAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAC5AAAABAAAABCepkign7sVkKCGKqChmveQ +y4kaoNIj9HDSYSYQ1v50INiArZDa/tGg28CQENzes6DdqayQ3r6VoN+JjpDgnneg4WlwkOJ+WaDjSVKQ +5F47oOUpNJDmR1gg5xJREOgnOiDo8jMQ6gccIOrSFRDr5v4g7LH3EO3G4CDukdkQ76/8oPBxuxDxj96g +8n/BkPNvwKD0X6OQ9U+ioPY/hZD3L4Sg+CiiEPkPZqD6CIQQ+viDIPvoZhD82GUg/chIEP64RyD/qCoQ +AJgpIAGIDBACeAsgA3EokARhJ6AFUQqQBkEJoAcw7JAHjUOgCRDOkAmtvyAK8LCQC+CvoAzZzRANwJGg +DrmvEA+priAQmZEQEYmQIBJ5cxATaXIgFFlVEBVJVCAWOTcQFyk2IBgiU5AZCRggGgI1kBryNKAb4heQ +HNIWoB3B+ZAesfigH6HbkCB2KyAhgb2QIlYNICNq2hAkNe8gJUq8ECYV0SAnKp4QJ/7toCkKgBAp3s+g +KupiECu+saAs036QLZ6ToC6zYJAvfnWgMJNCkDFnkiAycySQM0d0IDRTBpA1J1YgNjLokDcHOCA4HAUQ +OOcaIDn75xA6xvwgO9vJEDywGKA9u6sQPo/6oD+bjRBAb9ygQYSpkEJPvqBDZIuQRC+goEVEbZBF89Mg +Ry2KEEfTtSBJDWwQSbOXIErtThBLnLOgTNZqkE18laBOtkyQT1x3oFCWLpBRPFmgUnYQkFMcO6BUVfKQ +VPwdoFY11JBW5TogWB7xEFjFHCBZ/tMQWqT+IFvetRBchOAgXb6XEF5kwiBfnnkQYE3eoGGHlZBiLcCg +Y2d3kGQNoqBlR1mQZe2EoGcnO5BnzWagaQcdkGmtSKBq5v+Qa5ZlIGzQHBBtdkcgbq/+EG9WKSBwj+AQ +cTYLIHJvwhBzFe0gdE+kEHT/CaB2OMCQdt7roHgYopB4vs2gefiEkHqer6B72GaQfH6RoH24SJB+XnOg +f5gqkAABAAECAwEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/Base.lproj/DatePickerViewController_iPad.xib b/DUREX Vendor Control/Base.lproj/DatePickerViewController_iPad.xib new file mode 100644 index 0000000..0d6fb5b --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/DatePickerViewController_iPad.xib @@ -0,0 +1,78 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +VFppZgAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAC5AAAABAAAABCepkign7sVkKCGKqChmveQ +y4kaoNIj9HDSYSYQ1v50INiArZDa/tGg28CQENzes6DdqayQ3r6VoN+JjpDgnneg4WlwkOJ+WaDjSVKQ +5F47oOUpNJDmR1gg5xJREOgnOiDo8jMQ6gccIOrSFRDr5v4g7LH3EO3G4CDukdkQ76/8oPBxuxDxj96g +8n/BkPNvwKD0X6OQ9U+ioPY/hZD3L4Sg+CiiEPkPZqD6CIQQ+viDIPvoZhD82GUg/chIEP64RyD/qCoQ +AJgpIAGIDBACeAsgA3EokARhJ6AFUQqQBkEJoAcw7JAHjUOgCRDOkAmtvyAK8LCQC+CvoAzZzRANwJGg +DrmvEA+priAQmZEQEYmQIBJ5cxATaXIgFFlVEBVJVCAWOTcQFyk2IBgiU5AZCRggGgI1kBryNKAb4heQ +HNIWoB3B+ZAesfigH6HbkCB2KyAhgb2QIlYNICNq2hAkNe8gJUq8ECYV0SAnKp4QJ/7toCkKgBAp3s+g +KupiECu+saAs036QLZ6ToC6zYJAvfnWgMJNCkDFnkiAycySQM0d0IDRTBpA1J1YgNjLokDcHOCA4HAUQ +OOcaIDn75xA6xvwgO9vJEDywGKA9u6sQPo/6oD+bjRBAb9ygQYSpkEJPvqBDZIuQRC+goEVEbZBF89Mg +Ry2KEEfTtSBJDWwQSbOXIErtThBLnLOgTNZqkE18laBOtkyQT1x3oFCWLpBRPFmgUnYQkFMcO6BUVfKQ +VPwdoFY11JBW5TogWB7xEFjFHCBZ/tMQWqT+IFvetRBchOAgXb6XEF5kwiBfnnkQYE3eoGGHlZBiLcCg +Y2d3kGQNoqBlR1mQZe2EoGcnO5BnzWagaQcdkGmtSKBq5v+Qa5ZlIGzQHBBtdkcgbq/+EG9WKSBwj+AQ +cTYLIHJvwhBzFe0gdE+kEHT/CaB2OMCQdt7roHgYopB4vs2gefiEkHqer6B72GaQfH6RoH24SJB+XnOg +f5gqkAABAAECAwEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA +AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/Base.lproj/Localizable.strings b/DUREX Vendor Control/Base.lproj/Localizable.strings index 43ab022..00b7d08 100644 --- a/DUREX Vendor Control/Base.lproj/Localizable.strings +++ b/DUREX Vendor Control/Base.lproj/Localizable.strings @@ -57,4 +57,7 @@ "Nominal Price" = "Nominal Price"; "Discounted Price" = "Discounted Price"; "1€ Change" = "1€ Change"; -"50c Change" = "50c Change"; \ No newline at end of file +"50c Change" = "50c Change"; +"Update Date & Time" = "Update Date & Time"; +"Update product price" = "Update product price"; +"Update product name" = "Update product name"; \ No newline at end of file diff --git a/DUREX Vendor Control/Base.lproj/NameChangerViewController.xib b/DUREX Vendor Control/Base.lproj/NameChangerViewController.xib new file mode 100644 index 0000000..5f67659 --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/NameChangerViewController.xib @@ -0,0 +1,97 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/Base.lproj/NameChangerViewController_iPad.xib b/DUREX Vendor Control/Base.lproj/NameChangerViewController_iPad.xib new file mode 100644 index 0000000..353f356 --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/NameChangerViewController_iPad.xib @@ -0,0 +1,98 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/Base.lproj/PriceChangerViewController.xib b/DUREX Vendor Control/Base.lproj/PriceChangerViewController.xib new file mode 100644 index 0000000..afc0de3 --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/PriceChangerViewController.xib @@ -0,0 +1,97 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/Base.lproj/PriceChangerViewController_iPad.xib b/DUREX Vendor Control/Base.lproj/PriceChangerViewController_iPad.xib new file mode 100644 index 0000000..3e80a25 --- /dev/null +++ b/DUREX Vendor Control/Base.lproj/PriceChangerViewController_iPad.xib @@ -0,0 +1,98 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX Vendor Control/CommunicationProtocol.m b/DUREX Vendor Control/CommunicationProtocol.m index 1fabfac..014bf61 100644 --- a/DUREX Vendor Control/CommunicationProtocol.m +++ b/DUREX Vendor Control/CommunicationProtocol.m @@ -106,11 +106,11 @@ -(NSString*) readMessage { - __block uint8_t numPackets, numBytes; + __block uint8_t numPackets = 1, numBytes; //HACK! __block NSMutableString *message = [[NSMutableString alloc] init]; [message setString:@""]; - if([self waitForMessageAvailableDevice:TRUE]) - //if(1) //HACK! + //if([self waitForMessageAvailableDevice:TRUE]) + if(1) //HACK! { [[EMConnectionManager sharedManager] readResource:@"numPackets" onSuccess:^(id readValue) { @@ -126,8 +126,8 @@ { for(int i = 0; i < numPackets; i++) { - if([self waitForMessageAvailableDevice:TRUE]) - //if(1)//HACK! + //if([self waitForMessageAvailableDevice:TRUE]) + if(1)//HACK! { [[EMConnectionManager sharedManager] readResource:@"numBytes" onSuccess:^(id readValue) { @@ -144,6 +144,7 @@ [[EMConnectionManager sharedManager] readResource:@"data" onSuccess:^(id readValue) { [message appendString: readValue]; + [message setString: [message substringToIndex:numBytes]]; NSLog(@"[CommunicationProtocol.m]: data read: %@",message); } onFail:^(NSError *error) @@ -170,15 +171,6 @@ } } } - [[EMConnectionManager sharedManager] writeValue:@"0" toResource:@"messageAvailableDevice" onSuccess:^ - { - NSLog(@"[CommunicationProtocol.m]: messageAvailableDevice set to FALSE"); - } - onFail:^(NSError *error) - { - NSLog(@"[CommunicationProtocol.m]: %@",error); - } - ]; NSLog(@"[CommunicationProtocol.m]: Message received: %@",message); return message; } @@ -187,8 +179,8 @@ { unsigned long remainingBytes = [message length]; uint8_t numBytes, current_index = 0; - __block Boolean status = FALSE; - __block Boolean blockCompleted = FALSE; + __block Boolean status = TRUE; //HACK + __block Boolean blockCompleted = TRUE; //HACK! [[EMConnectionManager sharedManager] writeValue:@"0" toResource:@"messageAvailableMobile" onSuccess:^ { status = TRUE; diff --git a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.pbxproj b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.pbxproj index bc9f17e..32ecda6 100644 --- a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.pbxproj +++ b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.pbxproj @@ -19,9 +19,15 @@ 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */; }; 34AAB889189804FF0019860D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB880189804FF0019860D /* main.m */; }; 34AAB88D189805300019860D /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 34AAB88C189805300019860D /* Images.xcassets */; }; + F9015D9019B73052006C7882 /* DatePickerViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F9015D9219B73052006C7882 /* DatePickerViewController.xib */; }; + F9015D9719B7305E006C7882 /* DatePickerViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = F9015D9919B7305E006C7882 /* DatePickerViewController_iPad.xib */; }; + F92F567919B75F5E00A1EACA /* PriceChangerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F92F567719B75F5E00A1EACA /* PriceChangerViewController.m */; }; + F92F567D19B7609C00A1EACA /* PriceChangerViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F567F19B7609C00A1EACA /* PriceChangerViewController.xib */; }; + F92F568419B760A800A1EACA /* PriceChangerViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F568619B760A800A1EACA /* PriceChangerViewController_iPad.xib */; }; + F92F569019B763FD00A1EACA /* NameChangerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F92F568E19B763FD00A1EACA /* NameChangerViewController.m */; }; + F92F569219B7665F00A1EACA /* NameChangerViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F569419B7665F00A1EACA /* NameChangerViewController.xib */; }; + F92F569B19B76A5D00A1EACA /* NameChangerViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F569D19B76A5D00A1EACA /* NameChangerViewController_iPad.xib */; }; F933F80419B6819400521B90 /* DatePickerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F933F80219B6819400521B90 /* DatePickerViewController.m */; }; - F933F80519B6819400521B90 /* DatePickerViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F933F80319B6819400521B90 /* DatePickerViewController.xib */; }; - F933F80719B681E000521B90 /* DatePickerViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = F933F80619B681E000521B90 /* DatePickerViewController_iPad.xib */; }; F961D804199A5F1000E9282C /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F961D806199A5F1000E9282C /* MainStoryboard.storyboard */; }; F961D80C199A5F2D00E9282C /* back_arrow.png in Resources */ = {isa = PBXBuildFile; fileRef = F961D80E199A5F2D00E9282C /* back_arrow.png */; }; F961D816199A5FA000E9282C /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = F961D814199A5FA000E9282C /* Localizable.strings */; }; @@ -75,10 +81,30 @@ 34AAB87F189804FF0019860D /* DUREX Vendor Control-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "DUREX Vendor Control-Prefix.pch"; path = "FirstAppExample/DUREX Vendor Control-Prefix.pch"; sourceTree = SOURCE_ROOT; }; 34AAB880189804FF0019860D /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = FirstAppExample/main.m; sourceTree = SOURCE_ROOT; }; 34AAB88C189805300019860D /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = FirstAppExample/Images.xcassets; sourceTree = SOURCE_ROOT; }; + F9015D9119B73052006C7882 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/DatePickerViewController.xib; sourceTree = ""; }; + F9015D9419B73056006C7882 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/DatePickerViewController.strings; sourceTree = ""; }; + F9015D9619B73057006C7882 /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/DatePickerViewController.strings; sourceTree = ""; }; + F9015D9819B7305E006C7882 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/DatePickerViewController_iPad.xib; sourceTree = ""; }; + F9015D9B19B73062006C7882 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/DatePickerViewController_iPad.strings; sourceTree = ""; }; + F9015D9D19B73062006C7882 /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/DatePickerViewController_iPad.strings; sourceTree = ""; }; + F92F567619B75F5E00A1EACA /* PriceChangerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PriceChangerViewController.h; sourceTree = SOURCE_ROOT; }; + F92F567719B75F5E00A1EACA /* PriceChangerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PriceChangerViewController.m; sourceTree = SOURCE_ROOT; }; + F92F567E19B7609C00A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/PriceChangerViewController.xib; sourceTree = ""; }; + F92F568119B760A100A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/PriceChangerViewController.strings; sourceTree = ""; }; + F92F568519B760A800A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/PriceChangerViewController_iPad.xib; sourceTree = ""; }; + F92F568819B760AA00A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/PriceChangerViewController_iPad.strings; sourceTree = ""; }; + F92F568A19B760AB00A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/PriceChangerViewController_iPad.strings; sourceTree = ""; }; + F92F568C19B7616200A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/PriceChangerViewController.strings; sourceTree = ""; }; + F92F568D19B763FD00A1EACA /* NameChangerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NameChangerViewController.h; sourceTree = SOURCE_ROOT; }; + F92F568E19B763FD00A1EACA /* NameChangerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NameChangerViewController.m; sourceTree = SOURCE_ROOT; }; + F92F569319B7665F00A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/NameChangerViewController.xib; sourceTree = ""; }; + F92F569619B7666300A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/NameChangerViewController.strings; sourceTree = ""; }; + F92F569819B7666400A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/NameChangerViewController.strings; sourceTree = ""; }; + F92F569C19B76A5D00A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/NameChangerViewController_iPad.xib; sourceTree = ""; }; + F92F569F19B76A6300A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/NameChangerViewController_iPad.strings; sourceTree = ""; }; + F92F56A119B76A6400A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/NameChangerViewController_iPad.strings; sourceTree = ""; }; F933F80119B6819400521B90 /* DatePickerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DatePickerViewController.h; sourceTree = SOURCE_ROOT; }; F933F80219B6819400521B90 /* DatePickerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DatePickerViewController.m; sourceTree = SOURCE_ROOT; }; - F933F80319B6819400521B90 /* DatePickerViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = DatePickerViewController.xib; sourceTree = SOURCE_ROOT; }; - F933F80619B681E000521B90 /* DatePickerViewController_iPad.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = DatePickerViewController_iPad.xib; sourceTree = SOURCE_ROOT; }; F961D807199A5F1800E9282C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/MainStoryboard.storyboard; sourceTree = ""; }; F961D809199A5F2200E9282C /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/MainStoryboard.strings; sourceTree = ""; }; F961D80B199A5F2300E9282C /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/MainStoryboard.strings; sourceTree = ""; }; @@ -176,8 +202,16 @@ F9A8EF7B192FE201009E7532 /* Stack.m */, F933F80119B6819400521B90 /* DatePickerViewController.h */, F933F80219B6819400521B90 /* DatePickerViewController.m */, - F933F80319B6819400521B90 /* DatePickerViewController.xib */, - F933F80619B681E000521B90 /* DatePickerViewController_iPad.xib */, + F9015D9219B73052006C7882 /* DatePickerViewController.xib */, + F9015D9919B7305E006C7882 /* DatePickerViewController_iPad.xib */, + F92F567619B75F5E00A1EACA /* PriceChangerViewController.h */, + F92F567719B75F5E00A1EACA /* PriceChangerViewController.m */, + F92F567F19B7609C00A1EACA /* PriceChangerViewController.xib */, + F92F568619B760A800A1EACA /* PriceChangerViewController_iPad.xib */, + F92F568D19B763FD00A1EACA /* NameChangerViewController.h */, + F92F568E19B763FD00A1EACA /* NameChangerViewController.m */, + F92F569419B7665F00A1EACA /* NameChangerViewController.xib */, + F92F569D19B76A5D00A1EACA /* NameChangerViewController_iPad.xib */, 34AAB88C189805300019860D /* Images.xcassets */, 347186B91807290E00FA0FB2 /* Schemas */, 347186A718070F7F00FA0FB2 /* Device Picker */, @@ -327,14 +361,18 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( - F933F80519B6819400521B90 /* DatePickerViewController.xib in Resources */, + F9015D9019B73052006C7882 /* DatePickerViewController.xib in Resources */, F98356D8192E906600EA6821 /* bluetooth.png in Resources */, - F933F80719B681E000521B90 /* DatePickerViewController_iPad.xib in Resources */, + F9015D9719B7305E006C7882 /* DatePickerViewController_iPad.xib in Resources */, F961D819199A711300E9282C /* EMConnectingView.xib in Resources */, F9C77F50192CDE30002DBE8A /* system.json in Resources */, + F92F569B19B76A5D00A1EACA /* NameChangerViewController_iPad.xib in Resources */, + F92F567D19B7609C00A1EACA /* PriceChangerViewController.xib in Resources */, + F92F569219B7665F00A1EACA /* NameChangerViewController.xib in Resources */, F961D80C199A5F2D00E9282C /* back_arrow.png in Resources */, F961D816199A5FA000E9282C /* Localizable.strings in Resources */, 34AAB88D189805300019860D /* Images.xcassets in Resources */, + F92F568419B760A800A1EACA /* PriceChangerViewController_iPad.xib in Resources */, F961D804199A5F1000E9282C /* MainStoryboard.storyboard in Resources */, ); runOnlyForDeploymentPostprocessing = 0; @@ -353,10 +391,12 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( + F92F569019B763FD00A1EACA /* NameChangerViewController.m in Sources */, F933F80419B6819400521B90 /* DatePickerViewController.m in Sources */, F98356D6192E835F00EA6821 /* InitialViewController.m in Sources */, F9A8EF7C192FE201009E7532 /* Stack.m in Sources */, 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */, + F92F567919B75F5E00A1EACA /* PriceChangerViewController.m in Sources */, 34AAB883189804FF0019860D /* DUREXAppDelegate.m in Sources */, F98356DB192EAFD400EA6821 /* CommunicationProtocol.m in Sources */, F98356E1192EC84700EA6821 /* MenuTableViewController.m in Sources */, @@ -382,6 +422,66 @@ /* End PBXTargetDependency section */ /* Begin PBXVariantGroup section */ + F9015D9219B73052006C7882 /* DatePickerViewController.xib */ = { + isa = PBXVariantGroup; + children = ( + F9015D9119B73052006C7882 /* Base */, + F9015D9419B73056006C7882 /* en */, + F9015D9619B73057006C7882 /* es */, + ); + name = DatePickerViewController.xib; + sourceTree = SOURCE_ROOT; + }; + F9015D9919B7305E006C7882 /* DatePickerViewController_iPad.xib */ = { + isa = PBXVariantGroup; + children = ( + F9015D9819B7305E006C7882 /* Base */, + F9015D9B19B73062006C7882 /* en */, + F9015D9D19B73062006C7882 /* es */, + ); + name = DatePickerViewController_iPad.xib; + sourceTree = SOURCE_ROOT; + }; + F92F567F19B7609C00A1EACA /* PriceChangerViewController.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F567E19B7609C00A1EACA /* Base */, + F92F568119B760A100A1EACA /* en */, + F92F568C19B7616200A1EACA /* es */, + ); + name = PriceChangerViewController.xib; + sourceTree = SOURCE_ROOT; + }; + F92F568619B760A800A1EACA /* PriceChangerViewController_iPad.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F568519B760A800A1EACA /* Base */, + F92F568819B760AA00A1EACA /* en */, + F92F568A19B760AB00A1EACA /* es */, + ); + name = PriceChangerViewController_iPad.xib; + sourceTree = SOURCE_ROOT; + }; + F92F569419B7665F00A1EACA /* NameChangerViewController.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F569319B7665F00A1EACA /* Base */, + F92F569619B7666300A1EACA /* en */, + F92F569819B7666400A1EACA /* es */, + ); + name = NameChangerViewController.xib; + sourceTree = SOURCE_ROOT; + }; + F92F569D19B76A5D00A1EACA /* NameChangerViewController_iPad.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F569C19B76A5D00A1EACA /* Base */, + F92F569F19B76A6300A1EACA /* en */, + F92F56A119B76A6400A1EACA /* es */, + ); + name = NameChangerViewController_iPad.xib; + sourceTree = SOURCE_ROOT; + }; F961D806199A5F1000E9282C /* MainStoryboard.storyboard */ = { isa = PBXVariantGroup; children = ( diff --git a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate index de5c75e..b1efc66 100644 Binary files a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate and b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist index 4ccceb2..966b7bc 100644 --- a/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist +++ b/DUREX Vendor Control/DUREX Vendor Control.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -10,7 +10,7 @@ ignoreCount = "0" continueAfterRunningActions = "No" filePath = "CommunicationProtocol.m" - timestampString = "431391382.511911" + timestampString = "431435824.615796" startingColumnNumber = "9223372036854775807" endingColumnNumber = "9223372036854775807" startingLineNumber = "109" @@ -22,16 +22,16 @@ @@ -45,8 +45,8 @@ timestampString = "431391382.511911" startingColumnNumber = "9223372036854775807" endingColumnNumber = "9223372036854775807" - startingLineNumber = "100" - endingLineNumber = "100" + startingLineNumber = "104" + endingLineNumber = "104" landmarkName = "-waitForMessageAvailableDevice:" landmarkType = "5"> @@ -57,13 +57,29 @@ shouldBeEnabled = "No" ignoreCount = "0" continueAfterRunningActions = "No" - filePath = "CommunicationProtocol.m" - timestampString = "431391382.511911" + filePath = "MenuTableViewController.m" + timestampString = "431435390.453053" startingColumnNumber = "9223372036854775807" endingColumnNumber = "9223372036854775807" - startingLineNumber = "104" - endingLineNumber = "104" - landmarkName = "-waitForMessageAvailableDevice:" + startingLineNumber = "204" + endingLineNumber = "204" + landmarkName = "-viewDidLoad" + landmarkType = "5"> + + + + diff --git a/DUREX Vendor Control/DatePickerViewController.h b/DUREX Vendor Control/DatePickerViewController.h index 53a5e7f..903dc56 100644 --- a/DUREX Vendor Control/DatePickerViewController.h +++ b/DUREX Vendor Control/DatePickerViewController.h @@ -13,7 +13,7 @@ #import "DUREXAppDelegate.h" @protocol DatePickerViewControllerDelegate -- (void)addItemViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date; +- (void)passDateViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date; @end diff --git a/DUREX Vendor Control/DatePickerViewController.m b/DUREX Vendor Control/DatePickerViewController.m index fb33999..929acb6 100644 --- a/DUREX Vendor Control/DatePickerViewController.m +++ b/DUREX Vendor Control/DatePickerViewController.m @@ -63,7 +63,7 @@ - (IBAction)closePopup:(id)sender { - [self.delegate addItemViewController:self didFinishEnteringItem:[[self datePicker] date]]; + [self.delegate passDateViewController:self didFinishEnteringItem:[[self datePicker] date]]; [self removeAnimate]; } diff --git a/DUREX Vendor Control/DatePickerViewController.xib b/DUREX Vendor Control/DatePickerViewController.xib deleted file mode 100644 index d4fa1c2..0000000 --- a/DUREX Vendor Control/DatePickerViewController.xib +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -VFppZgAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAC5AAAABAAAABCepkign7sVkKCGKqChmveQ -y4kaoNIj9HDSYSYQ1v50INiArZDa/tGg28CQENzes6DdqayQ3r6VoN+JjpDgnneg4WlwkOJ+WaDjSVKQ -5F47oOUpNJDmR1gg5xJREOgnOiDo8jMQ6gccIOrSFRDr5v4g7LH3EO3G4CDukdkQ76/8oPBxuxDxj96g -8n/BkPNvwKD0X6OQ9U+ioPY/hZD3L4Sg+CiiEPkPZqD6CIQQ+viDIPvoZhD82GUg/chIEP64RyD/qCoQ -AJgpIAGIDBACeAsgA3EokARhJ6AFUQqQBkEJoAcw7JAHjUOgCRDOkAmtvyAK8LCQC+CvoAzZzRANwJGg -DrmvEA+priAQmZEQEYmQIBJ5cxATaXIgFFlVEBVJVCAWOTcQFyk2IBgiU5AZCRggGgI1kBryNKAb4heQ -HNIWoB3B+ZAesfigH6HbkCB2KyAhgb2QIlYNICNq2hAkNe8gJUq8ECYV0SAnKp4QJ/7toCkKgBAp3s+g -KupiECu+saAs036QLZ6ToC6zYJAvfnWgMJNCkDFnkiAycySQM0d0IDRTBpA1J1YgNjLokDcHOCA4HAUQ -OOcaIDn75xA6xvwgO9vJEDywGKA9u6sQPo/6oD+bjRBAb9ygQYSpkEJPvqBDZIuQRC+goEVEbZBF89Mg -Ry2KEEfTtSBJDWwQSbOXIErtThBLnLOgTNZqkE18laBOtkyQT1x3oFCWLpBRPFmgUnYQkFMcO6BUVfKQ -VPwdoFY11JBW5TogWB7xEFjFHCBZ/tMQWqT+IFvetRBchOAgXb6XEF5kwiBfnnkQYE3eoGGHlZBiLcCg -Y2d3kGQNoqBlR1mQZe2EoGcnO5BnzWagaQcdkGmtSKBq5v+Qa5ZlIGzQHBBtdkcgbq/+EG9WKSBwj+AQ -cTYLIHJvwhBzFe0gdE+kEHT/CaB2OMCQdt7roHgYopB4vs2gefiEkHqer6B72GaQfH6RoH24SJB+XnOg -f5gqkAABAAECAwEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA - - - - - - - - - - - - - - - - - - diff --git a/DUREX Vendor Control/DatePickerViewController_iPad.xib b/DUREX Vendor Control/DatePickerViewController_iPad.xib deleted file mode 100644 index 74375da..0000000 --- a/DUREX Vendor Control/DatePickerViewController_iPad.xib +++ /dev/null @@ -1,74 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -VFppZgAAAAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAAAAAC5AAAABAAAABCepkign7sVkKCGKqChmveQ -y4kaoNIj9HDSYSYQ1v50INiArZDa/tGg28CQENzes6DdqayQ3r6VoN+JjpDgnneg4WlwkOJ+WaDjSVKQ -5F47oOUpNJDmR1gg5xJREOgnOiDo8jMQ6gccIOrSFRDr5v4g7LH3EO3G4CDukdkQ76/8oPBxuxDxj96g -8n/BkPNvwKD0X6OQ9U+ioPY/hZD3L4Sg+CiiEPkPZqD6CIQQ+viDIPvoZhD82GUg/chIEP64RyD/qCoQ -AJgpIAGIDBACeAsgA3EokARhJ6AFUQqQBkEJoAcw7JAHjUOgCRDOkAmtvyAK8LCQC+CvoAzZzRANwJGg -DrmvEA+priAQmZEQEYmQIBJ5cxATaXIgFFlVEBVJVCAWOTcQFyk2IBgiU5AZCRggGgI1kBryNKAb4heQ -HNIWoB3B+ZAesfigH6HbkCB2KyAhgb2QIlYNICNq2hAkNe8gJUq8ECYV0SAnKp4QJ/7toCkKgBAp3s+g -KupiECu+saAs036QLZ6ToC6zYJAvfnWgMJNCkDFnkiAycySQM0d0IDRTBpA1J1YgNjLokDcHOCA4HAUQ -OOcaIDn75xA6xvwgO9vJEDywGKA9u6sQPo/6oD+bjRBAb9ygQYSpkEJPvqBDZIuQRC+goEVEbZBF89Mg -Ry2KEEfTtSBJDWwQSbOXIErtThBLnLOgTNZqkE18laBOtkyQT1x3oFCWLpBRPFmgUnYQkFMcO6BUVfKQ -VPwdoFY11JBW5TogWB7xEFjFHCBZ/tMQWqT+IFvetRBchOAgXb6XEF5kwiBfnnkQYE3eoGGHlZBiLcCg -Y2d3kGQNoqBlR1mQZe2EoGcnO5BnzWagaQcdkGmtSKBq5v+Qa5ZlIGzQHBBtdkcgbq/+EG9WKSBwj+AQ -cTYLIHJvwhBzFe0gdE+kEHT/CaB2OMCQdt7roHgYopB4vs2gefiEkHqer6B72GaQfH6RoH24SJB+XnOg -f5gqkAABAAECAwEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEA -AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA - - - - - - - - - - - - - - - - - - - - - diff --git a/DUREX Vendor Control/MenuTableViewController.h b/DUREX Vendor Control/MenuTableViewController.h index 8b3c209..c2bd8fc 100644 --- a/DUREX Vendor Control/MenuTableViewController.h +++ b/DUREX Vendor Control/MenuTableViewController.h @@ -11,6 +11,8 @@ #import "CommunicationProtocol.h" #import "Stack.h" #import "DatePickerViewController.h" +#import "PriceChangerViewController.h" +#import "NameChangerViewController.h" #define num(x) [NSNumber numberWithUnsignedInt:x] @@ -40,10 +42,12 @@ enum { REPORT, } navigationLevel; -@interface MenuTableViewController : UITableViewController +@interface MenuTableViewController : UITableViewController @property (strong,nonatomic) Stack *parentLayout; -@property (strong,nonatomic) DatePickerViewController *popupViewController; +@property (strong,nonatomic) DatePickerViewController *datePickerViewController; +@property (strong,nonatomic) PriceChangerViewController *priceChangerViewController; +@property (strong,nonatomic) NameChangerViewController *nameChangerViewController; - (void) navBack; diff --git a/DUREX Vendor Control/MenuTableViewController.m b/DUREX Vendor Control/MenuTableViewController.m index 410c029..56d0611 100644 --- a/DUREX Vendor Control/MenuTableViewController.m +++ b/DUREX Vendor Control/MenuTableViewController.m @@ -265,7 +265,7 @@ if([cellName isEqualToString:NSLocalizedString(@"Maintenance", nil)] && [self currentNavLevel] == MENU) { NSLog(@"[MenuTableViewController.m]: Changing to navLevel: MAINTENANCE"); - + [_protocol updateProductName:7 :2 :@"Producte #987654321"]; [self changeNavLevel:MAINTENANCE:TRUE]; } else if([cellName isEqualToString:NSLocalizedString(@"Sales log", nil)] && [self currentNavLevel] == MAINTENANCE) @@ -283,15 +283,48 @@ { if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) { - self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; - self.popupViewController.delegate = self; - [self.popupViewController showInView:self.navigationController.view animated:YES]; + //self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.datePickerViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.datePickerViewController.delegate = self; + [self.datePickerViewController showInView:self.navigationController.view animated:YES]; + } + else + { + self.datePickerViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController" bundle:nil]; + self.datePickerViewController.delegate = self; + [self.datePickerViewController showInView:self.navigationController.view animated:YES]; + } + } + else if([cellName isEqualToString:NSLocalizedString(@"Update product price", nil)] && [self currentNavLevel] == BASIC_CONFIGURATION) + { + if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) + { + //self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.priceChangerViewController = [[PriceChangerViewController alloc] initWithNibName:@"PriceChangerViewController_iPad" bundle:nil]; + self.priceChangerViewController.delegate = self; + [self.priceChangerViewController showInView:self.navigationController.view animated:YES]; } else { - self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController" bundle:nil]; - self.popupViewController.delegate = self; - [self.popupViewController showInView:self.navigationController.view animated:YES]; + self.priceChangerViewController = [[PriceChangerViewController alloc] initWithNibName:@"PriceChangerViewController" bundle:nil]; + self.priceChangerViewController.delegate = self; + [self.priceChangerViewController showInView:self.navigationController.view animated:YES]; + } + } + else if([cellName isEqualToString:NSLocalizedString(@"Update product name", nil)] && [self currentNavLevel] == BASIC_CONFIGURATION) + { + if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) + { + //self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.nameChangerViewController = [[NameChangerViewController alloc] initWithNibName:@"NameChangerViewController_iPad" bundle:nil]; + self.nameChangerViewController.delegate = self; + [self.nameChangerViewController showInView:self.navigationController.view animated:YES]; + } + else + { + self.nameChangerViewController = [[NameChangerViewController alloc] initWithNibName:@"NameChangerViewController" bundle:nil]; + self.nameChangerViewController.delegate = self; + [self.nameChangerViewController showInView:self.navigationController.view animated:YES]; } } } @@ -360,7 +393,7 @@ return cell; } -- (void)addItemViewController:(DatePickerViewController *)controller didFinishEnteringItem:(NSDate *)date +- (void)passDateViewController:(DatePickerViewController *)controller didFinishEnteringItem:(NSDate *)date { NSCalendar *calendar = [[NSCalendar alloc] initWithCalendarIdentifier:NSGregorianCalendar]; NSCalendarUnit units = NSYearCalendarUnit | NSMonthCalendarUnit | NSDayCalendarUnit | NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit; @@ -369,6 +402,26 @@ [_protocol updateTime: components]; } +- (void)passPriceViewController:(PriceChangerViewController *)controller didFinishEnteringItem:(NSArray *)data +{ + NSLog(@"[MenuTableViewController.m]: %@", data); + //Channel,Code,Price + int channel = [[data objectAtIndex:0] intValue]; + int code = [[data objectAtIndex:1] intValue]; + NSArray *price = [[data objectAtIndex:2] componentsSeparatedByString:@","]; + [_protocol updatePrice:channel :code :[[price objectAtIndex:0] intValue] :[[price objectAtIndex:1] intValue]]; +} + +- (void)passNameViewController:(PriceChangerViewController *)controller didFinishEnteringItem:(NSArray *)data +{ + NSLog(@"[MenuTableViewController.m]: %@", data); + //Channel,Code,Name + int channel = [[data objectAtIndex:0] intValue]; + int code = [[data objectAtIndex:1] intValue]; + NSString *name = [data objectAtIndex:2]; + [_protocol updateProductName:channel :code :name]; +} + /* // Override to support conditional editing of the table view. diff --git a/DUREX Vendor Control/NameChangerViewController.h b/DUREX Vendor Control/NameChangerViewController.h new file mode 100644 index 0000000..0304fd6 --- /dev/null +++ b/DUREX Vendor Control/NameChangerViewController.h @@ -0,0 +1,33 @@ +// +// NameChangerViewController.h +// DUREX Vendor Control +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +@class NameChangerViewController; + +#import +#import +#import "DUREXAppDelegate.h" + +@protocol NameChangerViewControllerDelegate +- (void)passNameViewController:(NameChangerViewController*)controller didFinishEnteringItem:(NSArray *)data; + +@end + + +@interface NameChangerViewController : UIViewController + +@property (strong, nonatomic) IBOutlet UIView *nameChangerView; +@property (strong, nonatomic) IBOutlet UITextField *name; +@property (strong, nonatomic) IBOutlet UITextField *channel; +@property (strong, nonatomic) IBOutlet UITextField *code; +@property (nonatomic, strong) id delegate; + +- (void)showInView:(UIView *)aView animated:(BOOL)animated; +- (IBAction)closePopup:(id)sender; + + +@end \ No newline at end of file diff --git a/DUREX Vendor Control/NameChangerViewController.m b/DUREX Vendor Control/NameChangerViewController.m new file mode 100644 index 0000000..993b8a7 --- /dev/null +++ b/DUREX Vendor Control/NameChangerViewController.m @@ -0,0 +1,102 @@ +// +// NameChangerViewController.m +// DUREX Vendor Control +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +#import "NameChangerViewController.h" + +@interface NameChangerViewController () + +@end + +@implementation NameChangerViewController + +- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +{ + self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + if (self) { + // Custom initialization + } + return self; +} + +- (void)viewDidLoad +{ + self.nameChangerView.layer.cornerRadius = 5; + self.nameChangerView.layer.shadowOpacity = 0.8; + self.nameChangerView.layer.shadowOffset = CGSizeMake(0.0f, 0.0f); + + self.code.delegate = self; + self.channel.delegate = self; + self.name.delegate = self; + + UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] + initWithTarget:self + action:@selector(dismissKeyboard)]; + + [self.view addGestureRecognizer:tap]; + + [super viewDidLoad]; + // Do any additional setup after loading the view from its nib. +} + +-(void)dismissKeyboard +{ + [self.code resignFirstResponder]; + [self.name resignFirstResponder]; + [self.channel resignFirstResponder]; +} + +-(BOOL)textFieldShouldReturn:(UITextField *)textField +{ + [textField resignFirstResponder]; + return YES; +} + +- (void)didReceiveMemoryWarning +{ + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +- (void)showAnimate +{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0; + [UIView animateWithDuration:.25 animations:^{ + self.view.alpha = 1; + self.view.transform = CGAffineTransformMakeScale(1, 1); + }]; +} + +- (void)removeAnimate +{ + [UIView animateWithDuration:.25 animations:^{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0.0; + } completion:^(BOOL finished) { + if (finished) { + [self.view removeFromSuperview]; + } + }]; +} + +- (IBAction)closePopup:(id)sender +{ + NSArray *data = [[NSArray alloc] initWithObjects:[[self channel] text],[[self code] text],[[self name] text], nil]; + [self.delegate passNameViewController:self didFinishEnteringItem:data]; + [self removeAnimate]; +} + +- (void)showInView:(UIView *)aView animated:(BOOL)animated +{ + [aView addSubview:self.view]; + if (animated) { + [self showAnimate]; + } +} + +@end diff --git a/DUREX Vendor Control/PriceChangerViewController.h b/DUREX Vendor Control/PriceChangerViewController.h new file mode 100644 index 0000000..f60a149 --- /dev/null +++ b/DUREX Vendor Control/PriceChangerViewController.h @@ -0,0 +1,33 @@ +// +// PriceChangerViewController.h +// DUREX Vendor Control +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +@class PriceChangerViewController; + +#import +#import +#import "DUREXAppDelegate.h" + +@protocol PriceChangerViewControllerDelegate +- (void)passPriceViewController:(PriceChangerViewController*)controller didFinishEnteringItem:(NSArray *)data; + +@end + + +@interface PriceChangerViewController : UIViewController + +@property (strong, nonatomic) IBOutlet UIView *priceChangerView; +@property (strong, nonatomic) IBOutlet UITextField *price; +@property (strong, nonatomic) IBOutlet UITextField *channel; +@property (strong, nonatomic) IBOutlet UITextField *code; +@property (nonatomic, strong) id delegate; + +- (void)showInView:(UIView *)aView animated:(BOOL)animated; +- (IBAction)closePopup:(id)sender; + + +@end diff --git a/DUREX Vendor Control/PriceChangerViewController.m b/DUREX Vendor Control/PriceChangerViewController.m new file mode 100644 index 0000000..9282561 --- /dev/null +++ b/DUREX Vendor Control/PriceChangerViewController.m @@ -0,0 +1,103 @@ +// +// PriceChangerViewController.m +// DUREX Vendor Control +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +#import "PriceChangerViewController.h" + +@interface PriceChangerViewController () + +@end + +@implementation PriceChangerViewController + +- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +{ + self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + if (self) { + // Custom initialization + } + return self; +} + +- (void)viewDidLoad +{ + self.priceChangerView.layer.cornerRadius = 5; + self.priceChangerView.layer.shadowOpacity = 0.8; + self.priceChangerView.layer.shadowOffset = CGSizeMake(0.0f, 0.0f); + + self.code.delegate = self; + self.channel.delegate = self; + self.price.delegate = self; + + UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] + initWithTarget:self + action:@selector(dismissKeyboard)]; + + [self.view addGestureRecognizer:tap]; + + [super viewDidLoad]; + // Do any additional setup after loading the view from its nib. +} + +-(void)dismissKeyboard +{ + [self.code resignFirstResponder]; + [self.price resignFirstResponder]; + [self.channel resignFirstResponder]; +} + +-(BOOL)textFieldShouldReturn:(UITextField *)textField +{ + [textField resignFirstResponder]; + return YES; +} + +- (void)didReceiveMemoryWarning +{ + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +- (void)showAnimate +{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0; + [UIView animateWithDuration:.25 animations:^{ + self.view.alpha = 1; + self.view.transform = CGAffineTransformMakeScale(1, 1); + }]; +} + +- (void)removeAnimate +{ + [UIView animateWithDuration:.25 animations:^{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0.0; + } completion:^(BOOL finished) { + if (finished) { + [self.view removeFromSuperview]; + } + }]; +} + +- (IBAction)closePopup:(id)sender +{ + NSArray *data = [[NSArray alloc] initWithObjects:[[self channel] text],[[self code] text],[[self price] text], nil]; + [self.delegate passPriceViewController:self didFinishEnteringItem:data]; + [self removeAnimate]; +} + +- (void)showInView:(UIView *)aView animated:(BOOL)animated +{ + [aView addSubview:self.view]; + if (animated) { + [self showAnimate]; + } +} + + +@end diff --git a/DUREX Vendor Control/en.lproj/DatePickerViewController.strings b/DUREX Vendor Control/en.lproj/DatePickerViewController.strings new file mode 100644 index 0000000..1b5338e --- /dev/null +++ b/DUREX Vendor Control/en.lproj/DatePickerViewController.strings @@ -0,0 +1,3 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "8vW-ig-tUA"; */ +"8vW-ig-tUA.normalTitle" = "Done"; diff --git a/DUREX Vendor Control/en.lproj/DatePickerViewController_iPad.strings b/DUREX Vendor Control/en.lproj/DatePickerViewController_iPad.strings new file mode 100644 index 0000000..78dd0bc --- /dev/null +++ b/DUREX Vendor Control/en.lproj/DatePickerViewController_iPad.strings @@ -0,0 +1,3 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "RGE-Ye-qon"; */ +"RGE-Ye-qon.normalTitle" = "Done"; diff --git a/DUREX Vendor Control/en.lproj/Localizable.strings b/DUREX Vendor Control/en.lproj/Localizable.strings index 43ab022..00b7d08 100644 --- a/DUREX Vendor Control/en.lproj/Localizable.strings +++ b/DUREX Vendor Control/en.lproj/Localizable.strings @@ -57,4 +57,7 @@ "Nominal Price" = "Nominal Price"; "Discounted Price" = "Discounted Price"; "1€ Change" = "1€ Change"; -"50c Change" = "50c Change"; \ No newline at end of file +"50c Change" = "50c Change"; +"Update Date & Time" = "Update Date & Time"; +"Update product price" = "Update product price"; +"Update product name" = "Update product name"; \ No newline at end of file diff --git a/DUREX Vendor Control/en.lproj/NameChangerViewController.strings b/DUREX Vendor Control/en.lproj/NameChangerViewController.strings new file mode 100644 index 0000000..1b12c50 --- /dev/null +++ b/DUREX Vendor Control/en.lproj/NameChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "Y9f-BL-5ZB"; */ +"Y9f-BL-5ZB.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "New Name"; ObjectID = "Zfh-RB-roO"; */ +"Zfh-RB-roO.text" = "New Name"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "u0t-Gj-gKZ"; */ +"u0t-Gj-gKZ.text" = "Channel"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "zk3-Qc-MYf"; */ +"zk3-Qc-MYf.text" = "Product Code"; diff --git a/DUREX Vendor Control/en.lproj/NameChangerViewController_iPad.strings b/DUREX Vendor Control/en.lproj/NameChangerViewController_iPad.strings new file mode 100644 index 0000000..58829f0 --- /dev/null +++ b/DUREX Vendor Control/en.lproj/NameChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "9PW-xp-3t9"; */ +"9PW-xp-3t9.text" = "Channel"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "Md5-1l-LqY"; */ +"Md5-1l-LqY.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "RCD-6Z-45A"; */ +"RCD-6Z-45A.text" = "Product Code"; + +/* Class = "IBUILabel"; text = "New Name"; ObjectID = "pLv-EG-y2m"; */ +"pLv-EG-y2m.text" = "New Name"; diff --git a/DUREX Vendor Control/en.lproj/PriceChangerViewController.strings b/DUREX Vendor Control/en.lproj/PriceChangerViewController.strings new file mode 100644 index 0000000..58d4466 --- /dev/null +++ b/DUREX Vendor Control/en.lproj/PriceChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "2cF-of-r57"; */ +"2cF-of-r57.text" = "Product Code"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "Cbx-ha-NZx"; */ +"Cbx-ha-NZx.text" = "New Price"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "VCq-As-NrV"; */ +"VCq-As-NrV.text" = "Channel"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "slH-Zj-pps"; */ +"slH-Zj-pps.normalTitle" = "Done"; diff --git a/DUREX Vendor Control/en.lproj/PriceChangerViewController_iPad.strings b/DUREX Vendor Control/en.lproj/PriceChangerViewController_iPad.strings new file mode 100644 index 0000000..17d58f3 --- /dev/null +++ b/DUREX Vendor Control/en.lproj/PriceChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "6M6-Rz-v0B"; */ +"6M6-Rz-v0B.text" = "Channel"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "BsH-aP-YXx"; */ +"BsH-aP-YXx.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "CRj-D6-8bV"; */ +"CRj-D6-8bV.text" = "New Price"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "y0J-fk-3XQ"; */ +"y0J-fk-3XQ.text" = "Product Code"; diff --git a/DUREX Vendor Control/es.lproj/DatePickerViewController.strings b/DUREX Vendor Control/es.lproj/DatePickerViewController.strings new file mode 100644 index 0000000..20456e3 --- /dev/null +++ b/DUREX Vendor Control/es.lproj/DatePickerViewController.strings @@ -0,0 +1,3 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "8vW-ig-tUA"; */ +"8vW-ig-tUA.normalTitle" = "Aceptar"; diff --git a/DUREX Vendor Control/es.lproj/DatePickerViewController_iPad.strings b/DUREX Vendor Control/es.lproj/DatePickerViewController_iPad.strings new file mode 100644 index 0000000..ed4f79a --- /dev/null +++ b/DUREX Vendor Control/es.lproj/DatePickerViewController_iPad.strings @@ -0,0 +1,3 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "RGE-Ye-qon"; */ +"RGE-Ye-qon.normalTitle" = "Aceptar"; diff --git a/DUREX Vendor Control/es.lproj/Localizable.strings b/DUREX Vendor Control/es.lproj/Localizable.strings index 3987546..18a3250 100644 --- a/DUREX Vendor Control/es.lproj/Localizable.strings +++ b/DUREX Vendor Control/es.lproj/Localizable.strings @@ -57,4 +57,7 @@ "Nominal Price" = "Precio Nominal"; "Discounted Price" = "Precio con descuento"; "1€ Change" = "Cambio de 1€"; -"50c Change" = "Cambio de 50c"; \ No newline at end of file +"50c Change" = "Cambio de 50c"; +"Update Date & Time" = "Actualizar fecha y hora"; +"Update product price" = "Actualizar precio del producto"; +"Update product name" = "Actualizar nombre del producto"; \ No newline at end of file diff --git a/DUREX Vendor Control/es.lproj/NameChangerViewController.strings b/DUREX Vendor Control/es.lproj/NameChangerViewController.strings new file mode 100644 index 0000000..1b12c50 --- /dev/null +++ b/DUREX Vendor Control/es.lproj/NameChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "Y9f-BL-5ZB"; */ +"Y9f-BL-5ZB.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "New Name"; ObjectID = "Zfh-RB-roO"; */ +"Zfh-RB-roO.text" = "New Name"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "u0t-Gj-gKZ"; */ +"u0t-Gj-gKZ.text" = "Channel"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "zk3-Qc-MYf"; */ +"zk3-Qc-MYf.text" = "Product Code"; diff --git a/DUREX Vendor Control/es.lproj/NameChangerViewController_iPad.strings b/DUREX Vendor Control/es.lproj/NameChangerViewController_iPad.strings new file mode 100644 index 0000000..4c55a0e --- /dev/null +++ b/DUREX Vendor Control/es.lproj/NameChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "9PW-xp-3t9"; */ +"9PW-xp-3t9.text" = "Canal"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "Md5-1l-LqY"; */ +"Md5-1l-LqY.normalTitle" = "Aceptar"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "RCD-6Z-45A"; */ +"RCD-6Z-45A.text" = "Código del Producto"; + +/* Class = "IBUILabel"; text = "New Name"; ObjectID = "pLv-EG-y2m"; */ +"pLv-EG-y2m.text" = "Nuevo Nombre"; diff --git a/DUREX Vendor Control/es.lproj/PriceChangerViewController.strings b/DUREX Vendor Control/es.lproj/PriceChangerViewController.strings new file mode 100644 index 0000000..a6d4a99 --- /dev/null +++ b/DUREX Vendor Control/es.lproj/PriceChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "2cF-of-r57"; */ +"2cF-of-r57.text" = "Código del Producto"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "Cbx-ha-NZx"; */ +"Cbx-ha-NZx.text" = "Nuevo Precio"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "VCq-As-NrV"; */ +"VCq-As-NrV.text" = "Canal"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "slH-Zj-pps"; */ +"slH-Zj-pps.normalTitle" = "Aceptar"; diff --git a/DUREX Vendor Control/es.lproj/PriceChangerViewController_iPad.strings b/DUREX Vendor Control/es.lproj/PriceChangerViewController_iPad.strings new file mode 100644 index 0000000..4542d61 --- /dev/null +++ b/DUREX Vendor Control/es.lproj/PriceChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "6M6-Rz-v0B"; */ +"6M6-Rz-v0B.text" = "Canal"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "BsH-aP-YXx"; */ +"BsH-aP-YXx.normalTitle" = "Aceptar"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "CRj-D6-8bV"; */ +"CRj-D6-8bV.text" = "Nuevo Precio"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "y0J-fk-3XQ"; */ +"y0J-fk-3XQ.text" = "Código del Producto"; diff --git a/DUREX tests/Base.lproj/DatePickerViewController.xib b/DUREX tests/Base.lproj/DatePickerViewController.xib index c3d860c..dbbdbb4 100644 --- a/DUREX tests/Base.lproj/DatePickerViewController.xib +++ b/DUREX tests/Base.lproj/DatePickerViewController.xib @@ -1,5 +1,5 @@ - + @@ -66,7 +66,7 @@ AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA - + diff --git a/DUREX tests/Base.lproj/DatePickerViewController_iPad.xib b/DUREX tests/Base.lproj/DatePickerViewController_iPad.xib index 74c0762..b72f739 100644 --- a/DUREX tests/Base.lproj/DatePickerViewController_iPad.xib +++ b/DUREX tests/Base.lproj/DatePickerViewController_iPad.xib @@ -1,5 +1,5 @@ - + @@ -66,7 +66,7 @@ AQABAAEAAQAB//+dkAEA//+PgAAE//+dkAEI//+dkAEMUERUAFBTVABQV1QAUFBUAAAAAAEAAAABA - + diff --git a/DUREX tests/Base.lproj/MainStoryboard.storyboard b/DUREX tests/Base.lproj/MainStoryboard.storyboard index 9f0a6e4..bb41308 100644 --- a/DUREX tests/Base.lproj/MainStoryboard.storyboard +++ b/DUREX tests/Base.lproj/MainStoryboard.storyboard @@ -1,5 +1,5 @@ - + diff --git a/DUREX tests/Base.lproj/PriceChangerViewController.xib b/DUREX tests/Base.lproj/PriceChangerViewController.xib new file mode 100644 index 0000000..fbb1779 --- /dev/null +++ b/DUREX tests/Base.lproj/PriceChangerViewController.xib @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX tests/Base.lproj/PriceChangerViewController_iPad.xib b/DUREX tests/Base.lproj/PriceChangerViewController_iPad.xib new file mode 100644 index 0000000..f637e47 --- /dev/null +++ b/DUREX tests/Base.lproj/PriceChangerViewController_iPad.xib @@ -0,0 +1,97 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DUREX tests/DUREX test.xcodeproj/project.pbxproj b/DUREX tests/DUREX test.xcodeproj/project.pbxproj index 717a4ca..fccda79 100644 --- a/DUREX tests/DUREX test.xcodeproj/project.pbxproj +++ b/DUREX tests/DUREX test.xcodeproj/project.pbxproj @@ -18,7 +18,10 @@ 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB87A189804FF0019860D /* EMDevicePickerViewController.m */; }; 34AAB889189804FF0019860D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 34AAB880189804FF0019860D /* main.m */; }; 34AAB88D189805300019860D /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 34AAB88C189805300019860D /* Images.xcassets */; }; + F9015DA119B731B4006C7882 /* PriceChangerViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = F9015D9F19B731B4006C7882 /* PriceChangerViewController.m */; }; F92B0B6C19993D3F00CAEF3E /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = F92B0B6E19993D3F00CAEF3E /* Localizable.strings */; }; + F92F565E19B740B100A1EACA /* PriceChangerViewController_iPad.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F566019B740B100A1EACA /* PriceChangerViewController_iPad.xib */; }; + F92F566F19B758BD00A1EACA /* PriceChangerViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = F92F567119B758BD00A1EACA /* PriceChangerViewController.xib */; }; F9469169193015EE006DACD3 /* icon_checkmark.png in Resources */ = {isa = PBXBuildFile; fileRef = F9469167193015EE006DACD3 /* icon_checkmark.png */; }; F946916A193015EE006DACD3 /* icon_delete.png in Resources */ = {isa = PBXBuildFile; fileRef = F9469168193015EE006DACD3 /* icon_delete.png */; }; F961D7F5199A4A4800E9282C /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F961D7F3199A4A4800E9282C /* MainStoryboard.storyboard */; }; @@ -59,8 +62,16 @@ 34AAB87F189804FF0019860D /* DUREX test-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "DUREX test-Prefix.pch"; path = "FirstAppExample/DUREX test-Prefix.pch"; sourceTree = SOURCE_ROOT; }; 34AAB880189804FF0019860D /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = FirstAppExample/main.m; sourceTree = SOURCE_ROOT; }; 34AAB88C189805300019860D /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = FirstAppExample/Images.xcassets; sourceTree = SOURCE_ROOT; }; + F9015D9E19B731B4006C7882 /* PriceChangerViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PriceChangerViewController.h; sourceTree = SOURCE_ROOT; }; + F9015D9F19B731B4006C7882 /* PriceChangerViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PriceChangerViewController.m; sourceTree = SOURCE_ROOT; }; F92B0B6D19993D3F00CAEF3E /* Base */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = Base; path = Base.lproj/Localizable.strings; sourceTree = ""; }; F92B0B6F19993D4400CAEF3E /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/Localizable.strings; sourceTree = ""; }; + F92F565F19B740B100A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/PriceChangerViewController_iPad.xib; sourceTree = ""; }; + F92F566219B740BB00A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/PriceChangerViewController_iPad.strings; sourceTree = ""; }; + F92F566419B740BB00A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/PriceChangerViewController_iPad.strings; sourceTree = ""; }; + F92F567019B758BD00A1EACA /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/PriceChangerViewController.xib; sourceTree = ""; }; + F92F567319B758C200A1EACA /* es */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/PriceChangerViewController.strings; sourceTree = ""; }; + F92F567519B758C300A1EACA /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/PriceChangerViewController.strings; sourceTree = ""; }; F9469167193015EE006DACD3 /* icon_checkmark.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = icon_checkmark.png; sourceTree = SOURCE_ROOT; }; F9469168193015EE006DACD3 /* icon_delete.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = icon_delete.png; sourceTree = SOURCE_ROOT; }; F961D7F4199A4A4800E9282C /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/MainStoryboard.storyboard; sourceTree = SOURCE_ROOT; }; @@ -162,6 +173,10 @@ F98ACEDA19B6294E00D90AEE /* DatePickerViewController.m */, F9AB5A7119B63931006785E4 /* DatePickerViewController.xib */, F9AB5A7419B63938006785E4 /* DatePickerViewController_iPad.xib */, + F9015D9E19B731B4006C7882 /* PriceChangerViewController.h */, + F9015D9F19B731B4006C7882 /* PriceChangerViewController.m */, + F92F567119B758BD00A1EACA /* PriceChangerViewController.xib */, + F92F566019B740B100A1EACA /* PriceChangerViewController_iPad.xib */, 34AAB88C189805300019860D /* Images.xcassets */, 347186B91807290E00FA0FB2 /* Schemas */, 347186A718070F7F00FA0FB2 /* Device Picker */, @@ -288,11 +303,13 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + F92F565E19B740B100A1EACA /* PriceChangerViewController_iPad.xib in Resources */, F98356D8192E906600EA6821 /* bluetooth.png in Resources */, F9AB5A6F19B63931006785E4 /* DatePickerViewController.xib in Resources */, 34AAB88D189805300019860D /* Images.xcassets in Resources */, F92B0B6C19993D3F00CAEF3E /* Localizable.strings in Resources */, F961D7FE199A5B4700E9282C /* back_arrow.png in Resources */, + F92F566F19B758BD00A1EACA /* PriceChangerViewController.xib in Resources */, F9AB5A7219B63938006785E4 /* DatePickerViewController_iPad.xib in Resources */, F9469169193015EE006DACD3 /* icon_checkmark.png in Resources */, F961D7F5199A4A4800E9282C /* MainStoryboard.storyboard in Resources */, @@ -318,6 +335,7 @@ F962A233192FCA8A00E4324A /* Stack.m in Sources */, 34AAB885189804FF0019860D /* EMDevicePickerViewController.m in Sources */, F98ACEDC19B6294E00D90AEE /* DatePickerViewController.m in Sources */, + F9015DA119B731B4006C7882 /* PriceChangerViewController.m in Sources */, 34AAB883189804FF0019860D /* DUREXAppDelegate.m in Sources */, F98356DB192EAFD400EA6821 /* CommunicationProtocol.m in Sources */, F98356E1192EC84700EA6821 /* MenuTableViewController.m in Sources */, @@ -353,6 +371,26 @@ name = Localizable.strings; sourceTree = SOURCE_ROOT; }; + F92F566019B740B100A1EACA /* PriceChangerViewController_iPad.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F565F19B740B100A1EACA /* Base */, + F92F566219B740BB00A1EACA /* en */, + F92F566419B740BB00A1EACA /* es */, + ); + name = PriceChangerViewController_iPad.xib; + sourceTree = SOURCE_ROOT; + }; + F92F567119B758BD00A1EACA /* PriceChangerViewController.xib */ = { + isa = PBXVariantGroup; + children = ( + F92F567019B758BD00A1EACA /* Base */, + F92F567319B758C200A1EACA /* es */, + F92F567519B758C300A1EACA /* en */, + ); + name = PriceChangerViewController.xib; + sourceTree = SOURCE_ROOT; + }; F961D7F3199A4A4800E9282C /* MainStoryboard.storyboard */ = { isa = PBXVariantGroup; children = ( diff --git a/DUREX tests/DUREX test.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate b/DUREX tests/DUREX test.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate index 961ac2a..6759501 100644 Binary files a/DUREX tests/DUREX test.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate and b/DUREX tests/DUREX test.xcodeproj/project.xcworkspace/xcuserdata/imanol.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/DUREX tests/DUREX test.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/DUREX tests/DUREX test.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist index fe2b454..472035b 100644 --- a/DUREX tests/DUREX test.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist +++ b/DUREX tests/DUREX test.xcodeproj/xcuserdata/imanol.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -2,4 +2,22 @@ + + + + + + diff --git a/DUREX tests/DatePickerViewController.h b/DUREX tests/DatePickerViewController.h index e1dc31a..c10eb1f 100644 --- a/DUREX tests/DatePickerViewController.h +++ b/DUREX tests/DatePickerViewController.h @@ -13,7 +13,7 @@ #import "DUREXAppDelegate.h" @protocol DatePickerViewControllerDelegate -- (void)addItemViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date; +- (void)passDateViewController:(DatePickerViewController*)controller didFinishEnteringItem:(NSDate *)date; @end diff --git a/DUREX tests/DatePickerViewController.m b/DUREX tests/DatePickerViewController.m index b666603..6de1190 100644 --- a/DUREX tests/DatePickerViewController.m +++ b/DUREX tests/DatePickerViewController.m @@ -62,7 +62,7 @@ - (IBAction)closePopup:(id)sender { - [self.delegate addItemViewController:self didFinishEnteringItem:[[self datePicker] date]]; + [self.delegate passDateViewController:self didFinishEnteringItem:[[self datePicker] date]]; [self removeAnimate]; } diff --git a/DUREX tests/MenuTableViewController.h b/DUREX tests/MenuTableViewController.h index d699dc9..13de67e 100644 --- a/DUREX tests/MenuTableViewController.h +++ b/DUREX tests/MenuTableViewController.h @@ -10,6 +10,7 @@ #import "CommunicationProtocol.h" #import "Stack.h" #import "DatePickerViewController.h" +#import "PriceChangerViewController.h" #define num(x) [NSNumber numberWithUnsignedInt:x] @@ -40,10 +41,11 @@ enum { REPORT, } navigationLevel; -@interface MenuTableViewController : UITableViewController +@interface MenuTableViewController : UITableViewController @property (strong,nonatomic) Stack *parentLayout; -@property (strong,nonatomic) DatePickerViewController *popupViewController; +@property (strong,nonatomic) DatePickerViewController *datePickerViewController; +@property (strong,nonatomic) PriceChangerViewController *priceChangerViewController; - (void) navBack; diff --git a/DUREX tests/MenuTableViewController.m b/DUREX tests/MenuTableViewController.m index 81ce799..1a7252c 100644 --- a/DUREX tests/MenuTableViewController.m +++ b/DUREX tests/MenuTableViewController.m @@ -271,15 +271,31 @@ if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) { //self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; - self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; - self.popupViewController.delegate = self; - [self.popupViewController showInView:self.navigationController.view animated:YES]; + self.datePickerViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.datePickerViewController.delegate = self; + [self.datePickerViewController showInView:self.navigationController.view animated:YES]; } else { - self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController" bundle:nil]; - self.popupViewController.delegate = self; - [self.popupViewController showInView:self.navigationController.view animated:YES]; + self.datePickerViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController" bundle:nil]; + self.datePickerViewController.delegate = self; + [self.datePickerViewController showInView:self.navigationController.view animated:YES]; + } + } + else if([cellName isEqualToString:NSLocalizedString(@"Update product price", nil)] && [self currentNavLevel] == BASIC_CONFIGURATION) + { + if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) + { + //self.popupViewController = [[DatePickerViewController alloc] initWithNibName:@"DatePickerViewController_iPad" bundle:nil]; + self.priceChangerViewController = [[PriceChangerViewController alloc] initWithNibName:@"PriceChangerViewController_iPad" bundle:nil]; + self.priceChangerViewController.delegate = self; + [self.priceChangerViewController showInView:self.navigationController.view animated:YES]; + } + else + { + self.priceChangerViewController = [[PriceChangerViewController alloc] initWithNibName:@"PriceChangerViewController" bundle:nil]; + self.priceChangerViewController.delegate = self; + [self.priceChangerViewController showInView:self.navigationController.view animated:YES]; } } @@ -349,15 +365,18 @@ return cell; } -- (void)addItemViewController:(DatePickerViewController *)controller didFinishEnteringItem:(NSDate *)date +- (void)passDateViewController:(DatePickerViewController *)controller didFinishEnteringItem:(NSDate *)date { NSCalendar *calendar = [[NSCalendar alloc] initWithCalendarIdentifier:NSGregorianCalendar]; NSCalendarUnit units = NSYearCalendarUnit | NSMonthCalendarUnit | NSDayCalendarUnit | NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit; NSDateComponents *components = [calendar components:units fromDate:date]; NSLog(@"[MenuTableViewController.m]: %@", components); - //[_protocol updateTime: components]; } +- (void)passPriceViewController:(PriceChangerViewController *)controller didFinishEnteringItem:(NSArray *)data +{ + NSLog(@"[MenuTableViewController.m]: %@", data); +} /* // Override to support conditional editing of the table view. diff --git a/DUREX tests/PriceChangerViewController.h b/DUREX tests/PriceChangerViewController.h new file mode 100644 index 0000000..36fa30d --- /dev/null +++ b/DUREX tests/PriceChangerViewController.h @@ -0,0 +1,33 @@ +// +// PriceChangerViewController.h +// DUREX test +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +@class PriceChangerViewController; + +#import +#import +#import "DUREXAppDelegate.h" + +@protocol PriceChangerViewControllerDelegate +- (void)passPriceViewController:(PriceChangerViewController*)controller didFinishEnteringItem:(NSArray *)date; + +@end + + +@interface PriceChangerViewController : UIViewController + +@property (strong, nonatomic) IBOutlet UIView *priceChangerView; +@property (strong, nonatomic) IBOutlet UITextField *price; +@property (strong, nonatomic) IBOutlet UITextField *channel; +@property (strong, nonatomic) IBOutlet UITextField *code; +@property (nonatomic, strong) id delegate; + +- (void)showInView:(UIView *)aView animated:(BOOL)animated; +- (IBAction)closePopup:(id)sender; + + +@end diff --git a/DUREX tests/PriceChangerViewController.m b/DUREX tests/PriceChangerViewController.m new file mode 100644 index 0000000..11e4656 --- /dev/null +++ b/DUREX tests/PriceChangerViewController.m @@ -0,0 +1,103 @@ +// +// PriceChangerViewController.m +// DUREX test +// +// Created by Imanol Barba on 9/3/14. +// Copyright (c) 2014 Emmoco. All rights reserved. +// + +#import "PriceChangerViewController.h" + +@interface PriceChangerViewController () + +@end + +@implementation PriceChangerViewController + +- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil +{ + self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; + if (self) { + // Custom initialization + } + return self; +} + +- (void)viewDidLoad +{ + self.priceChangerView.layer.cornerRadius = 5; + self.priceChangerView.layer.shadowOpacity = 0.8; + self.priceChangerView.layer.shadowOffset = CGSizeMake(0.0f, 0.0f); + + self.code.delegate = self; + self.channel.delegate = self; + self.price.delegate = self; + + UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] + initWithTarget:self + action:@selector(dismissKeyboard)]; + + [self.view addGestureRecognizer:tap]; + + [super viewDidLoad]; + // Do any additional setup after loading the view from its nib. +} + +-(void)dismissKeyboard +{ + [self.code resignFirstResponder]; + [self.price resignFirstResponder]; + [self.channel resignFirstResponder]; +} + +-(BOOL)textFieldShouldReturn:(UITextField *)textField +{ + [textField resignFirstResponder]; + return YES; +} + +- (void)didReceiveMemoryWarning +{ + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +- (void)showAnimate +{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0; + [UIView animateWithDuration:.25 animations:^{ + self.view.alpha = 1; + self.view.transform = CGAffineTransformMakeScale(1, 1); + }]; +} + +- (void)removeAnimate +{ + [UIView animateWithDuration:.25 animations:^{ + self.view.transform = CGAffineTransformMakeScale(1.3, 1.3); + self.view.alpha = 0.0; + } completion:^(BOOL finished) { + if (finished) { + [self.view removeFromSuperview]; + } + }]; +} + +- (IBAction)closePopup:(id)sender +{ + NSArray *data = [[NSArray alloc] initWithObjects:[[self channel] text],[[self code] text],[[self price] text], nil]; + [self.delegate passPriceViewController:self didFinishEnteringItem:data]; + [self removeAnimate]; +} + +- (void)showInView:(UIView *)aView animated:(BOOL)animated +{ + [aView addSubview:self.view]; + if (animated) { + [self showAnimate]; + } +} + + +@end diff --git a/DUREX tests/en.lproj/PriceChangerViewController.strings b/DUREX tests/en.lproj/PriceChangerViewController.strings new file mode 100644 index 0000000..9dcf2c1 --- /dev/null +++ b/DUREX tests/en.lproj/PriceChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "3dU-vK-GGP"; */ +"3dU-vK-GGP.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "btL-PO-K6a"; */ +"btL-PO-K6a.text" = "Channel"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "m7Z-ve-Gxr"; */ +"m7Z-ve-Gxr.text" = "New Price"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "ngW-rD-Fgz"; */ +"ngW-rD-Fgz.text" = "Product Code"; diff --git a/DUREX tests/en.lproj/PriceChangerViewController_iPad.strings b/DUREX tests/en.lproj/PriceChangerViewController_iPad.strings new file mode 100644 index 0000000..1c2b48b --- /dev/null +++ b/DUREX tests/en.lproj/PriceChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "SHT-SD-io5"; */ +"SHT-SD-io5.text" = "Product Code"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "m8X-pz-4b0"; */ +"m8X-pz-4b0.text" = "Channel"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "oiq-sw-yPK"; */ +"oiq-sw-yPK.normalTitle" = "Done"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "vak-Pa-Znz"; */ +"vak-Pa-Znz.text" = "New Price"; diff --git a/DUREX tests/es.lproj/PriceChangerViewController.strings b/DUREX tests/es.lproj/PriceChangerViewController.strings new file mode 100644 index 0000000..c274521 --- /dev/null +++ b/DUREX tests/es.lproj/PriceChangerViewController.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "3dU-vK-GGP"; */ +"3dU-vK-GGP.normalTitle" = "Aceptar"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "btL-PO-K6a"; */ +"btL-PO-K6a.text" = "Canal"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "m7Z-ve-Gxr"; */ +"m7Z-ve-Gxr.text" = "Nuevo Precio"; + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "ngW-rD-Fgz"; */ +"ngW-rD-Fgz.text" = "Código del Producto"; diff --git a/DUREX tests/es.lproj/PriceChangerViewController_iPad.strings b/DUREX tests/es.lproj/PriceChangerViewController_iPad.strings new file mode 100644 index 0000000..ee5185d --- /dev/null +++ b/DUREX tests/es.lproj/PriceChangerViewController_iPad.strings @@ -0,0 +1,12 @@ + +/* Class = "IBUILabel"; text = "Product Code"; ObjectID = "SHT-SD-io5"; */ +"SHT-SD-io5.text" = "Código del Producto"; + +/* Class = "IBUILabel"; text = "Channel"; ObjectID = "m8X-pz-4b0"; */ +"m8X-pz-4b0.text" = "Canal"; + +/* Class = "IBUIButton"; normalTitle = "Done"; ObjectID = "oiq-sw-yPK"; */ +"oiq-sw-yPK.normalTitle" = "Aceptar"; + +/* Class = "IBUILabel"; text = "New Price"; ObjectID = "vak-Pa-Znz"; */ +"vak-Pa-Znz.text" = "Nuevo Precio"; diff --git a/TODO b/TODO index d0f8982..12fc30e 100644 --- a/TODO +++ b/TODO @@ -1,6 +1,6 @@ -- messageAvailable checks and status checks NOT working +- messageAvailable checks and status checks NOT working (long operations) - pop to previous view on connect error NOT working - +- On date change, response is overwritten by previous query, trimming needed according to numBytes - Incident class -- libgit2 0.22.2