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
dce4b572
Commit
dce4b572
authored
Dec 08, 2022
by
lizefeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
796088a3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
7 deletions
+21
-7
report_invest_return_dao.cs
AutoTurnOver.DB/report_invest_return_dao.cs
+16
-2
ReportInvestReturnServices.cs
AutoTurnOver.Services/ReportInvestReturnServices.cs
+2
-2
ReportInvestReturnController.cs
AutoTurnOver/Controllers/ReportInvestReturnController.cs
+2
-2
Program.cs
ResetOutofstock/Program.cs
+1
-1
No files found.
AutoTurnOver.DB/report_invest_return_dao.cs
View file @
dce4b572
...
...
@@ -14,7 +14,7 @@ namespace AutoTurnOver.DB
/// </summary>
public
class
report_invest_return_dao
:
connectionHelper
{
public
static
List
<
dc_report_invest_return_analysis
>
AnaList
(
Condition_ConfigPromotion
m
,
int
offset
,
int
limit
,
ref
int
total
)
public
static
List
<
dc_report_invest_return_analysis
>
AnaList
(
Condition_ConfigPromotion
m
,
int
offset
,
int
limit
,
string
sort
,
string
order
,
ref
int
total
)
{
var
list
=
new
List
<
dc_report_invest_return_analysis
>();
...
...
@@ -27,6 +27,20 @@ namespace AutoTurnOver.DB
total
=
_connection
.
QuerySingleOrDefault
<
int
>(
"select count(0) from ("
+
sql
+
") tb1"
);
if
(!
string
.
IsNullOrEmpty
(
sort
)
&&
!
string
.
IsNullOrEmpty
(
order
))
{
sql
+=
" order by "
+
sort
;
if
(!
string
.
IsNullOrEmpty
(
order
))
{
sql
+=
" "
+
order
;
}
else
{
sql
+=
" asc"
;
}
}
var
obj
=
_connection
.
Query
<
dc_report_invest_return_analysis
>(
sql
+
" limit "
+
offset
+
","
+
limit
);
return
obj
.
AsList
();
...
...
@@ -248,7 +262,7 @@ namespace AutoTurnOver.DB
ana
.
adfee_rate
=
Math
.
Round
(
ana
.
adfee_day_30
.
Division
(
ana
.
amount_total_day_30
),
4
);
// 计算最近1个月的平台费率
ana
.
platform_fee_day_30
=
orders
.
Where
(
s
=>
s
.
paid_time
>=
day30Btime
).
Sum
(
s
=>
s
.
cost_platform_fee
*
s
.
order_to_usd_exchange_rate
);
ana
.
platform_fee_day_30
=
orders
.
Where
(
s
=>
s
.
paid_time
>=
day30Btime
).
Where
(
s
=>
s
.
cost_platform_fee
>
0
).
Sum
(
s
=>
s
.
cost_platform_fee
*
s
.
order_to_usd_exchange_rate
);
ana
.
platform_fee_rate
=
Math
.
Round
(
ana
.
platform_fee_day_30
.
Division
(
ana
.
amount_total_day_30
),
4
);
...
...
AutoTurnOver.Services/ReportInvestReturnServices.cs
View file @
dce4b572
...
...
@@ -15,9 +15,9 @@ namespace AutoTurnOver.Services
/// <param name="limit"></param>
/// <param name="total"></param>
/// <returns></returns>
public
List
<
dc_report_invest_return_analysis
>
AnaList
(
Condition_ConfigPromotion
m
,
int
offset
,
int
limit
,
ref
int
total
)
public
List
<
dc_report_invest_return_analysis
>
AnaList
(
Condition_ConfigPromotion
m
,
int
offset
,
int
limit
,
string
sort
,
string
order
,
ref
int
total
)
{
return
DB
.
report_invest_return_dao
.
AnaList
(
m
,
offset
,
limit
,
ref
total
);
return
DB
.
report_invest_return_dao
.
AnaList
(
m
,
offset
,
limit
,
sort
,
order
,
ref
total
);
}
}
}
AutoTurnOver/Controllers/ReportInvestReturnController.cs
View file @
dce4b572
...
...
@@ -24,7 +24,7 @@ namespace AutoTurnOver.Controllers
{
var
total
=
0
;
var
service
=
new
Services
.
ReportInvestReturnService
();
var
list
=
service
.
AnaList
(
new
Condition_ConfigPromotion
{
},
offset
,
limit
,
ref
total
);
var
list
=
service
.
AnaList
(
new
Condition_ConfigPromotion
{
},
offset
,
limit
,
order
,
sort
,
ref
total
);
return
new
JsonResult
(
new
{
...
...
@@ -37,7 +37,7 @@ namespace AutoTurnOver.Controllers
{
int
total
=
0
;
var
service
=
new
Services
.
ReportInvestReturnService
();
var
list
=
service
.
AnaList
(
new
Condition_ConfigPromotion
{
},
0
,
int
.
MaxValue
,
ref
total
);
var
list
=
service
.
AnaList
(
new
Condition_ConfigPromotion
{
},
0
,
int
.
MaxValue
,
null
,
null
,
ref
total
);
DataTable
table
=
new
DataTable
();
string
[]
cols
=
new
string
[]
{
...
...
ResetOutofstock/Program.cs
View file @
dce4b572
...
...
@@ -48,7 +48,7 @@ namespace ResetOutofstock
// report_invest_return_dao.SynchBtmAdFees();
//report_invest_return_dao.ShareAdFee();
//report_invest_return_dao.SynchBtmOrderRefund();
//report_invest_return_dao.CalculationStockScore(
);
report_invest_return_dao
.
CalculationStockScore
(
"961922201"
);
}
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