Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
W
wyszyk
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
注册表
注册表
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
任建彩
wyszyk
Commits
2ab7e32d
提交
2ab7e32d
authored
8月 03, 2022
作者:
任建彩
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat:关联内容
1.resource
上级
5310e1dc
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
12 行增加
和
9 行删除
+12
-9
EbookController.java
...com/zrqx/resource/controller/backend/EbookController.java
+4
-1
ResourceLibraryController.java
...esource/controller/backend/ResourceLibraryController.java
+3
-3
ResourceRelationMapper.java
...java/com/zrqx/resource/mapper/ResourceRelationMapper.java
+2
-2
ResourceRelationService.java
...va/com/zrqx/resource/service/ResourceRelationService.java
+1
-1
ResourceRelationServiceImpl.java
...qx/resource/service/impl/ResourceRelationServiceImpl.java
+2
-2
没有找到文件。
wyszyk-provider/wyszyk-provider-resource/src/main/java/com/zrqx/resource/controller/backend/EbookController.java
浏览文件 @
2ab7e32d
...
@@ -131,8 +131,11 @@ public class EbookController {
...
@@ -131,8 +131,11 @@ public class EbookController {
}
}
@ApiOperation
(
"根据物料号查询是否存在"
)
@ApiOperation
(
"根据物料号查询是否存在"
)
@GetMapping
(
"/getItemNo"
)
@GetMapping
(
"/getItemNo"
)
public
CallBack
<
Boolean
>
getItemNo
(
String
itemNo
)
{
public
CallBack
<
Boolean
>
getItemNo
(
String
i
d
,
String
i
temNo
)
{
LambdaQueryWrapper
<
Book
>
lambdaQueryWrapper
=
new
LambdaQueryWrapper
<>();
LambdaQueryWrapper
<
Book
>
lambdaQueryWrapper
=
new
LambdaQueryWrapper
<>();
if
(
StringUtils
.
isNotBlank
(
id
)){
lambdaQueryWrapper
.
ne
(
Book:
:
getId
,
id
);
}
lambdaQueryWrapper
.
eq
(
Book:
:
getItemNo
,
itemNo
);
lambdaQueryWrapper
.
eq
(
Book:
:
getItemNo
,
itemNo
);
List
<
Book
>
list
=
bookservice
.
list
(
lambdaQueryWrapper
);
List
<
Book
>
list
=
bookservice
.
list
(
lambdaQueryWrapper
);
if
(
list
.
size
()>
0
){
if
(
list
.
size
()>
0
){
...
...
wyszyk-provider/wyszyk-provider-resource/src/main/java/com/zrqx/resource/controller/backend/ResourceLibraryController.java
浏览文件 @
2ab7e32d
...
@@ -227,7 +227,7 @@ public class ResourceLibraryController {
...
@@ -227,7 +227,7 @@ public class ResourceLibraryController {
ResourceRelation
e
=
new
ResourceRelation
();
ResourceRelation
e
=
new
ResourceRelation
();
e
.
setObjectId
(
entity
.
getId
());
e
.
setObjectId
(
entity
.
getId
());
e
.
setResourceId
(
resourceId
);
e
.
setResourceId
(
resourceId
);
e
.
setSort
(
resourceRelationService
.
getMaxSort
(
entity
.
getId
())
+
index
);
e
.
setSort
(
resourceRelationService
.
getMaxSort
(
entity
.
getId
()
,
entity
.
getResourceType
()
)
+
index
);
e
.
setCreatedTime
(
new
Date
());
e
.
setCreatedTime
(
new
Date
());
e
.
setResourceType
(
entity
.
getResourceType
());
e
.
setResourceType
(
entity
.
getResourceType
());
e
.
setCreaterId
(
tokenManager
.
getUserId
());
e
.
setCreaterId
(
tokenManager
.
getUserId
());
...
@@ -265,8 +265,8 @@ public class ResourceLibraryController {
...
@@ -265,8 +265,8 @@ public class ResourceLibraryController {
@ApiOperation
(
value
=
"获取关联资源的最大排序号"
,
notes
=
"获取资源最大排序号"
)
@ApiOperation
(
value
=
"获取关联资源的最大排序号"
,
notes
=
"获取资源最大排序号"
)
@GetMapping
(
value
=
"/get/sort"
)
@GetMapping
(
value
=
"/get/sort"
)
public
CallBack
<
Integer
>
getMaxSort
(
@RequestParam
String
objectId
)
{
public
CallBack
<
Integer
>
getMaxSort
(
@RequestParam
String
objectId
,
String
resourceType
)
{
return
CallBack
.
success
(
resourceRelationService
.
getMaxSort
(
objectId
));
return
CallBack
.
success
(
resourceRelationService
.
getMaxSort
(
objectId
,
resourceType
));
}
}
@ApiOperation
(
value
=
"选择弹框中的列表"
,
notes
=
"资源类型 "
)
@ApiOperation
(
value
=
"选择弹框中的列表"
,
notes
=
"资源类型 "
)
...
...
wyszyk-provider/wyszyk-provider-resource/src/main/java/com/zrqx/resource/mapper/ResourceRelationMapper.java
浏览文件 @
2ab7e32d
...
@@ -102,8 +102,8 @@ public interface ResourceRelationMapper extends BaseMapper<ResourceRelation> {
...
@@ -102,8 +102,8 @@ public interface ResourceRelationMapper extends BaseMapper<ResourceRelation> {
*
*
* @return
* @return
*/
*/
@Select
(
"SELECT MAX(sort) FROM res_resource_relation WHERE objectId = #{objectId}
"
)
@Select
(
"SELECT MAX(sort) FROM res_resource_relation WHERE objectId = #{objectId}
and resourceType = #{type}"
)
Integer
getMaxSort
(
@Param
(
"objectId"
)
String
objectId
);
Integer
getMaxSort
(
@Param
(
"objectId"
)
String
objectId
,
@Param
(
"type"
)
String
type
);
/**
/**
* 根据直播id查询直播信息
* 根据直播id查询直播信息
...
...
wyszyk-provider/wyszyk-provider-resource/src/main/java/com/zrqx/resource/service/ResourceRelationService.java
浏览文件 @
2ab7e32d
...
@@ -68,7 +68,7 @@ public interface ResourceRelationService extends IService<ResourceRelation> {
...
@@ -68,7 +68,7 @@ public interface ResourceRelationService extends IService<ResourceRelation> {
* @param objectId
* @param objectId
* @return
* @return
*/
*/
Integer
getMaxSort
(
String
objectId
);
Integer
getMaxSort
(
String
objectId
,
String
type
);
/**
/**
* 查询直播
* 查询直播
...
...
wyszyk-provider/wyszyk-provider-resource/src/main/java/com/zrqx/resource/service/impl/ResourceRelationServiceImpl.java
浏览文件 @
2ab7e32d
...
@@ -330,8 +330,8 @@ public class ResourceRelationServiceImpl extends ServiceImpl<ResourceRelationMap
...
@@ -330,8 +330,8 @@ public class ResourceRelationServiceImpl extends ServiceImpl<ResourceRelationMap
}
}
@Override
@Override
public
Integer
getMaxSort
(
String
objectId
)
{
public
Integer
getMaxSort
(
String
objectId
,
String
type
)
{
Integer
sort
=
mapper
.
getMaxSort
(
objectId
);
Integer
sort
=
mapper
.
getMaxSort
(
objectId
,
type
);
if
(
sort
==
null
)
{
if
(
sort
==
null
)
{
sort
=
1
;
sort
=
1
;
}
else
{
}
else
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论