Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Z
zynrgl
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
注册表
注册表
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
svn
zynrgl
Commits
750c6b53
提交
750c6b53
authored
5月 17, 2019
作者:
renjiancai
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
--no commit message
上级
a1e21b20
显示空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
35 行增加
和
5 行删除
+35
-5
EbookLibraryController.java
...ce/bg/controller/ebooklibrary/EbookLibraryController.java
+10
-0
AchievementResourceServiceImpl.java
...ce/achievementLibrary/AchievementResourceServiceImpl.java
+4
-1
PaperResourceServiceImpl.java
...rce/bg/service/paperLibrary/PaperResourceServiceImpl.java
+1
-1
PatentResourceServiceImpl.java
...e/bg/service/patentLibrary/PatentResourceServiceImpl.java
+1
-1
PeriodVolumeResourceServiceImpl.java
...g/service/periodical/PeriodVolumeResourceServiceImpl.java
+1
-1
Swagger2Config.java
...java/com/zrqx/resource/commons/config/Swagger2Config.java
+18
-1
没有找到文件。
com.zrqx.resource/src/main/java/com/zrqx/resource/bg/controller/ebooklibrary/EbookLibraryController.java
浏览文件 @
750c6b53
...
...
@@ -53,6 +53,7 @@ import com.zrqx.core.model.resource.ebook.BookIssued;
import
com.zrqx.core.model.resource.ebook.BookLibraryLabel
;
import
com.zrqx.core.model.resource.ebook.BookResource
;
import
com.zrqx.core.model.resource.ebook.Ebook
;
import
com.zrqx.core.model.resource.imagelibrary.ImageGoods
;
import
com.zrqx.core.model.resource.imagelibrary.ImageLibrary
;
import
com.zrqx.core.model.resource.imagelibrary.ImageLibraryDiyType
;
import
com.zrqx.core.model.resource.pdflibrary.PdfLibrary
;
...
...
@@ -69,6 +70,7 @@ import com.zrqx.core.vo.resource.ebook.EbookVO;
import
com.zrqx.core.vo.resource.ebook.EpubVo
;
import
com.zrqx.core.vo.resource.ebook.ImportExcelBookVO
;
import
com.zrqx.core.vo.resource.label.LabelAndContentByDataTypeVO
;
import
com.zrqx.resource.bg.mapper.imagelibrary.ImageGoodsMapper
;
import
com.zrqx.resource.bg.service.ResourceRelationService
;
import
com.zrqx.resource.bg.service.animationlibrary.AnimationLibraryService
;
import
com.zrqx.resource.bg.service.articlelibrary.ArticleLibraryDiyTypeService
;
...
...
@@ -84,6 +86,7 @@ import com.zrqx.resource.bg.service.ebook.BookLabelContentDiyTypeService;
import
com.zrqx.resource.bg.service.ebook.BookResourceService
;
import
com.zrqx.resource.bg.service.ebook.BookService
;
import
com.zrqx.resource.bg.service.ebook.EbookService
;
import
com.zrqx.resource.bg.service.imagelibrary.ImageGoodsService
;
import
com.zrqx.resource.bg.service.imagelibrary.ImageLibraryDiyTypeRelationService
;
import
com.zrqx.resource.bg.service.imagelibrary.ImageLibraryService
;
import
com.zrqx.resource.bg.service.label.LabelContentDiyTypeService
;
...
...
@@ -125,6 +128,8 @@ public class EbookLibraryController {
@Autowired
private
ImageLibraryDiyTypeRelationService
ildtrService
;
@Autowired
private
ImageGoodsService
imageGoodsService
;
@Autowired
private
BookGoodsService
bookGoodsService
;
@Autowired
private
BookIssuedService
bookIssuedService
;
...
...
@@ -434,6 +439,11 @@ public class EbookLibraryController {
ildt
.
setCode
(
ev
.
getCode
());
ildt
.
setObjectId
(
image
.
getId
());
ildtrService
.
insertSelective
(
ildt
);
//商品信息
ImageGoods
goods
=
new
ImageGoods
();
goods
.
setObjectId
(
image
.
getId
());
goods
.
setDataSources
(
1
);
imageGoodsService
.
insertSelective
(
goods
);
});
try
{
...
...
com.zrqx.resource/src/main/java/com/zrqx/resource/bg/service/achievementLibrary/AchievementResourceServiceImpl.java
浏览文件 @
750c6b53
...
...
@@ -4,6 +4,8 @@
*/
package
com
.
zrqx
.
resource
.
bg
.
service
.
achievementLibrary
;
import
io.swagger.annotations.Example
;
import
java.util.List
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -50,8 +52,9 @@ public class AchievementResourceServiceImpl extends BaseServiceImpl<AchievementR
}
createCriteria
().
andIn
(
"id"
,
form
.
getIds
());
List
<
AchievementResource
>
list
=
mapper
.
selectByExample
(
example
);
for
(
AchievementResource
entity
:
list
)
{
entity
.
setObjectId
(
form
.
getObjec
tId
());
entity
.
setObjectId
(
entity
.
ge
tId
());
mapper
.
delete
(
entity
);
}
return
true
;
...
...
com.zrqx.resource/src/main/java/com/zrqx/resource/bg/service/paperLibrary/PaperResourceServiceImpl.java
浏览文件 @
750c6b53
...
...
@@ -41,7 +41,7 @@ public class PaperResourceServiceImpl extends BaseServiceImpl<PaperResource, Int
createCriteria
().
andIn
(
"id"
,
form
.
getIds
());
List
<
PaperResource
>
list
=
mapper
.
selectByExample
(
example
);
for
(
PaperResource
entity
:
list
)
{
entity
.
set
ObjectId
(
form
.
getObjec
tId
());
entity
.
set
Id
(
entity
.
ge
tId
());
mapper
.
delete
(
entity
);
}
return
true
;
...
...
com.zrqx.resource/src/main/java/com/zrqx/resource/bg/service/patentLibrary/PatentResourceServiceImpl.java
浏览文件 @
750c6b53
...
...
@@ -50,7 +50,7 @@ public class PatentResourceServiceImpl extends BaseServiceImpl<PatentResource, I
createCriteria
().
andIn
(
"id"
,
form
.
getIds
());
List
<
PatentResource
>
list
=
mapper
.
selectByExample
(
example
);
for
(
PatentResource
entity
:
list
)
{
entity
.
set
ObjectId
(
form
.
getObjec
tId
());
entity
.
set
Id
(
entity
.
ge
tId
());
mapper
.
delete
(
entity
);
}
return
true
;
...
...
com.zrqx.resource/src/main/java/com/zrqx/resource/bg/service/periodical/PeriodVolumeResourceServiceImpl.java
浏览文件 @
750c6b53
...
...
@@ -48,7 +48,7 @@ public class PeriodVolumeResourceServiceImpl extends BaseServiceImpl<PeriodVolum
createCriteria
().
andIn
(
"id"
,
form
.
getIds
());
List
<
PeriodVolumeResource
>
list
=
resourceMapper
.
selectByExample
(
example
);
for
(
PeriodVolumeResource
entity
:
list
)
{
entity
.
set
ObjectId
(
form
.
getObjec
tId
());
entity
.
set
Id
(
entity
.
ge
tId
());
resourceMapper
.
delete
(
entity
);
}
return
true
;
...
...
com.zrqx.resource/src/main/java/com/zrqx/resource/commons/config/Swagger2Config.java
浏览文件 @
750c6b53
package
com
.
zrqx
.
resource
.
commons
.
config
;
import
java.util.ArrayList
;
import
java.util.List
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.web.bind.annotation.CrossOrigin
;
import
springfox.documentation.builders.ApiInfoBuilder
;
import
springfox.documentation.builders.ParameterBuilder
;
import
springfox.documentation.builders.PathSelectors
;
import
springfox.documentation.builders.RequestHandlerSelectors
;
import
springfox.documentation.schema.ModelRef
;
import
springfox.documentation.service.ApiInfo
;
import
springfox.documentation.service.Contact
;
import
springfox.documentation.service.Parameter
;
import
springfox.documentation.spi.DocumentationType
;
import
springfox.documentation.spring.web.plugins.Docket
;
import
springfox.documentation.swagger2.annotations.EnableSwagger2
;
...
...
@@ -44,13 +50,24 @@ public class Swagger2Config {
@Bean
public
Docket
createRestApi
()
{
//添加head参数start
ParameterBuilder
tokenPar
=
new
ParameterBuilder
();
List
<
Parameter
>
pars
=
new
ArrayList
<
Parameter
>();
tokenPar
.
name
(
"y-token"
).
description
(
"y令牌"
).
modelRef
(
new
ModelRef
(
"string"
)).
parameterType
(
"header"
).
required
(
false
).
build
();
pars
.
add
(
tokenPar
.
build
());
tokenPar
.
name
(
"x-token"
).
description
(
"x令牌"
).
modelRef
(
new
ModelRef
(
"string"
)).
parameterType
(
"header"
).
required
(
false
).
build
();
pars
.
add
(
tokenPar
.
build
());
//添加head参数end
return
new
Docket
(
DocumentationType
.
SWAGGER_2
)
.
apiInfo
(
apiInfo
())
.
select
()
//为当前包路径
.
apis
(
RequestHandlerSelectors
.
basePackage
(
"com.zrqx"
))
.
paths
(
PathSelectors
.
any
())
.
build
();
.
build
()
.
globalOperationParameters
(
pars
);
}
//构建 api文档的详细信息函数
private
ApiInfo
apiInfo
()
{
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论