添加代理记录相关表
This commit is contained in:
1 parent
b2ab430eb6
commit
81febe2c56
14 files changed
+1644
No files matched your search
+107
@@ -0,0 +1,107 @@
|
||||
package com.ruoyi.system.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.select.Ids;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.system.domain.UsdtDelegationToOther;
|
||||
import com.ruoyi.system.domain.UsdtDelegationToOtherPlus;
|
||||
import com.ruoyi.system.service.IUsdtProxyToOtherService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 代理给其他地址Controller
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2026-10-12
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/otherToDelegation")
|
||||
public class UsdtDelegationToOtherController extends BaseController {
|
||||
@Autowired
|
||||
private IUsdtProxyToOtherService usdtProxyToOtherService;
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:getByIds')")
|
||||
@PostMapping("/getByIds")
|
||||
public AjaxResult getByIds(@RequestBody Ids ids) {
|
||||
List<UsdtDelegationToOtherPlus> list = usdtProxyToOtherService.getByIds(ids.getLongIds(), UsdtDelegationToOtherPlus::getToken, UsdtDelegationToOtherPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:select')")
|
||||
@GetMapping("/select")
|
||||
public AjaxResult select(String keyword) {
|
||||
List<SelectItem> list = usdtProxyToOtherService.select(keyword);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询代理给其他地址列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(UsdtDelegationToOther usdtDelegationToOther) {
|
||||
startPage();
|
||||
List<UsdtDelegationToOther> list = usdtProxyToOtherService.selectUsdtDelegationToOtherList(usdtDelegationToOther);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出代理给其他地址列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:export')")
|
||||
@Log(title = "代理给其他地址", businessType = BusinessType.EXPORT)
|
||||
@GetMapping("/export")
|
||||
public AjaxResult export(UsdtDelegationToOther usdtDelegationToOther) {
|
||||
List<UsdtDelegationToOther> list = usdtProxyToOtherService.selectUsdtDelegationToOtherList(usdtDelegationToOther);
|
||||
ExcelUtil<UsdtDelegationToOther> util = new ExcelUtil<UsdtDelegationToOther>(UsdtDelegationToOther.class);
|
||||
return util.exportExcel(list, "otherToDelegation");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取代理给其他地址详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id) {
|
||||
return AjaxResult.success(usdtProxyToOtherService.selectUsdtDelegationToOtherById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增代理给其他地址
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:add')")
|
||||
@Log(title = "代理给其他地址", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody UsdtDelegationToOther usdtDelegationToOther) {
|
||||
return toAjax(usdtProxyToOtherService.insertUsdtDelegationToOther(usdtDelegationToOther));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改代理给其他地址
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:edit')")
|
||||
@Log(title = "代理给其他地址", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody UsdtDelegationToOther usdtDelegationToOther) {
|
||||
return toAjax(usdtProxyToOtherService.updateUsdtDelegationToOther(usdtDelegationToOther));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除代理给其他地址
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:otherToDelegation:remove')")
|
||||
@Log(title = "代理给其他地址", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(usdtProxyToOtherService.deleteUsdtDelegationToOtherByIds(ids));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user