Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
data-center-auto
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bltdc
data-center-auto
Commits
f60d6fb2
Commit
f60d6fb2
authored
Mar 03, 2023
by
lizefeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
13b563a9
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
2 deletions
+21
-2
ApiServices.cs
AutoTurnOver.Services/ApiServices.cs
+20
-1
Program.cs
ResetOutofstock/Program.cs
+1
-1
No files found.
AutoTurnOver.Services/ApiServices.cs
View file @
f60d6fb2
...
@@ -12,6 +12,7 @@ using System.Text.RegularExpressions;
...
@@ -12,6 +12,7 @@ using System.Text.RegularExpressions;
using
AutoTurnOver.Models.Base
;
using
AutoTurnOver.Models.Base
;
using
System.Threading.Tasks
;
using
System.Threading.Tasks
;
using
AutoTurnOver.Models.ApiDto.Stock
;
using
AutoTurnOver.Models.ApiDto.Stock
;
using
System.Threading
;
namespace
AutoTurnOver.Services
namespace
AutoTurnOver.Services
{
{
...
@@ -262,7 +263,9 @@ namespace AutoTurnOver.Services
...
@@ -262,7 +263,9 @@ namespace AutoTurnOver.Services
/// 获取亚马逊账号
/// 获取亚马逊账号
/// </summary>
/// </summary>
/// <returns></returns>
/// <returns></returns>
public
static
List
<
AmazonAccountDto
>
GetAmazonAccountList
()
public
static
List
<
AmazonAccountDto
>
GetAmazonAccountList
(
int
count
=
0
)
{
try
{
{
string
url
=
ConfigHelper
.
GetValue
(
"Pams_GetAccountToken"
);
string
url
=
ConfigHelper
.
GetValue
(
"Pams_GetAccountToken"
);
string
resultStr
=
HttpHelper
.
Request
(
url
,
RequestType
.
GET
,
""
,
timeout
:
1000
*
60
*
60
*
24
);
string
resultStr
=
HttpHelper
.
Request
(
url
,
RequestType
.
GET
,
""
,
timeout
:
1000
*
60
*
60
*
24
);
...
@@ -277,6 +280,22 @@ namespace AutoTurnOver.Services
...
@@ -277,6 +280,22 @@ namespace AutoTurnOver.Services
}
}
return
result
.
Data
;
return
result
.
Data
;
}
}
catch
(
Exception
ex
)
{
if
(
count
<
20
)
{
Thread
.
Sleep
(
10
*
1000
);
count
++;
return
GetAmazonAccountList
(
count
);
}
else
{
throw
;
}
}
}
public
static
List
<
AccountDto
>
AccountList
(
string
name
)
public
static
List
<
AccountDto
>
AccountList
(
string
name
)
{
{
...
...
ResetOutofstock/Program.cs
View file @
f60d6fb2
...
@@ -57,7 +57,7 @@ namespace ResetOutofstock
...
@@ -57,7 +57,7 @@ namespace ResetOutofstock
//new AmazonDataSynchroService().SynchroReportIds(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_V2_SETTLEMENT_REPORT_DATA_FLAT_FILE_V2, 10);
//new AmazonDataSynchroService().SynchroReportIds(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_V2_SETTLEMENT_REPORT_DATA_FLAT_FILE_V2, 10);
//while (true)
//while (true)
//{
//{
// new AmazonDataSynchroService().AnaReport();
// new AmazonDataSynchroService().AnaReport(
-1
);
//}
//}
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment