通用文件新项目

This commit is contained in:
wuchunlei
2024-03-25 17:46:34 +08:00
parent 92a582bee0
commit 21a8309563
23 changed files with 858 additions and 22 deletions

View File

@@ -0,0 +1,70 @@
package com.peanut.modules.master.controller;
import com.peanut.common.utils.PageUtils;
import com.peanut.common.utils.R;
import com.peanut.modules.common.entity.PayPaymentOrderEntity;
import com.peanut.modules.master.service.PayPaymentOrderService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.Arrays;
import java.util.Map;
/**
* 充值订单表
*/
@Slf4j
@RestController("masterPayPaymentOrder")
@RequestMapping("master/payPaymentOrder")
public class PayPaymentOrderController {
@Autowired
private PayPaymentOrderService payPaymentOrderService;
/**
* 列表
*/
@RequestMapping("/list")
public R list(@RequestParam Map<String, Object> params){
PageUtils page = payPaymentOrderService.queryPage(params);
return R.ok().put("page", page);
}
/**
* 信息
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id){
PayPaymentOrderEntity payPaymentOrder = payPaymentOrderService.getById(id);
return R.ok().put("payPaymentOrder", payPaymentOrder);
}
/**
* 保存
*/
@RequestMapping("/save")
public R save(@RequestBody PayPaymentOrderEntity payPaymentOrder){
payPaymentOrderService.save(payPaymentOrder);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
public R update(@RequestBody PayPaymentOrderEntity payPaymentOrder){
payPaymentOrderService.updateById(payPaymentOrder);
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
payPaymentOrderService.removeByIds(Arrays.asList(ids));
return R.ok();
}
}