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
b75cd44b
Commit
b75cd44b
authored
Feb 18, 2024
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增评论标签表
parent
86e5dac1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
424 additions
and
114 deletions
+424
-114
RB_Goods_Comment.cs
Mall.Model/Entity/Product/RB_Goods_Comment.cs
+5
-0
RB_Goods_DistributionCommission.cs
Mall.Model/Entity/Product/RB_Goods_DistributionCommission.cs
+2
-5
RB_Goods_Specification_Extend.cs
Mall.Model/Extend/Product/RB_Goods_Specification_Extend.cs
+13
-0
OrderModule.cs
Mall.Module.Product/OrderModule.cs
+88
-0
OrderModule_Part.cs
Mall.Module.Product/OrderModule_Part.cs
+60
-38
ProductModule.cs
Mall.Module.Product/ProductModule.cs
+143
-59
RB_Goods_CommentRepository.cs
Mall.Repository/Product/RB_Goods_CommentRepository.cs
+2
-5
OrderController.cs
Mall.WebApi/Controllers/Product/OrderController.cs
+111
-7
No files found.
Mall.Model/Entity/Product/RB_Goods_Comment.cs
View file @
b75cd44b
...
@@ -200,5 +200,10 @@ namespace Mall.Model.Entity.Product
...
@@ -200,5 +200,10 @@ namespace Mall.Model.Entity.Product
/// 门店id
/// 门店id
/// </summary>
/// </summary>
public
int
StoreId
{
get
;
set
;
}
public
int
StoreId
{
get
;
set
;
}
/// <summary>
/// 评论标签Id
/// </summary>
public
int
LabelId
{
get
;
set
;
}
}
}
}
}
Mall.Model/Entity/Product/RB_Goods_DistributionCommission.cs
View file @
b75cd44b
using
VT.FW.DB
;
using
System
;
using
Mall.Common.Enum.User
;
using
VT.FW.DB
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
namespace
Mall.Model.Entity.Product
namespace
Mall.Model.Entity.Product
{
{
...
...
Mall.Model/Extend/Product/RB_Goods_Specification_Extend.cs
View file @
b75cd44b
...
@@ -23,4 +23,17 @@ namespace Mall.Model.Extend.Product
...
@@ -23,4 +23,17 @@ namespace Mall.Model.Extend.Product
/// </summary>
/// </summary>
public
List
<
RB_Goods_SpecificationValue_Extend
>
SpecificationValueList
{
get
;
set
;
}
public
List
<
RB_Goods_SpecificationValue_Extend
>
SpecificationValueList
{
get
;
set
;
}
}
}
public
class
DateItem
{
/// <summary>
/// 年份
/// </summary>
public
int
YearStr
{
get
;
set
;
}
public
string
MonthStr
{
get
;
set
;
}
public
string
DayStr
{
get
;
set
;
}
}
}
}
Mall.Module.Product/OrderModule.cs
View file @
b75cd44b
...
@@ -25,6 +25,7 @@ using Newtonsoft.Json.Linq;
...
@@ -25,6 +25,7 @@ using Newtonsoft.Json.Linq;
using
System
;
using
System
;
using
System.Collections.Generic
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Linq
;
using
System.Text
;
using
System.Threading.Tasks
;
using
System.Threading.Tasks
;
using
VT.FW.DB
;
using
VT.FW.DB
;
...
@@ -402,6 +403,11 @@ namespace Mall.Module.Product
...
@@ -402,6 +403,11 @@ namespace Mall.Module.Product
private
readonly
Repository
.
TradePavilion
.
RB_Custom_FormRepository
custom_FormRepository
=
new
Repository
.
TradePavilion
.
RB_Custom_FormRepository
();
private
readonly
Repository
.
TradePavilion
.
RB_Custom_FormRepository
custom_FormRepository
=
new
Repository
.
TradePavilion
.
RB_Custom_FormRepository
();
/// <summary>
/// 评论标签仓储层对象
/// </summary>
private
readonly
RB_Comment_LabelRepository
comment_LabelRepository
=
new
RB_Comment_LabelRepository
();
#
region
购物车
#
region
购物车
/// <summary>
/// <summary>
...
@@ -9266,5 +9272,87 @@ namespace Mall.Module.Product
...
@@ -9266,5 +9272,87 @@ namespace Mall.Module.Product
}
}
return
list
;
return
list
;
}
}
#
region
评论标签管理
/// <summary>
/// 获取评论标签分页列表
/// </summary>
/// <param name="pageIndex"></param>
/// <param name="pageSize"></param>
/// <param name="totalCount"></param>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Comment_Label_Extend
>
GetCommentLabelPageModule
(
int
pageIndex
,
int
pageSize
,
out
long
totalCount
,
RB_Comment_Label_Extend
query
)
{
var
list
=
comment_LabelRepository
.
GetCommentLabelPageRepository
(
pageIndex
,
pageSize
,
out
totalCount
,
query
);
return
list
;
}
/// <summary>
/// 获取评论标签列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Comment_Label_Extend
>
GetCommentLabelListModule
(
RB_Comment_Label_Extend
query
)
{
var
list
=
comment_LabelRepository
.
GetCommentLabelListRepository
(
query
);
return
list
;
}
/// <summary>
/// 新增修改评论标签
/// </summary>
/// <param name="model"></param>
/// <returns></returns>
public
bool
SetCommentLabelModule
(
RB_Comment_Label_Extend
model
)
{
bool
flag
=
false
;
if
(
model
.
Id
>
0
)
{
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Comment_Label_Extend
.
Name
),
model
.
Name
},
{
nameof
(
RB_Comment_Label_Extend
.
UpdateDate
),
model
.
UpdateDate
},
};
flag
=
comment_LabelRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_Comment_Label_Extend
.
Id
),
model
.
Id
));
}
else
{
var
newId
=
comment_LabelRepository
.
Insert
(
model
);
model
.
Id
=
newId
;
flag
=
newId
>
0
;
}
return
flag
;
}
/// <summary>
/// 根据编号获取频率标签
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public
RB_Comment_Label_Extend
GetCommentLabelModule
(
int
Id
)
{
var
extModel
=
comment_LabelRepository
.
GetEntity
<
RB_Comment_Label_Extend
>(
Id
);
return
extModel
;
}
/// <summary>
/// 根据编号删除评论标签
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public
bool
RemoveCommentLabelModule
(
int
Id
)
{
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Comment_Label_Extend
.
Status
),
1
},
{
nameof
(
RB_Comment_Label_Extend
.
UpdateDate
),
DateTime
.
Now
},
};
var
flag
=
comment_LabelRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_Comment_Label_Extend
.
Id
),
Id
));
return
flag
;
}
#
endregion
}
}
}
}
Mall.Module.Product/OrderModule_Part.cs
View file @
b75cd44b
This diff is collapsed.
Click to expand it.
Mall.Module.Product/ProductModule.cs
View file @
b75cd44b
This diff is collapsed.
Click to expand it.
Mall.Repository/Product/RB_Goods_CommentRepository.cs
View file @
b75cd44b
using
System
;
using
Mall.Model.Entity.Product
;
using
System.Collections.Generic
;
using
System.Text
;
using
Mall.Model.Entity.Product
;
using
Mall.Model.Extend.Product
;
using
Mall.Model.Extend.Product
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Linq
;
using
Mall.Model.Entity.User
;
namespace
Mall.Repository.Product
namespace
Mall.Repository.Product
{
{
...
...
Mall.WebApi/Controllers/Product/OrderController.cs
View file @
b75cd44b
...
@@ -20,6 +20,7 @@ using Microsoft.AspNetCore.Http;
...
@@ -20,6 +20,7 @@ using Microsoft.AspNetCore.Http;
using
Microsoft.Extensions.Configuration
;
using
Microsoft.Extensions.Configuration
;
using
Microsoft.Extensions.Configuration.Json
;
using
Microsoft.Extensions.Configuration.Json
;
using
Mall.AOP
;
using
Mall.AOP
;
using
Consul
;
namespace
Mall.WebApi.Controllers.MallBase
namespace
Mall.WebApi.Controllers.MallBase
{
{
...
@@ -711,18 +712,19 @@ namespace Mall.WebApi.Controllers.MallBase
...
@@ -711,18 +712,19 @@ namespace Mall.WebApi.Controllers.MallBase
List
<
object
>
result
=
new
List
<
object
>();
List
<
object
>
result
=
new
List
<
object
>();
foreach
(
var
item
in
list
)
foreach
(
var
item
in
list
)
{
{
if
(
item
.
Value
==
"1"
||
item
.
Value
==
"5"
||
item
.
Value
==
"6"
||
item
.
Value
==
"7"
)
if
(
item
.
Value
==
"1"
||
item
.
Value
==
"5"
||
item
.
Value
==
"6"
||
item
.
Value
==
"7"
)
{
{
result
.
Add
(
new
{
Id
=
Convert
.
ToInt32
(
item
.
Value
),
Name
=
item
.
Key
});
result
.
Add
(
new
{
Id
=
Convert
.
ToInt32
(
item
.
Value
),
Name
=
item
.
Key
});
}
}
else
if
(
item
.
Value
==
"3"
)
else
if
(
item
.
Value
==
"3"
)
{
{
result
.
Add
(
new
{
Id
=
Convert
.
ToInt32
(
item
.
Value
),
Name
=
"待出团"
});
result
.
Add
(
new
{
Id
=
Convert
.
ToInt32
(
item
.
Value
),
Name
=
"待出团"
});
}
}
}
}
return
ApiResult
.
Success
(
""
,
result
);
return
ApiResult
.
Success
(
""
,
result
);
}
}
else
{
else
{
return
ApiResult
.
Success
(
""
,
list
.
OrderBy
(
x
=>
Convert
.
ToInt32
(
x
.
Value
)).
Select
(
x
=>
new
return
ApiResult
.
Success
(
""
,
list
.
OrderBy
(
x
=>
Convert
.
ToInt32
(
x
.
Value
)).
Select
(
x
=>
new
{
{
Name
=
x
.
Key
,
Name
=
x
.
Key
,
...
@@ -3467,7 +3469,8 @@ namespace Mall.WebApi.Controllers.MallBase
...
@@ -3467,7 +3469,8 @@ namespace Mall.WebApi.Controllers.MallBase
{
{
return
ApiResult
.
Success
(
""
);
return
ApiResult
.
Success
(
""
);
}
}
else
{
else
{
return
ApiResult
.
Failed
(
msg
);
return
ApiResult
.
Failed
(
msg
);
}
}
}
}
...
@@ -4775,11 +4778,13 @@ namespace Mall.WebApi.Controllers.MallBase
...
@@ -4775,11 +4778,13 @@ namespace Mall.WebApi.Controllers.MallBase
#
region
教育资产商品
#
region
教育资产商品
[
HttpPost
]
[
HttpPost
]
public
ApiResult
SetEduGoodsFreightCostFinance
()
{
public
ApiResult
SetEduGoodsFreightCostFinance
()
{
var
userInfo
=
base
.
UserInfo
;
var
userInfo
=
base
.
UserInfo
;
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
int
OrderId
=
parm
.
GetInt
(
"OrderId"
,
0
);
int
OrderId
=
parm
.
GetInt
(
"OrderId"
,
0
);
if
(
OrderId
<=
0
)
{
if
(
OrderId
<=
0
)
{
return
ApiResult
.
ParamIsNull
();
return
ApiResult
.
ParamIsNull
();
}
}
...
@@ -4788,11 +4793,110 @@ namespace Mall.WebApi.Controllers.MallBase
...
@@ -4788,11 +4793,110 @@ namespace Mall.WebApi.Controllers.MallBase
{
{
return
ApiResult
.
Success
();
return
ApiResult
.
Success
();
}
}
else
{
else
{
return
ApiResult
.
Failed
(
msg
);
return
ApiResult
.
Failed
(
msg
);
}
}
}
}
#
endregion
#
endregion
#
region
评论标签管理
/// <summary>
/// 新增修改评论标签
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
SetCommentLabel
()
{
var
userInfo
=
base
.
UserInfo
;
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
RB_Comment_Label_Extend
extModel
=
new
RB_Comment_Label_Extend
()
{
Id
=
parm
.
GetInt
(
"Id"
),
Name
=
parm
.
GetStringValue
(
"Name"
),
Status
=
0
,
TenantId
=
userInfo
.
TenantId
,
MallBaseId
=
userInfo
.
MallBaseId
,
};
if
(
extModel
.
Id
>
0
)
{
extModel
.
UpdateDate
=
DateTime
.
Now
;
}
else
{
extModel
.
CreateDate
=
DateTime
.
Now
;
}
bool
flag
=
orderModule
.
SetCommentLabelModule
(
extModel
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
/// <summary>
/// 根据编号获取评论标签
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCommentLabel
()
{
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
int
Id
=
parm
.
GetInt
(
"Id"
);
var
extModel
=
orderModule
.
GetCommentLabelModule
(
Id
);
return
ApiResult
.
Success
(
data
:
extModel
);
}
/// <summary>
/// 根据编号删除评论标签
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
RemoveCommentLabel
()
{
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
int
Id
=
parm
.
GetInt
(
"Id"
);
var
flag
=
orderModule
.
RemoveCommentLabelModule
(
Id
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
/// <summary>
/// 获取评论标签分页列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCommentLabelPage
()
{
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
ResultPageModel
pageModel
=
new
ResultPageModel
()
{
pageIndex
=
parm
.
GetInt
(
"pageIndex"
),
pageSize
=
parm
.
GetInt
(
"pageSize"
),
};
var
query
=
new
RB_Comment_Label_Extend
()
{
Name
=
parm
.
GetStringValue
(
"Name"
),
};
var
dataList
=
orderModule
.
GetCommentLabelPageModule
(
pageModel
.
pageIndex
,
pageModel
.
pageSize
,
out
long
rowsCount
,
query
);
pageModel
.
count
=
Convert
.
ToInt32
(
rowsCount
);
pageModel
.
pageData
=
dataList
;
return
ApiResult
.
Success
(
data
:
pageModel
);
}
/// <summary>
/// 获取评论标签列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCommentLabelList
()
{
var
parm
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
var
query
=
new
RB_Comment_Label_Extend
()
{
Name
=
parm
.
GetStringValue
(
"Name"
),
};
var
dataList
=
orderModule
.
GetCommentLabelListModule
(
query
);
return
ApiResult
.
Success
(
data
:
dataList
);
}
#
endregion
}
}
}
}
\ No newline at end of file
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