diff --git a/wfc-modules/wfc-system/src/main/java/org/wfc/system/controller/UPaymentController.java b/wfc-modules/wfc-system/src/main/java/org/wfc/system/controller/UPaymentController.java new file mode 100644 index 0000000..f8f80d4 --- /dev/null +++ b/wfc-modules/wfc-system/src/main/java/org/wfc/system/controller/UPaymentController.java @@ -0,0 +1,69 @@ +package org.wfc.system.controller; + +import cn.hutool.core.collection.CollUtil; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import org.wfc.common.core.web.controller.BaseController; +import org.wfc.common.core.web.domain.AjaxResult; +import org.wfc.common.core.web.page.TableDataInfo; +import org.wfc.system.domain.UPayment; +import org.wfc.system.service.IUPaymentService; + +import java.util.List; + +/** + *

+ * 用户平台-支付表 前端控制器 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@RestController +@RequestMapping("/system/uPayment") +public class UPaymentController extends BaseController { + + @Autowired + private IUPaymentService uPaymentService; + + @GetMapping("/page") + public TableDataInfo page(UPayment uPayment) { + startPage(); + List list = uPaymentService.list(); + return getDataTable(list); + } + + @GetMapping("/list") + public AjaxResult list(UPayment uPayment) { + List list = uPaymentService.list(); + return success(list); + } + + @GetMapping(value = "/{id}") + public AjaxResult getById(@PathVariable("id") Long id) { + return success(uPaymentService.getById(id)); + } + + @PostMapping + public AjaxResult add(@RequestBody UPayment uPayment) { + return toAjax(uPaymentService.save(uPayment)); + } + + @PutMapping + public AjaxResult edit(@RequestBody UPayment uPayment) { + return toAjax(uPaymentService.updateById(uPayment)); + } + + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(uPaymentService.removeByIds(CollUtil.newArrayList(ids))); + } + +} diff --git a/wfc-modules/wfc-system/src/main/java/org/wfc/system/domain/UPayment.java b/wfc-modules/wfc-system/src/main/java/org/wfc/system/domain/UPayment.java new file mode 100644 index 0000000..4d67d28 --- /dev/null +++ b/wfc-modules/wfc-system/src/main/java/org/wfc/system/domain/UPayment.java @@ -0,0 +1,58 @@ +package org.wfc.system.domain; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import org.wfc.common.mybatis.domain.BaseData; +import io.swagger.v3.oas.annotations.media.Schema; +import lombok.Getter; +import lombok.Setter; + +/** + *

+ * 用户平台-支付表 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@Getter +@Setter +@TableName("u_payment") +@Schema(name = "UPayment", description = "用户平台-支付表") +public class UPayment extends BaseData { + + private static final long serialVersionUID = 1L; + + @Schema(description = "支付名称") + private String name; + + @Schema(description = "类型(0支付宝 1微信 2信用卡)") + private Integer type; + + @Schema(description = "应用编号") + private String appId; + + @Schema(description = "支付网关") + private String serverUrl; + + @Schema(description = "外网访问项目的域名") + private String domain; + + @Schema(description = "应用私钥") + private String privateKey; + + @Schema(description = "应用公钥") + private String publicKey; + + @Schema(description = "应用公钥证书") + private String appCertPath; + + @Schema(description = "公钥证书") + private String certPath; + + @Schema(description = "根证书") + private String rootCertPath; + + @Schema(description = "是否启用") + private Boolean enable; +} diff --git a/wfc-modules/wfc-system/src/main/java/org/wfc/system/mapper/UPaymentMapper.java b/wfc-modules/wfc-system/src/main/java/org/wfc/system/mapper/UPaymentMapper.java new file mode 100644 index 0000000..abbc5ad --- /dev/null +++ b/wfc-modules/wfc-system/src/main/java/org/wfc/system/mapper/UPaymentMapper.java @@ -0,0 +1,16 @@ +package org.wfc.system.mapper; + +import org.wfc.system.domain.UPayment; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 用户平台-支付表 Mapper 接口 + *

+ * + * @author sys + * @since 2025-01-09 + */ +public interface UPaymentMapper extends BaseMapper { + +} diff --git a/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/IUPaymentService.java b/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/IUPaymentService.java new file mode 100644 index 0000000..01963bf --- /dev/null +++ b/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/IUPaymentService.java @@ -0,0 +1,16 @@ +package org.wfc.system.service; + +import org.wfc.system.domain.UPayment; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 用户平台-支付表 服务类 + *

+ * + * @author sys + * @since 2025-01-09 + */ +public interface IUPaymentService extends IService { + +} diff --git a/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/impl/UPaymentServiceImpl.java b/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/impl/UPaymentServiceImpl.java new file mode 100644 index 0000000..e56c06f --- /dev/null +++ b/wfc-modules/wfc-system/src/main/java/org/wfc/system/service/impl/UPaymentServiceImpl.java @@ -0,0 +1,20 @@ +package org.wfc.system.service.impl; + +import org.wfc.system.domain.UPayment; +import org.wfc.system.mapper.UPaymentMapper; +import org.wfc.system.service.IUPaymentService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 用户平台-支付表 服务实现类 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@Service +public class UPaymentServiceImpl extends ServiceImpl implements IUPaymentService { + +} diff --git a/wfc-modules/wfc-system/src/main/resources/mapper/system/UPaymentMapper.xml b/wfc-modules/wfc-system/src/main/resources/mapper/system/UPaymentMapper.xml new file mode 100644 index 0000000..d84c2e7 --- /dev/null +++ b/wfc-modules/wfc-system/src/main/resources/mapper/system/UPaymentMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/wfc-modules/wfc-user/src/main/java/org/wfc/user/controller/UPaymentController.java b/wfc-modules/wfc-user/src/main/java/org/wfc/user/controller/UPaymentController.java new file mode 100644 index 0000000..8960362 --- /dev/null +++ b/wfc-modules/wfc-user/src/main/java/org/wfc/user/controller/UPaymentController.java @@ -0,0 +1,69 @@ +package org.wfc.user.controller; + +import cn.hutool.core.collection.CollUtil; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import org.wfc.common.core.web.controller.BaseController; +import org.wfc.common.core.web.domain.AjaxResult; +import org.wfc.common.core.web.page.TableDataInfo; +import org.wfc.user.domain.UPayment; +import org.wfc.user.service.IUPaymentService; + +import java.util.List; + +/** + *

+ * 用户平台-支付表 前端控制器 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@RestController +@RequestMapping("/user/uPayment") +public class UPaymentController extends BaseController { + + @Autowired + private IUPaymentService uPaymentService; + + @GetMapping("/page") + public TableDataInfo page(UPayment uPayment) { + startPage(); + List list = uPaymentService.list(); + return getDataTable(list); + } + + @GetMapping("/list") + public AjaxResult list(UPayment uPayment) { + List list = uPaymentService.list(); + return success(list); + } + + @GetMapping(value = "/{id}") + public AjaxResult getById(@PathVariable("id") Long id) { + return success(uPaymentService.getById(id)); + } + + @PostMapping + public AjaxResult add(@RequestBody UPayment uPayment) { + return toAjax(uPaymentService.save(uPayment)); + } + + @PutMapping + public AjaxResult edit(@RequestBody UPayment uPayment) { + return toAjax(uPaymentService.updateById(uPayment)); + } + + @DeleteMapping("/{ids}") + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(uPaymentService.removeByIds(CollUtil.newArrayList(ids))); + } + +} diff --git a/wfc-modules/wfc-user/src/main/java/org/wfc/user/domain/UPayment.java b/wfc-modules/wfc-user/src/main/java/org/wfc/user/domain/UPayment.java new file mode 100644 index 0000000..2216e7d --- /dev/null +++ b/wfc-modules/wfc-user/src/main/java/org/wfc/user/domain/UPayment.java @@ -0,0 +1,58 @@ +package org.wfc.user.domain; + +import com.baomidou.mybatisplus.annotation.TableName; +import java.io.Serializable; +import org.wfc.common.mybatis.domain.BaseData; +import io.swagger.v3.oas.annotations.media.Schema; +import lombok.Getter; +import lombok.Setter; + +/** + *

+ * 用户平台-支付表 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@Getter +@Setter +@TableName("u_payment") +@Schema(name = "UPayment", description = "用户平台-支付表") +public class UPayment extends BaseData { + + private static final long serialVersionUID = 1L; + + @Schema(description = "支付名称") + private String name; + + @Schema(description = "类型(0支付宝 1微信 2信用卡)") + private Integer type; + + @Schema(description = "应用编号") + private String appId; + + @Schema(description = "支付网关") + private String serverUrl; + + @Schema(description = "外网访问项目的域名") + private String domain; + + @Schema(description = "应用私钥") + private String privateKey; + + @Schema(description = "应用公钥") + private String publicKey; + + @Schema(description = "应用公钥证书") + private String appCertPath; + + @Schema(description = "公钥证书") + private String certPath; + + @Schema(description = "根证书") + private String rootCertPath; + + @Schema(description = "是否启用") + private Boolean enable; +} diff --git a/wfc-modules/wfc-user/src/main/java/org/wfc/user/mapper/UPaymentMapper.java b/wfc-modules/wfc-user/src/main/java/org/wfc/user/mapper/UPaymentMapper.java new file mode 100644 index 0000000..34ee19c --- /dev/null +++ b/wfc-modules/wfc-user/src/main/java/org/wfc/user/mapper/UPaymentMapper.java @@ -0,0 +1,16 @@ +package org.wfc.user.mapper; + +import org.wfc.user.domain.UPayment; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + *

+ * 用户平台-支付表 Mapper 接口 + *

+ * + * @author sys + * @since 2025-01-09 + */ +public interface UPaymentMapper extends BaseMapper { + +} diff --git a/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/IUPaymentService.java b/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/IUPaymentService.java new file mode 100644 index 0000000..57765bd --- /dev/null +++ b/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/IUPaymentService.java @@ -0,0 +1,16 @@ +package org.wfc.user.service; + +import org.wfc.user.domain.UPayment; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + *

+ * 用户平台-支付表 服务类 + *

+ * + * @author sys + * @since 2025-01-09 + */ +public interface IUPaymentService extends IService { + +} diff --git a/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/impl/UPaymentServiceImpl.java b/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/impl/UPaymentServiceImpl.java new file mode 100644 index 0000000..668d68f --- /dev/null +++ b/wfc-modules/wfc-user/src/main/java/org/wfc/user/service/impl/UPaymentServiceImpl.java @@ -0,0 +1,20 @@ +package org.wfc.user.service.impl; + +import org.wfc.user.domain.UPayment; +import org.wfc.user.mapper.UPaymentMapper; +import org.wfc.user.service.IUPaymentService; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.stereotype.Service; + +/** + *

+ * 用户平台-支付表 服务实现类 + *

+ * + * @author sys + * @since 2025-01-09 + */ +@Service +public class UPaymentServiceImpl extends ServiceImpl implements IUPaymentService { + +} diff --git a/wfc-modules/wfc-user/src/main/resources/mapper/user/UPaymentMapper.xml b/wfc-modules/wfc-user/src/main/resources/mapper/user/UPaymentMapper.xml new file mode 100644 index 0000000..49f7563 --- /dev/null +++ b/wfc-modules/wfc-user/src/main/resources/mapper/user/UPaymentMapper.xml @@ -0,0 +1,5 @@ + + + + +