健康教育 列表
parent
11354d3505
commit
e27dae32f1
|
@ -7,6 +7,7 @@
|
||||||
<file url="file://$PROJECT_DIR$/bwie-common/src/main/resources" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/bwie-common/src/main/resources" charset="UTF-8" />
|
||||||
<file url="file://$PROJECT_DIR$/bwie-gateway/src/main/java" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/bwie-gateway/src/main/java" charset="UTF-8" />
|
||||||
<file url="file://$PROJECT_DIR$/bwie-gateway/src/main/resources" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/bwie-gateway/src/main/resources" charset="UTF-8" />
|
||||||
|
<file url="file://$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java" charset="UTF-8" />
|
||||||
<file url="file://$PROJECT_DIR$/bwie-modules/src/main/java" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/bwie-modules/src/main/java" charset="UTF-8" />
|
||||||
<file url="file://$PROJECT_DIR$/bwie-modules/src/main/resources" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/bwie-modules/src/main/resources" charset="UTF-8" />
|
||||||
<file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
|
<file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,119 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="AutoImportSettings">
|
||||||
|
<option name="autoReloadType" value="SELECTIVE" />
|
||||||
|
</component>
|
||||||
|
<component name="ChangeListManager">
|
||||||
|
<list default="true" id="4740c5ae-3633-49ee-af3c-6c838d096709" name="Changes" comment="">
|
||||||
|
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-common/src/main/java/com/bwie/common/domain/Formation.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/pom.xml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java/com/bwie/formaiton/FormaitonAppliaction.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java/com/bwie/formaiton/controller/FormationController.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java/com/bwie/formaiton/mapper/FormationMapper.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java/com/bwie/formaiton/service/FormationService.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/java/com/bwie/formaiton/service/impl/FormationServiceImpl.java" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/resources/bootstrap.yml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/bwie-modules/bwie-formation/src/main/resources/mapper/FormationMapper.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/encodings.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/encodings.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/bwie-modules/pom.xml" beforeDir="false" afterPath="$PROJECT_DIR$/bwie-modules/pom.xml" afterDir="false" />
|
||||||
|
</list>
|
||||||
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||||
|
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||||
|
</component>
|
||||||
|
<component name="FileTemplateManagerImpl">
|
||||||
|
<option name="RECENT_TEMPLATES">
|
||||||
|
<list>
|
||||||
|
<option value="Interface" />
|
||||||
|
<option value="mapper.xml" />
|
||||||
|
<option value="Class" />
|
||||||
|
</list>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="Git.Settings">
|
||||||
|
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectId" id="2ZeGellpVQfTUIgDOaAVyh8QC8Z" />
|
||||||
|
<component name="ProjectLevelVcsManager" settingsEditedManually="true">
|
||||||
|
<ConfirmationsSetting value="2" id="Add" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectViewState">
|
||||||
|
<option name="showLibraryContents" value="true" />
|
||||||
|
</component>
|
||||||
|
<component name="PropertiesComponent"><![CDATA[{
|
||||||
|
"keyToString": {
|
||||||
|
"RequestMappingsPanelOrder0": "0",
|
||||||
|
"RequestMappingsPanelOrder1": "1",
|
||||||
|
"RequestMappingsPanelWidth0": "75",
|
||||||
|
"RequestMappingsPanelWidth1": "75",
|
||||||
|
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
||||||
|
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||||
|
"SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||||
|
"WebServerToolWindowFactoryState": "false",
|
||||||
|
"git-widget-placeholder": "master",
|
||||||
|
"jdk.selected.JAVA_MODULE": "1.8",
|
||||||
|
"last_opened_file_path": "D:/workspace/javaweb/JavaHeathl/bwie-modules/bwie-formation/src/main/java",
|
||||||
|
"node.js.detected.package.eslint": "true",
|
||||||
|
"node.js.detected.package.tslint": "true",
|
||||||
|
"node.js.selected.package.eslint": "(autodetect)",
|
||||||
|
"node.js.selected.package.tslint": "(autodetect)",
|
||||||
|
"vue.rearranger.settings.migration": "true"
|
||||||
|
}
|
||||||
|
}]]></component>
|
||||||
|
<component name="ReactorSettings">
|
||||||
|
<option name="notificationShown" value="true" />
|
||||||
|
</component>
|
||||||
|
<component name="RecentsManager">
|
||||||
|
<key name="CopyFile.RECENT_KEYS">
|
||||||
|
<recent name="D:\workspace\javaweb\JavaHeathl\bwie-modules\bwie-formation\src\main\java" />
|
||||||
|
<recent name="D:\workspace\javaweb\JavaHeathl\bwie-modules\bwie-formation\src\main\resources" />
|
||||||
|
</key>
|
||||||
|
</component>
|
||||||
|
<component name="RunDashboard">
|
||||||
|
<option name="configurationTypes">
|
||||||
|
<set>
|
||||||
|
<option value="SpringBootApplicationConfigurationType" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="RunManager">
|
||||||
|
<configuration name="FormaitonAppliaction" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot" temporary="true" nameIsGenerated="true">
|
||||||
|
<module name="bwie-formation" />
|
||||||
|
<option name="SPRING_BOOT_MAIN_CLASS" value="com.bwie.formaiton.FormaitonAppliaction" />
|
||||||
|
<extension name="coverage">
|
||||||
|
<pattern>
|
||||||
|
<option name="PATTERN" value="com.bwie.formaiton.*" />
|
||||||
|
<option name="ENABLED" value="true" />
|
||||||
|
</pattern>
|
||||||
|
</extension>
|
||||||
|
<method v="2">
|
||||||
|
<option name="Make" enabled="true" />
|
||||||
|
</method>
|
||||||
|
</configuration>
|
||||||
|
<recent_temporary>
|
||||||
|
<list>
|
||||||
|
<item itemvalue="Spring Boot.FormaitonAppliaction" />
|
||||||
|
</list>
|
||||||
|
</recent_temporary>
|
||||||
|
</component>
|
||||||
|
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
|
||||||
|
<component name="SshConsoleOptionsProvider">
|
||||||
|
<option name="myEncoding" value="UTF-8" />
|
||||||
|
</component>
|
||||||
|
<component name="TaskManager">
|
||||||
|
<task active="true" id="Default" summary="Default task">
|
||||||
|
<changelist id="4740c5ae-3633-49ee-af3c-6c838d096709" name="Changes" comment="" />
|
||||||
|
<created>1702775230647</created>
|
||||||
|
<option name="number" value="Default" />
|
||||||
|
<option name="presentableId" value="Default" />
|
||||||
|
<updated>1702775230647</updated>
|
||||||
|
<workItem from="1702775231994" duration="4891000" />
|
||||||
|
</task>
|
||||||
|
<servers />
|
||||||
|
</component>
|
||||||
|
<component name="TypeScriptGeneratedFilesManager">
|
||||||
|
<option name="version" value="3" />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,25 @@
|
||||||
|
package com.bwie.common.domain;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class Formation {
|
||||||
|
|
||||||
|
private Integer formationId;//用户具体信息表
|
||||||
|
private Integer formationPress;//血压
|
||||||
|
private Integer formationSugar;//血糖
|
||||||
|
private Date formationDate;//加入时间
|
||||||
|
private String formationAddress;//住址
|
||||||
|
private Integer userId; //用户Id
|
||||||
|
private String userName;//用户名
|
||||||
|
private String userPwd;//密码
|
||||||
|
private String formationPhone;//手机号
|
||||||
|
private Integer formationAge; //年龄
|
||||||
|
private String formationSex;//性别
|
||||||
|
private String formationName;//昵称
|
||||||
|
private Integer isDele;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,38 @@
|
||||||
|
target/
|
||||||
|
!.mvn/wrapper/maven-wrapper.jar
|
||||||
|
!**/src/main/**/target/
|
||||||
|
!**/src/test/**/target/
|
||||||
|
|
||||||
|
### IntelliJ IDEA ###
|
||||||
|
.idea/modules.xml
|
||||||
|
.idea/jarRepositories.xml
|
||||||
|
.idea/compiler.xml
|
||||||
|
.idea/libraries/
|
||||||
|
*.iws
|
||||||
|
*.iml
|
||||||
|
*.ipr
|
||||||
|
|
||||||
|
### Eclipse ###
|
||||||
|
.apt_generated
|
||||||
|
.classpath
|
||||||
|
.factorypath
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
.springBeans
|
||||||
|
.sts4-cache
|
||||||
|
|
||||||
|
### NetBeans ###
|
||||||
|
/nbproject/private/
|
||||||
|
/nbbuild/
|
||||||
|
/dist/
|
||||||
|
/nbdist/
|
||||||
|
/.nb-gradle/
|
||||||
|
build/
|
||||||
|
!**/src/main/**/build/
|
||||||
|
!**/src/test/**/build/
|
||||||
|
|
||||||
|
### VS Code ###
|
||||||
|
.vscode/
|
||||||
|
|
||||||
|
### Mac OS ###
|
||||||
|
.DS_Store
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<parent>
|
||||||
|
<groupId>com.bwie</groupId>
|
||||||
|
<artifactId>bwie-modules</artifactId>
|
||||||
|
<version>1.0-SNAPSHOT</version>
|
||||||
|
</parent>
|
||||||
|
|
||||||
|
<artifactId>bwie-formation</artifactId>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<maven.compiler.source>8</maven.compiler.source>
|
||||||
|
<maven.compiler.target>8</maven.compiler.target>
|
||||||
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
|
</properties>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<!-- 系统公共 依赖 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.bwie</groupId>
|
||||||
|
<artifactId>bwie-common</artifactId>
|
||||||
|
</dependency>
|
||||||
|
<!-- SpringBoot Web-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-starter-web</artifactId>
|
||||||
|
</dependency>
|
||||||
|
<!-- Druid -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba</groupId>
|
||||||
|
<artifactId>druid-spring-boot-starter</artifactId>
|
||||||
|
<version>1.2.8</version>
|
||||||
|
</dependency>
|
||||||
|
<!-- Mysql Connector -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>mysql</groupId>
|
||||||
|
<artifactId>mysql-connector-java</artifactId>
|
||||||
|
</dependency>
|
||||||
|
<!-- Mybatis 依赖配置 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.mybatis.spring.boot</groupId>
|
||||||
|
<artifactId>mybatis-spring-boot-starter</artifactId>
|
||||||
|
<version>2.2.2</version>
|
||||||
|
</dependency>
|
||||||
|
<!-- Pagehelper -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.github.pagehelper</groupId>
|
||||||
|
<artifactId>pagehelper-spring-boot-starter</artifactId>
|
||||||
|
<version>1.4.1</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
</project>
|
|
@ -0,0 +1,13 @@
|
||||||
|
package com.bwie.formaiton;
|
||||||
|
|
||||||
|
import org.mybatis.spring.annotation.MapperScan;
|
||||||
|
import org.springframework.boot.SpringApplication;
|
||||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||||
|
|
||||||
|
@SpringBootApplication
|
||||||
|
@MapperScan("com.bwie.formaiton.mapper")
|
||||||
|
public class FormaitonAppliaction {
|
||||||
|
public static void main(String[] args) {
|
||||||
|
SpringApplication.run(FormaitonAppliaction.class,args);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.bwie.formaiton.controller;
|
||||||
|
|
||||||
|
import com.bwie.common.domain.Formation;
|
||||||
|
import com.bwie.common.result.Result;
|
||||||
|
import com.bwie.formaiton.service.FormationService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
public class FormationController {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private FormationService formationService;
|
||||||
|
|
||||||
|
@PostMapping("/list")
|
||||||
|
public Result<List<Formation>> list(){
|
||||||
|
return formationService.list();
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/insert")
|
||||||
|
public Result<Integer> insert(@RequestBody Formation formation){
|
||||||
|
return formationService.insert(formation);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,11 @@
|
||||||
|
package com.bwie.formaiton.mapper;
|
||||||
|
|
||||||
|
import com.bwie.common.domain.Formation;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface FormationMapper {
|
||||||
|
List<Formation> list();
|
||||||
|
|
||||||
|
Integer insert(Formation formation);
|
||||||
|
}
|
|
@ -0,0 +1,12 @@
|
||||||
|
package com.bwie.formaiton.service;
|
||||||
|
|
||||||
|
import com.bwie.common.domain.Formation;
|
||||||
|
import com.bwie.common.result.Result;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface FormationService {
|
||||||
|
Result<List<Formation>> list();
|
||||||
|
|
||||||
|
Result<Integer> insert(Formation formation);
|
||||||
|
}
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.bwie.formaiton.service.impl;
|
||||||
|
|
||||||
|
import com.bwie.common.domain.Formation;
|
||||||
|
import com.bwie.common.result.Result;
|
||||||
|
import com.bwie.formaiton.mapper.FormationMapper;
|
||||||
|
import com.bwie.formaiton.service.FormationService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Service
|
||||||
|
public class FormationServiceImpl implements FormationService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private FormationMapper formationMapper;
|
||||||
|
@Override
|
||||||
|
public Result<List<Formation>> list() {
|
||||||
|
List<Formation> list = formationMapper.list();
|
||||||
|
return Result.success(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Result<Integer> insert(Formation formation) {
|
||||||
|
Integer i = formationMapper.insert(formation);
|
||||||
|
return Result.success(i);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,29 @@
|
||||||
|
# Tomcat
|
||||||
|
server:
|
||||||
|
port: 9002
|
||||||
|
# Spring
|
||||||
|
spring:
|
||||||
|
main:
|
||||||
|
allow-circular-references: true
|
||||||
|
jackson:
|
||||||
|
date-format: yyyy-MM-dd HH:mm:ss
|
||||||
|
time-zone: GMT+8
|
||||||
|
application:
|
||||||
|
# 应用名称
|
||||||
|
name: bwie-formation
|
||||||
|
profiles:
|
||||||
|
# 环境配置
|
||||||
|
active: dev
|
||||||
|
cloud:
|
||||||
|
nacos:
|
||||||
|
discovery:
|
||||||
|
# 服务注册地址
|
||||||
|
server-addr: 122.51.35.58:8848
|
||||||
|
config:
|
||||||
|
# 配置中心地址
|
||||||
|
server-addr: 122.51.35.58:8848
|
||||||
|
# 配置文件格式
|
||||||
|
file-extension: yml
|
||||||
|
# 共享配置
|
||||||
|
shared-configs:
|
||||||
|
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
|
@ -0,0 +1,13 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||||
|
<mapper namespace="com.bwie.formaiton.mapper.FormationMapper">
|
||||||
|
<insert id="insert">
|
||||||
|
INSERT INTO `health`.`formation` (`formation_press`, `formation_sugar`, `formation_date`, `formation_address`, `user_id`, `user_name`, `user_pwd`, `formation_phone`,`formation_age`, `formation_sex`, `formation_name`, `is_dele`) VALUES
|
||||||
|
(#{formationPress}, #{formationSugar}, now(), #{formationAddress}, #{userId}, #{userName}, #{userPwd}, #{formationPhone},#{formationAge}, #{formationSex}, #{formationName}, 1);
|
||||||
|
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<select id="list" resultType="com.bwie.common.domain.Formation">
|
||||||
|
select * from formation f left join user u on f.user_id=u.id
|
||||||
|
</select>
|
||||||
|
</mapper>
|
|
@ -10,6 +10,10 @@
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<artifactId>bwie-modules</artifactId>
|
<artifactId>bwie-modules</artifactId>
|
||||||
|
<packaging>pom</packaging>
|
||||||
|
<modules>
|
||||||
|
<module>bwie-formation</module>
|
||||||
|
</modules>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<maven.compiler.source>8</maven.compiler.source>
|
<maven.compiler.source>8</maven.compiler.source>
|
||||||
|
|
Loading…
Reference in New Issue