Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pms
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
pms
Commits
6f8d33ea
提交
6f8d33ea
authored
6月 10, 2023
作者:
xiaowang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
新增:产品管理列表目录
上级
dc418fff
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
58 行增加
和
21 行删除
+58
-21
BackstageProductSpecController.java
...om/mmc/pms/controller/BackstageProductSpecController.java
+8
-0
ProductDao.java
src/main/java/com/mmc/pms/dao/ProductDao.java
+2
-0
QueryClassifyVO.java
src/main/java/com/mmc/pms/model/sale/vo/QueryClassifyVO.java
+22
-18
ProductServiceImpl.java
...ain/java/com/mmc/pms/service/Impl/ProductServiceImpl.java
+13
-1
ProductSkuService.java
src/main/java/com/mmc/pms/service/ProductSkuService.java
+3
-0
CategoriesDao.xml
src/main/resources/mapper/CategoriesDao.xml
+0
-2
ProductDao.xml
src/main/resources/mapper/ProductDao.xml
+10
-0
没有找到文件。
src/main/java/com/mmc/pms/controller/BackstageProductSpecController.java
浏览文件 @
6f8d33ea
package
com
.
mmc
.
pms
.
controller
;
import
com.mmc.pms.common.ResultBody
;
import
com.mmc.pms.model.categories.vo.DirectoryInfoVO
;
import
com.mmc.pms.model.group.Create
;
import
com.mmc.pms.model.group.Update
;
import
com.mmc.pms.model.lease.vo.PriceAcquisition
;
...
...
@@ -49,6 +50,13 @@ public class BackstageProductSpecController {
return
productSkuService
.
editProductSku
(
param
);
}
@ApiOperation
(
value
=
"产品目录列表"
)
@GetMapping
(
"productDirectoryList"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
DirectoryInfoVO
.
class
)})
public
ResultBody
<
DirectoryInfoVO
>
productDirectoryList
()
{
return
productSkuService
.
productDirectoryList
();
}
@ApiOperation
(
value
=
"产品sku分页列表"
)
@PostMapping
(
"listPageProductSku"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ProductSkuDTO
.
class
)})
...
...
src/main/java/com/mmc/pms/dao/ProductDao.java
浏览文件 @
6f8d33ea
...
...
@@ -116,4 +116,6 @@ public interface ProductDao {
List
<
ProductSpecPriceDO
>
getProductSpecPriceList
(
List
<
Integer
>
specIds
);
ProductSpecPriceDO
getProductSpecPriceById
(
Integer
id
);
List
<
DirectoryDO
>
productDirectoryList
();
}
src/main/java/com/mmc/pms/model/sale/vo/QueryClassifyVO.java
浏览文件 @
6f8d33ea
...
...
@@ -15,30 +15,34 @@ import java.io.Serializable;
/**
* @Author LW
*
@date 2023/5/25 11:25
* 概要:
*
*
@date 2023/5/25 11:25
概要:
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
public
class
QueryClassifyVO
implements
Serializable
{
@ApiModelProperty
(
value
=
"所属目录id"
)
@NotNull
(
message
=
"所属目录id不能为空"
,
groups
=
{
Update
.
class
,
Create
.
class
})
private
Integer
directoryId
;
@ApiModelProperty
(
value
=
"所属目录id"
)
@NotNull
(
message
=
"所属目录id不能为空"
,
groups
=
{
Update
.
class
,
Create
.
class
})
private
Integer
directoryId
;
@ApiModelProperty
(
value
=
"分类所属模块id(0:通用分类 1:作业服务分类 2:设备租赁分类 3:飞手培训分类 4:产品商城分类)"
)
private
Integer
type
;
@ApiModelProperty
(
value
=
"页码"
,
required
=
true
)
@NotNull
(
message
=
"页码不能为空"
,
groups
=
{
Page
.
class
,
Freeze
.
class
})
@Min
(
value
=
1
,
groups
=
Page
.
class
)
private
Integer
pageNo
;
@ApiModelProperty
(
value
=
"每页显示数"
,
required
=
true
)
@NotNull
(
message
=
"每页显示数不能为空"
,
groups
=
{
Page
.
class
,
Freeze
.
class
})
@Min
(
value
=
1
,
groups
=
Page
.
class
)
private
Integer
pageSize
;
@ApiModelProperty
(
value
=
"页码"
,
required
=
true
)
@NotNull
(
message
=
"页码不能为空"
,
groups
=
{
Page
.
class
,
Freeze
.
class
})
@Min
(
value
=
1
,
groups
=
Page
.
class
)
private
Integer
pageNo
;
public
void
buildCurrentPage
()
{
this
.
pageNo
=
(
pageNo
-
1
)
*
pageSize
;
}
@ApiModelProperty
(
value
=
"每页显示数"
,
required
=
true
)
@NotNull
(
message
=
"每页显示数不能为空"
,
groups
=
{
Page
.
class
,
Freeze
.
class
})
@Min
(
value
=
1
,
groups
=
Page
.
class
)
private
Integer
pageSize
;
public
void
buildCurrentPage
()
{
this
.
pageNo
=
(
pageNo
-
1
)
*
pageSize
;
}
}
src/main/java/com/mmc/pms/service/Impl/ProductServiceImpl.java
浏览文件 @
6f8d33ea
...
...
@@ -11,9 +11,9 @@ import com.mmc.pms.model.sale.dto.*;
import
com.mmc.pms.model.sale.vo.ProductSpecCPQVO
;
import
com.mmc.pms.page.PageResult
;
import
com.mmc.pms.service.ProductSkuService
;
import
org.apache.commons.collections4.CollectionUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
javax.validation.constraints.NotNull
;
import
java.math.BigDecimal
;
...
...
@@ -304,4 +304,16 @@ public class ProductServiceImpl implements ProductSkuService {
priceAcquisition
.
setDay
(
dayRange
);
return
productDao
.
feignGetUnitPriceByTag
(
priceAcquisition
);
}
@Override
public
ResultBody
productDirectoryList
()
{
List
<
DirectoryDO
>
directoryList
=
productDao
.
productDirectoryList
();
if
(
CollectionUtils
.
isNotEmpty
(
directoryList
))
{
return
ResultBody
.
success
(
directoryList
.
stream
()
.
map
(
DirectoryDO:
:
buildDirectoryInfoVO
)
.
collect
(
Collectors
.
toList
()));
}
return
ResultBody
.
success
();
}
}
src/main/java/com/mmc/pms/service/ProductSkuService.java
浏览文件 @
6f8d33ea
...
...
@@ -2,6 +2,7 @@ package com.mmc.pms.service;
import
com.mmc.pms.common.ResultBody
;
import
com.mmc.pms.entity.ProductSpecPriceDO
;
import
com.mmc.pms.model.categories.vo.DirectoryInfoVO
;
import
com.mmc.pms.model.lease.vo.PriceAcquisition
;
import
com.mmc.pms.model.qo.ProductSkuQO
;
import
com.mmc.pms.model.sale.dto.ProductSkuVO
;
...
...
@@ -46,4 +47,6 @@ public interface ProductSkuService {
ResultBody
removeProductSpec
(
Integer
id
);
BigDecimal
feignGetUnitPriceByTag
(
PriceAcquisition
priceAcquisition
);
ResultBody
<
DirectoryInfoVO
>
productDirectoryList
();
}
src/main/resources/mapper/CategoriesDao.xml
浏览文件 @
6f8d33ea
...
...
@@ -148,7 +148,6 @@
FROM categories
WHERE is_deleted = 0
AND directory_id = #{directoryId}
AND type = #{type}
ORDER BY sort asc
LIMIT #{pageNo}, #{pageSize}
</select>
...
...
@@ -157,7 +156,6 @@
FROM categories
WHERE is_deleted = 0
AND directory_id = #{directoryId}
AND `type` = #{type}
</select>
<select
id=
"getDirectoryList"
resultType=
"com.mmc.pms.entity.DirectoryDO"
>
SELECT d.id,
...
...
src/main/resources/mapper/ProductDao.xml
浏览文件 @
6f8d33ea
...
...
@@ -511,4 +511,14 @@
AND cooperation_tag = 0
AND type = 1
</select>
<select
id=
"productDirectoryList"
resultType=
"com.mmc.pms.entity.DirectoryDO"
>
SELECT id,
directory_name,
`type`
FROM `directory`
WHERE type IN (2, 4)
OR (`type` = 0 AND `show` LIKE '%2%')
OR (`type` = 0 AND `show` LIKE '%4%')
AND is_deleted = 0
</select>
</mapper>
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论