Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vehicle-quality-review
Project
Project
Details
Activity
Releases
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
王飞
vehicle-quality-review
Commits
0f14f512
Commit
0f14f512
authored
Jan 30, 2024
by
高滢
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
样品管理 类名修改
parent
2686c6f7
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
32 additions
and
34 deletions
+32
-34
Sample.java
quality-review/src/main/java/com/ruoyi/domain/Sample.java
+1
-2
SampleManagementMapper.java
...rc/main/java/com/ruoyi/mapper/SampleManagementMapper.java
+8
-8
SampleManagementService.java
.../main/java/com/ruoyi/service/SampleManagementService.java
+6
-6
SampleManagementServiceImpl.java
...a/com/ruoyi/service/impl/SampleManagementServiceImpl.java
+6
-6
SampleManagementController.java
...c/main/java/com/ruoyi/web/SampleManagementController.java
+5
-6
SampleManagementMapper.xml
...view/src/main/resources/mapper/SampleManagementMapper.xml
+6
-6
No files found.
quality-review/src/main/java/com/ruoyi/domain/Sample
Management
.java
→
quality-review/src/main/java/com/ruoyi/domain/Sample.java
View file @
0f14f512
...
...
@@ -6,7 +6,6 @@ import com.baomidou.mybatisplus.annotation.IdType;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.ruoyi.common.annotation.Excel
;
import
com.ruoyi.common.core.domain.BaseEntity
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
...
...
@@ -22,7 +21,7 @@ import lombok.Data;
@ApiModel
@TableName
(
value
=
"t_sample"
)
@Data
public
class
Sample
Management
extends
BaseEntity
public
class
Sample
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
...
...
quality-review/src/main/java/com/ruoyi/mapper/SampleManagementMapper.java
View file @
0f14f512
package
com
.
ruoyi
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.ruoyi.domain.Sample
Management
;
import
com.ruoyi.domain.Sample
;
import
com.ruoyi.web.request.SampleManagementRequest
;
import
org.springframework.stereotype.Repository
;
...
...
@@ -9,14 +9,14 @@ import java.util.List;
@Repository
public
interface
SampleManagementMapper
extends
BaseMapper
<
Sample
Management
>
{
public
interface
SampleManagementMapper
extends
BaseMapper
<
Sample
>
{
/**
* 查询样品管理
*
* @param id 样品管理主键
* @return 样品管理
*/
public
Sample
Management
selectSampleManagementById
(
Long
id
);
public
Sample
selectSampleManagementById
(
Long
id
);
/**
* 查询样品管理列表
...
...
@@ -24,7 +24,7 @@ public interface SampleManagementMapper extends BaseMapper<SampleManagement> {
* @param sampleManagementRequest 样品管理
* @return 样品管理集合
*/
public
List
<
Sample
Management
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
);
public
List
<
Sample
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
);
/**
* 新增样品管理
...
...
@@ -32,7 +32,7 @@ public interface SampleManagementMapper extends BaseMapper<SampleManagement> {
* @param tSampleManagement 样品管理
* @return 结果
*/
public
int
insertSampleManagement
(
Sample
Management
tSampleManagement
);
public
int
insertSampleManagement
(
Sample
tSampleManagement
);
/**
* 修改样品管理
...
...
@@ -40,7 +40,7 @@ public interface SampleManagementMapper extends BaseMapper<SampleManagement> {
* @param tSampleManagement 样品管理
* @return 结果
*/
public
int
updateSampleManagement
(
Sample
Management
tSampleManagement
);
public
int
updateSampleManagement
(
Sample
tSampleManagement
);
/**
* 删除样品管理
...
...
@@ -53,10 +53,10 @@ public interface SampleManagementMapper extends BaseMapper<SampleManagement> {
/**
* 查询车辆识别码是否重复
* */
public
int
selectIdentificationCodeCount
(
Sample
Management
sampleManagement
);
public
int
selectIdentificationCodeCount
(
Sample
sampleManagement
);
/**
* 查询样品编号是否重复
* */
public
int
selectSampleNumberCount
(
Sample
Management
sampleManagement
);
public
int
selectSampleNumberCount
(
Sample
sampleManagement
);
}
quality-review/src/main/java/com/ruoyi/service/SampleManagementService.java
View file @
0f14f512
...
...
@@ -3,7 +3,7 @@ package com.ruoyi.service;
import
java.util.List
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
com.ruoyi.domain.Sample
Management
;
import
com.ruoyi.domain.Sample
;
import
com.ruoyi.web.request.SampleManagementRequest
;
/**
...
...
@@ -12,7 +12,7 @@ import com.ruoyi.web.request.SampleManagementRequest;
* @author ruoyi
* @date 2024-01-29
*/
public
interface
SampleManagementService
extends
IService
<
Sample
Management
>
public
interface
SampleManagementService
extends
IService
<
Sample
>
{
/**
* 查询样品管理
...
...
@@ -20,7 +20,7 @@ public interface SampleManagementService extends IService<SampleManagement>
* @param id 样品管理主键
* @return 样品管理
*/
public
Sample
Management
selectSampleManagementById
(
Long
id
);
public
Sample
selectSampleManagementById
(
Long
id
);
/**
* 查询样品管理列表
...
...
@@ -28,7 +28,7 @@ public interface SampleManagementService extends IService<SampleManagement>
* @param sampleManagementRequest 样品管理
* @return 样品管理集合
*/
public
List
<
Sample
Management
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
);
public
List
<
Sample
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
);
/**
* 新增样品管理
...
...
@@ -36,7 +36,7 @@ public interface SampleManagementService extends IService<SampleManagement>
* @param tSampleManagement 样品管理
* @return 结果
*/
public
int
insertSampleManagement
(
Sample
Management
tSampleManagement
);
public
int
insertSampleManagement
(
Sample
tSampleManagement
);
/**
* 修改样品管理
...
...
@@ -44,7 +44,7 @@ public interface SampleManagementService extends IService<SampleManagement>
* @param tSampleManagement 样品管理
* @return 结果
*/
public
int
updateSampleManagement
(
Sample
Management
tSampleManagement
);
public
int
updateSampleManagement
(
Sample
tSampleManagement
);
/**
* 删除样品管理信息
...
...
quality-review/src/main/java/com/ruoyi/service/impl/SampleManagementServiceImpl.java
View file @
0f14f512
...
...
@@ -6,7 +6,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import
com.ruoyi.common.exception.ServiceException
;
import
com.ruoyi.common.utils.DateUtils
;
import
com.ruoyi.common.utils.SecurityUtils
;
import
com.ruoyi.domain.Sample
Management
;
import
com.ruoyi.domain.Sample
;
import
com.ruoyi.mapper.SampleManagementMapper
;
import
com.ruoyi.service.SampleManagementService
;
import
com.ruoyi.web.request.SampleManagementRequest
;
...
...
@@ -22,7 +22,7 @@ import org.springframework.transaction.annotation.Transactional;
*/
@Service
@Transactional
public
class
SampleManagementServiceImpl
extends
ServiceImpl
<
SampleManagementMapper
,
Sample
Management
>
implements
SampleManagementService
public
class
SampleManagementServiceImpl
extends
ServiceImpl
<
SampleManagementMapper
,
Sample
>
implements
SampleManagementService
{
@Autowired
private
SampleManagementMapper
sampleManagementMapper
;
...
...
@@ -34,7 +34,7 @@ public class SampleManagementServiceImpl extends ServiceImpl<SampleManagementMap
* @return 样品管理
*/
@Override
public
Sample
Management
selectSampleManagementById
(
Long
id
)
public
Sample
selectSampleManagementById
(
Long
id
)
{
return
sampleManagementMapper
.
selectSampleManagementById
(
id
);
}
...
...
@@ -46,7 +46,7 @@ public class SampleManagementServiceImpl extends ServiceImpl<SampleManagementMap
* @return 样品管理
*/
@Override
public
List
<
Sample
Management
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
)
public
List
<
Sample
>
selectSampleManagementList
(
SampleManagementRequest
sampleManagementRequest
)
{
return
sampleManagementMapper
.
selectSampleManagementList
(
sampleManagementRequest
);
}
...
...
@@ -58,7 +58,7 @@ public class SampleManagementServiceImpl extends ServiceImpl<SampleManagementMap
* @return 结果
*/
@Override
public
int
insertSampleManagement
(
Sample
Management
sampleManagement
)
public
int
insertSampleManagement
(
Sample
sampleManagement
)
{
// 判断车辆识别码是否重复
int
dentificationCode
=
sampleManagementMapper
.
selectIdentificationCodeCount
(
sampleManagement
);
...
...
@@ -82,7 +82,7 @@ public class SampleManagementServiceImpl extends ServiceImpl<SampleManagementMap
* @return 结果
*/
@Override
public
int
updateSampleManagement
(
Sample
Management
sampleManagement
)
public
int
updateSampleManagement
(
Sample
sampleManagement
)
{
// 判断车辆识别码是否重复
int
dentificationCode
=
sampleManagementMapper
.
selectIdentificationCodeCount
(
sampleManagement
);
...
...
quality-review/src/main/java/com/ruoyi/web/SampleManagementController.java
View file @
0f14f512
...
...
@@ -3,7 +3,7 @@ package com.ruoyi.web;
import
java.util.List
;
import
com.ruoyi.common.core.domain.R
;
import
com.ruoyi.domain.Sample
Management
;
import
com.ruoyi.domain.Sample
;
import
com.ruoyi.service.SampleManagementService
;
import
com.ruoyi.web.request.SampleManagementGetInfoRequest
;
import
com.ruoyi.web.request.SampleManagementRequest
;
...
...
@@ -12,7 +12,6 @@ import io.swagger.annotations.ApiOperation;
import
org.apache.skywalking.apm.toolkit.trace.Tag
;
import
org.apache.skywalking.apm.toolkit.trace.Tags
;
import
org.apache.skywalking.apm.toolkit.trace.Trace
;
import
org.springframework.security.access.prepost.PreAuthorize
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.*
;
...
...
@@ -46,7 +45,7 @@ public class SampleManagementController extends BaseController
public
TableDataInfo
list
(
@Validated
@RequestBody
SampleManagementRequest
request
)
{
startPage
();
List
<
Sample
Management
>
list
=
sampleManagementService
.
selectSampleManagementList
(
request
);
List
<
Sample
>
list
=
sampleManagementService
.
selectSampleManagementList
(
request
);
return
getDataTable
(
list
);
}
...
...
@@ -57,7 +56,7 @@ public class SampleManagementController extends BaseController
@Trace
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/getInfo"
)
public
R
<
Sample
Management
>
getInfo
(
@Validated
@RequestBody
SampleManagementGetInfoRequest
request
)
public
R
<
Sample
>
getInfo
(
@Validated
@RequestBody
SampleManagementGetInfoRequest
request
)
{
return
R
.
ok
(
sampleManagementService
.
selectSampleManagementById
(
request
.
getId
()));
}
...
...
@@ -70,7 +69,7 @@ public class SampleManagementController extends BaseController
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"样品管理"
,
businessType
=
BusinessType
.
INSERT
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/add"
)
public
R
<
Integer
>
add
(
@Validated
@RequestBody
Sample
Management
tSampleManagement
)
public
R
<
Integer
>
add
(
@Validated
@RequestBody
Sample
tSampleManagement
)
{
return
R
.
ok
(
sampleManagementService
.
insertSampleManagement
(
tSampleManagement
));
}
...
...
@@ -84,7 +83,7 @@ public class SampleManagementController extends BaseController
@Tags
({
@Tag
(
key
=
"param"
,
value
=
"arg[0]"
),
@Tag
(
key
=
"result"
,
value
=
"returnedObj"
)})
@Log
(
title
=
"样品管理"
,
businessType
=
BusinessType
.
UPDATE
)
@RequestMapping
(
method
=
RequestMethod
.
POST
,
value
=
"/edit"
)
public
R
<
Integer
>
edit
(
@Validated
@RequestBody
Sample
Management
tSampleManagement
)
public
R
<
Integer
>
edit
(
@Validated
@RequestBody
Sample
tSampleManagement
)
{
return
R
.
ok
(
sampleManagementService
.
updateSampleManagement
(
tSampleManagement
));
}
...
...
quality-review/src/main/resources/mapper/SampleManagementMapper.xml
View file @
0f14f512
...
...
@@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.ruoyi.mapper.SampleManagementMapper"
>
<resultMap
type=
"com.ruoyi.domain.Sample
Management
"
id=
"SampleManagementResult"
>
<resultMap
type=
"com.ruoyi.domain.Sample"
id=
"SampleManagementResult"
>
<result
property=
"id"
column=
"id"
/>
<result
property=
"identificationCode"
column=
"identification_code"
/>
<result
property=
"sampleNumber"
column=
"sample_number"
/>
...
...
@@ -52,7 +52,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join t_automobile_enterprise ae on ae.id = sm.enterprise_id
</sql>
<select
id=
"selectSampleManagementList"
parameterType=
"com.ruoyi.domain.Sample
Management
"
resultMap=
"SampleManagementResult"
>
<select
id=
"selectSampleManagementList"
parameterType=
"com.ruoyi.domain.Sample"
resultMap=
"SampleManagementResult"
>
<include
refid=
"selectTSampleManagementVo"
/>
<where>
sm.deleted = 0
...
...
@@ -68,7 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where sm.id = #{id}
</select>
<insert
id=
"insertSampleManagement"
parameterType=
"com.ruoyi.domain.Sample
Management
"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
<insert
id=
"insertSampleManagement"
parameterType=
"com.ruoyi.domain.Sample"
useGeneratedKeys=
"true"
keyProperty=
"id"
>
insert into t_sample
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"identificationCode != null"
>
identification_code,
</if>
...
...
@@ -112,7 +112,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</trim>
</insert>
<update
id=
"updateSampleManagement"
parameterType=
"com.ruoyi.domain.Sample
Management
"
>
<update
id=
"updateSampleManagement"
parameterType=
"com.ruoyi.domain.Sample"
>
update t_sample
<trim
prefix=
"SET"
suffixOverrides=
","
>
<if
test=
"identificationCode != null"
>
identification_code = #{identificationCode},
</if>
...
...
@@ -141,7 +141,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where id = #{id}
</delete>
<select
id=
"selectIdentificationCodeCount"
parameterType=
"com.ruoyi.domain.Sample
Management
"
resultType=
"integer"
>
<select
id=
"selectIdentificationCodeCount"
parameterType=
"com.ruoyi.domain.Sample"
resultType=
"integer"
>
select count(id) from t_sample
<where>
deleted = 0
...
...
@@ -151,7 +151,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
</select>
<select
id=
"selectSampleNumberCount"
parameterType=
"com.ruoyi.domain.Sample
Management
"
resultType=
"integer"
>
<select
id=
"selectSampleNumberCount"
parameterType=
"com.ruoyi.domain.Sample"
resultType=
"integer"
>
select count(id) from t_sample
<where>
deleted = 0
...
...
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