//
//  PackageTotalCell.m
//  as350b3e
//
//  Created by Vadim on 5/21/14.
//
//

#import "PackageTotalCell.h"
#import "MedicalPackage.h"

@implementation PackageTotalCell {
    
    __weak IBOutlet UILabel *packageNameLabel_;
    __weak IBOutlet UILabel *totalWeightLabel_;
    __weak IBOutlet UILabel *totalArmLabel_;
    __weak IBOutlet UILabel *totalMomentLabel_;
}

- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        // Initialization code
    }
    return self;
}

- (void)awakeFromNib
{
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated
{
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setPackage:(MedicalPackage *)package {
    packageNameLabel_.text = package.packageName;
    totalWeightLabel_.text = [NSString stringWithFormat:@"%.2f", package.totalWeight];
    totalArmLabel_.text = [NSString stringWithFormat:@"%.2f", package.totalArm];
    totalMomentLabel_.text = [NSString stringWithFormat:@"%.2f", package.totalMoment];
}

@end
