Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
J
jgjy
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
注册表
注册表
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
svn
jgjy
Commits
9718656c
提交
9718656c
authored
5月 14, 2019
作者:
lvwei
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
--no commit message
上级
8c8427ae
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
20 行增加
和
13 行删除
+20
-13
DiyTypeManage.java
...va/com/zrqx/bg/resource/manage/diytype/DiyTypeManage.java
+6
-6
LabelManage.java
...n/java/com/zrqx/bg/resource/manage/label/LabelManage.java
+12
-7
EleResourceServiceImpl.java
...rce/service/goods/eleresource/EleResourceServiceImpl.java
+2
-0
没有找到文件。
com.zrqx.bg.resource/src/main/java/com/zrqx/bg/resource/manage/diytype/DiyTypeManage.java
浏览文件 @
9718656c
package
com
.
zrqx
.
bg
.
resource
.
manage
.
diytype
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
import
java.util.stream.Stream
;
...
...
@@ -28,15 +30,13 @@ public class DiyTypeManage {
* @author lw
* @date: 2019年4月1日 下午2:44:46
*/
public
List
<
String
>
getDiyTypesName
(
String
goodsid
){
public
Map
<
Integer
,
String
>
getDiyTypesName
(
String
goodsid
){
GoodsDiyTypeRelation
record
=
new
GoodsDiyTypeRelation
();
record
.
setGoodsid
(
String
.
valueOf
(
goodsid
));
List
<
GoodsDiyTypeRelation
>
goodsDiyTypeRelations
=
goodsDiyTypeRelationMapper
.
select
(
record
);
List
<
String
>
diyTypeNames
=
goodsDiyTypeRelations
.
stream
()
.
map
(
GoodsDiyTypeRelation
::
getDiytypeid
)
.
map
(
id
->
{
return
getName
(
id
,
new
StringBuffer
());
}).
collect
(
Collectors
.
toList
());
Map
<
Integer
,
String
>
diyTypeNames
=
new
HashMap
<
Integer
,
String
>();
goodsDiyTypeRelations
.
stream
().
map
(
GoodsDiyTypeRelation
::
getDiytypeid
)
.
forEach
(
id
->
diyTypeNames
.
put
(
id
,
getName
(
id
,
new
StringBuffer
())));
return
diyTypeNames
;
}
...
...
com.zrqx.bg.resource/src/main/java/com/zrqx/bg/resource/manage/label/LabelManage.java
浏览文件 @
9718656c
package
com
.
zrqx
.
bg
.
resource
.
manage
.
label
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
...
...
@@ -9,6 +11,9 @@ import java.util.stream.Collectors;
import
net.bytebuddy.asm.Advice.This
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -19,6 +24,9 @@ import org.springframework.stereotype.Component;
import
com.zrqx.bg.resource.mapper.label.LabelGoodsRelationMapper
;
import
com.zrqx.bg.resource.mapper.label.LabelMapper
;
import
com.zrqx.core.model.resource.diytype.DiyType
;
...
...
@@ -44,16 +52,13 @@ public class LabelManage {
* @author lw
* @date: 2019年4月1日 下午2:54:52
*/
public
List
<
String
>
getLabelName
(
String
goodsid
)
{
public
Map
<
Integer
,
String
>
getLabelName
(
String
goodsid
)
{
LabelGoodsRelation
record
=
new
LabelGoodsRelation
();
record
.
setGoodsid
(
String
.
valueOf
(
goodsid
));
List
<
LabelGoodsRelation
>
labelGoodsRelation
=
labelGoodsRelationMapper
.
select
(
record
);
List
<
String
>
labelNames
=
labelGoodsRelation
.
stream
()
.
map
(
LabelGoodsRelation
::
getLabelId
)
.
map
(
id
->
{
return
getName
(
id
,
new
StringBuffer
());
})
.
collect
(
Collectors
.
toList
());
Map
<
Integer
,
String
>
labelNames
=
new
HashMap
<
Integer
,
String
>();
labelGoodsRelation
.
stream
().
map
(
LabelGoodsRelation
::
getLabelId
)
.
map
(
id
->
labelNames
.
put
(
id
,
getName
(
id
,
new
StringBuffer
())));
return
labelNames
;
}
...
...
com.zrqx.bg.resource/src/main/java/com/zrqx/bg/resource/service/goods/eleresource/EleResourceServiceImpl.java
浏览文件 @
9718656c
...
...
@@ -4,9 +4,11 @@ package com.zrqx.bg.resource.service.goods.eleresource;
import
java.text.SimpleDateFormat
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
org.apache.commons.beanutils.BeanUtils
;
import
org.apache.commons.collections4.map.HashedMap
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论