添加MySQL配置,并跑通项目
This commit is contained in:
		
							
								
								
									
										1
									
								
								backend/.idea/encodings.xml
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										1
									
								
								backend/.idea/encodings.xml
									
									
									
										generated
									
									
									
								
							@@ -2,6 +2,7 @@
 | 
			
		||||
<project version="4">
 | 
			
		||||
  <component name="Encoding" defaultCharsetForPropertiesFiles="UTF-8">
 | 
			
		||||
    <file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
 | 
			
		||||
    <file url="file://$PROJECT_DIR$/src/main/resources" charset="UTF-8" />
 | 
			
		||||
    <file url="PROJECT" charset="UTF-8" />
 | 
			
		||||
  </component>
 | 
			
		||||
</project>
 | 
			
		||||
							
								
								
									
										1
									
								
								backend/.idea/misc.xml
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										1
									
								
								backend/.idea/misc.xml
									
									
									
										generated
									
									
									
								
							@@ -1,6 +1,5 @@
 | 
			
		||||
<?xml version="1.0" encoding="UTF-8"?>
 | 
			
		||||
<project version="4">
 | 
			
		||||
  <component name="ExternalStorageConfigurationManager" enabled="true" />
 | 
			
		||||
  <component name="MavenProjectsManager">
 | 
			
		||||
    <option name="originalFiles">
 | 
			
		||||
      <list>
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										
											BIN
										
									
								
								backend/.mvn/wrapper/maven-wrapper.jar
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								backend/.mvn/wrapper/maven-wrapper.jar
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							@@ -1,10 +0,0 @@
 | 
			
		||||
<component name="ProjectRunConfigurationManager">
 | 
			
		||||
  <configuration default="false" name="Application" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
 | 
			
		||||
    <option name="ACTIVE_PROFILES" />
 | 
			
		||||
    <module name="entrance" />
 | 
			
		||||
    <option name="SPRING_BOOT_MAIN_CLASS" value="com.cxyxiaomo.entrance.Application" />
 | 
			
		||||
    <method v="2">
 | 
			
		||||
      <option name="Make" enabled="true" />
 | 
			
		||||
    </method>
 | 
			
		||||
  </configuration>
 | 
			
		||||
</component>
 | 
			
		||||
@@ -12,17 +12,27 @@
 | 
			
		||||
    <artifactId>entrance</artifactId>
 | 
			
		||||
    <version>0.0.1-SNAPSHOT</version>
 | 
			
		||||
    <name>Epidemic prevention platform</name>
 | 
			
		||||
	<description></description>
 | 
			
		||||
    <description>Epidemic prevention platform</description>
 | 
			
		||||
    <properties>
 | 
			
		||||
        <java.version>11</java.version>
 | 
			
		||||
    </properties>
 | 
			
		||||
    <dependencies>
 | 
			
		||||
		<!-- spring -->
 | 
			
		||||
        <!-- Spring -->
 | 
			
		||||
        <!-- spring-boot-starter -->
 | 
			
		||||
		<dependency>
 | 
			
		||||
			<groupId>org.springframework.boot</groupId>
 | 
			
		||||
			<artifactId>spring-boot-starter-test</artifactId>
 | 
			
		||||
            <version>2.7.4</version>
 | 
			
		||||
			<scope>test</scope>
 | 
			
		||||
		</dependency>
 | 
			
		||||
        <dependency>
 | 
			
		||||
            <groupId>org.springframework.boot</groupId>
 | 
			
		||||
            <artifactId>spring-boot-starter-data-jdbc</artifactId>
 | 
			
		||||
            <version>2.7.4</version>
 | 
			
		||||
        </dependency>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
        <!-- Database -->
 | 
			
		||||
		<!-- mybatis -->
 | 
			
		||||
        <dependency>
 | 
			
		||||
            <groupId>org.mybatis.spring.boot</groupId>
 | 
			
		||||
@@ -35,6 +45,8 @@
 | 
			
		||||
            <artifactId>mysql-connector-java</artifactId>
 | 
			
		||||
            <scope>runtime</scope>
 | 
			
		||||
        </dependency>
 | 
			
		||||
 | 
			
		||||
        <!-- Others -->
 | 
			
		||||
		<!-- lombok -->
 | 
			
		||||
        <dependency>
 | 
			
		||||
            <groupId>org.projectlombok</groupId>
 | 
			
		||||
@@ -59,5 +71,41 @@
 | 
			
		||||
            </plugin>
 | 
			
		||||
        </plugins>
 | 
			
		||||
    </build>
 | 
			
		||||
    <repositories>
 | 
			
		||||
        <repository>
 | 
			
		||||
            <id>spring-milestones</id>
 | 
			
		||||
            <name>Spring Milestones</name>
 | 
			
		||||
            <url>https://repo.spring.io/milestone</url>
 | 
			
		||||
            <snapshots>
 | 
			
		||||
                <enabled>false</enabled>
 | 
			
		||||
            </snapshots>
 | 
			
		||||
        </repository>
 | 
			
		||||
        <repository>
 | 
			
		||||
            <id>spring-snapshots</id>
 | 
			
		||||
            <name>Spring Snapshots</name>
 | 
			
		||||
            <url>https://repo.spring.io/snapshot</url>
 | 
			
		||||
            <releases>
 | 
			
		||||
                <enabled>false</enabled>
 | 
			
		||||
            </releases>
 | 
			
		||||
        </repository>
 | 
			
		||||
    </repositories>
 | 
			
		||||
    <pluginRepositories>
 | 
			
		||||
        <pluginRepository>
 | 
			
		||||
            <id>spring-milestones</id>
 | 
			
		||||
            <name>Spring Milestones</name>
 | 
			
		||||
            <url>https://repo.spring.io/milestone</url>
 | 
			
		||||
            <snapshots>
 | 
			
		||||
                <enabled>false</enabled>
 | 
			
		||||
            </snapshots>
 | 
			
		||||
        </pluginRepository>
 | 
			
		||||
        <pluginRepository>
 | 
			
		||||
            <id>spring-snapshots</id>
 | 
			
		||||
            <name>Spring Snapshots</name>
 | 
			
		||||
            <url>https://repo.spring.io/snapshot</url>
 | 
			
		||||
            <releases>
 | 
			
		||||
                <enabled>false</enabled>
 | 
			
		||||
            </releases>
 | 
			
		||||
        </pluginRepository>
 | 
			
		||||
    </pluginRepositories>
 | 
			
		||||
 | 
			
		||||
</project>
 | 
			
		||||
 
 | 
			
		||||
@@ -1 +1,5 @@
 | 
			
		||||
 | 
			
		||||
# MySQL配置
 | 
			
		||||
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
 | 
			
		||||
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/epp?useUnicode=true&characterEncoding=utf8&useSSL=false
 | 
			
		||||
spring.datasource.username=root
 | 
			
		||||
spring.datasource.password=root
 | 
			
		||||
							
								
								
									
										20
									
								
								database/epp.sql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								database/epp.sql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,20 @@
 | 
			
		||||
/*
 | 
			
		||||
 Navicat Premium Data Transfer
 | 
			
		||||
 | 
			
		||||
 Source Server         : localhost MySQL 8.0
 | 
			
		||||
 Source Server Type    : MySQL
 | 
			
		||||
 Source Server Version : 80012
 | 
			
		||||
 Source Host           : localhost:3306
 | 
			
		||||
 Source Schema         : epp
 | 
			
		||||
 | 
			
		||||
 Target Server Type    : MySQL
 | 
			
		||||
 Target Server Version : 80012
 | 
			
		||||
 File Encoding         : 65001
 | 
			
		||||
 | 
			
		||||
 Date: 21/10/2022 01:13:14
 | 
			
		||||
*/
 | 
			
		||||
 | 
			
		||||
SET NAMES utf8mb4;
 | 
			
		||||
SET FOREIGN_KEY_CHECKS = 0;
 | 
			
		||||
 | 
			
		||||
SET FOREIGN_KEY_CHECKS = 1;
 | 
			
		||||
		Reference in New Issue
	
	Block a user