@@ -18,7 +18,7 @@ public ReportManager(AmazonConnection amazonConnection)
18
18
19
19
#region feedback
20
20
public List < FeedbackOrderRow > GetFeedbackFromDays ( int days ) =>
21
- GetFeedbackFromDaysAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
21
+ Task . Run ( ( ) => GetFeedbackFromDaysAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
22
22
public async Task < List < FeedbackOrderRow > > GetFeedbackFromDaysAsync ( int days )
23
23
{
24
24
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
@@ -43,15 +43,15 @@ private async Task<string> GetFeedbackFromDateAsync(AmazonConnection amazonConne
43
43
44
44
#region Reimbursement
45
45
public IList < ReimbursementsOrderRow > GetReimbursementsOrder ( int days ) =>
46
- GetReimbursementsOrderAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
46
+ Task . Run ( ( ) => GetReimbursementsOrderAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
47
47
public async Task < IList < ReimbursementsOrderRow > > GetReimbursementsOrderAsync ( int days )
48
48
{
49
49
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
50
50
DateTime toDate = DateTime . UtcNow ;
51
51
return await GetReimbursementsOrderAsync ( fromDate , toDate ) ;
52
52
}
53
53
public IList < ReimbursementsOrderRow > GetReimbursementsOrder ( DateTime fromDate , DateTime toDate ) =>
54
- GetReimbursementsOrderAsync ( fromDate , toDate ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
54
+ Task . Run ( ( ) => GetReimbursementsOrderAsync ( fromDate , toDate ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
55
55
public async Task < IList < ReimbursementsOrderRow > > GetReimbursementsOrderAsync ( DateTime fromDate , DateTime toDate )
56
56
{
57
57
var path = await GetReimbursementsOrderAsync ( _amazonConnection , fromDate , toDate ) ;
@@ -67,7 +67,7 @@ private async Task<string> GetReimbursementsOrderAsync(AmazonConnection amazonCo
67
67
68
68
#region ReturnFBAOrder
69
69
public List < ReturnFBAOrderRow > GetReturnFBAOrder ( int days ) =>
70
- GetReturnFBAOrderAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
70
+ Task . Run ( ( ) => GetReturnFBAOrderAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
71
71
public async Task < List < ReturnFBAOrderRow > > GetReturnFBAOrderAsync ( int days )
72
72
{
73
73
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
@@ -76,7 +76,7 @@ public async Task<List<ReturnFBAOrderRow>> GetReturnFBAOrderAsync(int days)
76
76
}
77
77
78
78
public List < ReturnFBAOrderRow > GetReturnFBAOrder ( DateTime fromDate , DateTime toDate ) =>
79
- GetReturnFBAOrderAsync ( fromDate , toDate ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
79
+ Task . Run ( ( ) => GetReturnFBAOrderAsync ( fromDate , toDate ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
80
80
public async Task < List < ReturnFBAOrderRow > > GetReturnFBAOrderAsync ( DateTime fromDate , DateTime toDate )
81
81
{
82
82
var path = await GetReturnFBAOrderAsync ( _amazonConnection , fromDate , toDate ) ;
@@ -95,15 +95,15 @@ private async Task<string> GetReturnFBAOrderAsync(AmazonConnection amazonConnect
95
95
96
96
#region ReturnFBMOrder
97
97
public List < ReturnFBMOrderRow > GetReturnMFNOrder ( int days ) =>
98
- GetReturnMFNOrderAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
98
+ Task . Run ( ( ) => GetReturnMFNOrderAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
99
99
public async Task < List < ReturnFBMOrderRow > > GetReturnMFNOrderAsync ( int days )
100
100
{
101
101
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
102
102
DateTime toDate = DateTime . UtcNow ;
103
103
return await GetReturnMFNOrderAsync ( fromDate , toDate ) ;
104
104
}
105
105
public List < ReturnFBMOrderRow > GetReturnMFNOrder ( DateTime fromDate , DateTime toDate ) =>
106
- GetReturnMFNOrderAsync ( fromDate , toDate ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
106
+ Task . Run ( ( ) => GetReturnMFNOrderAsync ( fromDate , toDate ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
107
107
public async Task < List < ReturnFBMOrderRow > > GetReturnMFNOrderAsync ( DateTime fromDate , DateTime toDate )
108
108
{
109
109
List < ReturnFBMOrderRow > list = new List < ReturnFBMOrderRow > ( ) ;
@@ -125,7 +125,7 @@ private async Task<string> GetReturnMFNOrderAsync(AmazonConnection amazonConnect
125
125
126
126
#region Settlement
127
127
public List < SettlementOrderRow > GetSettlementOrder ( int days ) =>
128
- GetSettlementOrderAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
128
+ Task . Run ( ( ) => GetSettlementOrderAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
129
129
public async Task < List < SettlementOrderRow > > GetSettlementOrderAsync ( int days )
130
130
{
131
131
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
@@ -168,7 +168,7 @@ private string GetInventoryQty(AmazonConnection amazonConnection)
168
168
169
169
#region GetInventoryAging
170
170
public List < InventoryAgingRow > GetInventoryAging ( ) =>
171
- GetInventoryAgingAsync ( ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
171
+ Task . Run ( ( ) => GetInventoryAgingAsync ( ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
172
172
public async Task < List < InventoryAgingRow > > GetInventoryAgingAsync ( )
173
173
{
174
174
var path = await GetInventoryAgingAsync ( _amazonConnection ) ;
@@ -183,7 +183,7 @@ private async Task<string> GetInventoryAgingAsync(AmazonConnection amazonConnect
183
183
184
184
#region Products
185
185
public List < ProductsRow > GetProducts ( ) =>
186
- GetProductsAsync ( ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
186
+ Task . Run ( ( ) => GetProductsAsync ( ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
187
187
public async Task < List < ProductsRow > > GetProductsAsync ( )
188
188
{
189
189
var path = await GetProductsAsync ( _amazonConnection ) ;
@@ -198,7 +198,7 @@ private async Task<string> GetProductsAsync(AmazonConnection amazonConnection)
198
198
199
199
#region Orders
200
200
public List < OrdersRow > GetOrdersByLastUpdate ( int days ) =>
201
- GetOrdersByLastUpdateAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
201
+ Task . Run ( ( ) => GetOrdersByLastUpdateAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
202
202
public async Task < List < OrdersRow > > GetOrdersByLastUpdateAsync ( int days )
203
203
{
204
204
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
@@ -223,15 +223,15 @@ private async Task<string> GetOrdersByLastUpdateAsync(AmazonConnection amazonCon
223
223
}
224
224
225
225
public List < OrdersRow > GetOrdersByOrderDate ( int days ) =>
226
- GetOrdersByOrderDateAsync ( days ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
226
+ Task . Run ( ( ) => GetOrdersByOrderDateAsync ( days ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
227
227
public async Task < List < OrdersRow > > GetOrdersByOrderDateAsync ( int days )
228
228
{
229
229
DateTime fromDate = DateTime . UtcNow . AddDays ( - 1 * days ) ;
230
230
DateTime toDate = DateTime . UtcNow ;
231
231
return await GetOrdersByOrderDateAsync ( fromDate , toDate ) ;
232
232
}
233
233
public List < OrdersRow > GetOrdersByOrderDate ( DateTime fromDate , DateTime toDate ) =>
234
- GetOrdersByOrderDateAsync ( fromDate , toDate ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
234
+ Task . Run ( ( ) => GetOrdersByOrderDateAsync ( fromDate , toDate ) ) . ConfigureAwait ( false ) . GetAwaiter ( ) . GetResult ( ) ;
235
235
public async Task < List < OrdersRow > > GetOrdersByOrderDateAsync ( DateTime fromDate , DateTime toDate )
236
236
{
237
237
List < OrdersRow > list = new List < OrdersRow > ( ) ;
0 commit comments