Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jty-wsxt
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
aye
jty-wsxt
Commits
f342210e
Commit
f342210e
authored
Jun 21, 2019
by
aye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码提交
parent
9487a457
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
130 additions
and
28 deletions
+130
-28
.idea/libraries/Maven__javax_servlet_servlet_api_2_5.xml
+14
-0
service-paper/src/main/java/com/jty/wsxt/application/ApplicationRegistry.java
+20
-0
service-paper/src/main/java/com/jty/wsxt/application/service/ModuleService.java
+10
-0
service-paper/src/main/java/com/jty/wsxt/application/service/PaperService.java
+10
-0
service-paper/src/main/java/com/jty/wsxt/application/service/SubjectService.java
+10
-0
service-paper/src/main/java/com/jty/wsxt/application/service/TypeService.java
+10
-0
service-paper/src/main/java/com/jty/wsxt/application/service/impl/ModuleServiceImpl.java
+14
-0
service-paper/src/main/java/com/jty/wsxt/application/service/impl/PaperServiceImpl.java
+14
-0
service-paper/src/main/java/com/jty/wsxt/application/service/impl/SubjectServiceImpl.java
+14
-0
service-paper/src/main/java/com/jty/wsxt/application/service/impl/TypeServiceImpl.java
+14
-0
service-paper/src/main/java/com/jty/wsxt/infrastructure/config/FeignConfig.java
+0
-28
No files found.
.idea/libraries/Maven__javax_servlet_servlet_api_2_5.xml
0 → 100644
View file @
f342210e
<component
name=
"libraryTable"
>
<library
name=
"Maven: javax.servlet:servlet-api:2.5"
>
<CLASSES>
<root
url=
"jar://D:/Tool/apache-maven-3.3.1/maven-repository/javax/servlet/servlet-api/2.5/servlet-api-2.5.jar!/"
/>
</CLASSES>
<JAVADOC>
<root
url=
"jar://D:/Tool/apache-maven-3.3.1/maven-repository/javax/servlet/servlet-api/2.5/servlet-api-2.5-javadoc.jar!/"
/>
</JAVADOC>
<SOURCES>
<root
url=
"jar://D:/Tool/apache-maven-3.3.1/maven-repository/javax/servlet/servlet-api/2.5/servlet-api-2.5-sources.jar!/"
/>
</SOURCES>
</library>
</component>
\ No newline at end of file
service-paper/src/main/java/com/jty/wsxt/application/ApplicationRegistry.java
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
;
import
com.jty.wsxt.application.feign.UserFeign
;
import
com.jty.wsxt.application.service.ModuleService
;
import
com.jty.wsxt.application.service.PaperService
;
import
com.jty.wsxt.application.service.SubjectService
;
import
com.jty.wsxt.application.service.TypeService
;
import
org.springframework.beans.BeansException
;
import
org.springframework.context.ApplicationContext
;
import
org.springframework.context.ApplicationContextAware
;
...
...
@@ -21,6 +25,22 @@ public class ApplicationRegistry implements ApplicationContextAware {
return
applicationContext
.
getBean
(
UserFeign
.
class
);
}
public
static
ModuleService
moduleService
(){
return
applicationContext
.
getBean
(
ModuleService
.
class
);
}
public
static
PaperService
paperService
(){
return
applicationContext
.
getBean
(
PaperService
.
class
);
}
public
static
SubjectService
subjectService
(){
return
applicationContext
.
getBean
(
SubjectService
.
class
);
}
public
static
TypeService
typeService
(){
return
applicationContext
.
getBean
(
TypeService
.
class
);
}
@Override
public
synchronized
void
setApplicationContext
(
ApplicationContext
applicationContext
)
throws
BeansException
{
if
(
ApplicationRegistry
.
applicationContext
==
null
)
{
...
...
service-paper/src/main/java/com/jty/wsxt/application/service/ModuleService.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
;
/**
* ModuleService
*
* @author Manjiajie
* @since 2019-6-21 11:33:48
*/
public
interface
ModuleService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/PaperService.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
;
/**
* PaperService
*
* @author Manjiajie
* @since 2019-6-21 11:35:20
*/
public
interface
PaperService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/SubjectService.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
;
/**
* SubjectService
*
* @author Manjiajie
* @since 2019-6-21 11:34:41
*/
public
interface
SubjectService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/TypeService.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
;
/**
* TypeService
*
* @author Manjiajie
* @since 2019-6-21 11:35:54
*/
public
interface
TypeService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/impl/ModuleServiceImpl.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
.
impl
;
import
com.jty.wsxt.application.service.ModuleService
;
import
org.springframework.stereotype.Service
;
/**
* ModuleServiceImpl
*
* @author Manjiajie
* @since 2019-6-21 11:37:06
*/
@Service
public
class
ModuleServiceImpl
implements
ModuleService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/impl/PaperServiceImpl.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
.
impl
;
import
com.jty.wsxt.application.service.PaperService
;
import
org.springframework.stereotype.Service
;
/**
* PaperServiceImpl
*
* @author Manjiajie
* @since 2019-6-21 11:38:06
*/
@Service
public
class
PaperServiceImpl
implements
PaperService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/impl/SubjectServiceImpl.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
.
impl
;
import
com.jty.wsxt.application.service.SubjectService
;
import
org.springframework.stereotype.Service
;
/**
* SubjectServiceImpl
*
* @author Manjiajie
* @since 2019-6-21 11:38:53
*/
@Service
public
class
SubjectServiceImpl
implements
SubjectService
{
}
service-paper/src/main/java/com/jty/wsxt/application/service/impl/TypeServiceImpl.java
0 → 100644
View file @
f342210e
package
com
.
jty
.
wsxt
.
application
.
service
.
impl
;
import
com.jty.wsxt.application.service.TypeService
;
import
org.springframework.stereotype.Service
;
/**
* TypeServiceImpl
*
* @author Manjiajie
* @since 2019-6-21 11:39:44
*/
@Service
public
class
TypeServiceImpl
implements
TypeService
{
}
service-paper/src/main/java/com/jty/wsxt/infrastructure/config/FeignConfig.java
deleted
100644 → 0
View file @
9487a457
package
com
.
jty
.
wsxt
.
infrastructure
.
config
;
import
feign.RequestInterceptor
;
import
feign.RequestTemplate
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.web.context.request.RequestContextHolder
;
import
org.springframework.web.context.request.ServletRequestAttributes
;
import
javax.servlet.http.HttpServletRequest
;
/**
* Feign调用配置Token转发
*
* @author Jason
* @since 2018/12/29 13:08
*/
@Configuration
public
class
FeignConfig
implements
RequestInterceptor
{
@Override
public
void
apply
(
RequestTemplate
template
)
{
ServletRequestAttributes
attributes
=
(
ServletRequestAttributes
)
RequestContextHolder
.
getRequestAttributes
();
HttpServletRequest
request
=
attributes
.
getRequest
();
//添加token
template
.
header
(
"Access-Token"
,
request
.
getHeader
(
"Access-Token"
));
template
.
header
(
"Authorization"
,
request
.
getHeader
(
"Authorization"
));
}
}
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