Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Applied Carls Changes to my fork

  • Loading branch information...
commit 2a125aacc276e88cee816d756aa9f19b7f6b52e2 1 parent c85f085
@nglayton nglayton authored
View
15 Classes/ItunesConnectDownloaderOperation.m
@@ -485,7 +485,7 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
viewState = [html ajaxViewState];
NSString *pickerAjax = [html tagHTMLforTag:@"select" WithID:@"theForm:datePickerSourceSelectElementSales"];
- ajaxParams = [pickerAjax parametersFromAjaxSubmitString];
+ ajaxParams = [html parametersFromAjaxSubmitStringForFunction:@"onLoad"];//[pickerAjax parametersFromAjaxSubmitString];
NSString *weekPickerAjax = [html tagHTMLforTag:@"select" WithID:@"theForm:weekPickerSourceSelectElement"];
NSArray *weekAjaxParams = [weekPickerAjax parametersFromAjaxSubmitString];
@@ -493,7 +493,7 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
NSRange range = [html rangeOfString:@" id=\"weeklyLabel\""];
NSString *weekSwitchHTML = [html substringFromIndex:range.location];
NSArray *weekSwitchAjaxParams = [weekSwitchHTML parametersFromAjaxSubmitString]; // has extra at the end, but we ignore that
-
+
//----- download DAILY
for (NSString *oneDayOption in dayOptions)
{
@@ -510,8 +510,7 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
[oneDayOption stringByUrlEncoding],
[[weekOptions objectAtIndex:0] stringByUrlEncoding]];
- NSArray *ajaxParams2 = [html parametersFromAjaxSubmitStringForFunction:@"onLoad"];
- ajaxRequest = [NSURLRequest ajaxRequestWithParameters:ajaxParams2 extraFormString:extraFormString2 viewState:viewState baseURL:baseURL];
+ ajaxRequest = [NSURLRequest ajaxRequestWithParameters:ajaxParams extraFormString:extraFormString2 viewState:viewState baseURL:baseURL];
data = [NSURLConnection sendSynchronousRequest:ajaxRequest returningResponse:&response error:&error];
@@ -578,7 +577,7 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
// ----- switch to weekly so that we get the viewstate for weekly
- extraFormString = [NSString stringWithFormat:@"theForm%%3AuserType=notnormal&theForm%%3AvendorType=Y&=&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@",
+ extraFormString = [NSString stringWithFormat:@"theForm%%3AuserType=notnormal&theForm%%3AvendorType=Y&theForm%%3AdateType=W&theForm%%3AoptInVar=A&theForm%%3AcontentType=iOS&theForm%%3AcontentSubType=Paid%%20Apps&=&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@",
[[dayOptions objectAtIndex:0] stringByUrlEncoding],
[[dayOptions objectAtIndex:0] stringByUrlEncoding]];
@@ -617,12 +616,12 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
{
// -----switch weekly report screen via AJAX
- NSString *extraFormString = [NSString stringWithFormat:@"theForm%%3AuserType=notnormal&theForm%%3AvendorType=Y&=&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@",
+ NSString *extraFormString = [NSString stringWithFormat:@"theForm%%3AvendorType=Y&=&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@",
[[dayOptions objectAtIndex:0] stringByUrlEncoding],
[oneWeekOption stringByUrlEncoding]];
- ajaxRequest = [NSURLRequest ajaxRequestWithParameters:weekAjaxParams extraFormString:extraFormString viewState:viewState baseURL:baseURL];
+ ajaxRequest = [NSURLRequest ajaxRequestWithParameters:weekSwitchAjaxParams extraFormString:extraFormString viewState:viewState baseURL:baseURL];
data = [NSURLConnection sendSynchronousRequest:ajaxRequest returningResponse:&response error:&error];
@@ -648,7 +647,7 @@ - (void)loadSalesReportsAtURL:(NSURL *)url
cachePolicy:NSURLRequestReloadIgnoringCacheData
timeoutInterval:60.0];
- bodyString = [NSString stringWithFormat:@"theForm=theForm&theForm%%3AuserType=notnormal&theForm%%3AvendorType=Y&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@&javax.faces.ViewState=%@&theForm%%3AdownloadLabel2=theForm%%3AdownloadLabel2",
+ bodyString = [NSString stringWithFormat:@"theForm=theForm&theForm%%3AuserType=notnormal&theForm%%3AvendorType=Y&theForm%%3AdateType=W&theForm%%3AoptInVar=A&theForm%%3AdatePickerSourceSelectElementSales=%@&theForm%%3AweekPickerSourceSelectElement=%@&javax.faces.ViewState=%@&theForm%%3AdownloadLabel2=theForm%%3AdownloadLabel2",
[[dayOptions objectAtIndex:0] stringByUrlEncoding],
[oneWeekOption stringByUrlEncoding],
[viewState stringByUrlEncoding] ];
View
BIN  MyAppSales.xcodeproj/project.xcworkspace/xcuserdata/Neal.xcuserdatad/UserInterfaceState.xcuserstate
Binary file not shown
Please sign in to comment.
Something went wrong with that request. Please try again.