aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--iBean/iBean.xcodeproj/project.pbxproj35
-rw-r--r--iBean/iBean.xcodeproj/project.xcworkspace/xcuserdata/eddiex.xcuserdatad/UserInterfaceState.xcuserstatebin21878 -> 25626 bytes
-rw-r--r--iBean/iBean/AppDelegate+Storage.h3
-rw-r--r--iBean/iBean/AppDelegate+Storage.m39
-rw-r--r--iBean/iBean/Bean.h21
-rw-r--r--iBean/iBean/Bean.m20
-rw-r--r--iBean/iBean/BeanCollection.h32
-rw-r--r--iBean/iBean/BeanCollection.m23
-rw-r--r--iBean/iBean/InstaBeanViewController.m3
-rw-r--r--iBean/iBean/iBean.xcdatamodeld/iBean.xcdatamodel/contents17
-rw-r--r--iBean/iBean/iBeanListViewController.h23
-rw-r--r--iBean/iBean/iBeanListViewController.m175
-rw-r--r--iBean/iBean/iPhoneStoryboard.storyboard35
13 files changed, 413 insertions, 13 deletions
diff --git a/iBean/iBean.xcodeproj/project.pbxproj b/iBean/iBean.xcodeproj/project.pbxproj
index b66ea7d..264aee4 100644
--- a/iBean/iBean.xcodeproj/project.pbxproj
+++ b/iBean/iBean.xcodeproj/project.pbxproj
@@ -22,6 +22,9 @@
020C55C41691059800D8224C /* InstaBeanViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55C31691059800D8224C /* InstaBeanViewController.m */; };
020C55C716910EAD00D8224C /* InstaBeanConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55C616910EAD00D8224C /* InstaBeanConfiguration.m */; };
020C55CA1691100000D8224C /* AppDelegate+Storage.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55C91691100000D8224C /* AppDelegate+Storage.m */; };
+ 020C55DA1695CAD200D8224C /* iBeanListViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55D91695CAD200D8224C /* iBeanListViewController.m */; };
+ 020C55EF1697970200D8224C /* Bean.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55EE1697970200D8224C /* Bean.m */; };
+ 020C55F21697970200D8224C /* BeanCollection.m in Sources */ = {isa = PBXBuildFile; fileRef = 020C55F11697970200D8224C /* BeanCollection.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -47,6 +50,12 @@
020C55C616910EAD00D8224C /* InstaBeanConfiguration.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = InstaBeanConfiguration.m; sourceTree = "<group>"; };
020C55C81691100000D8224C /* AppDelegate+Storage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "AppDelegate+Storage.h"; sourceTree = "<group>"; };
020C55C91691100000D8224C /* AppDelegate+Storage.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "AppDelegate+Storage.m"; sourceTree = "<group>"; };
+ 020C55D81695CAD200D8224C /* iBeanListViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iBeanListViewController.h; sourceTree = "<group>"; };
+ 020C55D91695CAD200D8224C /* iBeanListViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iBeanListViewController.m; sourceTree = "<group>"; };
+ 020C55ED1697970200D8224C /* Bean.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Bean.h; sourceTree = "<group>"; };
+ 020C55EE1697970200D8224C /* Bean.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Bean.m; sourceTree = "<group>"; };
+ 020C55F01697970200D8224C /* BeanCollection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BeanCollection.h; sourceTree = "<group>"; };
+ 020C55F11697970200D8224C /* BeanCollection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BeanCollection.m; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
@@ -95,6 +104,7 @@
020C559F1691014E00D8224C /* iBean */ = {
isa = PBXGroup;
children = (
+ 020C55D31695C2C800D8224C /* iBean */,
020C55BB169101CE00D8224C /* Storyboards */,
020C55B9169101A300D8224C /* InstaBean */,
020C55A81691014E00D8224C /* AppDelegate.h */,
@@ -140,6 +150,27 @@
name = Storyboards;
sourceTree = "<group>";
};
+ 020C55D31695C2C800D8224C /* iBean */ = {
+ isa = PBXGroup;
+ children = (
+ 020C55DF169792F800D8224C /* Data */,
+ 020C55D81695CAD200D8224C /* iBeanListViewController.h */,
+ 020C55D91695CAD200D8224C /* iBeanListViewController.m */,
+ );
+ name = iBean;
+ sourceTree = "<group>";
+ };
+ 020C55DF169792F800D8224C /* Data */ = {
+ isa = PBXGroup;
+ children = (
+ 020C55F01697970200D8224C /* BeanCollection.h */,
+ 020C55F11697970200D8224C /* BeanCollection.m */,
+ 020C55ED1697970200D8224C /* Bean.h */,
+ 020C55EE1697970200D8224C /* Bean.m */,
+ );
+ name = Data;
+ sourceTree = "<group>";
+ };
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -212,6 +243,9 @@
020C55C41691059800D8224C /* InstaBeanViewController.m in Sources */,
020C55C716910EAD00D8224C /* InstaBeanConfiguration.m in Sources */,
020C55CA1691100000D8224C /* AppDelegate+Storage.m in Sources */,
+ 020C55DA1695CAD200D8224C /* iBeanListViewController.m in Sources */,
+ 020C55EF1697970200D8224C /* Bean.m in Sources */,
+ 020C55F21697970200D8224C /* BeanCollection.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -322,6 +356,7 @@
020C55B81691014E00D8224C /* Release */,
);
defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
diff --git a/iBean/iBean.xcodeproj/project.xcworkspace/xcuserdata/eddiex.xcuserdatad/UserInterfaceState.xcuserstate b/iBean/iBean.xcodeproj/project.xcworkspace/xcuserdata/eddiex.xcuserdatad/UserInterfaceState.xcuserstate
index 1c1f737..170f786 100644
--- a/iBean/iBean.xcodeproj/project.xcworkspace/xcuserdata/eddiex.xcuserdatad/UserInterfaceState.xcuserstate
+++ b/iBean/iBean.xcodeproj/project.xcworkspace/xcuserdata/eddiex.xcuserdatad/UserInterfaceState.xcuserstate
Binary files differ
diff --git a/iBean/iBean/AppDelegate+Storage.h b/iBean/iBean/AppDelegate+Storage.h
index 3fa5acd..09ef412 100644
--- a/iBean/iBean/AppDelegate+Storage.h
+++ b/iBean/iBean/AppDelegate+Storage.h
@@ -18,13 +18,14 @@
#pragma mark - Common storage related methods
- (NSError*) save;
+- (NSError*) deleteObject: (NSManagedObject*) managedObject;
#pragma mark - InstaBean related storage methods
- (InstaBeanConfiguration*) getInstaBeanConfiguration;
#pragma mark - iBean related storage methods
-
+- (NSArray*) getBeanCollections;
diff --git a/iBean/iBean/AppDelegate+Storage.m b/iBean/iBean/AppDelegate+Storage.m
index 0fb5fac..6d4288a 100644
--- a/iBean/iBean/AppDelegate+Storage.m
+++ b/iBean/iBean/AppDelegate+Storage.m
@@ -20,6 +20,17 @@
return error;
}
+- (NSError*) deleteObject: (NSManagedObject*) managedObject
+{
+ NSError *error = nil;
+ if (managedObject != nil && self.managedObjectContext != nil)
+ {
+ [self.managedObjectContext deleteObject:managedObject];
+ error = [self save];
+ }
+ return error;
+}
+
#pragma mark - InstaBean related storage methods
- (InstaBeanConfiguration*) getInstaBeanConfiguration
{
@@ -33,7 +44,7 @@
NSError *fetchRequestError = nil;
NSArray *fetchRequestResult = [self.managedObjectContext executeFetchRequest:fetchRequest error:&fetchRequestError];
- if (fetchRequestResult == nil || fetchRequestError)
+ if (fetchRequestResult == nil || fetchRequestError != nil)
{
NSLog(@"getInstaBeanConfiguration - Fetch request resulted in an error!");
#warning TODO: Implement proper error handling (perhaps a message box?)
@@ -51,6 +62,32 @@
return config;
}
+#pragma mark - iBean (Bean Collections) related storage methods
+- (NSArray*) getBeanCollections
+{
+ NSArray *fetchRequestResult = nil;
+
+ if (self.managedObjectContext != nil)
+ {
+ NSFetchRequest *fetchRequest = [NSFetchRequest fetchRequestWithEntityName:@"BeanCollection"];
+ //For now we sort them on name.
+ fetchRequest.sortDescriptors = [NSArray arrayWithObject: [NSSortDescriptor sortDescriptorWithKey:@"name" ascending:NO]];
+
+ NSError *fetchRequestError = nil;
+ fetchRequestResult = [self.managedObjectContext executeFetchRequest:fetchRequest error:&fetchRequestError];
+
+ if (fetchRequestResult == nil || fetchRequestError != nil)
+ {
+ NSLog(@"getBeanCollections - Fetch request resulted in an error!");
+#warning TODO: Implement proper error handling (perhaps a message box?)
+ }
+ }
+
+ return fetchRequestResult;
+}
+
+
+
@end
diff --git a/iBean/iBean/Bean.h b/iBean/iBean/Bean.h
new file mode 100644
index 0000000..d42a98f
--- /dev/null
+++ b/iBean/iBean/Bean.h
@@ -0,0 +1,21 @@
+//
+// Bean.h
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-05.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import <CoreData/CoreData.h>
+
+@class BeanCollection;
+
+@interface Bean : NSManagedObject
+
+@property (nonatomic, retain) NSString * name;
+@property (nonatomic, retain) NSNumber * amount;
+@property (nonatomic, retain) NSNumber * grindSetting;
+@property (nonatomic, retain) BeanCollection *beanCollection;
+
+@end
diff --git a/iBean/iBean/Bean.m b/iBean/iBean/Bean.m
new file mode 100644
index 0000000..e9b85fa
--- /dev/null
+++ b/iBean/iBean/Bean.m
@@ -0,0 +1,20 @@
+//
+// Bean.m
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-05.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import "Bean.h"
+#import "BeanCollection.h"
+
+
+@implementation Bean
+
+@dynamic name;
+@dynamic amount;
+@dynamic grindSetting;
+@dynamic beanCollection;
+
+@end
diff --git a/iBean/iBean/BeanCollection.h b/iBean/iBean/BeanCollection.h
new file mode 100644
index 0000000..73f935d
--- /dev/null
+++ b/iBean/iBean/BeanCollection.h
@@ -0,0 +1,32 @@
+//
+// BeanCollection.h
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-05.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import <CoreData/CoreData.h>
+
+@class Bean;
+
+@interface BeanCollection : NSManagedObject
+
+@property (nonatomic, retain) NSString * name;
+@property (nonatomic, retain) NSNumber * extractionTime;
+@property (nonatomic, retain) NSDate * created;
+@property (nonatomic, retain) NSNumber * extractionCounter;
+@property (nonatomic, retain) NSString * note;
+@property (nonatomic, retain) NSDate * modified;
+@property (nonatomic, retain) NSSet *beans;
+@end
+
+@interface BeanCollection (CoreDataGeneratedAccessors)
+
+- (void)addBeansObject:(Bean *)value;
+- (void)removeBeansObject:(Bean *)value;
+- (void)addBeans:(NSSet *)values;
+- (void)removeBeans:(NSSet *)values;
+
+@end
diff --git a/iBean/iBean/BeanCollection.m b/iBean/iBean/BeanCollection.m
new file mode 100644
index 0000000..cfeceda
--- /dev/null
+++ b/iBean/iBean/BeanCollection.m
@@ -0,0 +1,23 @@
+//
+// BeanCollection.m
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-05.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import "BeanCollection.h"
+#import "Bean.h"
+
+
+@implementation BeanCollection
+
+@dynamic name;
+@dynamic extractionTime;
+@dynamic created;
+@dynamic extractionCounter;
+@dynamic note;
+@dynamic modified;
+@dynamic beans;
+
+@end
diff --git a/iBean/iBean/InstaBeanViewController.m b/iBean/iBean/InstaBeanViewController.m
index 15b8330..4b28005 100644
--- a/iBean/iBean/InstaBeanViewController.m
+++ b/iBean/iBean/InstaBeanViewController.m
@@ -15,7 +15,7 @@
@implementation InstaBeanViewController
-/*
+
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
@@ -24,7 +24,6 @@
}
return self;
}
-*/
- (void)viewDidLoad
{
diff --git a/iBean/iBean/iBean.xcdatamodeld/iBean.xcdatamodel/contents b/iBean/iBean/iBean.xcdatamodeld/iBean.xcdatamodel/contents
index 3098915..cbceae9 100644
--- a/iBean/iBean/iBean.xcdatamodeld/iBean.xcdatamodel/contents
+++ b/iBean/iBean/iBean.xcdatamodeld/iBean.xcdatamodel/contents
@@ -1,9 +1,26 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<model name="" userDefinedModelVersionIdentifier="" type="com.apple.IDECoreDataModeler.DataModel" documentVersion="1.0" lastSavedToolsVersion="1811" systemVersion="12C60" minimumToolsVersion="Automatic" macOSVersion="Automatic" iOSVersion="Automatic">
+ <entity name="Bean" representedClassName="Bean" syncable="YES">
+ <attribute name="amount" optional="YES" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
+ <attribute name="grindSetting" optional="YES" attributeType="Integer 32" defaultValueString="0" syncable="YES"/>
+ <attribute name="name" optional="YES" attributeType="String" syncable="YES"/>
+ <relationship name="beanCollection" optional="YES" minCount="1" maxCount="1" deletionRule="Nullify" destinationEntity="BeanCollection" inverseName="beans" inverseEntity="BeanCollection" syncable="YES"/>
+ </entity>
+ <entity name="BeanCollection" representedClassName="BeanCollection" syncable="YES">
+ <attribute name="created" optional="YES" attributeType="Date" syncable="YES"/>
+ <attribute name="extractionCounter" optional="YES" attributeType="Integer 64" defaultValueString="0" syncable="YES"/>
+ <attribute name="extractionTime" optional="YES" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
+ <attribute name="modified" optional="YES" attributeType="Date" syncable="YES"/>
+ <attribute name="name" optional="YES" attributeType="String" syncable="YES"/>
+ <attribute name="note" optional="YES" attributeType="String" syncable="YES"/>
+ <relationship name="beans" optional="YES" toMany="YES" deletionRule="Cascade" destinationEntity="Bean" inverseName="beanCollection" inverseEntity="Bean" syncable="YES"/>
+ </entity>
<entity name="InstaBeanConfiguration" representedClassName="InstaBeanConfiguration" syncable="YES">
<attribute name="extractionTime" optional="YES" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
</entity>
<elements>
<element name="InstaBeanConfiguration" positionX="160" positionY="192" width="128" height="60"/>
+ <element name="BeanCollection" positionX="160" positionY="192" width="128" height="148"/>
+ <element name="Bean" positionX="-369" positionY="111" width="128" height="105"/>
</elements>
</model> \ No newline at end of file
diff --git a/iBean/iBean/iBeanListViewController.h b/iBean/iBean/iBeanListViewController.h
new file mode 100644
index 0000000..f0a76b9
--- /dev/null
+++ b/iBean/iBean/iBeanListViewController.h
@@ -0,0 +1,23 @@
+//
+// iBeanListViewController.h
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-03.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface iBeanListViewController : UITableViewController
+
+@property (nonatomic, strong) NSArray *beanCollections;
+
+/* Utility methods */
+- (void) initViewController;
+
+/* UI Outlets */
+
+
+/* UI Actions */
+
+@end
diff --git a/iBean/iBean/iBeanListViewController.m b/iBean/iBean/iBeanListViewController.m
new file mode 100644
index 0000000..ac97a10
--- /dev/null
+++ b/iBean/iBean/iBeanListViewController.m
@@ -0,0 +1,175 @@
+//
+// iBeanListViewController.m
+// iBean
+//
+// Created by Eddie Ehlin on 2013-01-03.
+// Copyright (c) 2013 Eddie Ehlin. All rights reserved.
+//
+
+#import "iBeanListViewController.h"
+#import "BeanCollection.h"
+#import "AppDelegate+Storage.h"
+
+@interface iBeanListViewController ()
+
+@end
+
+@implementation iBeanListViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+ self = [super initWithStyle:style];
+ if (self) {
+ // Custom initialization
+ }
+ return self;
+}
+
+- (void)viewDidLoad
+{
+ [super viewDidLoad];
+ NSLog(@"iBeanListViewController view's loaded!");
+
+
+ // Uncomment the following line to preserve selection between presentations.
+ // self.clearsSelectionOnViewWillAppear = NO;
+
+ // Uncomment the following line to display an Edit button in the navigation bar for this view controller.
+ // self.navigationItem.rightBarButtonItem = self.editButtonItem;
+}
+
+- (void) viewWillAppear:(BOOL)animated
+{
+ [super viewWillAppear:animated];
+ [self initViewController];
+
+ //TODO: Rollback if view is "backed" to from add-state, so that nothing gets saved...that shouldn't be saved.
+}
+
+- (void) prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
+{
+ if ([segue.identifier isEqualToString:@"AddNewStep1Segue"])
+ {
+ NSLog(@"Going to Add new - Step 1");
+ //TODO: Create new bean collection object (managed context object) and push it through the segue
+ //to the next view controller!
+ //segue.destinationViewController Points to next view controller! Fetch it and add/set the bean collection object to use.
+ }
+}
+
+- (void)didReceiveMemoryWarning
+{
+ [super didReceiveMemoryWarning];
+ // Dispose of any resources that can be recreated.
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+ // Return the number of sections.
+ return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+ // Return the number of rows in the section (we only have one section).
+ return self.beanCollections.count;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+ static NSString *CellIdentifier = @"BeanCollectionCell";
+ UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier forIndexPath:indexPath];
+
+ //Configure the cell and set its title
+ BeanCollection *currentCollection = [self.beanCollections objectAtIndex:indexPath.row];
+ cell.textLabel.text = currentCollection.name;
+
+ return cell;
+}
+
+
+// Override to support conditional editing of the table view.
+- (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath
+{
+ // Return NO if you do not want the specified item to be editable (we want to be able to REMOVE though).
+ return YES;
+}
+
+// Override to support editing the table view.
+- (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+ if (editingStyle == UITableViewCellEditingStyleDelete) {
+ // Delete the row from the data source
+ if (self.beanCollections != nil)
+ {
+ if ([(AppDelegate*) [[UIApplication sharedApplication] delegate] deleteObject:[self.beanCollections objectAtIndex:indexPath.row]] != nil)
+ {
+ NSLog(@"deleteObject returned an error when deleting bean collection!");
+#warning TODO: Handle deletion error!?
+ }
+ else
+ {
+ //Reload our bean collections array from storage (since it is no longer consistent)
+ self.beanCollections = [(AppDelegate*) [[UIApplication sharedApplication] delegate] getBeanCollections];
+ }
+ }
+ [tableView deleteRowsAtIndexPaths:@[indexPath] withRowAnimation:UITableViewRowAnimationFade];
+ }
+ else if (editingStyle == UITableViewCellEditingStyleInsert) {
+ // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view
+ }
+}
+
+/*
+// Override to support rearranging the table view.
+- (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath
+{
+}
+*/
+
+/*
+// Override to support conditional rearranging of the table view.
+- (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath
+{
+ // Return NO if you do not want the item to be re-orderable.
+ return YES;
+}
+*/
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+ // Navigation logic may go here. Create and push another view controller.
+ /*
+ <#DetailViewController#> *detailViewController = [[<#DetailViewController#> alloc] initWithNibName:@"<#Nib name#>" bundle:nil];
+ // ...
+ // Pass the selected object to the new view controller.
+ [self.navigationController pushViewController:detailViewController animated:YES];
+ */
+}
+
+
+/*****************************************************
+ Utility methods
+ *****************************************************/
+- (void) initViewController
+{
+ NSLog(@"iBeanListViewController - initViewController");
+
+ //Load bean collections from core data storage
+ self.beanCollections = [(AppDelegate*) [[UIApplication sharedApplication] delegate] getBeanCollections];
+ if (self.beanCollections != nil)
+ {
+ [self.tableView reloadData];
+ }
+}
+
+/*****************************************************
+ UI Actions
+ *****************************************************/
+#pragma mark - IBActions
+
+@end
diff --git a/iBean/iBean/iPhoneStoryboard.storyboard b/iBean/iBean/iPhoneStoryboard.storyboard
index 00a86fa..aca958d 100644
--- a/iBean/iBean/iPhoneStoryboard.storyboard
+++ b/iBean/iBean/iPhoneStoryboard.storyboard
@@ -4,21 +4,28 @@
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="1930"/>
</dependencies>
<scenes>
- <!--Table View Controller - iBean-->
+ <!--I Bean List View Controller - iBean-->
<scene sceneID="SSu-AL-Mw5">
<objects>
- <tableViewController id="agK-tm-pZO" sceneMemberID="viewController">
+ <tableViewController id="agK-tm-pZO" customClass="iBeanListViewController" sceneMemberID="viewController">
<tableView key="view" opaque="NO" clipsSubviews="YES" clearsContextBeforeDrawing="NO" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" rowHeight="44" sectionHeaderHeight="22" sectionFooterHeight="22" id="Mma-e7-grn">
<rect key="frame" x="0.0" y="64" width="320" height="455"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
- <tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" id="nt6-NB-YC3">
+ <tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" reuseIdentifier="BeanCollectionCell" textLabel="cIq-IL-xU6" style="IBUITableViewCellStyleDefault" id="nt6-NB-YC3">
<rect key="frame" x="0.0" y="22" width="320" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<view key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center">
<rect key="frame" x="0.0" y="0.0" width="320" height="43"/>
<autoresizingMask key="autoresizingMask"/>
+ <subviews>
+ <label opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="left" text="Bean collection title" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="cIq-IL-xU6">
+ <fontDescription key="fontDescription" type="boldSystem" pointSize="20"/>
+ <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
+ <color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="calibratedRGB"/>
+ </label>
+ </subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
</view>
</tableViewCell>
@@ -32,14 +39,14 @@
<barButtonItem key="leftBarButtonItem" systemItem="edit" id="lNm-m6-tWK"/>
<barButtonItem key="rightBarButtonItem" systemItem="add" id="Wuc-np-Bjz">
<connections>
- <segue destination="5Zc-ii-ZPi" kind="push" id="9nO-3G-dWz"/>
+ <segue destination="5Zc-ii-ZPi" kind="push" identifier="AddNewStep1Segue" id="9nO-3G-dWz"/>
</connections>
</barButtonItem>
</navigationItem>
</tableViewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="BXw-pd-TpS" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
- <point key="canvasLocation" x="755" y="337"/>
+ <point key="canvasLocation" x="773" y="427"/>
</scene>
<!--Insta Bean View Controller - Insta bean-->
<scene sceneID="Lvr-w4-t8a">
@@ -177,7 +184,7 @@
<color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</state>
<connections>
- <segue destination="utP-dF-IAb" kind="push" id="M6f-zy-35z"/>
+ <segue destination="utP-dF-IAb" kind="push" identifier="AddNewStep2Segue" id="M6f-zy-35z"/>
</connections>
</button>
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" text="Notes:" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="HFn-UM-1hs">
@@ -237,18 +244,25 @@
<color key="titleColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</state>
<connections>
- <segue destination="49F-vz-WhB" kind="push" id="KeQ-zN-iII"/>
+ <segue destination="49F-vz-WhB" kind="push" identifier="AddNewStep3Segue" id="KeQ-zN-iII"/>
</connections>
</button>
<tableView clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" rowHeight="44" sectionHeaderHeight="22" sectionFooterHeight="22" translatesAutoresizingMaskIntoConstraints="NO" id="bW3-E7-UoQ">
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<prototypes>
- <tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" id="4VM-0O-fxA">
+ <tableViewCell contentMode="scaleToFill" selectionStyle="blue" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" reuseIdentifier="BeanCell" textLabel="87B-hs-oLz" style="IBUITableViewCellStyleDefault" id="4VM-0O-fxA">
<rect key="frame" x="0.0" y="22" width="320" height="44"/>
<autoresizingMask key="autoresizingMask"/>
<view key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center">
<rect key="frame" x="0.0" y="0.0" width="320" height="43"/>
<autoresizingMask key="autoresizingMask"/>
+ <subviews>
+ <label opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="left" text="Bean title" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="87B-hs-oLz">
+ <fontDescription key="fontDescription" type="boldSystem" pointSize="20"/>
+ <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
+ <color key="highlightedColor" red="1" green="1" blue="1" alpha="1" colorSpace="calibratedRGB"/>
+ </label>
+ </subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="calibratedWhite"/>
</view>
</tableViewCell>
@@ -268,7 +282,7 @@
<navigationItem key="navigationItem" title="Beans (2/3)" id="AvU-FE-egp">
<barButtonItem key="rightBarButtonItem" systemItem="add" id="GqH-Ye-0oU">
<connections>
- <segue destination="YXO-0S-PzZ" kind="push" id="COq-b9-noK"/>
+ <segue destination="YXO-0S-PzZ" kind="push" identifier="AddBeanSegue" id="COq-b9-noK"/>
</connections>
</barButtonItem>
</navigationItem>
@@ -422,6 +436,9 @@
<class className="NSLayoutConstraint" superclassName="NSObject">
<source key="sourceIdentifier" type="project" relativePath="./Classes/NSLayoutConstraint.h"/>
</class>
+ <class className="iBeanListViewController" superclassName="UITableViewController">
+ <source key="sourceIdentifier" type="project" relativePath="./Classes/iBeanListViewController.h"/>
+ </class>
</classes>
<simulatedMetricsContainer key="defaultSimulatedMetrics">
<simulatedStatusBarMetrics key="statusBar"/>