Commit 2d300a22 authored by Achilles's avatar Achilles

update.

parent 96d017a3
This diff is collapsed.
...@@ -123,7 +123,7 @@ CONVERT_PROPERTY_CLASS(items, SubjectItem) ...@@ -123,7 +123,7 @@ CONVERT_PROPERTY_CLASS(items, SubjectItem)
-(NSString*) getPictureUrlOrDefault { -(NSString*) getPictureUrlOrDefault {
if ([VankeUtil isBlankString:self.picture]) { if ([VankeUtil isBlankString:self.picture]) {
return @"bill_icon.png"; return @"bill_default_image.png";
} else { } else {
return [NSString stringWithFormat:@"%@/%@", VANKE_SERVER_MEDIA_BASE_URL, self.picture]; return [NSString stringWithFormat:@"%@/%@", VANKE_SERVER_MEDIA_BASE_URL, self.picture];
} }
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
return; return;
} }
NSString *url = [NSString stringWithFormat:@"/wanke/user/login/%@", self.userName]; NSString *url = [NSString stringWithFormat:@"/user/login/%@", self.userName];
NSString *encryptPwd = [VankeUtil md5: self.password]; NSString *encryptPwd = [VankeUtil md5: self.password];
NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys: NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:
self.authenticode, @"authenticode", self.authenticode, @"authenticode",
......
...@@ -284,7 +284,7 @@ ON_SIGNAL3(VankeStatementDetailListBoard_iPhone, btnConfirm, signal) { ...@@ -284,7 +284,7 @@ ON_SIGNAL3(VankeStatementDetailListBoard_iPhone, btnConfirm, signal) {
} else { } else {
for ( BeeUIScrollItem *item in self.list.items ) for ( BeeUIScrollItem *item in self.list.items )
{ {
item.size = CGSizeMake( self.list.width / self.list.lineCount, 80 ); item.size = CGSizeMake( self.list.width / self.list.lineCount, 70 );
item.order = 0; item.order = 0;
item.rule = BeeUIScrollLayoutRule_Fall; item.rule = BeeUIScrollLayoutRule_Fall;
item.clazz = [VankeStatementDetailListCell_iPhone class]; item.clazz = [VankeStatementDetailListCell_iPhone class];
......
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#import "VankeStatementDetailListCell_iPhone.h" #import "VankeStatementDetailListCell_iPhone.h"
#import "VankeSettlementListAPI.h" #import "VankeSettlementListAPI.h"
#import "VankeUtil.h"
#pragma mark - #pragma mark -
...@@ -52,7 +53,13 @@ DEF_OUTLET(BeeUILabel, lblDateRange) ...@@ -52,7 +53,13 @@ DEF_OUTLET(BeeUILabel, lblDateRange)
} }
$(self.lblName).DATA(item.subject); $(self.lblName).DATA(item.subject);
$(self.lblAmount).DATA(item.amount.description); if ([VankeUtil isBlankString:item.remark]) {
$(@"btnRemark").HIDE();
} else {
$(@"btnRemark").SHOW();
}
$(self.lblAmount).DATA([NSString stringWithFormat:@"%.2f ", [item.amount doubleValue]]);
NSString *beginDate = [self trancateToDateString: item.beginDate]; NSString *beginDate = [self trancateToDateString: item.beginDate];
NSString *endDate = [self trancateToDateString: item.endDate]; NSString *endDate = [self trancateToDateString: item.endDate];
...@@ -74,4 +81,18 @@ DEF_OUTLET(BeeUILabel, lblDateRange) ...@@ -74,4 +81,18 @@ DEF_OUTLET(BeeUILabel, lblDateRange)
// TODO: custom layout here // TODO: custom layout here
} }
ON_SIGNAL3(VankeStatementDetailListCell_iPhone, btnRemark, signal) {
SubjectItem *item = (SubjectItem*) self.data;
if (!item) {
return;
}
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"备注"
message:item.remark
delegate:nil
cancelButtonTitle:@"确定"
otherButtonTitles:nil, nil];
[alert show];
}
@end @end
...@@ -13,7 +13,10 @@ ...@@ -13,7 +13,10 @@
<linear orientation="v" class="col name-col"> <linear orientation="v" class="col name-col">
<linear orientation="v" class="name-wrapper"> <linear orientation="v" class="name-wrapper">
<linear orientation="h" class="name-remark-wrapper">
<label id="lblName" class="name"/> <label id="lblName" class="name"/>
<button id="btnRemark" class="remark" />
</linear>
<label id="lblDateRange" class="date-range"/> <label id="lblDateRange" class="date-range"/>
</linear> </linear>
</linear> </linear>
...@@ -63,16 +66,14 @@ ...@@ -63,16 +66,14 @@
} }
.photo-col { .photo-col {
width: 25%; width: 50px;
h-align: center; v-align: center;
align: center;
} }
.photo-col .photo { .photo-col .photo {
width: 100%; width: auto;
height: 100%; height: auto;
image-mode: fit;
image-loading: white;
padding: 2px;
} }
.name-col { .name-col {
...@@ -82,16 +83,24 @@ ...@@ -82,16 +83,24 @@
v-align: center; v-align: center;
} }
.name-col .name-wrapper { .name-col .name-wrapper,
.name-col .name-wrapper .name-remark-wrapper {
height: auto; height: auto;
width: 100%; width: 100%;
} }
.name-col .name { .name-remark-wrapper .name {
font-size: 18px; font-size: 18px;
font-style: bold; font-style: bold;
width: 100%; width: auto;
height: auto;
}
.name-remark-wrapper .remark {
width: auto;
height: auto; height: auto;
padding: 3px 0px 0px 5px;
background-image: url(bill_remark.png);
} }
.name-col .date-range { .name-col .date-range {
......
...@@ -50,7 +50,9 @@ DEF_OUTLET( BeeUILabel, lblTotalPrefix ) ...@@ -50,7 +50,9 @@ DEF_OUTLET( BeeUILabel, lblTotalPrefix )
[dateFormatter setDateFormat:@"yyyyMM"]; [dateFormatter setDateFormat:@"yyyyMM"];
NSDate *settleDate = [dateFormatter dateFromString:shop.settle]; NSDate *settleDate = [dateFormatter dateFromString:shop.settle];
[self setSettleDate:settleDate]; [self setSettleDate:settleDate];
$(self.lblAmount).DATA(shop.amount.description);
NSNumber *amount = shop.amount;
$(self.lblAmount).DATA([NSString stringWithFormat:@"%.2f ", nil == amount? 0.0f:[amount doubleValue]]);
} }
- (void)layoutDidFinish - (void)layoutDidFinish
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
position: absolute; position: absolute;
left: 0px; left: 0px;
top: 0px; top: 0px;
background-color: white; background-image: url(wave_line.png);
} }
.col-wrapper { .col-wrapper {
...@@ -86,7 +86,11 @@ ...@@ -86,7 +86,11 @@
/** 左边日期列 */ /** 左边日期列 */
.date-col { .date-col {
padding-left: 10px; align: center;
}
.date-col .col-body {
width: 100px;
} }
.date-col .row { .date-col .row {
......
...@@ -65,6 +65,7 @@ ON_CREATE_VIEWS( signal ) ...@@ -65,6 +65,7 @@ ON_CREATE_VIEWS( signal )
self.allowedSwipeToBack = YES; self.allowedSwipeToBack = YES;
self.title = @"对账单"; self.title = @"对账单";
[self initListAndModel]; [self initListAndModel];
// [self.searchBar setBarTintColor :[VankeUtil rgbStringToColor: @"246,246,246"]];
} }
ON_DELETE_VIEWS( signal ) ON_DELETE_VIEWS( signal )
......
...@@ -48,8 +48,7 @@ DEF_OUTLET(BeeUIImageView, imgState) ...@@ -48,8 +48,7 @@ DEF_OUTLET(BeeUIImageView, imgState)
$(self.imgPhoto).DATA([item getPictureUrlOrDefault]); $(self.imgPhoto).DATA([item getPictureUrlOrDefault]);
$(self.lblName).DATA([item codeName]); $(self.lblName).DATA([item codeName]);
$(self.lblState).DATA(@"已确认"); $(self.lblAmount).DATA([NSString stringWithFormat:@"%.2f ", [item.amount doubleValue]]);
$(self.lblAmount).DATA(item.amount.description);
$(self.imgState).DATA([NSString stringWithFormat:@"%@.png", item.state]); $(self.imgState).DATA([NSString stringWithFormat:@"%@.png", item.state]);
} }
......
...@@ -47,14 +47,16 @@ DEF_OUTLET( BeeUILabel, lblTotalPrefix ) ...@@ -47,14 +47,16 @@ DEF_OUTLET( BeeUILabel, lblTotalPrefix )
StatementListResponse *resp = (StatementListResponse*) self.data; StatementListResponse *resp = (StatementListResponse*) self.data;
if (nil == resp) { if (nil == resp) {
[self setSettleDate:[NSDate date]]; [self setSettleDate:[NSDate date]];
$(self.lblCount).DATA(@"0"); $(self.lblCount).DATA([NSString stringWithFormat:@" %d ", 0]);
$(self.lblAmount).DATA(@"0"); $(self.lblAmount).DATA([NSString stringWithFormat:@"%.2f ", 0.0f]);
return; return;
} }
[self setSettleDate:resp.settle]; [self setSettleDate:resp.settle];
$(self.lblCount).DATA([NSString stringWithFormat:@"%d", [resp.data.paging.recordCount intValue]]); $(self.lblCount).DATA([NSString stringWithFormat:@" %d ", [resp.data.paging.recordCount intValue]]);
$(self.lblAmount).DATA(nil == resp.data.amount? @"0": resp.data.amount.description);
NSNumber *amount = resp.data.amount;
$(self.lblAmount).DATA([NSString stringWithFormat:@"%.2f ", nil == amount? 0.0f:[amount doubleValue]]);
} }
- (void)layoutDidFinish - (void)layoutDidFinish
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
position: absolute; position: absolute;
left: 0px; left: 0px;
top: 0px; top: 0px;
background-color: white; background-image: url(wave_line.png);
} }
.col-wrapper { .col-wrapper {
...@@ -89,7 +89,11 @@ ...@@ -89,7 +89,11 @@
/** 左边日期列 */ /** 左边日期列 */
.date-col { .date-col {
padding-left: 10px; align: center;
}
.date-col .col-body {
width: 100px;
} }
.date-col .row { .date-col .row {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment