Compare commits
42 Commits
Author | SHA1 | Date |
---|---|---|
|
3e539806a7 | |
|
085455098c | |
|
3208a94e3a | |
|
219836225b | |
|
d9a0d443d8 | |
|
5b7e09c250 | |
|
9fc9640d19 | |
|
1aa45c06c6 | |
|
4814dd5722 | |
|
8fc61c539a | |
|
631ee0eeb2 | |
|
8de4d707aa | |
|
d9232a3a57 | |
|
4142283e4c | |
|
e276c30b82 | |
|
e4f26c8fa0 | |
|
b071358ab1 | |
|
27d6538eca | |
|
59a5ddc03a | |
|
bbbd8960b5 | |
|
a995347b54 | |
|
055d9741e8 | |
|
5f438eb78c | |
|
faccb76a75 | |
|
e187813e0b | |
|
4de8ee516e | |
|
a1044924b5 | |
|
abca2eb9d6 | |
|
8037d9a93a | |
|
c621f8e42b | |
|
8b5d3cb5ea | |
|
085277bf83 | |
|
7a61976dd0 | |
|
d5d328a74a | |
|
dd84f5b334 | |
|
18f20efe02 | |
|
9569223c90 | |
|
085640abc4 | |
|
5689ca1157 | |
|
acdfc6c6e3 | |
|
d220e23ce6 | |
|
23e7320db6 |
|
@ -1,17 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="Encoding">
|
||||
<file url="file://$APPLICATION_HOME_DIR$/jbr/bin/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$APPLICATION_HOME_DIR$/jbr/bin/src/main/resources" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-client/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-client/src/main/resources" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-common/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-common/src/main/resources" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-remote/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-remote/src/main/resources" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-server/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/cloud-market-server/src/main/resources" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/src/main/java" charset="UTF-8" />
|
||||
<file url="file://$PROJECT_DIR$/src/main/resources" charset="UTF-8" />
|
||||
</component>
|
||||
</project>
|
||||
</project>
|
|
@ -23,6 +23,12 @@
|
|||
<groupId>com.muyu</groupId>
|
||||
<artifactId>cloud-common-core</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springdoc</groupId>
|
||||
<artifactId>springdoc-openapi-starter-common</artifactId>
|
||||
<version>2.0.4</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
|
|
@ -10,6 +10,8 @@ import lombok.EqualsAndHashCode;
|
|||
import lombok.NoArgsConstructor;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
import java.util.function.Supplier;
|
||||
|
||||
/**
|
||||
接口列表
|
||||
*/
|
||||
|
@ -44,5 +46,25 @@ public class Connector extends BaseEntity {
|
|||
*/
|
||||
private Integer status;
|
||||
|
||||
//添加
|
||||
public static Connector addBuild(Connector connector){
|
||||
return Connector.builder()
|
||||
.connectorName(connector.connectorName)
|
||||
.connectorDescription(connector.connectorDescription)
|
||||
.connectorNum(connector.connectorNum)
|
||||
.status(connector.status)
|
||||
.build();
|
||||
}
|
||||
|
||||
//修改
|
||||
public static Connector updBuild(Connector connector, Supplier<Long> supplier){
|
||||
return Connector.builder()
|
||||
.connectorId(supplier.get())
|
||||
.connectorName(connector.connectorName)
|
||||
.connectorDescription(connector.connectorDescription)
|
||||
.connectorNum(connector.connectorNum)
|
||||
.status(connector.status)
|
||||
.build();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -48,7 +48,7 @@ public class Defined extends BaseEntity {
|
|||
/**
|
||||
* 有效期(天)
|
||||
*/
|
||||
private Integer definedDateValidity ;
|
||||
private Integer definedDataValidity ;
|
||||
/**
|
||||
* 接口类型
|
||||
*/
|
||||
|
|
|
@ -11,6 +11,7 @@ import lombok.NoArgsConstructor;
|
|||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
/***
|
||||
* 支付表
|
||||
|
@ -45,4 +46,25 @@ public class Pay extends BaseEntity {
|
|||
*/
|
||||
private Date payTime;
|
||||
|
||||
//添加
|
||||
public static Pay addBuild(Pay pay){
|
||||
return Pay.builder()
|
||||
.payStatus(pay.payStatus)
|
||||
.payTime(pay.payTime)
|
||||
.payType(pay.payType)
|
||||
.userId(pay.userId)
|
||||
.build();
|
||||
}
|
||||
|
||||
//修改
|
||||
public static Pay updBuild(Pay pay, Supplier<Long> supplier){
|
||||
return Pay.builder()
|
||||
.payId(supplier.get())
|
||||
.payStatus(pay.payStatus)
|
||||
.payTime(pay.payTime)
|
||||
.payType(pay.payType)
|
||||
.userId(pay.userId)
|
||||
.build();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -36,4 +36,5 @@ public class Rule extends BaseEntity {
|
|||
/** 使用次数 */
|
||||
private Integer ruleNum ;
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,128 @@
|
|||
|
||||
package com.muyu.market.domian.config;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.OrderItem;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.PageDTO;
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import org.springdoc.core.annotations.ParameterObject;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 分页参数
|
||||
*/
|
||||
@Schema
|
||||
@ParameterObject
|
||||
public class PageParam<T> extends PageDTO<T> {
|
||||
|
||||
private static final int PAGE_LIMIT = 100;
|
||||
/**
|
||||
* 每页显示条数,默认 10
|
||||
*/
|
||||
@Schema(description = "每页大小,默认10")
|
||||
private long size = 10;
|
||||
|
||||
/**
|
||||
* 当前页
|
||||
*/
|
||||
@Schema(description = "当前页,默认1")
|
||||
private long current = 1;
|
||||
|
||||
/**
|
||||
* 查询数据列表
|
||||
*/
|
||||
@Hidden
|
||||
private List<T> records;
|
||||
/**
|
||||
* 总数
|
||||
*/
|
||||
@Hidden
|
||||
private long total = 0;
|
||||
|
||||
|
||||
/**
|
||||
* 是否进行 count 查询
|
||||
*/
|
||||
@Hidden
|
||||
private boolean searchCount = true;
|
||||
|
||||
@Hidden
|
||||
private String countId;
|
||||
@Hidden
|
||||
private Long maxLimit;
|
||||
@Hidden
|
||||
private boolean optimizeCountSql;
|
||||
@Hidden
|
||||
private List<OrderItem> orders;
|
||||
|
||||
@Override
|
||||
public List<T> getRecords() {
|
||||
return this.records;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<T> setRecords(List<T> records) {
|
||||
this.records = records;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getTotal() {
|
||||
return this.total;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<T> setTotal(long total) {
|
||||
this.total = total;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Hidden
|
||||
public boolean searchCount() {
|
||||
if (total < 0) {
|
||||
return false;
|
||||
}
|
||||
return searchCount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<T> setSearchCount(boolean searchCount) {
|
||||
this.searchCount = searchCount;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getSize() {
|
||||
return this.size;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<T> setSize(long size) {
|
||||
if (size > PAGE_LIMIT) {
|
||||
this.size = PAGE_LIMIT;
|
||||
} else {
|
||||
this.size = size;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getCurrent() {
|
||||
return this.current;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<T> setCurrent(long current) {
|
||||
this.current = current;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setOrders(List<OrderItem> orders) {
|
||||
super.setOrders(Collections.emptyList());
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,35 @@
|
|||
package com.muyu.market.domian.req;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.*;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
/**
|
||||
接口列表
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Tag(name = "接口列表")
|
||||
public class ConnectorReq {
|
||||
|
||||
|
||||
/**
|
||||
* 接口名称
|
||||
*/
|
||||
private String connectorName;
|
||||
|
||||
|
||||
/**
|
||||
* 状态
|
||||
*/
|
||||
private Integer status;
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,61 @@
|
|||
package com.muyu.market.domian.req;
|
||||
|
||||
import com.muyu.market.domian.Defined;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.market.domian.req
|
||||
* @Filename:DefinedReq
|
||||
* @Description TODO
|
||||
* @Date:2024/8/22 22:01
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Tag(name = "定义接口列表")
|
||||
public class DefinedReq {
|
||||
|
||||
/**
|
||||
* 定义名称
|
||||
*/
|
||||
private String definedName ;
|
||||
|
||||
/**
|
||||
* 有效期(天)
|
||||
*/
|
||||
private Integer definedDateValidity ;
|
||||
|
||||
|
||||
// private List<DefinedReq>definedReqList;
|
||||
|
||||
/**
|
||||
* 数据库对象构建为返回结果对象
|
||||
* @param
|
||||
* @return 视图对象
|
||||
*/
|
||||
|
||||
//
|
||||
// public static DefinedReq definedBuild(Defined defined, Supplier<List<DefinedReq>>function) {
|
||||
//
|
||||
// return DefinedReq.builder()
|
||||
// .definedDateValidity(defined.getDefinedDateValidity())
|
||||
// .definedName(defined.getDefinedName())
|
||||
// .definedReqList(function.get())
|
||||
// .build();
|
||||
// }
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,40 @@
|
|||
package com.muyu.market.domian.req;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.*;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/***
|
||||
* 支付表
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Tag(name = "支付列表")
|
||||
public class PayReq {
|
||||
|
||||
|
||||
/**
|
||||
* 支付类型
|
||||
*/
|
||||
private Integer payType;
|
||||
/**
|
||||
* 支付状态
|
||||
*/
|
||||
private Integer payStatus;
|
||||
|
||||
|
||||
/**
|
||||
* 支付时间
|
||||
*/
|
||||
private Date payTime;
|
||||
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
package com.muyu.market.domian.req;
|
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.muyu.common.core.web.domain.BaseEntity;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.*;
|
||||
import lombok.experimental.SuperBuilder;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Description 接口规则
|
||||
* @Date:2024/8/20 11:17
|
||||
*/
|
||||
@Data
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Tag(name = "接口规则列表")
|
||||
public class RuleReq {
|
||||
|
||||
|
||||
/** 规则名称 */
|
||||
private String ruleName ;
|
||||
|
||||
|
||||
/** 规则状态 */
|
||||
private Integer status ;
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -17,6 +17,8 @@
|
|||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
|
@ -98,6 +100,7 @@
|
|||
<dependency>
|
||||
<groupId>com.muyu</groupId>
|
||||
<artifactId>cloud-common-nacos-remote</artifactId>
|
||||
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
|
|
@ -0,0 +1,90 @@
|
|||
package com.muyu.market.controller;
|
||||
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.market.domian.Connector;
|
||||
import com.muyu.market.domian.Pay;
|
||||
import com.muyu.market.service.ConnectorService;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/connector")
|
||||
@Tag(name = "接口调用展示",description = "进行接口调用量的展示")
|
||||
public class ConnectorController {
|
||||
|
||||
@Autowired
|
||||
private ConnectorService service;
|
||||
|
||||
|
||||
/**
|
||||
* 查询接口调用量
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
@Operation(summary = "查询接口调用量",description = "查询接口调用量")
|
||||
public Result<List<Connector>> showList(){
|
||||
List<Connector> list=service.showList();
|
||||
return Result.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加信息
|
||||
* @param
|
||||
* @return 添加结果
|
||||
*/
|
||||
@PostMapping
|
||||
@Operation(summary = "信息添加",description = "添加信息,添加成功之后才可以只用支付类的产品")
|
||||
public Result<String> save(@Validated @RequestBody Connector connector){
|
||||
service.save(Connector.addBuild(connector));
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
|
||||
// /**
|
||||
// * 修改客户
|
||||
// * @param
|
||||
// * @return 修改结果
|
||||
// */
|
||||
// @PutMapping("/{connectorId}")
|
||||
// @Operation(summary = "客户信息修改",description = "通过ID修改客户信息")
|
||||
// public Result<String> update(
|
||||
// @Schema(title = "客户ID",type = "Long",defaultValue = "1",description = "修改客户信息需要依据的唯一条件")
|
||||
// @PathVariable("connectorId") Long connectorId,
|
||||
// @RequestBody @Validated Connector connector){
|
||||
// service.updateById(Connector.updBuild(connector,
|
||||
// () -> connectorId));
|
||||
// return Result.success(null,"操作成功");
|
||||
// }
|
||||
|
||||
/**
|
||||
* 删除客户
|
||||
* @param connectorId 删除客户请求信息
|
||||
* @return 删除结果
|
||||
*/
|
||||
@DeleteMapping("/{connectorId}")
|
||||
@Operation(summary = "信息删除",description = "通过ID删除信息")
|
||||
public Result<String> delete(@PathVariable("connectorId") Long connectorId){
|
||||
service.removeById(connectorId);
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过ID获取客户
|
||||
* @param connectorId ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
@GetMapping("/{connectorId}")
|
||||
@Operation(summary = "通过ID获取信息",description = "通过ID获取信息")
|
||||
public Result<Connector> findById(@PathVariable("connectorId") Long connectorId){
|
||||
return Result.success(service.getById(connectorId),"操作成功");
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,115 @@
|
|||
package com.muyu.market.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.dtflys.forest.springboot.annotation.ForestScannerRegister;
|
||||
import com.muyu.common.core.domain.Result;
|
||||
|
||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||
import com.muyu.market.domian.Defined;
|
||||
import com.muyu.market.domian.config.PageParam;
|
||||
import com.muyu.market.domian.req.DefinedReq;
|
||||
import com.muyu.market.service.DefinedService;
|
||||
import io.micrometer.common.util.StringUtils;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.controller
|
||||
* @Filename:MarketController
|
||||
* @Description 定义接口
|
||||
* @Date:2024/8/20 11:17
|
||||
*/
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/market")
|
||||
@Tag(name = "定义接口控制层",description = "进行客户管理,查看等相关操作")
|
||||
public class DefinedController {
|
||||
|
||||
public DefinedController() {
|
||||
log.info("forest扫描路径:{}", ForestScannerRegister.getBasePackages());
|
||||
}
|
||||
|
||||
/**
|
||||
* 接口业务层
|
||||
*/
|
||||
@Autowired
|
||||
private DefinedService definedService;
|
||||
|
||||
|
||||
/**
|
||||
* 接口列表 分页 查询
|
||||
*/
|
||||
@RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
@Operation(summary = "查询",description = "根据接口的名称 有效期 等可以进行筛选")
|
||||
public Result<PageParam<Defined>> selectList(PageParam<Defined> page,
|
||||
@Validated @RequestBody DefinedReq definedReq) {
|
||||
|
||||
/**模糊查询 名称**/
|
||||
LambdaQueryWrapper<Defined> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.like(
|
||||
StringUtils.isNotEmpty(definedReq.getDefinedName()),
|
||||
Defined::getDefinedName,definedReq.getDefinedName()
|
||||
);
|
||||
|
||||
/**模糊查询 有效期**/
|
||||
queryWrapper.like(
|
||||
StringUtils.isNotEmpty(String.valueOf(definedReq.getDefinedDateValidity())),
|
||||
Defined::getDefinedDataValidity,
|
||||
definedReq.getDefinedDateValidity()
|
||||
);
|
||||
|
||||
PageParam<Defined>pageDTO=definedService.page(page,queryWrapper);
|
||||
|
||||
return Result.success(pageDTO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 接口添加
|
||||
*/
|
||||
@PostMapping
|
||||
@Operation(summary = "添加", description = "根据接口实体类添加,添加成功之后才可以使用支付类产品")
|
||||
public Result<String> save(@Validated @RequestBody Defined defined) {
|
||||
definedService.save(defined);
|
||||
return Result.success();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 接口修改
|
||||
*/
|
||||
@PutMapping("/{definedId}")
|
||||
@Operation(summary = "修改", description = "通过ID修改信息")
|
||||
public Result<String> updateById(
|
||||
@Schema(title = "ID", defaultValue = "1", type = "Long", description = "修改信息所需的唯一条件")
|
||||
@Validated @RequestBody Defined defined
|
||||
) {
|
||||
|
||||
definedService.updateById(defined);
|
||||
return Result.success();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 通过id查询信息
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "根据id获取信息",description = "根据id获取信息")
|
||||
@GetMapping("/{definedId}")
|
||||
public Result<Defined> findById(@PathVariable("definedId") Long definedId){
|
||||
definedService.getById(definedId);
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -1,8 +1,9 @@
|
|||
package com.muyu.master.controller;
|
||||
package com.muyu.market.controller;
|
||||
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||
import com.muyu.market.domian.Logs;
|
||||
import com.muyu.master.service.LogsService;
|
||||
import com.muyu.market.service.LogsService;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
|
@ -11,6 +12,7 @@ import org.springframework.web.bind.annotation.*;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/logs")
|
||||
|
@ -24,9 +26,9 @@ public class LogsController {
|
|||
* 查询日志列表
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "查询日志列表",description = "查询用户操作日志列表")
|
||||
@GetMapping("/list")
|
||||
public Result<List<Logs>> show(){
|
||||
@RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
@Operation(summary = "查询",description = "查询日志列表")
|
||||
public Result<List<Logs>> list(){
|
||||
List<Logs> list=service.showList();
|
||||
return Result.success(list);
|
||||
}
|
|
@ -0,0 +1,112 @@
|
|||
package com.muyu.market.controller;
|
||||
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.market.domian.Pay;
|
||||
import com.muyu.market.service.PayService;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/pay")
|
||||
@Tag(name = "支付接口",description = "进行支付管理,查看等相关操作")
|
||||
public class PayController {
|
||||
|
||||
@Autowired
|
||||
private PayService service;
|
||||
|
||||
/**
|
||||
* 查询支付日志列表
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
@Operation(summary = "支付接口查询",description = "查询支付接口日志列表")
|
||||
public Result<List<Pay>> showList(){
|
||||
List<Pay> list=service.showList();
|
||||
return Result.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加支付信息
|
||||
* @param
|
||||
* @return 添加结果
|
||||
*/
|
||||
@PostMapping
|
||||
@Operation(summary = "客户信息添加",description = "添加支付平台客户信息,添加成功之后才可以只用支付类的产品")
|
||||
public Result<String> save(@Validated @RequestBody Pay pay){
|
||||
service.save(Pay.addBuild(pay));
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改客户
|
||||
* @param
|
||||
* @return 修改结果
|
||||
*/
|
||||
@PutMapping("/{payId}")
|
||||
@Operation(summary = "客户信息修改",description = "通过ID修改客户信息")
|
||||
public Result<String> update(
|
||||
@Schema(title = "客户ID",type = "Long",defaultValue = "1",description = "修改客户信息需要依据的唯一条件")
|
||||
@PathVariable("payId") Long payId,
|
||||
@RequestBody @Validated Pay pay){
|
||||
service.updateById(Pay.updBuild(pay,
|
||||
() -> payId));
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除客户
|
||||
* @param payId 删除客户请求信息
|
||||
* @return 删除结果
|
||||
*/
|
||||
@DeleteMapping("/{payId}")
|
||||
@Operation(summary = "客户信息删除",description = "通过ID删除客户信息,七天内存在支付先关记录的客户,不可进行删除")
|
||||
public Result<String> delete(@PathVariable("payId") Long payId){
|
||||
service.removeById(payId);
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过ID获取客户
|
||||
* @param payId ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
@GetMapping("/{payId}")
|
||||
@Operation(summary = "通过ID获取客户",description = "通过ID获取客户")
|
||||
public Result<Pay> findById(@PathVariable("payId") Long payId){
|
||||
return Result.success(service.getById(payId),"操作成功");
|
||||
}
|
||||
|
||||
|
||||
// /**
|
||||
// * 通过ID禁用
|
||||
// * @param payId ID
|
||||
// * @return 禁用结果
|
||||
// */
|
||||
// @GetMapping("/disable/{orderCustomerId}")
|
||||
// @Operation(summary = "通过ID禁用客户",description = "通过ID获取客户,禁用之后禁止调用支付相关接口")
|
||||
// public Result<String> disable(@PathVariable("payId") Long payId){
|
||||
// this.service.disable(payId);
|
||||
// return Result.success(null,"操作成功");
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 通过ID启用
|
||||
// * @param payId ID
|
||||
// * @return 启用结果
|
||||
// */
|
||||
// @GetMapping("/enable/{orderCustomerId}")
|
||||
// @Operation(summary = "通过ID启用客户",description = "通过ID启用客户,启用之后可以进行支付相关接口的调用")
|
||||
// public Result<String> enable(@PathVariable("payId") Long payId){
|
||||
// this.service.enable(payId);
|
||||
// return Result.success(null,"操作成功");
|
||||
// }
|
||||
|
||||
}
|
|
@ -0,0 +1,110 @@
|
|||
package com.muyu.market.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.market.domian.Connector;
|
||||
import com.muyu.market.domian.Defined;
|
||||
import com.muyu.market.domian.Rule;
|
||||
import com.muyu.market.domian.config.PageParam;
|
||||
import com.muyu.market.domian.req.DefinedReq;
|
||||
import com.muyu.market.domian.req.RuleReq;
|
||||
import com.muyu.market.service.ConnectorService;
|
||||
import com.muyu.market.service.RuleService;
|
||||
import io.micrometer.common.util.StringUtils;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/rule")
|
||||
@Tag(name = "接口调用展示",description = "进行接口调用量的展示")
|
||||
public class RuleController {
|
||||
|
||||
@Autowired
|
||||
private RuleService service;
|
||||
|
||||
|
||||
/**
|
||||
* 接口列表 分页 查询
|
||||
*/
|
||||
@RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
@Operation(summary = "查询",description = "根据接口的名称 有效期 等可以进行筛选")
|
||||
public Result<PageParam<Rule>> selectList(PageParam<Rule> page,
|
||||
@Validated @RequestBody RuleReq ruleReq) {
|
||||
|
||||
/**模糊查询 名称**/
|
||||
LambdaQueryWrapper<Rule> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.like(
|
||||
StringUtils.isNotEmpty(ruleReq.getRuleName()),
|
||||
Rule::getRuleName,ruleReq.getRuleName()
|
||||
);
|
||||
|
||||
/**模糊查询 有效期**/
|
||||
queryWrapper.like(
|
||||
StringUtils.isNotEmpty(String.valueOf(ruleReq.getStatus())),
|
||||
Rule::getStatus,
|
||||
ruleReq.getStatus()
|
||||
);
|
||||
|
||||
PageParam<Rule>pageDTO=service.page(page,queryWrapper);
|
||||
|
||||
return Result.success(pageDTO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 添加
|
||||
*/
|
||||
@PostMapping
|
||||
@Operation(summary = "添加", description = "根据接口实体类添加,添加成功之后才可以使用支付类产品")
|
||||
public Result<String> save(@Validated @RequestBody Rule rule) {
|
||||
service.save(rule);
|
||||
return Result.success();
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 修改客户
|
||||
// * @param
|
||||
// * @return 修改结果
|
||||
// */
|
||||
// @PutMapping("/{connectorId}")
|
||||
// @Operation(summary = "客户信息修改",description = "通过ID修改客户信息")
|
||||
// public Result<String> update(
|
||||
// @Schema(title = "客户ID",type = "Long",defaultValue = "1",description = "修改客户信息需要依据的唯一条件")
|
||||
// @PathVariable("connectorId") Long connectorId,
|
||||
// @RequestBody @Validated Connector connector){
|
||||
// service.updateById(Connector.updBuild(connector,
|
||||
// () -> connectorId));
|
||||
// return Result.success(null,"操作成功");
|
||||
// }
|
||||
|
||||
/**
|
||||
* 删除客户
|
||||
* @param ruleId 删除客户请求信息
|
||||
* @return 删除结果
|
||||
*/
|
||||
@DeleteMapping("/{ruleId}")
|
||||
@Operation(summary = "信息删除",description = "通过ID删除信息")
|
||||
public Result<String> delete(@PathVariable("ruleId") Long ruleId){
|
||||
service.removeById(ruleId);
|
||||
return Result.success(null,"操作成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过ID获取客户
|
||||
* @param ruleId ID
|
||||
* @return 客户信息
|
||||
*/
|
||||
@GetMapping("/{ruleId}")
|
||||
@Operation(summary = "通过ID获取信息",description = "通过ID获取信息")
|
||||
public Result<Rule> findById(@PathVariable("ruleId") Long ruleId){
|
||||
return Result.success(service.getById(ruleId),"操作成功");
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
package com.muyu.market.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.market.domian.Connector;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface ConnectorMapper extends BaseMapper<Connector> {
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
package com.muyu.master.mapper;
|
||||
package com.muyu.market.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.market.domian.Defined;
|
|
@ -1,4 +1,4 @@
|
|||
package com.muyu.master.mapper;
|
||||
package com.muyu.market.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.market.domian.Logs;
|
|
@ -0,0 +1,15 @@
|
|||
package com.muyu.market.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.market.domian.Pay;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@Mapper
|
||||
public interface PayMapper extends BaseMapper<Pay> {
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,17 @@
|
|||
package com.muyu.market.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.muyu.market.domian.Rule;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.market.mapper
|
||||
* @Filename:RuleMapper
|
||||
* @Description TODO
|
||||
* @Date:2024/8/25 14:12
|
||||
*/
|
||||
@Mapper
|
||||
public interface RuleMapper extends BaseMapper<Rule> {
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.muyu.market.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.market.domian.Connector;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface ConnectorService extends IService<Connector> {
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
* @return
|
||||
*/
|
||||
List<Connector> showList();
|
||||
}
|
|
@ -1,8 +1,8 @@
|
|||
package com.muyu.master.service;
|
||||
package com.muyu.market.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.market.domian.Defined;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
|
@ -14,4 +14,6 @@ import java.util.List;
|
|||
*/
|
||||
public interface DefinedService extends IService<Defined> {
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
package com.muyu.master.service;
|
||||
package com.muyu.market.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.market.domian.Logs;
|
||||
|
@ -8,6 +8,6 @@ import java.util.List;
|
|||
|
||||
public interface LogsService extends IService<Logs> {
|
||||
|
||||
List<Logs> showList();
|
||||
|
||||
List<Logs> showList();
|
||||
}
|
|
@ -0,0 +1,14 @@
|
|||
package com.muyu.market.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.market.domian.Logs;
|
||||
import com.muyu.market.domian.Pay;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
public interface PayService extends IService<Pay> {
|
||||
|
||||
|
||||
List<Pay> showList();
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
package com.muyu.market.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.market.domian.Rule;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.market.service
|
||||
* @Filename:RuleService
|
||||
* @Description TODO
|
||||
* @Date:2024/8/25 14:10
|
||||
*/
|
||||
public interface RuleService extends IService<Rule> {
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
package com.muyu.market.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.market.domian.Connector;
|
||||
import com.muyu.market.mapper.ConnectorMapper;
|
||||
import com.muyu.market.service.ConnectorService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Service
|
||||
public class ConnectorServiceImpl
|
||||
extends ServiceImpl<ConnectorMapper, Connector>
|
||||
implements ConnectorService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private ConnectorMapper mapper;
|
||||
|
||||
|
||||
/**
|
||||
* 列表查询
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public List<Connector> showList() {
|
||||
|
||||
LambdaQueryWrapper<Connector> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.select(Connector::getConnectorId);
|
||||
List<Connector> list = this.list();
|
||||
list.stream().map(Connector::getConnectorId).collect(Collectors.toSet());
|
||||
return this.list(queryWrapper).stream().toList();
|
||||
}
|
||||
}
|
|
@ -1,17 +1,17 @@
|
|||
package com.muyu.master.service.impl;
|
||||
package com.muyu.market.service.impl;
|
||||
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.market.domian.Defined;
|
||||
import com.muyu.master.mapper.DefinedMapper;
|
||||
|
||||
import com.muyu.master.service.DefinedService;
|
||||
import io.micrometer.common.util.StringUtils;
|
||||
import com.muyu.market.mapper.DefinedMapper;
|
||||
|
||||
import com.muyu.market.service.DefinedService;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
|
@ -1,10 +1,10 @@
|
|||
package com.muyu.master.service.impl;
|
||||
package com.muyu.market.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.market.domian.Logs;
|
||||
import com.muyu.master.mapper.LogsMapper;
|
||||
import com.muyu.master.service.LogsService;
|
||||
import com.muyu.market.mapper.LogsMapper;
|
||||
import com.muyu.market.service.LogsService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
|
@ -19,16 +19,13 @@ public class LogsServiceImpl
|
|||
@Autowired
|
||||
private LogsMapper mapper;
|
||||
|
||||
|
||||
@Override
|
||||
public List<Logs> showList() {
|
||||
|
||||
LambdaQueryWrapper<Logs> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.select(Logs::getLogsId);//根据用户id查询
|
||||
queryWrapper.select(Logs::getLogsId);
|
||||
List<Logs> list = this.list();
|
||||
|
||||
list.stream().map(Logs::getLogsId).collect(Collectors.toSet());
|
||||
return this.list(queryWrapper)
|
||||
.stream()
|
||||
.toList();
|
||||
return this.list(queryWrapper).stream().toList();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,28 @@
|
|||
package com.muyu.market.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.market.domian.Pay;
|
||||
import com.muyu.market.mapper.PayMapper;
|
||||
import com.muyu.market.service.PayService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Service
|
||||
public class PayServiceImpl
|
||||
extends ServiceImpl<PayMapper, Pay>
|
||||
implements PayService {
|
||||
|
||||
|
||||
@Override
|
||||
public List<Pay> showList() {
|
||||
LambdaQueryWrapper<Pay> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.select(Pay::getPayId);
|
||||
List<Pay> list = this.list();
|
||||
|
||||
list.stream().map(Pay::getPayId).collect(Collectors.toSet());
|
||||
return this.list(queryWrapper).stream().toList();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,28 @@
|
|||
package com.muyu.market.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.Mapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.muyu.market.domian.Rule;
|
||||
import com.muyu.market.mapper.RuleMapper;
|
||||
import com.muyu.market.service.RuleService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.market.service.impl
|
||||
* @Filename:RuleServiceImpl
|
||||
* @Description TODO
|
||||
* @Date:2024/8/25 14:11
|
||||
*/
|
||||
@Service
|
||||
public class RuleServiceImpl extends ServiceImpl<RuleMapper,Rule> implements RuleService {
|
||||
|
||||
@Autowired
|
||||
private RuleMapper ruleMapper;
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
|
@ -1,79 +0,0 @@
|
|||
package com.muyu.master.controller;
|
||||
|
||||
import com.muyu.common.core.domain.Result;
|
||||
import com.muyu.common.security.annotation.RequiresPermissions;
|
||||
import com.muyu.market.domian.Defined;
|
||||
import com.muyu.master.service.DefinedService;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author:ChenYan
|
||||
* @Project:2112-cloud-market
|
||||
* @Package:com.muyu.controller
|
||||
* @Filename:MarketController
|
||||
* @Description 定义接口
|
||||
* @Date:2024/8/20 11:17
|
||||
*/
|
||||
|
||||
@Log4j2
|
||||
@RestController
|
||||
@RequestMapping("/master")
|
||||
@Tag(name = "定义接口控制层",description = "进行客户管理,查看等相关操作")
|
||||
public class DefinedController {
|
||||
|
||||
|
||||
// /**
|
||||
// * 接口业务层
|
||||
// */
|
||||
// @Autowired
|
||||
// private DefinedService definedService;
|
||||
//
|
||||
// /**
|
||||
// * 接口列表
|
||||
// */
|
||||
// @RequestMapping(path = "/list",method = RequestMethod.POST)
|
||||
// @Operation(summary = "查询",description = "根据接口的名称、编码,是否开启等可以进行筛选")
|
||||
// public Result<List<Defined>> selectList(
|
||||
// @Validated @RequestBody Defined defined) {
|
||||
// return Result.success(
|
||||
// definedService.selectList(defined)
|
||||
// );
|
||||
// }
|
||||
//
|
||||
//
|
||||
// /**
|
||||
// * 接口添加
|
||||
// */
|
||||
// @PostMapping
|
||||
// @Operation(summary = "添加", description = "根据接口实体类添加,添加成功之后才可以使用支付类产品")
|
||||
// public Result<String> save(@Validated @RequestBody Defined defined) {
|
||||
// definedService.save(defined);
|
||||
// return Result.success();
|
||||
// }
|
||||
//
|
||||
//
|
||||
// /**
|
||||
// * 接口修改
|
||||
// */
|
||||
// @PutMapping("/{definedId}")
|
||||
// @Operation(summary = "修改", description = "通过ID修改信息")
|
||||
// public Result<String> updateById(
|
||||
// @Validated @RequestBody Defined defined,
|
||||
// @Schema(title = "ID", defaultValue = "1", type = "Long", description = "修改信息所需的唯一条件")
|
||||
// @PathVariable("definedId") Long definedId) {
|
||||
//
|
||||
// definedService.updateById(defined);
|
||||
// return Result.success();
|
||||
// }
|
||||
|
||||
|
||||
}
|
|
@ -15,7 +15,7 @@ spring:
|
|||
allow-bean-definition-overriding: true
|
||||
application:
|
||||
# 应用名称
|
||||
name: cloud-master
|
||||
name: cloud-market
|
||||
profiles:
|
||||
# 环境配置
|
||||
active: dev
|
||||
|
|
|
@ -14,7 +14,7 @@ org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse
|
|||
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1363)
|
||||
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1352)
|
||||
at com.muyu.MuYuMarketApplication.main(MuYuMarketApplication.java:19)
|
||||
Caused by: org.springframework.context.annotation.ConflictingBeanDefinitionException: Annotation-specified bean name 'definedController' for bean class [com.muyu.master.controller.DefinedController] conflicts with existing, non-compatible bean definition of same name and class [com.muyu.market.controller.DefinedController]
|
||||
Caused by: org.springframework.context.annotation.ConflictingBeanDefinitionException: Annotation-specified bean name 'definedController' for bean class [com.muyu.market.controller.DefinedController] conflicts with existing, non-compatible bean definition of same name and class [com.muyu.market.controller.DefinedController]
|
||||
at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.checkCandidate(ClassPathBeanDefinitionScanner.java:361)
|
||||
at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.doScan(ClassPathBeanDefinitionScanner.java:288)
|
||||
at org.springframework.context.annotation.ComponentScanAnnotationParser.parse(ComponentScanAnnotationParser.java:128)
|
||||
|
|
Loading…
Reference in New Issue