Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mall.oytour.com
Project
Project
Details
Activity
Releases
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
黄奎
mall.oytour.com
Commits
ef0a6cdd
Commit
ef0a6cdd
authored
Jul 02, 2020
by
吴春
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.oytour.com/Kui2/mall.oytour.com
parents
4554fa9d
3c829cee
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
154 additions
and
14 deletions
+154
-14
UserSourceEnum.cs
Mall.Common/Enum/User/UserSourceEnum.cs
+6
-1
RB_Goods_OrderAfterSale_Extend.cs
Mall.Model/Extend/Product/RB_Goods_OrderAfterSale_Extend.cs
+9
-0
OrderModule.cs
Mall.Module.Product/OrderModule.cs
+7
-2
RB_Goods_OrderAfterSaleRepository.cs
Mall.Repository/Product/RB_Goods_OrderAfterSaleRepository.cs
+6
-0
TimersHelper.cs
Mall.WindowsService/Helper/TimersHelper.cs
+6
-0
FinanceModule.cs
Mall.WindowsService/Module/FinanceModule.cs
+120
-11
No files found.
Mall.Common/Enum/User/UserSourceEnum.cs
View file @
ef0a6cdd
...
@@ -31,6 +31,11 @@ namespace Mall.Common.Enum.User
...
@@ -31,6 +31,11 @@ namespace Mall.Common.Enum.User
/// 百度
/// 百度
/// </summary>
/// </summary>
[
EnumField
(
"百度"
)]
[
EnumField
(
"百度"
)]
Baidu
=
4
Baidu
=
4
,
/// <summary>
/// H5站点
/// </summary>
[
EnumField
(
"H5"
)]
H5
=
5
}
}
}
}
Mall.Model/Extend/Product/RB_Goods_OrderAfterSale_Extend.cs
View file @
ef0a6cdd
...
@@ -74,5 +74,14 @@ namespace Mall.Model.Extend.Product
...
@@ -74,5 +74,14 @@ namespace Mall.Model.Extend.Product
/// 凭证列表
/// 凭证列表
/// </summary>
/// </summary>
public
List
<
string
>
VoucherList
{
get
;
set
;
}
public
List
<
string
>
VoucherList
{
get
;
set
;
}
/// <summary>
/// 完成开始时间
/// </summary>
public
string
FStartTime
{
get
;
set
;
}
/// <summary>
/// 完成结束时间
/// </summary>
public
string
FEndTime
{
get
;
set
;
}
}
}
}
}
Mall.Module.Product/OrderModule.cs
View file @
ef0a6cdd
...
@@ -5564,6 +5564,7 @@ namespace Mall.Module.Product
...
@@ -5564,6 +5564,7 @@ namespace Mall.Module.Product
if
(
type
==
1
)
if
(
type
==
1
)
{
{
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
OrderStatus
),
OrderStatusEnum
.
Cancel
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
OrderStatus
),
OrderStatusEnum
.
Cancel
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
CancelTime
),
DateTime
.
Now
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
ApplyForCancelStatus
),
1
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
ApplyForCancelStatus
),
1
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
RefundOrderNo
),
RefundOrderNo
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
RefundOrderNo
),
RefundOrderNo
);
}
}
...
@@ -5828,6 +5829,7 @@ namespace Mall.Module.Product
...
@@ -5828,6 +5829,7 @@ namespace Mall.Module.Product
{
{
Dictionary
<
string
,
object
>
keyValues
=
new
Dictionary
<
string
,
object
>()
{
};
Dictionary
<
string
,
object
>
keyValues
=
new
Dictionary
<
string
,
object
>()
{
};
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
OrderStatus
),
OrderStatusEnum
.
Cancel
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
OrderStatus
),
OrderStatusEnum
.
Cancel
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
CancelTime
),
DateTime
.
Now
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
RefundOrderNo
),
RefundOrderNo
);
keyValues
.
Add
(
nameof
(
RB_Goods_Order
.
RefundOrderNo
),
RefundOrderNo
);
if
(
omodel
.
OrderStatus
!=
OrderStatusEnum
.
NonPayment
)
if
(
omodel
.
OrderStatus
!=
OrderStatusEnum
.
NonPayment
)
{
{
...
@@ -6049,10 +6051,13 @@ namespace Mall.Module.Product
...
@@ -6049,10 +6051,13 @@ namespace Mall.Module.Product
}
}
goods_OrderRepository
.
DBSession
.
Commit
();
goods_OrderRepository
.
DBSession
.
Commit
();
if
(
flag
&&
tenantId
==
1
)
if
(
flag
&&
tenantId
==
1
)
{
if
(
omodel
.
OrderStatus
!=
OrderStatusEnum
.
NonPayment
)
{
{
//同意 创建财务单据
//同意 创建财务单据
OrderRefundFinanceModule
(
omodel
,
true
);
OrderRefundFinanceModule
(
omodel
,
true
);
}
}
}
return
flag
;
return
flag
;
}
}
catch
(
Exception
ex
)
catch
(
Exception
ex
)
...
...
Mall.Repository/Product/RB_Goods_OrderAfterSaleRepository.cs
View file @
ef0a6cdd
...
@@ -191,6 +191,12 @@ INNER JOIN rb_member_user mu on mu.Id=oas.UserId
...
@@ -191,6 +191,12 @@ INNER JOIN rb_member_user mu on mu.Id=oas.UserId
{
{
where
+=
$" and oas.
{
nameof
(
RB_Goods_OrderAfterSale
.
OrderDetialId
)}
in(
{
dmodel
.
OrderDetailIds
}
)"
;
where
+=
$" and oas.
{
nameof
(
RB_Goods_OrderAfterSale
.
OrderDetialId
)}
in(
{
dmodel
.
OrderDetailIds
}
)"
;
}
}
if
(!
string
.
IsNullOrEmpty
(
dmodel
.
FStartTime
))
{
where
+=
$" and oas.
{
nameof
(
RB_Goods_OrderAfterSale
.
FinishTime
)}
>='
{
dmodel
.
FStartTime
}
'"
;
}
if
(!
string
.
IsNullOrEmpty
(
dmodel
.
FEndTime
))
{
where
+=
$" and oas.
{
nameof
(
RB_Goods_OrderAfterSale
.
FinishTime
)}
<='
{
dmodel
.
FEndTime
}
23:59:59'"
;
}
string
sql
=
$@"SELECT oas.* FROM rb_goods_orderaftersale oas
{
where
}
order by oas.ReOrderId desc"
;
string
sql
=
$@"SELECT oas.* FROM rb_goods_orderaftersale oas
{
where
}
order by oas.ReOrderId desc"
;
return
Get
<
RB_Goods_OrderAfterSale_Extend
>(
sql
).
ToList
();
return
Get
<
RB_Goods_OrderAfterSale_Extend
>(
sql
).
ToList
();
...
...
Mall.WindowsService/Helper/TimersHelper.cs
View file @
ef0a6cdd
...
@@ -29,6 +29,12 @@ namespace Mall.WindowsService.Helper
...
@@ -29,6 +29,12 @@ namespace Mall.WindowsService.Helper
Module
.
FinanceModule
.
OrderIncomeFinanceModule
();
Module
.
FinanceModule
.
OrderIncomeFinanceModule
();
LogHelper
.
Write
(
"RevenueFinance=====End"
);
LogHelper
.
Write
(
"RevenueFinance=====End"
);
#
region
退款制单
LogHelper
.
Write
(
"AutoCreateFinanceRefund=====Start"
);
Module
.
FinanceModule
.
AutoCreateFinanceRefund
();
LogHelper
.
Write
(
"AutoCreateFinanceRefund=====End"
);
#
endregion
Interlocked
.
Exchange
(
ref
inTimer
,
0
);
Interlocked
.
Exchange
(
ref
inTimer
,
0
);
}
}
}
}
...
...
Mall.WindowsService/Module/FinanceModule.cs
View file @
ef0a6cdd
...
@@ -91,6 +91,10 @@ namespace Mall.WindowsService.Module
...
@@ -91,6 +91,10 @@ namespace Mall.WindowsService.Module
/// 订单明细
/// 订单明细
/// </summary>
/// </summary>
private
static
RB_Goods_OrderDetailRepository
goods_OrderDetailRepository
=
new
RB_Goods_OrderDetailRepository
();
private
static
RB_Goods_OrderDetailRepository
goods_OrderDetailRepository
=
new
RB_Goods_OrderDetailRepository
();
/// <summary>
/// 售后订单流程
/// </summary>
private
static
RB_Goods_OrderAfterSaleLogRepository
goods_OrderAfterSaleLogRepository
=
new
RB_Goods_OrderAfterSaleLogRepository
();
#
region
收入
#
region
收入
...
@@ -981,16 +985,17 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -981,16 +985,17 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
{
{
if
(
item
.
StartTime
.
HasValue
&&
item
.
StartTime
<
System
.
DateTime
.
Now
)
//判断开始时间是否大于当前时间
if
(
item
.
StartTime
.
HasValue
&&
item
.
StartTime
<
System
.
DateTime
.
Now
)
//判断开始时间是否大于当前时间
{
{
//查询
今天
是否已经生成了财务单据
//查询
最近
是否已经生成了财务单据
var
addFinance
=
false
;
var
addFinance
=
false
;
DateTime
startDate
=
System
.
DateTime
.
Now
.
AddDays
(-
1
);
DateTime
startDate
=
System
.
DateTime
.
Now
.
AddDays
(-
1
);
var
recordModel
=
financeRecordRepository
.
GetList
(
new
RB_Finance_Record_Extend
{
TenantId
=
item
.
TenantId
,
MallBaseId
=
item
.
MallBaseId
,
Type
=
3
}).
OrderByDescending
(
x
=>
x
.
CreateDate
).
FirstOrDefault
();
var
recordModel
=
financeRecordRepository
.
GetList
(
new
RB_Finance_Record_Extend
{
TenantId
=
item
.
TenantId
,
MallBaseId
=
item
.
MallBaseId
,
Type
=
3
}).
OrderByDescending
(
x
=>
x
.
CreateDate
).
FirstOrDefault
();
if
(
recordModel
==
null
)
//
今天
没生成单据
if
(
recordModel
==
null
)
//没生成单据
{
{
if
(
Convert
.
ToDateTime
(
item
.
StartTime
.
Value
.
AddDays
(
item
.
IntervalDay
??
0
).
ToString
(
"yyyy-MM-dd 00:00:00"
))
<=
Convert
.
ToDateTime
(
System
.
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd 00:00:00"
)))
//判断开始时间加上执行周期是否等于当前日期
if
(
Convert
.
ToDateTime
(
item
.
StartTime
.
Value
.
AddDays
(
item
.
IntervalDay
??
0
).
ToString
(
"yyyy-MM-dd 00:00:00"
))
<=
Convert
.
ToDateTime
(
System
.
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd 00:00:00"
)))
//判断开始时间加上执行周期是否等于当前日期
{
{
startDate
=
item
.
StartTime
.
Value
;
//startDate = item.StartTime.Value;
startDate
=
Convert
.
ToDateTime
(
"2020-07-01"
);
addFinance
=
true
;
addFinance
=
true
;
}
}
}
}
...
@@ -1008,8 +1013,11 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1008,8 +1013,11 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
//查询所有的退款
//查询所有的退款
var
olist
=
goods_OrderRepository
.
GetOrderRefunedCreateList
(
item
.
TenantId
,
item
.
MallBaseId
,
startDate
.
ToString
(
"yyyy-MM-dd"
),
endDate
.
ToString
(
"yyyy-MM-dd"
));
var
olist
=
goods_OrderRepository
.
GetOrderRefunedCreateList
(
item
.
TenantId
,
item
.
MallBaseId
,
startDate
.
ToString
(
"yyyy-MM-dd"
),
endDate
.
ToString
(
"yyyy-MM-dd"
));
//查询所有的售后退款
//查询所有的售后退款
goods_OrderAfterSaleRepository
.
GetList
(
new
RB_Goods_OrderAfterSale_Extend
()
{
});
var
afterlist
=
goods_OrderAfterSaleRepository
.
GetList
(
new
RB_Goods_OrderAfterSale_Extend
()
{
FStartTime
=
startDate
.
ToString
(
"yyyy-MM-dd"
),
FEndTime
=
endDate
.
AddDays
(-
1
).
ToString
(
"yyyy-MM-dd"
),
TenantId
=
item
.
TenantId
,
MallBaseId
=
item
.
MallBaseId
,
Type
=
1
,
ReOrderStatus
=
OrderAfterSaleStatusEnum
.
Completed
});
OrderRefundFinanceModule
(
olist
);
if
(
olist
.
Any
()
||
afterlist
.
Any
())
{
OrderRefundFinanceModule
(
olist
,
afterlist
);
}
}
}
}
}
}
}
...
@@ -1030,7 +1038,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1030,7 +1038,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
/// </summary>
/// </summary>
/// <param name="omodel"></param>
/// <param name="omodel"></param>
/// <returns></returns>
/// <returns></returns>
public
static
bool
OrderRefundFinanceModule
(
List
<
RB_Goods_Order_Extend
>
oList
)
public
static
bool
OrderRefundFinanceModule
(
List
<
RB_Goods_Order_Extend
>
oList
,
List
<
RB_Goods_OrderAfterSale_Extend
>
afterList
)
{
{
var
flag
=
false
;
var
flag
=
false
;
try
try
...
@@ -1044,12 +1052,13 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1044,12 +1052,13 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
RB_Finance_Record_Extend
record
=
new
RB_Finance_Record_Extend
();
RB_Finance_Record_Extend
record
=
new
RB_Finance_Record_Extend
();
record
.
MallBaseId
=
item
.
MallBaseId
;
record
.
MallBaseId
=
item
.
MallBaseId
;
record
.
TenantId
=
item
.
TenantId
;
record
.
TenantId
=
item
.
TenantId
;
record
.
Type
=
1
;
record
.
Type
=
3
;
record
.
CreateDate
=
System
.
DateTime
.
Now
;
record
.
CreateDate
=
System
.
DateTime
.
Now
;
record
.
RecordDetailList
=
new
List
<
RB_Finance_RecordDetail
>();
record
.
RecordDetailList
=
new
List
<
RB_Finance_RecordDetail
>();
decimal
TotalMoney
=
0
;
decimal
TotalMoney
=
0
;
var
detailList
=
new
List
<
object
>();
var
detailList
=
new
List
<
object
>();
//订单退款
foreach
(
var
omodel
in
oList
)
foreach
(
var
omodel
in
oList
)
{
{
decimal
Money
=
omodel
.
Income
??
0
;
decimal
Money
=
omodel
.
Income
??
0
;
...
@@ -1058,7 +1067,6 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1058,7 +1067,6 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
var
umodel
=
member_UserRepository
.
GetEntity
(
omodel
.
UserId
);
var
umodel
=
member_UserRepository
.
GetEntity
(
omodel
.
UserId
);
if
(
umodel
==
null
)
{
return
false
;
}
if
(
umodel
==
null
)
{
return
false
;
}
string
dstr
=
"客人付款:"
+
(
omodel
.
Income
??
0
)
+
"金额,退款:"
+
(
omodel
.
Income
??
0
);
detailList
.
Add
(
detailList
.
Add
(
new
new
{
{
...
@@ -1066,7 +1074,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1066,7 +1074,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
Number
=
1
,
Number
=
1
,
OriginalMoney
=
Money
,
OriginalMoney
=
Money
,
UnitPrice
=
Money
,
UnitPrice
=
Money
,
Remark
=
"订单号:"
+
omodel
.
OrderNo
+
" "
+
dstr
Remark
=
omodel
.
OrderNo
}
}
);
);
...
@@ -1080,7 +1088,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1080,7 +1088,7 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
MallBaseId
=
record
.
MallBaseId
,
MallBaseId
=
record
.
MallBaseId
,
FinanceId
=
0
,
FinanceId
=
0
,
CreateDate
=
record
.
CreateDate
,
CreateDate
=
record
.
CreateDate
,
Name
=
""
,
Name
=
"
订单取消退款
"
,
OrderId
=
omodel
.
OrderId
,
OrderId
=
omodel
.
OrderId
,
OrderDetailId
=
0
,
OrderDetailId
=
0
,
GoodsPrice
=
0
,
GoodsPrice
=
0
,
...
@@ -1090,6 +1098,49 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1090,6 +1098,49 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
};
};
record
.
RecordDetailList
.
Add
(
financeRecordDetail
);
record
.
RecordDetailList
.
Add
(
financeRecordDetail
);
}
}
//售后退款
foreach
(
var
dmodel
in
afterList
)
{
decimal
Money
=
dmodel
.
Refund
??
0
;
TotalMoney
+=
Money
;
//查询用户
var
umodel
=
member_UserRepository
.
GetEntity
(
dmodel
.
UserId
);
if
(
umodel
==
null
)
{
return
false
;
}
var
omodel
=
goods_OrderRepository
.
GetEntity
(
dmodel
.
OrderId
);
if
(
omodel
==
null
)
{
return
false
;
}
string
dstr
=
"客人付款:"
+
(
dmodel
.
Income
??
0
)
+
",退款:"
+
(
dmodel
.
Refund
??
0
);
detailList
.
Add
(
new
{
CostTypeId
=
item
.
RefundCostTypeId
,
Number
=
1
,
OriginalMoney
=
Money
,
UnitPrice
=
Money
,
Remark
=
"订单号:"
+
omodel
.
OrderNo
+
" 售后单号:"
+
(
dmodel
.
ReOrderNo
??
"暂无"
)
+
" "
+
dstr
}
);
RB_Finance_RecordDetail
financeRecordDetail
=
new
RB_Finance_RecordDetail
{
ID
=
0
,
RecordId
=
0
,
Type
=
record
.
Type
,
TenantId
=
record
.
TenantId
,
MallBaseId
=
record
.
MallBaseId
,
FinanceId
=
0
,
CreateDate
=
record
.
CreateDate
,
Name
=
"售后退款"
,
OrderId
=
omodel
.
OrderId
,
OrderDetailId
=
dmodel
.
OrderDetialId
??
0
,
GoodsPrice
=
0
,
FreightMoney
=
0
,
Unit_Price
=
Money
,
Number
=
1
};
record
.
RecordDetailList
.
Add
(
financeRecordDetail
);
}
item
.
IsPublic
=
8
;
//默认原路退款
item
.
IsPublic
=
8
;
//默认原路退款
string
Remark
=
System
.
DateTime
.
Now
.
ToString
(
"yyyy年MM月dd日"
)
+
" 自动生成财务单据"
;
string
Remark
=
System
.
DateTime
.
Now
.
ToString
(
"yyyy年MM月dd日"
)
+
" 自动生成财务单据"
;
...
@@ -1125,10 +1176,68 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
...
@@ -1125,10 +1176,68 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
{
{
record
.
FinanceId
=
frid
;
record
.
FinanceId
=
frid
;
int
recordId
=
financeRecordRepository
.
Insert
(
record
);
int
recordId
=
financeRecordRepository
.
Insert
(
record
);
Helper
.
LogHelper
.
Write
(
"
财务
单据ID:"
+
frid
+
",记录id:"
+
recordId
+
"订单数量:"
+
record
.
RecordDetailList
.
Count
());
Helper
.
LogHelper
.
Write
(
"
退款
单据ID:"
+
frid
+
",记录id:"
+
recordId
+
"订单数量:"
+
record
.
RecordDetailList
.
Count
());
record
.
RecordDetailList
.
ForEach
(
x
=>
x
.
RecordId
=
recordId
);
record
.
RecordDetailList
.
ForEach
(
x
=>
x
.
RecordId
=
recordId
);
record
.
RecordDetailList
.
ForEach
(
x
=>
x
.
FinanceId
=
frid
);
record
.
RecordDetailList
.
ForEach
(
x
=>
x
.
FinanceId
=
frid
);
flag
=
financeRecordDetailRepository
.
InsertBatch
(
record
.
RecordDetailList
);
flag
=
financeRecordDetailRepository
.
InsertBatch
(
record
.
RecordDetailList
);
foreach
(
var
omodel
in
oList
)
{
Dictionary
<
string
,
object
>
keyValues
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Goods_Order_Extend
.
Remark
),
omodel
.
Remark
+
" 自动生成财务退款单据:"
+
frid
}
};
List
<
WhereHelper
>
wheres
=
new
List
<
WhereHelper
>()
{
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_Order_Extend
.
OrderId
),
FiledValue
=
omodel
.
OrderId
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_Order_Extend
.
TenantId
),
FiledValue
=
omodel
.
TenantId
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_Order_Extend
.
MallBaseId
),
FiledValue
=
omodel
.
MallBaseId
,
OperatorEnum
=
OperatorEnum
.
Equal
}
};
//goods_OrderRepository.Update(keyValues, wheres);
}
foreach
(
var
dmodel
in
afterList
)
{
Dictionary
<
string
,
object
>
keyValues
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Goods_OrderAfterSale
.
ReRemark
),
dmodel
.
ReRemark
+
" 自动生成财务退款单据:"
+
frid
},
{
nameof
(
RB_Goods_OrderAfterSale
.
FinanceId
),
frid
},
};
List
<
WhereHelper
>
wheres
=
new
List
<
WhereHelper
>()
{
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderAfterSale
.
ReOrderId
),
FiledValue
=
dmodel
.
ReOrderId
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderAfterSale
.
TenantId
),
FiledValue
=
dmodel
.
TenantId
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderAfterSale
.
MallBaseId
),
FiledValue
=
dmodel
.
MallBaseId
,
OperatorEnum
=
OperatorEnum
.
Equal
}
};
//goods_OrderAfterSaleRepository.Update(keyValues, wheres);
goods_OrderAfterSaleLogRepository
.
Insert
(
new
RB_Goods_OrderAfterSaleLog
()
{
Id
=
0
,
Content
=
"自动生成财务退款单据:"
+
frid
,
CreateDate
=
DateTime
.
Now
,
MallBaseId
=
dmodel
.
MallBaseId
,
ReOrderId
=
dmodel
.
ReOrderId
,
TenantId
=
dmodel
.
TenantId
,
Type
=
2
});
}
}
}
Helper
.
LogHelper
.
Write
(
apiResult
);
Helper
.
LogHelper
.
Write
(
apiResult
);
}
}
...
...
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