Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1-office-web-sit
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴迪
gs1-office-web-sit
Commits
807f2032
Commit
807f2032
authored
Nov 21, 2021
by
rongkailun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【新增】医疗管理基础代码
parent
9302282c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
253 additions
and
0 deletions
+253
-0
MedicalController.java
...o/office/modules/manage/controller/MedicalController.java
+90
-0
MedicalDao.java
src/main/java/io/office/modules/manage/dao/MedicalDao.java
+17
-0
MedicalEntity.java
...n/java/io/office/modules/manage/entity/MedicalEntity.java
+72
-0
MedicalService.java
...java/io/office/modules/manage/service/MedicalService.java
+20
-0
MedicalServiceImpl.java
...ffice/modules/manage/service/impl/MedicalServiceImpl.java
+30
-0
MedicalDao.xml
src/main/resources/mapper/manage/MedicalDao.xml
+24
-0
No files found.
src/main/java/io/office/modules/manage/controller/MedicalController.java
0 → 100644
View file @
807f2032
package
io
.
office
.
modules
.
manage
.
controller
;
import
java.util.Arrays
;
import
java.util.Map
;
import
io.office.modules.manage.entity.MedicalEntity
;
import
io.office.modules.manage.service.MedicalService
;
import
org.apache.shiro.authz.annotation.RequiresPermissions
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.PathVariable
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.R
;
/**
* ${comments}
*
* @author wudi
* @email
* @date 2021-11-21 12:15:48
*/
@RestController
@RequestMapping
(
"/medical"
)
public
class
MedicalController
{
@Autowired
private
MedicalService
medicalService
;
/**
* 列表
*/
@RequestMapping
(
"/list"
)
// @RequiresPermissions("manage:medical:list")
public
R
list
(
@RequestParam
Map
<
String
,
Object
>
params
){
PageUtils
page
=
medicalService
.
queryPage
(
params
);
return
R
.
ok
().
put
(
"page"
,
page
);
}
/**
* 信息
*/
@RequestMapping
(
"/info/{id}"
)
// @RequiresPermissions("manage:medical:info")
public
R
info
(
@PathVariable
(
"id"
)
Integer
id
){
MedicalEntity
medical
=
medicalService
.
getById
(
id
);
return
R
.
ok
().
put
(
"medical"
,
medical
);
}
/**
* 保存
*/
@RequestMapping
(
"/save"
)
// @RequiresPermissions("manage:medical:save")
public
R
save
(
@RequestBody
MedicalEntity
medical
){
medicalService
.
save
(
medical
);
return
R
.
ok
();
}
/**
* 修改
*/
@RequestMapping
(
"/update"
)
// @RequiresPermissions("manage:medical:update")
public
R
update
(
@RequestBody
MedicalEntity
medical
){
medicalService
.
updateById
(
medical
);
return
R
.
ok
();
}
/**
* 删除
*/
@RequestMapping
(
"/delete"
)
// @RequiresPermissions("manage:medical:delete")
public
R
delete
(
@RequestBody
Integer
[]
ids
){
medicalService
.
removeByIds
(
Arrays
.
asList
(
ids
));
return
R
.
ok
();
}
}
src/main/java/io/office/modules/manage/dao/MedicalDao.java
0 → 100644
View file @
807f2032
package
io
.
office
.
modules
.
manage
.
dao
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
io.office.modules.manage.entity.MedicalEntity
;
import
org.apache.ibatis.annotations.Mapper
;
/**
* ${comments}
*
* @author wudi
* @email
* @date 2021-11-21 12:15:48
*/
@Mapper
public
interface
MedicalDao
extends
BaseMapper
<
MedicalEntity
>
{
}
src/main/java/io/office/modules/manage/entity/MedicalEntity.java
0 → 100644
View file @
807f2032
package
io
.
office
.
modules
.
manage
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.util.Date
;
import
lombok.Data
;
/**
* ${comments}
*
* @author rkl
* @email
* @date 2021-11-21 12:15:48
*/
@Data
@TableName
(
"medical"
)
public
class
MedicalEntity
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* $column.comments
*/
@TableId
private
Integer
id
;
/**
* $column.comments
*/
private
String
title
;
/**
* $column.comments
*/
private
String
type
;
/**
* $column.comments
*/
private
Integer
level
;
/**
* $column.comments
*/
private
String
jumppath
;
/**
* $column.comments
*/
private
String
keyword
;
/**
* $column.comments
*/
private
String
source
;
/**
* $column.comments
*/
private
String
author
;
/**
* $column.comments
*/
private
Date
releasetime
;
/**
* $column.comments
*/
private
Date
implementationtime
;
/**
* $column.comments
*/
private
String
remarks
;
/**
* $column.comments
*/
private
String
content
;
}
src/main/java/io/office/modules/manage/service/MedicalService.java
0 → 100644
View file @
807f2032
package
io
.
office
.
modules
.
manage
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
io.office.common.utils.PageUtils
;
import
io.office.modules.manage.entity.MedicalEntity
;
import
java.util.Map
;
/**
* ${comments}
*
* @author wudi
* @email
* @date 2021-11-21 12:15:48
*/
public
interface
MedicalService
extends
IService
<
MedicalEntity
>
{
PageUtils
queryPage
(
Map
<
String
,
Object
>
params
);
}
src/main/java/io/office/modules/manage/service/impl/MedicalServiceImpl.java
0 → 100644
View file @
807f2032
package
io
.
office
.
modules
.
manage
.
service
.
impl
;
import
io.office.modules.manage.dao.MedicalDao
;
import
io.office.modules.manage.entity.MedicalEntity
;
import
io.office.modules.manage.service.MedicalService
;
import
org.springframework.stereotype.Service
;
import
java.util.Map
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
io.office.common.utils.PageUtils
;
import
io.office.common.utils.Query
;
@Service
(
"medicalService"
)
public
class
MedicalServiceImpl
extends
ServiceImpl
<
MedicalDao
,
MedicalEntity
>
implements
MedicalService
{
@Override
public
PageUtils
queryPage
(
Map
<
String
,
Object
>
params
)
{
IPage
<
MedicalEntity
>
page
=
this
.
page
(
new
Query
<
MedicalEntity
>().
getPage
(
params
),
new
QueryWrapper
<
MedicalEntity
>()
);
return
new
PageUtils
(
page
);
}
}
\ No newline at end of file
src/main/resources/mapper/manage/MedicalDao.xml
0 → 100644
View file @
807f2032
<?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=
"modules.manage.dao.MedicalDao"
>
<!-- 可根据自己的需求,是否要使用 -->
<resultMap
type=
"modules.manage.entity.MedicalEntity"
id=
"medicalMap"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"title"
column=
"title"
/>
<result
property=
"type"
column=
"type"
/>
<result
property=
"level"
column=
"level"
/>
<result
property=
"jumppath"
column=
"jumppath"
/>
<result
property=
"keyword"
column=
"keyword"
/>
<result
property=
"source"
column=
"source"
/>
<result
property=
"author"
column=
"author"
/>
<result
property=
"releasetime"
column=
"releaseTime"
/>
<result
property=
"implementationtime"
column=
"implementationTime"
/>
<result
property=
"remarks"
column=
"remarks"
/>
<result
property=
"content"
column=
"content"
/>
</resultMap>
</mapper>
\ No newline at end of file
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