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
4849b387
Commit
4849b387
authored
Aug 18, 2020
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交
parent
8fc11fff
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
90 additions
and
2 deletions
+90
-2
OrderModule.cs
Mall.Module.Product/OrderModule.cs
+57
-0
SmallShopsModule.cs
Mall.Module.User/SmallShopsModule.cs
+2
-0
OrderController.cs
Mall.WebApi/Controllers/Product/OrderController.cs
+31
-2
No files found.
Mall.Module.Product/OrderModule.cs
View file @
4849b387
...
...
@@ -8767,6 +8767,63 @@ namespace Mall.Module.Product
return
flag
;
}
/// <summary>
/// 修改商品订单成本价
/// </summary>
/// <param name="orderId"></param>
/// <param name="income"></param>
/// <param name="freightMoney"></param>
/// <param name="tenantId"></param>
/// <param name="mallBaseId"></param>
/// <returns></returns>
public
bool
SetOrderSupplierId
(
int
orderId
,
int
SupplierId
,
int
tenantId
,
int
mallBaseId
)
{
var
orderModel
=
goods_OrderDetailRepository
.
GetEntity
(
orderId
);
if
(
orderModel
==
null
)
{
return
false
;
}
Dictionary
<
string
,
object
>
keyValues1
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Goods_OrderDetail
.
SupplierId
),
SupplierId
}
};
List
<
WhereHelper
>
wheres1
=
new
List
<
WhereHelper
>()
{
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderDetail
.
Id
),
FiledValue
=
orderModel
.
Id
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderDetail
.
TenantId
),
FiledValue
=
tenantId
,
OperatorEnum
=
OperatorEnum
.
Equal
},
new
WhereHelper
(){
FiledName
=
nameof
(
RB_Goods_OrderDetail
.
MallBaseId
),
FiledValue
=
mallBaseId
,
OperatorEnum
=
OperatorEnum
.
Equal
}
};
var
flag
=
goods_OrderDetailRepository
.
Update
(
keyValues1
,
wheres1
);
if
(
flag
)
{
//记录日志
Task
.
Run
(()
=>
goods_LogRepository
.
Insert
(
new
RB_Goods_Log
()
{
Content
=
"修改订单商品:"
+
orderModel
.
GoodsName
+
"供应商ID:"
+
SupplierId
+
";供应商历史ID:"
+
orderModel
.
SupplierId
.
ToString
(),
CreateDate
=
DateTime
.
Now
,
Id
=
0
,
MallBaseId
=
mallBaseId
,
SourceId
=
orderModel
.
OrderId
,
TenantId
=
tenantId
,
Type
=
1
}));
}
return
flag
;
}
/// <summary>
/// 根据订单好获取物流id
/// </summary>
...
...
Mall.Module.User/SmallShopsModule.cs
View file @
4849b387
...
...
@@ -288,6 +288,8 @@ namespace Mall.Module.User
CanRemitMoney
,
basicsModel
.
MaxWithdrawal
,
basicsModel
.
WithdrawalFree
,
basicsModel
.
IsAllCommission
,
basicsModel
.
MinWithdrawal
,
IsWithdrawAll
=
1
,
WithdrawWayList
=
WayList
.
Select
(
x
=>
new
{
...
...
Mall.WebApi/Controllers/Product/OrderController.cs
View file @
4849b387
...
...
@@ -79,6 +79,7 @@ namespace Mall.WebApi.Controllers.MallBase
PaymentWayName
=
x
.
PaymentWay
.
GetEnumName
(),
DetailList
=
x
.
DetailList
.
Select
(
y
=>
new
{
y
.
SupplierId
,
y
.
SupplierName
,
y
.
FreightCostMoney
,
y
.
FreightMoney
,
...
...
@@ -944,7 +945,7 @@ namespace Mall.WebApi.Controllers.MallBase
#
region
修改运费成本以及商品成本
#
region
修改运费成本以及商品成本
、供应商
/// <summary>
/// 修改订单商品成本运费
/// </summary>
...
...
@@ -1007,7 +1008,35 @@ namespace Mall.WebApi.Controllers.MallBase
}
}
/// <summary>
/// 修改订单供应商
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
SetOrderSupplierId
()
{
var
req
=
RequestParm
;
JObject
parms
=
JObject
.
Parse
(
req
.
msg
.
ToString
());
int
OrderId
=
parms
.
GetInt
(
"Id"
,
0
);
int
SupplierId
=
parms
.
GetInt
(
"SupplierId"
,
0
);
if
(
OrderId
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递订单明细id"
);
}
if
(
SupplierId
<
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递供应商信息"
);
}
bool
flag
=
orderModule
.
SetOrderSupplierId
(
OrderId
,
SupplierId
,
req
.
TenantId
,
req
.
MallBaseId
);
if
(
flag
)
{
return
ApiResult
.
Success
();
}
else
{
return
ApiResult
.
Failed
();
}
}
#
endregion
#
endregion
...
...
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