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
f6fd3269
Commit
f6fd3269
authored
Jan 05, 2024
by
盖献康
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
车企信息 - 修改 - 2
parent
cbdfccf2
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
48 additions
and
23 deletions
+48
-23
AutomobileEnterpriseMapper.java
...ain/java/com/ruoyi/mapper/AutomobileEnterpriseMapper.java
+2
-0
AutomobileEnterpriseService.java
...n/java/com/ruoyi/service/AutomobileEnterpriseService.java
+1
-1
AutomobileEnterpriseServiceImpl.java
...m/ruoyi/service/impl/AutomobileEnterpriseServiceImpl.java
+4
-2
AutomobileEnterpriseController.java
...in/java/com/ruoyi/web/AutomobileEnterpriseController.java
+19
-20
AutomobileEnterpriseRequest.java
...va/com/ruoyi/web/request/AutomobileEnterpriseRequest.java
+22
-0
No files found.
quality-review/src/main/java/com/ruoyi/mapper/AutomobileEnterpriseMapper.java
View file @
f6fd3269
...
...
@@ -2,6 +2,7 @@ package com.ruoyi.mapper;
import
java.util.List
;
import
com.ruoyi.domain.AutomobileEnterprise
;
import
org.springframework.stereotype.Repository
;
/**
* 车企信息Mapper接口
...
...
@@ -9,6 +10,7 @@ import com.ruoyi.domain.AutomobileEnterprise;
* @author gxk
* @date 2024-01-05
*/
@Repository
public
interface
AutomobileEnterpriseMapper
{
/**
...
...
quality-review/src/main/java/com/ruoyi/service/
I
AutomobileEnterpriseService.java
→
quality-review/src/main/java/com/ruoyi/service/AutomobileEnterpriseService.java
View file @
f6fd3269
...
...
@@ -11,7 +11,7 @@ import org.apache.ibatis.annotations.Mapper;
* @date 2024-01-05
*/
@Mapper
public
interface
I
AutomobileEnterpriseService
public
interface
AutomobileEnterpriseService
{
/**
* 查询车企信息
...
...
quality-review/src/main/java/com/ruoyi/service/impl/AutomobileEnterpriseServiceImpl.java
View file @
f6fd3269
...
...
@@ -7,7 +7,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.stereotype.Service
;
import
com.ruoyi.mapper.AutomobileEnterpriseMapper
;
import
com.ruoyi.domain.AutomobileEnterprise
;
import
com.ruoyi.service.IAutomobileEnterpriseService
;
import
com.ruoyi.service.AutomobileEnterpriseService
;
import
org.springframework.transaction.annotation.Transactional
;
/**
* 车企信息Service业务层处理
...
...
@@ -16,7 +17,8 @@ import com.ruoyi.service.IAutomobileEnterpriseService;
* @date 2024-01-05
*/
@Service
public
class
AutomobileEnterpriseServiceImpl
implements
IAutomobileEnterpriseService
@Transactional
public
class
AutomobileEnterpriseServiceImpl
implements
AutomobileEnterpriseService
{
@Autowired
private
AutomobileEnterpriseMapper
automobileEnterpriseMapper
;
...
...
quality-review/src/main/java/com/ruoyi/web/AutomobileEnterpriseController.java
View file @
f6fd3269
...
...
@@ -5,24 +5,20 @@ import javax.servlet.http.HttpServletResponse;
import
com.ruoyi.common.annotation.Anonymous
;
import
com.ruoyi.common.core.domain.R
;
import
com.ruoyi.web.request.AutomobileEnterpriseRequest
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Qualifier
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.PutMapping
;
import
org.springframework.web.bind.annotation.DeleteMapping
;
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.RestController
;
import
com.ruoyi.common.annotation.Log
;
import
com.ruoyi.common.core.controller.BaseController
;
import
com.ruoyi.common.core.domain.AjaxResult
;
import
com.ruoyi.common.enums.BusinessType
;
import
com.ruoyi.domain.AutomobileEnterprise
;
import
com.ruoyi.service.
I
AutomobileEnterpriseService
;
import
com.ruoyi.service.AutomobileEnterpriseService
;
import
com.ruoyi.common.utils.poi.ExcelUtil
;
import
com.ruoyi.common.core.page.TableDataInfo
;
...
...
@@ -37,15 +33,17 @@ import com.ruoyi.common.core.page.TableDataInfo;
@RequestMapping
(
"/system/enterprise"
)
public
class
AutomobileEnterpriseController
extends
BaseController
{
@Autowired
private
I
AutomobileEnterpriseService
automobileEnterpriseService
;
private
AutomobileEnterpriseService
automobileEnterpriseService
;
/**
* 查询车企信息列表
*/
@Anonymous
@ApiOperation
(
"分页查询车企信息列表"
)
@
Ge
tMapping
(
"/list"
)
public
TableDataInfo
list
(
AutomobileEnterprise
automobileEnterprise
)
@
Pos
tMapping
(
"/list"
)
public
TableDataInfo
<
AutomobileEnterprise
>
list
(
AutomobileEnterprise
automobileEnterprise
)
{
startPage
();
List
<
AutomobileEnterprise
>
list
=
automobileEnterpriseService
.
selectAutomobileEnterpriseList
(
automobileEnterprise
);
...
...
@@ -68,11 +66,12 @@ public class AutomobileEnterpriseController extends BaseController
/**
* 获取车企信息详细信息
*/
@Anonymous
@ApiOperation
(
"获取车企信息详细信息"
)
@
GetMapping
(
value
=
"/{id}
"
)
public
R
getInfo
(
@PathVariable
(
"id"
)
Long
id
)
@
PostMapping
(
"/getById
"
)
public
R
<
AutomobileEnterprise
>
getInfo
(
@Validated
@RequestBody
AutomobileEnterpriseRequest
request
)
{
return
R
.
ok
(
automobileEnterpriseService
.
selectAutomobileEnterpriseById
(
id
));
return
R
.
ok
(
automobileEnterpriseService
.
selectAutomobileEnterpriseById
(
request
.
getId
()
));
}
/**
...
...
@@ -80,8 +79,8 @@ public class AutomobileEnterpriseController extends BaseController
*/
@ApiOperation
(
"新增车企信息"
)
@Log
(
title
=
"车企信息"
,
businessType
=
BusinessType
.
INSERT
)
@PostMapping
public
R
add
(
@RequestBody
AutomobileEnterprise
automobileEnterprise
)
@PostMapping
(
"/add"
)
public
R
<
Integer
>
add
(
@RequestBody
AutomobileEnterprise
automobileEnterprise
)
{
return
R
.
ok
(
automobileEnterpriseService
.
insertAutomobileEnterprise
(
automobileEnterprise
));
}
...
...
@@ -91,8 +90,8 @@ public class AutomobileEnterpriseController extends BaseController
*/
@ApiOperation
(
"修改车企信息"
)
@Log
(
title
=
"车企信息"
,
businessType
=
BusinessType
.
UPDATE
)
@P
utMapping
public
R
edit
(
@RequestBody
AutomobileEnterprise
automobileEnterprise
)
@P
ostMapping
(
"/edit"
)
public
R
<
Integer
>
edit
(
@RequestBody
AutomobileEnterprise
automobileEnterprise
)
{
return
R
.
ok
(
automobileEnterpriseService
.
updateAutomobileEnterprise
(
automobileEnterprise
));
}
...
...
@@ -102,9 +101,9 @@ public class AutomobileEnterpriseController extends BaseController
*/
@ApiOperation
(
"删除车企信息"
)
@Log
(
title
=
"车企信息"
,
businessType
=
BusinessType
.
DELETE
)
@
DeleteMapping
(
"/{ids}
"
)
public
R
remove
(
@PathVariable
Long
[]
ids
)
@
PostMapping
(
"/remove
"
)
public
R
<
Integer
>
remove
(
@Validated
@RequestBody
AutomobileEnterpriseRequest
request
)
{
return
R
.
ok
(
automobileEnterpriseService
.
deleteAutomobileEnterpriseByIds
(
ids
));
return
R
.
ok
(
automobileEnterpriseService
.
deleteAutomobileEnterpriseByIds
(
request
.
getIds
()
));
}
}
quality-review/src/main/java/com/ruoyi/web/request/AutomobileEnterpriseRequest.java
0 → 100644
View file @
f6fd3269
package
com
.
ruoyi
.
web
.
request
;
import
com.ruoyi.common.core.page.PageDomain
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
/**
* 车企信息DTO
* @author gxk
*/
@Data
@ApiModel
public
class
AutomobileEnterpriseRequest
extends
PageDomain
{
@ApiModelProperty
(
"ID"
)
private
Long
id
;
@ApiModelProperty
(
"车企ID集合"
)
private
Long
[]
ids
;
}
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