-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5c492b4
commit 09b0df0
Showing
12 changed files
with
222 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
src/main/java/ru/polinabevad/bugtracker/services/MainController.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package ru.polinabevad.bugtracker.services; | ||
|
||
import org.springframework.stereotype.Controller; | ||
import org.springframework.ui.Model; | ||
import org.springframework.web.bind.annotation.RequestMapping; | ||
|
||
@Controller | ||
|
||
public class MainController { | ||
@RequestMapping("/") | ||
public String helloWorld(Model model) { | ||
model.addAttribute("message", "Hello World!"); | ||
return "index"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<beans xmlns:context="http://www.springframework.org/schema/context" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xmlns:tx="http://www.springframework.org/schema/tx" | ||
xmlns="http://www.springframework.org/schema/beans" | ||
xsi:schemaLocation=" | ||
http://www.springframework.org/schema/beans | ||
http://www.springframework.org/schema/beans/spring-beans-4.2.xsd | ||
http://www.springframework.org/schema/context | ||
http://www.springframework.org/schema/context/spring-context-4.2.xsd | ||
http://www.springframework.org/schema/tx | ||
http://www.springframework.org/schema/tx/spring-tx-4.2.xsd | ||
"> | ||
|
||
<context:annotation-config/> | ||
|
||
<context:component-scan base-package="ru.polinabevad.bugtracker"/> | ||
|
||
<bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> | ||
<property name="viewClass" value="org.springframework.web.servlet.view.JstlView"/> | ||
<property name="prefix" value="/WEB-INF/pages/"/> | ||
<property name="suffix" value=".jsp"/> | ||
</bean> | ||
|
||
</beans> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,42 @@ | ||
<?xml version="1.0" encoding="ISO-8859-1"?> | ||
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
version="3.0" | ||
xmlns="http://java.sun.com/xml/ns/javaee" | ||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"> | ||
|
||
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee | ||
http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd" | ||
version="3.1" | ||
metadata-complete="true"> | ||
<context-param> | ||
<param-name>contextConfigLocation</param-name> | ||
<param-value> | ||
/WEB-INF/dispatcher-servlet.xml | ||
</param-value> | ||
</context-param> | ||
|
||
<listener> | ||
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> | ||
</listener> | ||
|
||
<display-name>BugTracker with Maven, TomCat, Junit</display-name> | ||
<servlet> | ||
<servlet-name>dispatcher</servlet-name> | ||
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> | ||
<load-on-startup>1</load-on-startup> | ||
</servlet> | ||
|
||
<servlet-mapping> | ||
<servlet-name>dispatcher</servlet-name> | ||
<url-pattern>/</url-pattern> | ||
</servlet-mapping> | ||
|
||
</web-app> | ||
|
||
<session-config> | ||
<session-timeout>30</session-timeout> | ||
</session-config> | ||
|
||
<servlet-mapping> | ||
<servlet-name>default</servlet-name> | ||
<url-pattern>*.css</url-pattern> | ||
</servlet-mapping> | ||
<servlet-mapping> | ||
<servlet-name>default</servlet-name> | ||
<url-pattern>*.js</url-pattern> | ||
</servlet-mapping> | ||
|
||
</web-app> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.