123
This commit is contained in:
1 parent
8d2c4e0159
commit
05b5a3d3cc
43 files changed
+434
-4728
No files matched your search
@@ -1,170 +0,0 @@
|
||||
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.UsdtFundFlow;
|
||||
import com.ruoyi.system.domain.UsdtFundFlowPlus;
|
||||
import com.ruoyi.system.service.IUsdtFundFlowService;
|
||||
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 2025-12-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/usdt_flow")
|
||||
public class UsdtFundFlowController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IUsdtFundFlowService usdtFundFlowService;
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:getByIds')")
|
||||
@PostMapping("/getByIds")
|
||||
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||
{
|
||||
List<UsdtFundFlowPlus> list = usdtFundFlowService.getByIds(ids.getLongIds(),false,UsdtFundFlowPlus::getRemark,UsdtFundFlowPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-getByIds')")
|
||||
@PostMapping("/user/getByIds")
|
||||
public AjaxResult userGetByIds(@RequestBody Ids ids)
|
||||
{
|
||||
List<UsdtFundFlowPlus> list = usdtFundFlowService.getByIds(ids.getLongIds(),true,UsdtFundFlowPlus::getUserId,UsdtFundFlowPlus::getRemark,UsdtFundFlowPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:select')")
|
||||
@GetMapping("/select")
|
||||
public AjaxResult select(String keyword)
|
||||
{
|
||||
List<SelectItem> list = usdtFundFlowService.select(keyword,false);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-select')")
|
||||
@GetMapping("/user/select")
|
||||
public AjaxResult userSelect(String keyword)
|
||||
{
|
||||
List<SelectItem> list = usdtFundFlowService.select(keyword,true);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
/**
|
||||
* 查询资金流水列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
startPage();
|
||||
List<UsdtFundFlow> list = usdtFundFlowService.selectUsdtFundFlowList(usdtFundFlow,false);
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 查询资金流水列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-list')")
|
||||
@GetMapping("/user/list")
|
||||
public TableDataInfo userList(UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
startPage();
|
||||
List<UsdtFundFlow> list = usdtFundFlowService.selectUsdtFundFlowList(usdtFundFlow,true);
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 导出资金流水列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:export')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.EXPORT)
|
||||
@GetMapping("/export")
|
||||
public AjaxResult export(UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
List<UsdtFundFlow> list = usdtFundFlowService.selectUsdtFundFlowList(usdtFundFlow,false);
|
||||
ExcelUtil<UsdtFundFlow> util = new ExcelUtil<UsdtFundFlow>(UsdtFundFlow.class);
|
||||
return util.exportExcel(list, "usdt_flow");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取资金流水详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return AjaxResult.success(usdtFundFlowService.selectUsdtFundFlowById(id,false));
|
||||
}
|
||||
/**
|
||||
* 获取资金流水详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-query')")
|
||||
@GetMapping(value = "/user/{id}")
|
||||
public AjaxResult userGetInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return AjaxResult.success(usdtFundFlowService.selectUsdtFundFlowById(id,true));
|
||||
}
|
||||
/**
|
||||
* 新增资金流水
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:add')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.insertUsdtFundFlow(usdtFundFlow,false));
|
||||
}
|
||||
/**
|
||||
* 新增资金流水
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-add')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/user")
|
||||
public AjaxResult userAdd(@RequestBody UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.insertUsdtFundFlow(usdtFundFlow,true));
|
||||
}
|
||||
/**
|
||||
* 修改资金流水
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:edit')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.updateUsdtFundFlow(usdtFundFlow,false));
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-edit')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/user")
|
||||
public AjaxResult userEdit(@RequestBody UsdtFundFlow usdtFundFlow)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.updateUsdtFundFlow(usdtFundFlow,true));
|
||||
}
|
||||
/**
|
||||
* 删除资金流水
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:remove')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.deleteUsdtFundFlowByIds(ids,false));
|
||||
}
|
||||
/**
|
||||
* 删除资金流水
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_flow:user-remove')")
|
||||
@Log(title = "资金流水", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/user/{ids}")
|
||||
public AjaxResult userRemove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(usdtFundFlowService.deleteUsdtFundFlowByIds(ids,true));
|
||||
}
|
||||
}
|
||||
-170
@@ -1,170 +0,0 @@
|
||||
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.UsdtUserSettlementConfiguration;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfigurationPlus;
|
||||
import com.ruoyi.system.service.IUsdtUserSettlementConfigurationService;
|
||||
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 2025-12-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/usdt_user_configuration")
|
||||
public class UsdtUserSettlementConfigurationController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IUsdtUserSettlementConfigurationService usdtUserSettlementConfigurationService;
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:getByIds')")
|
||||
@PostMapping("/getByIds")
|
||||
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||
{
|
||||
List<UsdtUserSettlementConfigurationPlus> list = usdtUserSettlementConfigurationService.getByIds(ids.getLongIds(),false,UsdtUserSettlementConfigurationPlus::getRemark,UsdtUserSettlementConfigurationPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-getByIds')")
|
||||
@PostMapping("/user/getByIds")
|
||||
public AjaxResult userGetByIds(@RequestBody Ids ids)
|
||||
{
|
||||
List<UsdtUserSettlementConfigurationPlus> list = usdtUserSettlementConfigurationService.getByIds(ids.getLongIds(),true,UsdtUserSettlementConfigurationPlus::getUserId,UsdtUserSettlementConfigurationPlus::getRemark,UsdtUserSettlementConfigurationPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:select')")
|
||||
@GetMapping("/select")
|
||||
public AjaxResult select(String keyword)
|
||||
{
|
||||
List<SelectItem> list = usdtUserSettlementConfigurationService.select(keyword,false);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-select')")
|
||||
@GetMapping("/user/select")
|
||||
public AjaxResult userSelect(String keyword)
|
||||
{
|
||||
List<SelectItem> list = usdtUserSettlementConfigurationService.select(keyword,true);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
/**
|
||||
* 查询商户配置列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
startPage();
|
||||
List<UsdtUserSettlementConfiguration> list = usdtUserSettlementConfigurationService.selectUsdtUserSettlementConfigurationList(usdtUserSettlementConfiguration,false);
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 查询商户配置列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-list')")
|
||||
@GetMapping("/user/list")
|
||||
public TableDataInfo userList(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
startPage();
|
||||
List<UsdtUserSettlementConfiguration> list = usdtUserSettlementConfigurationService.selectUsdtUserSettlementConfigurationList(usdtUserSettlementConfiguration,true);
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 导出商户配置列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:export')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.EXPORT)
|
||||
@GetMapping("/export")
|
||||
public AjaxResult export(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
List<UsdtUserSettlementConfiguration> list = usdtUserSettlementConfigurationService.selectUsdtUserSettlementConfigurationList(usdtUserSettlementConfiguration,false);
|
||||
ExcelUtil<UsdtUserSettlementConfiguration> util = new ExcelUtil<UsdtUserSettlementConfiguration>(UsdtUserSettlementConfiguration.class);
|
||||
return util.exportExcel(list, "usdt_user_configuration");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取商户配置详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return AjaxResult.success(usdtUserSettlementConfigurationService.selectUsdtUserSettlementConfigurationById(id,false));
|
||||
}
|
||||
/**
|
||||
* 获取商户配置详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-query')")
|
||||
@GetMapping(value = "/user/{id}")
|
||||
public AjaxResult userGetInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return AjaxResult.success(usdtUserSettlementConfigurationService.selectUsdtUserSettlementConfigurationById(id,true));
|
||||
}
|
||||
/**
|
||||
* 新增商户配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:add')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.insertUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration,false));
|
||||
}
|
||||
/**
|
||||
* 新增商户配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-add')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/user")
|
||||
public AjaxResult userAdd(@RequestBody UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.insertUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration,true));
|
||||
}
|
||||
/**
|
||||
* 修改商户配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:edit')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.updateUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration,false));
|
||||
}
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-edit')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/user")
|
||||
public AjaxResult userEdit(@RequestBody UsdtUserSettlementConfiguration usdtUserSettlementConfiguration)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.updateUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration,true));
|
||||
}
|
||||
/**
|
||||
* 删除商户配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:remove')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.deleteUsdtUserSettlementConfigurationByIds(ids,false));
|
||||
}
|
||||
/**
|
||||
* 删除商户配置
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:usdt_user_configuration:user-remove')")
|
||||
@Log(title = "商户配置", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/user/{ids}")
|
||||
public AjaxResult userRemove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(usdtUserSettlementConfigurationService.deleteUsdtUserSettlementConfigurationByIds(ids,true));
|
||||
}
|
||||
}
|
||||
@@ -1,168 +0,0 @@
|
||||
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.UserAuth;
|
||||
import com.ruoyi.system.domain.UserAuthPlus;
|
||||
import com.ruoyi.system.service.IUserAuthService;
|
||||
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 2025-11-25
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/auth" )
|
||||
public class UserAuthController extends BaseController {
|
||||
@Autowired
|
||||
private IUserAuthService userAuthService;
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:getByIds')" )
|
||||
@PostMapping("/getByIds" )
|
||||
public AjaxResult getByIds(@RequestBody Ids ids) {
|
||||
List<UserAuthPlus> list = userAuthService.getByIds(ids.getLongIds(), false, UserAuthPlus::getName, UserAuthPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-getByIds')" )
|
||||
@PostMapping("/user/getByIds" )
|
||||
public AjaxResult userGetByIds(@RequestBody Ids ids) {
|
||||
List<UserAuthPlus> list = userAuthService.getByIds(ids.getLongIds(), true, UserAuthPlus::getName,UserAuthPlus::getUserId, UserAuthPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:select')" )
|
||||
@GetMapping("/select" )
|
||||
public AjaxResult select(String keyword) {
|
||||
List<SelectItem> list = userAuthService.select(keyword, false);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-select')" )
|
||||
@GetMapping("/user/select" )
|
||||
public AjaxResult userSelect(String keyword) {
|
||||
List<SelectItem> list = userAuthService.select(keyword, true);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户授权列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:list')" )
|
||||
@GetMapping("/list" )
|
||||
public TableDataInfo list(UserAuth userAuth) {
|
||||
startPage();
|
||||
List<UserAuth> list = userAuthService.selectUserAuthList(userAuth, false);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户授权列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-list')" )
|
||||
@GetMapping("/user/list" )
|
||||
public TableDataInfo userList(UserAuth userAuth) {
|
||||
startPage();
|
||||
List<UserAuth> list = userAuthService.selectUserAuthList(userAuth, true);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出用户授权列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:export')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.EXPORT)
|
||||
@GetMapping("/export" )
|
||||
public AjaxResult export(UserAuth userAuth) {
|
||||
List<UserAuth> list = userAuthService.selectUserAuthList(userAuth, false);
|
||||
ExcelUtil<UserAuth> util = new ExcelUtil<UserAuth>(UserAuth.class);
|
||||
return util.exportExcel(list, "auth" );
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取用户授权详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:query')" )
|
||||
@GetMapping(value = "/{id}" )
|
||||
public AjaxResult getInfo(@PathVariable("id" ) Long id) {
|
||||
return AjaxResult.success(userAuthService.selectUserAuthById(id, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取用户授权详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-query')" )
|
||||
@GetMapping(value = "/user/{id}" )
|
||||
public AjaxResult userGetInfo(@PathVariable("id" ) Long id) {
|
||||
return AjaxResult.success(userAuthService.selectUserAuthById(id, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:add')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody UserAuth userAuth) {
|
||||
return toAjax(userAuthService.insertUserAuth(userAuth, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-add')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.INSERT)
|
||||
@PostMapping("/user" )
|
||||
public AjaxResult userAdd(@RequestBody UserAuth userAuth) {
|
||||
return toAjax(userAuthService.insertUserAuth(userAuth, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:edit')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody UserAuth userAuth) {
|
||||
return toAjax(userAuthService.updateUserAuth(userAuth, false));
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-edit')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/user" )
|
||||
public AjaxResult userEdit(@RequestBody UserAuth userAuth) {
|
||||
return toAjax(userAuthService.updateUserAuth(userAuth, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:remove')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}" )
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(userAuthService.deleteUserAuthByIds(ids, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除用户授权
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:auth:user-remove')" )
|
||||
@Log(title = "用户授权" , businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/user/{ids}" )
|
||||
public AjaxResult userRemove(@PathVariable Long[] ids) {
|
||||
return toAjax(userAuthService.deleteUserAuthByIds(ids, true));
|
||||
}
|
||||
}
|
||||
@@ -1,153 +0,0 @@
|
||||
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.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.system.domain.Web3Wallet;
|
||||
import com.ruoyi.system.domain.Web3WalletPlus;
|
||||
import com.ruoyi.system.service.IWeb3WalletService;
|
||||
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 2025-11-25
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/wallet" )
|
||||
public class Web3WalletController extends BaseController {
|
||||
@Autowired
|
||||
private IWeb3WalletService web3WalletService;
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:getByIds')" )
|
||||
@PostMapping("/getByIds" )
|
||||
public AjaxResult getByIds(@RequestBody Ids ids) {
|
||||
List<Web3WalletPlus> list = web3WalletService.getByIds(ids.getLongIds(), false, Web3WalletPlus::getUsdtBalance, Web3WalletPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-getByIds')" )
|
||||
@PostMapping("/user/getByIds" )
|
||||
public AjaxResult userGetByIds(@RequestBody Ids ids) {
|
||||
List<Web3WalletPlus> list = web3WalletService.getByIds(ids.getLongIds(), true, Web3WalletPlus::getUsdtBalance, Web3WalletPlus::getId);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询钱包管理列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:list')" )
|
||||
@GetMapping("/list" )
|
||||
public TableDataInfo list(Web3Wallet web3Wallet) {
|
||||
startPage();
|
||||
List<Web3Wallet> list = web3WalletService.selectWeb3WalletList(web3Wallet, false);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询钱包管理列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-list')" )
|
||||
@GetMapping("/user/list" )
|
||||
public TableDataInfo userList(Web3Wallet web3Wallet) {
|
||||
startPage();
|
||||
List<Web3Wallet> list = web3WalletService.selectWeb3WalletList(web3Wallet, true);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出钱包管理列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:export')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.EXPORT)
|
||||
@GetMapping("/export" )
|
||||
public AjaxResult export(Web3Wallet web3Wallet) {
|
||||
List<Web3Wallet> list = web3WalletService.selectWeb3WalletList(web3Wallet, false);
|
||||
ExcelUtil<Web3Wallet> util = new ExcelUtil<Web3Wallet>(Web3Wallet.class);
|
||||
return util.exportExcel(list, "wallet" );
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取钱包管理详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:query')" )
|
||||
@GetMapping(value = "/{id}" )
|
||||
public AjaxResult getInfo(@PathVariable("id" ) Long id) {
|
||||
return AjaxResult.success(web3WalletService.selectWeb3WalletById(id, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取钱包管理详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-query')" )
|
||||
@GetMapping(value = "/user/{id}" )
|
||||
public AjaxResult userGetInfo(@PathVariable("id" ) Long id) {
|
||||
return AjaxResult.success(web3WalletService.selectWeb3WalletById(id, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增钱包管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:add')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody Web3Wallet web3Wallet) {
|
||||
return toAjax(web3WalletService.insertWeb3Wallet(web3Wallet, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增钱包管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-add')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.INSERT)
|
||||
@PostMapping("/user" )
|
||||
public AjaxResult userAdd(@RequestBody Web3Wallet web3Wallet) {
|
||||
return toAjax(web3WalletService.insertWeb3Wallet(web3Wallet, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改钱包管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:edit')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody Web3Wallet web3Wallet) {
|
||||
return toAjax(web3WalletService.updateWeb3Wallet(web3Wallet, false));
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-edit')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.UPDATE)
|
||||
@PutMapping("/user" )
|
||||
public AjaxResult userEdit(@RequestBody Web3Wallet web3Wallet) {
|
||||
return toAjax(web3WalletService.updateWeb3Wallet(web3Wallet, true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除钱包管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:remove')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}" )
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(web3WalletService.deleteWeb3WalletByIds(ids, false));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除钱包管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:wallet:user-remove')" )
|
||||
@Log(title = "钱包管理" , businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/user/{ids}" )
|
||||
public AjaxResult userRemove(@PathVariable Long[] ids) {
|
||||
return toAjax(web3WalletService.deleteWeb3WalletByIds(ids, true));
|
||||
}
|
||||
}
|
||||
@@ -1,168 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* 资金流水对象 usdt_fund_flow
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public class UsdtFundFlow extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long id;
|
||||
|
||||
/** 订单ID */
|
||||
@Excel(name = "订单ID")
|
||||
private Long orderId;
|
||||
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
|
||||
/** 应用 */
|
||||
@Excel(name = "应用")
|
||||
private Long appId;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
|
||||
/** 操作金额 */
|
||||
@Excel(name = "操作金额")
|
||||
private BigDecimal amount;
|
||||
|
||||
/** 操作类型 */
|
||||
@Excel(name = "操作类型")
|
||||
private Integer opType;
|
||||
|
||||
/** Token地址 */
|
||||
@Excel(name = "Token地址")
|
||||
private String token;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setOrderId(Long orderId)
|
||||
{
|
||||
this.orderId = orderId;
|
||||
}
|
||||
|
||||
public Long getOrderId()
|
||||
{
|
||||
return orderId;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setAppId(Long appId)
|
||||
{
|
||||
this.appId = appId;
|
||||
}
|
||||
|
||||
public Long getAppId()
|
||||
{
|
||||
return appId;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setAmount(BigDecimal amount)
|
||||
{
|
||||
this.amount = amount;
|
||||
}
|
||||
|
||||
public BigDecimal getAmount()
|
||||
{
|
||||
return amount;
|
||||
}
|
||||
public void setOpType(Integer opType)
|
||||
{
|
||||
this.opType = opType;
|
||||
}
|
||||
|
||||
public Integer getOpType()
|
||||
{
|
||||
return opType;
|
||||
}
|
||||
public void setToken(String token)
|
||||
{
|
||||
this.token = token;
|
||||
}
|
||||
|
||||
public String getToken()
|
||||
{
|
||||
return token;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("orderId", getOrderId())
|
||||
.append("userId", getUserId())
|
||||
.append("appId", getAppId())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("amount", getAmount())
|
||||
.append("opType", getOpType())
|
||||
.append("token", getToken())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,177 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
/**
|
||||
* 资金流水对象 usdt_fund_flow
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
@TableName(value = "usdt_fund_flow")
|
||||
public class UsdtFundFlowPlus implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
@TableId(type = IdType.INPUT)
|
||||
private Long id;
|
||||
/** 订单ID */
|
||||
@Excel(name = "订单ID")
|
||||
private Long orderId;
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
/** 应用 */
|
||||
@Excel(name = "应用")
|
||||
private Long appId;
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
/** 操作金额 */
|
||||
@Excel(name = "操作金额")
|
||||
private BigDecimal amount;
|
||||
/** 操作类型 */
|
||||
@Excel(name = "操作类型 操作类型 0 商户收入 1 平台抽佣 2 商户归集提现金额")
|
||||
private Integer opType;
|
||||
/** Token地址 */
|
||||
@Excel(name = "Token地址")
|
||||
private String token;
|
||||
/** 备注 */
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setOrderId(Long orderId)
|
||||
{
|
||||
this.orderId = orderId;
|
||||
}
|
||||
|
||||
public Long getOrderId()
|
||||
{
|
||||
return orderId;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setAppId(Long appId)
|
||||
{
|
||||
this.appId = appId;
|
||||
}
|
||||
|
||||
public Long getAppId()
|
||||
{
|
||||
return appId;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setAmount(BigDecimal amount)
|
||||
{
|
||||
this.amount = amount;
|
||||
}
|
||||
|
||||
public BigDecimal getAmount()
|
||||
{
|
||||
return amount;
|
||||
}
|
||||
public void setOpType(Integer opType)
|
||||
{
|
||||
this.opType = opType;
|
||||
}
|
||||
|
||||
public Integer getOpType()
|
||||
{
|
||||
return opType;
|
||||
}
|
||||
public void setToken(String token)
|
||||
{
|
||||
this.token = token;
|
||||
}
|
||||
|
||||
public String getToken()
|
||||
{
|
||||
return token;
|
||||
}
|
||||
public void setRemark(String remark)
|
||||
{
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public String getRemark()
|
||||
{
|
||||
return remark;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("orderId", getOrderId())
|
||||
.append("userId", getUserId())
|
||||
.append("appId", getAppId())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("amount", getAmount())
|
||||
.append("opType", getOpType())
|
||||
.append("token", getToken())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -90,7 +90,17 @@ public class UsdtOrders extends BaseEntity
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
|
||||
public void setId(Long id)
|
||||
private Integer orderType;
|
||||
|
||||
public Integer getOrderType() {
|
||||
return orderType;
|
||||
}
|
||||
|
||||
public void setOrderType(Integer orderType) {
|
||||
this.orderType = orderType;
|
||||
}
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@@ -79,7 +79,19 @@ public class UsdtOrdersPlus implements Serializable
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
public void setId(Long id)
|
||||
|
||||
@Excel(name = "订单类型")
|
||||
private Integer orderType;
|
||||
|
||||
public Integer getOrderType() {
|
||||
return orderType;
|
||||
}
|
||||
|
||||
public void setOrderType(Integer orderType) {
|
||||
this.orderType = orderType;
|
||||
}
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
-154
@@ -1,154 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* 商户配置对象 usdt_user_settlement_configuration
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public class UsdtUserSettlementConfiguration extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long id;
|
||||
|
||||
/** 用户id */
|
||||
@Excel(name = "用户id")
|
||||
private Long userId;
|
||||
|
||||
/** 佣金比例 */
|
||||
@Excel(name = "佣金比例")
|
||||
private BigDecimal commissionRate;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
|
||||
/** 提现手续费 */
|
||||
@Excel(name = "提现手续费")
|
||||
private BigDecimal withdrawalFee;
|
||||
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
private Long status;
|
||||
|
||||
/** 预留配置 */
|
||||
@Excel(name = "预留配置")
|
||||
private String extInfo;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setCommissionRate(BigDecimal commissionRate)
|
||||
{
|
||||
this.commissionRate = commissionRate;
|
||||
}
|
||||
|
||||
public BigDecimal getCommissionRate()
|
||||
{
|
||||
return commissionRate;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setWithdrawalFee(BigDecimal withdrawalFee)
|
||||
{
|
||||
this.withdrawalFee = withdrawalFee;
|
||||
}
|
||||
|
||||
public BigDecimal getWithdrawalFee()
|
||||
{
|
||||
return withdrawalFee;
|
||||
}
|
||||
public void setStatus(Long status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public Long getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
public void setExtInfo(String extInfo)
|
||||
{
|
||||
this.extInfo = extInfo;
|
||||
}
|
||||
|
||||
public String getExtInfo()
|
||||
{
|
||||
return extInfo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("userId", getUserId())
|
||||
.append("commissionRate", getCommissionRate())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("withdrawalFee", getWithdrawalFee())
|
||||
.append("status", getStatus())
|
||||
.append("extInfo", getExtInfo())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
-164
@@ -1,164 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
/**
|
||||
* 商户配置对象 usdt_user_settlement_configuration
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
@TableName(value = "usdt_user_settlement_configuration")
|
||||
public class UsdtUserSettlementConfigurationPlus implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
@TableId(type = IdType.INPUT)
|
||||
private Long id;
|
||||
/** 用户id */
|
||||
@Excel(name = "用户id")
|
||||
private Long userId;
|
||||
/** 佣金比例 */
|
||||
@Excel(name = "佣金比例")
|
||||
private BigDecimal commissionRate;
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
/** 提现手续费 */
|
||||
@Excel(name = "提现手续费")
|
||||
private BigDecimal withdrawalFee;
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
private Long status;
|
||||
/** 预留配置 */
|
||||
@Excel(name = "预留配置")
|
||||
private String extInfo;
|
||||
/** 备注 */
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setCommissionRate(BigDecimal commissionRate)
|
||||
{
|
||||
this.commissionRate = commissionRate;
|
||||
}
|
||||
|
||||
public BigDecimal getCommissionRate()
|
||||
{
|
||||
return commissionRate;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setWithdrawalFee(BigDecimal withdrawalFee)
|
||||
{
|
||||
this.withdrawalFee = withdrawalFee;
|
||||
}
|
||||
|
||||
public BigDecimal getWithdrawalFee()
|
||||
{
|
||||
return withdrawalFee;
|
||||
}
|
||||
public void setStatus(Long status)
|
||||
{
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public Long getStatus()
|
||||
{
|
||||
return status;
|
||||
}
|
||||
public void setExtInfo(String extInfo)
|
||||
{
|
||||
this.extInfo = extInfo;
|
||||
}
|
||||
|
||||
public String getExtInfo()
|
||||
{
|
||||
return extInfo;
|
||||
}
|
||||
public void setRemark(String remark)
|
||||
{
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public String getRemark()
|
||||
{
|
||||
return remark;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("userId", getUserId())
|
||||
.append("commissionRate", getCommissionRate())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("withdrawalFee", getWithdrawalFee())
|
||||
.append("status", getStatus())
|
||||
.append("extInfo", getExtInfo())
|
||||
.append("remark", getRemark())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,180 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* 用户授权对象 user_auth
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
public class UserAuth extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键ID */
|
||||
private Long id;
|
||||
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
|
||||
/** 认证类型 */
|
||||
@Excel(name = "认证类型")
|
||||
private Integer authType;
|
||||
|
||||
/** 名称 */
|
||||
@Excel(name = "名称")
|
||||
private String name;
|
||||
|
||||
/** 身份证 */
|
||||
@Excel(name = "身份证")
|
||||
private String idNumber;
|
||||
|
||||
/** 公司名称 */
|
||||
@Excel(name = "公司名称")
|
||||
private String companyName;
|
||||
|
||||
/** 授权状态 */
|
||||
@Excel(name = "授权状态")
|
||||
private Integer authStatus;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
|
||||
/** 审核人 */
|
||||
@Excel(name = "审核人")
|
||||
private String reviewer;
|
||||
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setAuthType(Integer authType)
|
||||
{
|
||||
this.authType = authType;
|
||||
}
|
||||
|
||||
public Integer getAuthType()
|
||||
{
|
||||
return authType;
|
||||
}
|
||||
public void setName(String name)
|
||||
{
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getName()
|
||||
{
|
||||
return name;
|
||||
}
|
||||
public void setIdNumber(String idNumber)
|
||||
{
|
||||
this.idNumber = idNumber;
|
||||
}
|
||||
|
||||
public String getIdNumber()
|
||||
{
|
||||
return idNumber;
|
||||
}
|
||||
public void setCompanyName(String companyName)
|
||||
{
|
||||
this.companyName = companyName;
|
||||
}
|
||||
|
||||
public String getCompanyName()
|
||||
{
|
||||
return companyName;
|
||||
}
|
||||
public void setAuthStatus(Integer authStatus)
|
||||
{
|
||||
this.authStatus = authStatus;
|
||||
}
|
||||
|
||||
public Integer getAuthStatus()
|
||||
{
|
||||
return authStatus;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setReviewer(String reviewer)
|
||||
{
|
||||
this.reviewer = reviewer;
|
||||
}
|
||||
|
||||
public String getReviewer()
|
||||
{
|
||||
return reviewer;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("userId", getUserId())
|
||||
.append("authType", getAuthType())
|
||||
.append("name", getName())
|
||||
.append("idNumber", getIdNumber())
|
||||
.append("companyName", getCompanyName())
|
||||
.append("authStatus", getAuthStatus())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("reviewer", getReviewer())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,176 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
/**
|
||||
* 用户授权对象 user_auth
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
@TableName(value = "user_auth")
|
||||
public class UserAuthPlus implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键ID */
|
||||
@TableId(type = IdType.INPUT)
|
||||
private Long id;
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
private Long userId;
|
||||
/** 认证类型 */
|
||||
@Excel(name = "认证类型")
|
||||
private Integer authType;
|
||||
/** 名称 */
|
||||
@Excel(name = "名称")
|
||||
private String name;
|
||||
/** 身份证 */
|
||||
@Excel(name = "身份证")
|
||||
private String idNumber;
|
||||
/** 公司名称 */
|
||||
@Excel(name = "公司名称")
|
||||
private String companyName;
|
||||
/** 授权状态 */
|
||||
@Excel(name = "授权状态")
|
||||
private Integer authStatus;
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
/** 审核人 */
|
||||
@Excel(name = "审核人")
|
||||
private String reviewer;
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setAuthType(Integer authType)
|
||||
{
|
||||
this.authType = authType;
|
||||
}
|
||||
|
||||
public Integer getAuthType()
|
||||
{
|
||||
return authType;
|
||||
}
|
||||
public void setName(String name)
|
||||
{
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getName()
|
||||
{
|
||||
return name;
|
||||
}
|
||||
public void setIdNumber(String idNumber)
|
||||
{
|
||||
this.idNumber = idNumber;
|
||||
}
|
||||
|
||||
public String getIdNumber()
|
||||
{
|
||||
return idNumber;
|
||||
}
|
||||
public void setCompanyName(String companyName)
|
||||
{
|
||||
this.companyName = companyName;
|
||||
}
|
||||
|
||||
public String getCompanyName()
|
||||
{
|
||||
return companyName;
|
||||
}
|
||||
public void setAuthStatus(Integer authStatus)
|
||||
{
|
||||
this.authStatus = authStatus;
|
||||
}
|
||||
|
||||
public Integer getAuthStatus()
|
||||
{
|
||||
return authStatus;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setReviewer(String reviewer)
|
||||
{
|
||||
this.reviewer = reviewer;
|
||||
}
|
||||
|
||||
public String getReviewer()
|
||||
{
|
||||
return reviewer;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("userId", getUserId())
|
||||
.append("authType", getAuthType())
|
||||
.append("name", getName())
|
||||
.append("idNumber", getIdNumber())
|
||||
.append("companyName", getCompanyName())
|
||||
.append("authStatus", getAuthStatus())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("reviewer", getReviewer())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -9,125 +9,150 @@ import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* token管理对象 wallet_address
|
||||
* 【请填写功能名称】对象 wallet_address
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-30
|
||||
* @date 2026-09-26
|
||||
*/
|
||||
public class WalletAddress extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
@Excel(name = "主键")
|
||||
/** $column.columnComment */
|
||||
private Long id;
|
||||
|
||||
/** Token */
|
||||
@Excel(name = "Token")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String token;
|
||||
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long status;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date createdAt;
|
||||
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date updatedAt;
|
||||
|
||||
/** 删除时间 */
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date deletedAt;
|
||||
|
||||
/** 应用 */
|
||||
@Excel(name = "应用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long appId;
|
||||
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long userId;
|
||||
|
||||
/** 密钥 */
|
||||
@Excel(name = "密钥")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String walletUserName;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String tokenIndex;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String tokenKey;
|
||||
@Excel(name = "质押还剩能用的带宽")
|
||||
private Long bandwidthStakedNum;
|
||||
/** usdt余额 */
|
||||
@Excel(name = "usdt余额")
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal usdtBalance;
|
||||
|
||||
/** trx余额 */
|
||||
@Excel(name = "trx余额")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal trxBalance;
|
||||
|
||||
/** 能量-可用 */
|
||||
@Excel(name = "能量-可用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyNum;
|
||||
|
||||
/** 带宽-可用 */
|
||||
@Excel(name = "带宽-可用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyAllNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyUsedNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthNum;
|
||||
|
||||
/** 可以提现usdt金额 */
|
||||
@Excel(name = "可以提现usdt金额")
|
||||
private BigDecimal withdrawUsdtBalance;
|
||||
|
||||
/** 代理给别人能量的trx数量 */
|
||||
@Excel(name = "代理给别人能量的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long delegatedEnergyTrxNum;
|
||||
|
||||
/** 代理给别人的能量 */
|
||||
@Excel(name = "代理给别人的能量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal delegatedEnergyValue;
|
||||
|
||||
/** 别人代理给我能量的trx数量 */
|
||||
@Excel(name = "别人代理给我能量的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long acquiredDelegatedEnergyTrxNum;
|
||||
|
||||
/** 别人代理给我的能量 */
|
||||
@Excel(name = "别人代理给我的能量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal acquiredDelegatedEnergyValue;
|
||||
|
||||
/** 代理给别人的带宽trx数量 */
|
||||
@Excel(name = "代理给别人的带宽trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long delegatedBandwidthTrxNum;
|
||||
|
||||
/** 代理给别人的带宽 */
|
||||
@Excel(name = "代理给别人的带宽")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal delegatedBandwidthValue;
|
||||
|
||||
/** 别人代理给我带宽的trx数量 */
|
||||
@Excel(name = "别人代理给我带宽的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long acquiredDelegatedBandwidthTrxNum;
|
||||
|
||||
/** 别人代理给我的带宽 */
|
||||
@Excel(name = "别人代理给我的带宽")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal acquiredDelegatedBandwidthValue;
|
||||
|
||||
/** 质押的trx数量-不含代理 */
|
||||
@Excel(name = "质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long stakedTrxNum;
|
||||
|
||||
/** 能量质押的trx数量-不含代理 */
|
||||
@Excel(name = "能量质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyStakedTrxNum;
|
||||
|
||||
/** 带宽质押的trx数量-不含代理 */
|
||||
@Excel(name = "带宽质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedTrxNum;
|
||||
|
||||
/** 可投票数 */
|
||||
@Excel(name = "可投票数")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long voteNum;
|
||||
|
||||
/** 已经投票数量 */
|
||||
@Excel(name = "已经投票数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long votedNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedAllNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthFreeNum;
|
||||
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthFreeAllNum;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
@@ -142,15 +167,7 @@ public class WalletAddress extends BaseEntity
|
||||
this.token = token;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedNum() {
|
||||
return bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public void setBandwidthStakedNum(Long bandwidthStakedNum) {
|
||||
this.bandwidthStakedNum = bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public String getToken()
|
||||
public String getToken()
|
||||
{
|
||||
return token;
|
||||
}
|
||||
@@ -208,12 +225,30 @@ public class WalletAddress extends BaseEntity
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setTokenKey(String key)
|
||||
public void setWalletUserName(String walletUserName)
|
||||
{
|
||||
this.tokenKey = key;
|
||||
this.walletUserName = walletUserName;
|
||||
}
|
||||
|
||||
public String getTokenKey()
|
||||
public String getWalletUserName()
|
||||
{
|
||||
return walletUserName;
|
||||
}
|
||||
public void setTokenIndex(String tokenIndex)
|
||||
{
|
||||
this.tokenIndex = tokenIndex;
|
||||
}
|
||||
|
||||
public String getTokenIndex()
|
||||
{
|
||||
return tokenIndex;
|
||||
}
|
||||
public void setTokenKey(String tokenKey)
|
||||
{
|
||||
this.tokenKey = tokenKey;
|
||||
}
|
||||
|
||||
public String getTokenKey()
|
||||
{
|
||||
return tokenKey;
|
||||
}
|
||||
@@ -244,6 +279,24 @@ public class WalletAddress extends BaseEntity
|
||||
{
|
||||
return energyNum;
|
||||
}
|
||||
public void setEnergyAllNum(Long energyAllNum)
|
||||
{
|
||||
this.energyAllNum = energyAllNum;
|
||||
}
|
||||
|
||||
public Long getEnergyAllNum()
|
||||
{
|
||||
return energyAllNum;
|
||||
}
|
||||
public void setEnergyUsedNum(Long energyUsedNum)
|
||||
{
|
||||
this.energyUsedNum = energyUsedNum;
|
||||
}
|
||||
|
||||
public Long getEnergyUsedNum()
|
||||
{
|
||||
return energyUsedNum;
|
||||
}
|
||||
public void setBandwidthNum(Long bandwidthNum)
|
||||
{
|
||||
this.bandwidthNum = bandwidthNum;
|
||||
@@ -253,15 +306,6 @@ public class WalletAddress extends BaseEntity
|
||||
{
|
||||
return bandwidthNum;
|
||||
}
|
||||
public void setWithdrawUsdtBalance(BigDecimal withdrawUsdtBalance)
|
||||
{
|
||||
this.withdrawUsdtBalance = withdrawUsdtBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getWithdrawUsdtBalance()
|
||||
{
|
||||
return withdrawUsdtBalance;
|
||||
}
|
||||
public void setDelegatedEnergyTrxNum(Long delegatedEnergyTrxNum)
|
||||
{
|
||||
this.delegatedEnergyTrxNum = delegatedEnergyTrxNum;
|
||||
@@ -379,6 +423,42 @@ public class WalletAddress extends BaseEntity
|
||||
{
|
||||
return votedNum;
|
||||
}
|
||||
public void setBandwidthStakedNum(Long bandwidthStakedNum)
|
||||
{
|
||||
this.bandwidthStakedNum = bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedNum()
|
||||
{
|
||||
return bandwidthStakedNum;
|
||||
}
|
||||
public void setBandwidthStakedAllNum(Long bandwidthStakedAllNum)
|
||||
{
|
||||
this.bandwidthStakedAllNum = bandwidthStakedAllNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedAllNum()
|
||||
{
|
||||
return bandwidthStakedAllNum;
|
||||
}
|
||||
public void setBandwidthFreeNum(Long bandwidthFreeNum)
|
||||
{
|
||||
this.bandwidthFreeNum = bandwidthFreeNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthFreeNum()
|
||||
{
|
||||
return bandwidthFreeNum;
|
||||
}
|
||||
public void setBandwidthFreeAllNum(Long bandwidthFreeAllNum)
|
||||
{
|
||||
this.bandwidthFreeAllNum = bandwidthFreeAllNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthFreeAllNum()
|
||||
{
|
||||
return bandwidthFreeAllNum;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
@@ -391,12 +471,15 @@ public class WalletAddress extends BaseEntity
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("appId", getAppId())
|
||||
.append("userId", getUserId())
|
||||
.append("walletUserName", getWalletUserName())
|
||||
.append("tokenIndex", getTokenIndex())
|
||||
.append("tokenKey", getTokenKey())
|
||||
.append("usdtBalance", getUsdtBalance())
|
||||
.append("trxBalance", getTrxBalance())
|
||||
.append("energyNum", getEnergyNum())
|
||||
.append("energyAllNum", getEnergyAllNum())
|
||||
.append("energyUsedNum", getEnergyUsedNum())
|
||||
.append("bandwidthNum", getBandwidthNum())
|
||||
.append("withdrawUsdtBalance", getWithdrawUsdtBalance())
|
||||
.append("delegatedEnergyTrxNum", getDelegatedEnergyTrxNum())
|
||||
.append("delegatedEnergyValue", getDelegatedEnergyValue())
|
||||
.append("acquiredDelegatedEnergyTrxNum", getAcquiredDelegatedEnergyTrxNum())
|
||||
@@ -410,6 +493,10 @@ public class WalletAddress extends BaseEntity
|
||||
.append("bandwidthStakedTrxNum", getBandwidthStakedTrxNum())
|
||||
.append("voteNum", getVoteNum())
|
||||
.append("votedNum", getVotedNum())
|
||||
.append("bandwidthStakedNum", getBandwidthStakedNum())
|
||||
.append("bandwidthStakedAllNum", getBandwidthStakedAllNum())
|
||||
.append("bandwidthFreeNum", getBandwidthFreeNum())
|
||||
.append("bandwidthFreeAllNum", getBandwidthFreeAllNum())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -2,9 +2,6 @@ package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
@@ -14,101 +11,117 @@ import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
/**
|
||||
* token管理对象 wallet_address
|
||||
* 【请填写功能名称】对象 wallet_address
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-30
|
||||
* @date 2026-09-26
|
||||
*/
|
||||
@TableName(value = "wallet_address")
|
||||
public class WalletAddressPlus implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
@TableId(type = IdType.INPUT)
|
||||
@Excel(name = "主键")
|
||||
/** $column.columnComment */
|
||||
private Long id;
|
||||
/** Token */
|
||||
@Excel(name = "Token")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String token;
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long status;
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date createdAt;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date updatedAt;
|
||||
/** 删除时间 */
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Date deletedAt;
|
||||
/** 应用 */
|
||||
@Excel(name = "应用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long appId;
|
||||
/** 用户 */
|
||||
@Excel(name = "用户")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long userId;
|
||||
/** 密钥 */
|
||||
@Excel(name = "密钥")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String walletUserName;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String tokenIndex;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private String tokenKey;
|
||||
/** usdt余额 */
|
||||
@Excel(name = "usdt余额")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal usdtBalance;
|
||||
/** trx余额 */
|
||||
@Excel(name = "trx余额")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal trxBalance;
|
||||
/** 能量-可用 */
|
||||
@Excel(name = "能量-可用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyNum;
|
||||
@Excel(name = "质押还剩能用的带宽")
|
||||
private Long bandwidthStakedNum;
|
||||
/** 带宽-可用 */
|
||||
@Excel(name = "带宽-可用")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyAllNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyUsedNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthNum;
|
||||
/** 可以提现usdt金额 */
|
||||
@Excel(name = "可以提现usdt金额")
|
||||
private BigDecimal withdrawUsdtBalance;
|
||||
/** 代理给别人能量的trx数量 */
|
||||
@Excel(name = "代理给别人能量的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long delegatedEnergyTrxNum;
|
||||
/** 代理给别人的能量 */
|
||||
@Excel(name = "代理给别人的能量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal delegatedEnergyValue;
|
||||
/** 别人代理给我能量的trx数量 */
|
||||
@Excel(name = "别人代理给我能量的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long acquiredDelegatedEnergyTrxNum;
|
||||
/** 别人代理给我的能量 */
|
||||
@Excel(name = "别人代理给我的能量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal acquiredDelegatedEnergyValue;
|
||||
/** 代理给别人的带宽trx数量 */
|
||||
@Excel(name = "代理给别人的带宽trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long delegatedBandwidthTrxNum;
|
||||
/** 代理给别人的带宽 */
|
||||
@Excel(name = "代理给别人的带宽")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal delegatedBandwidthValue;
|
||||
/** 别人代理给我带宽的trx数量 */
|
||||
@Excel(name = "别人代理给我带宽的trx数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long acquiredDelegatedBandwidthTrxNum;
|
||||
/** 别人代理给我的带宽 */
|
||||
@Excel(name = "别人代理给我的带宽")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private BigDecimal acquiredDelegatedBandwidthValue;
|
||||
/** 质押的trx数量-不含代理 */
|
||||
@Excel(name = "质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long stakedTrxNum;
|
||||
/** 能量质押的trx数量-不含代理 */
|
||||
@Excel(name = "能量质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long energyStakedTrxNum;
|
||||
/** 带宽质押的trx数量-不含代理 */
|
||||
@Excel(name = "带宽质押的trx数量-不含代理")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedTrxNum;
|
||||
/** 可投票数 */
|
||||
@Excel(name = "可投票数")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long voteNum;
|
||||
/** 已经投票数量 */
|
||||
@Excel(name = "已经投票数量")
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long votedNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthStakedAllNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthFreeNum;
|
||||
/** $column.columnComment */
|
||||
@Excel(name = "${comment}", readConverterExp = "$column.readConverterExp()")
|
||||
private Long bandwidthFreeAllNum;
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
@@ -141,15 +154,7 @@ public class WalletAddressPlus implements Serializable
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedNum() {
|
||||
return bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public void setBandwidthStakedNum(Long bandwidthStakedNum) {
|
||||
this.bandwidthStakedNum = bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
@@ -189,12 +194,30 @@ public class WalletAddressPlus implements Serializable
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setTokenKey(String key)
|
||||
public void setWalletUserName(String walletUserName)
|
||||
{
|
||||
this.tokenKey = key;
|
||||
this.walletUserName = walletUserName;
|
||||
}
|
||||
|
||||
public String getTokenKey()
|
||||
public String getWalletUserName()
|
||||
{
|
||||
return walletUserName;
|
||||
}
|
||||
public void setTokenIndex(String tokenIndex)
|
||||
{
|
||||
this.tokenIndex = tokenIndex;
|
||||
}
|
||||
|
||||
public String getTokenIndex()
|
||||
{
|
||||
return tokenIndex;
|
||||
}
|
||||
public void setTokenKey(String tokenKey)
|
||||
{
|
||||
this.tokenKey = tokenKey;
|
||||
}
|
||||
|
||||
public String getTokenKey()
|
||||
{
|
||||
return tokenKey;
|
||||
}
|
||||
@@ -225,6 +248,24 @@ public class WalletAddressPlus implements Serializable
|
||||
{
|
||||
return energyNum;
|
||||
}
|
||||
public void setEnergyAllNum(Long energyAllNum)
|
||||
{
|
||||
this.energyAllNum = energyAllNum;
|
||||
}
|
||||
|
||||
public Long getEnergyAllNum()
|
||||
{
|
||||
return energyAllNum;
|
||||
}
|
||||
public void setEnergyUsedNum(Long energyUsedNum)
|
||||
{
|
||||
this.energyUsedNum = energyUsedNum;
|
||||
}
|
||||
|
||||
public Long getEnergyUsedNum()
|
||||
{
|
||||
return energyUsedNum;
|
||||
}
|
||||
public void setBandwidthNum(Long bandwidthNum)
|
||||
{
|
||||
this.bandwidthNum = bandwidthNum;
|
||||
@@ -234,15 +275,6 @@ public class WalletAddressPlus implements Serializable
|
||||
{
|
||||
return bandwidthNum;
|
||||
}
|
||||
public void setWithdrawUsdtBalance(BigDecimal withdrawUsdtBalance)
|
||||
{
|
||||
this.withdrawUsdtBalance = withdrawUsdtBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getWithdrawUsdtBalance()
|
||||
{
|
||||
return withdrawUsdtBalance;
|
||||
}
|
||||
public void setDelegatedEnergyTrxNum(Long delegatedEnergyTrxNum)
|
||||
{
|
||||
this.delegatedEnergyTrxNum = delegatedEnergyTrxNum;
|
||||
@@ -360,6 +392,42 @@ public class WalletAddressPlus implements Serializable
|
||||
{
|
||||
return votedNum;
|
||||
}
|
||||
public void setBandwidthStakedNum(Long bandwidthStakedNum)
|
||||
{
|
||||
this.bandwidthStakedNum = bandwidthStakedNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedNum()
|
||||
{
|
||||
return bandwidthStakedNum;
|
||||
}
|
||||
public void setBandwidthStakedAllNum(Long bandwidthStakedAllNum)
|
||||
{
|
||||
this.bandwidthStakedAllNum = bandwidthStakedAllNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthStakedAllNum()
|
||||
{
|
||||
return bandwidthStakedAllNum;
|
||||
}
|
||||
public void setBandwidthFreeNum(Long bandwidthFreeNum)
|
||||
{
|
||||
this.bandwidthFreeNum = bandwidthFreeNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthFreeNum()
|
||||
{
|
||||
return bandwidthFreeNum;
|
||||
}
|
||||
public void setBandwidthFreeAllNum(Long bandwidthFreeAllNum)
|
||||
{
|
||||
this.bandwidthFreeAllNum = bandwidthFreeAllNum;
|
||||
}
|
||||
|
||||
public Long getBandwidthFreeAllNum()
|
||||
{
|
||||
return bandwidthFreeAllNum;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
@@ -372,12 +440,15 @@ public class WalletAddressPlus implements Serializable
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("appId", getAppId())
|
||||
.append("userId", getUserId())
|
||||
.append("walletUserName", getWalletUserName())
|
||||
.append("tokenIndex", getTokenIndex())
|
||||
.append("tokenKey", getTokenKey())
|
||||
.append("usdtBalance", getUsdtBalance())
|
||||
.append("trxBalance", getTrxBalance())
|
||||
.append("energyNum", getEnergyNum())
|
||||
.append("energyAllNum", getEnergyAllNum())
|
||||
.append("energyUsedNum", getEnergyUsedNum())
|
||||
.append("bandwidthNum", getBandwidthNum())
|
||||
.append("withdrawUsdtBalance", getWithdrawUsdtBalance())
|
||||
.append("delegatedEnergyTrxNum", getDelegatedEnergyTrxNum())
|
||||
.append("delegatedEnergyValue", getDelegatedEnergyValue())
|
||||
.append("acquiredDelegatedEnergyTrxNum", getAcquiredDelegatedEnergyTrxNum())
|
||||
@@ -391,6 +462,10 @@ public class WalletAddressPlus implements Serializable
|
||||
.append("bandwidthStakedTrxNum", getBandwidthStakedTrxNum())
|
||||
.append("voteNum", getVoteNum())
|
||||
.append("votedNum", getVotedNum())
|
||||
.append("bandwidthStakedNum", getBandwidthStakedNum())
|
||||
.append("bandwidthStakedAllNum", getBandwidthStakedAllNum())
|
||||
.append("bandwidthFreeNum", getBandwidthFreeNum())
|
||||
.append("bandwidthFreeAllNum", getBandwidthFreeAllNum())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,139 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
/**
|
||||
* 钱包管理对象 web3_wallet
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
public class Web3Wallet extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 用户 */
|
||||
private Long id;
|
||||
|
||||
/** usdt */
|
||||
@Excel(name = "usdt")
|
||||
private BigDecimal usdtBalance;
|
||||
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
|
||||
/** trx */
|
||||
@Excel(name = "trx")
|
||||
private BigDecimal trxBalance;
|
||||
|
||||
/** eth */
|
||||
@Excel(name = "eth")
|
||||
private BigDecimal ethBalance;
|
||||
|
||||
/** 密码 */
|
||||
@Excel(name = "密码")
|
||||
private String password;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUsdtBalance(BigDecimal usdtBalance)
|
||||
{
|
||||
this.usdtBalance = usdtBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getUsdtBalance()
|
||||
{
|
||||
return usdtBalance;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setTrxBalance(BigDecimal trxBalance)
|
||||
{
|
||||
this.trxBalance = trxBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getTrxBalance()
|
||||
{
|
||||
return trxBalance;
|
||||
}
|
||||
public void setEthBalance(BigDecimal ethBalance)
|
||||
{
|
||||
this.ethBalance = ethBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getEthBalance()
|
||||
{
|
||||
return ethBalance;
|
||||
}
|
||||
public void setPassword(String password)
|
||||
{
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
public String getPassword()
|
||||
{
|
||||
return password;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("usdtBalance", getUsdtBalance())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("trxBalance", getTrxBalance())
|
||||
.append("ethBalance", getEthBalance())
|
||||
.append("password", getPassword())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,138 +0,0 @@
|
||||
package com.ruoyi.system.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
/**
|
||||
* 钱包管理对象 web3_wallet
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
@TableName(value = "web3_wallet")
|
||||
public class Web3WalletPlus implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 用户 */
|
||||
@TableId(type = IdType.INPUT)
|
||||
private Long id;
|
||||
/** usdt */
|
||||
@Excel(name = "usdt")
|
||||
private BigDecimal usdtBalance;
|
||||
/** 创建时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date createdAt;
|
||||
/** 更新时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date updatedAt;
|
||||
/** 删除时间 */
|
||||
private Date deletedAt;
|
||||
/** trx */
|
||||
@Excel(name = "trx")
|
||||
private BigDecimal trxBalance;
|
||||
/** eth */
|
||||
@Excel(name = "eth")
|
||||
private BigDecimal ethBalance;
|
||||
/** 密码 */
|
||||
@Excel(name = "密码")
|
||||
private String password;
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setUsdtBalance(BigDecimal usdtBalance)
|
||||
{
|
||||
this.usdtBalance = usdtBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getUsdtBalance()
|
||||
{
|
||||
return usdtBalance;
|
||||
}
|
||||
public void setCreatedAt(Date createdAt)
|
||||
{
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public Date getCreatedAt()
|
||||
{
|
||||
return createdAt;
|
||||
}
|
||||
public void setUpdatedAt(Date updatedAt)
|
||||
{
|
||||
this.updatedAt = updatedAt;
|
||||
}
|
||||
|
||||
public Date getUpdatedAt()
|
||||
{
|
||||
return updatedAt;
|
||||
}
|
||||
public void setDeletedAt(Date deletedAt)
|
||||
{
|
||||
this.deletedAt = deletedAt;
|
||||
}
|
||||
|
||||
public Date getDeletedAt()
|
||||
{
|
||||
return deletedAt;
|
||||
}
|
||||
public void setTrxBalance(BigDecimal trxBalance)
|
||||
{
|
||||
this.trxBalance = trxBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getTrxBalance()
|
||||
{
|
||||
return trxBalance;
|
||||
}
|
||||
public void setEthBalance(BigDecimal ethBalance)
|
||||
{
|
||||
this.ethBalance = ethBalance;
|
||||
}
|
||||
|
||||
public BigDecimal getEthBalance()
|
||||
{
|
||||
return ethBalance;
|
||||
}
|
||||
public void setPassword(String password)
|
||||
{
|
||||
this.password = password;
|
||||
}
|
||||
|
||||
public String getPassword()
|
||||
{
|
||||
return password;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("usdtBalance", getUsdtBalance())
|
||||
.append("createdAt", getCreatedAt())
|
||||
.append("updatedAt", getUpdatedAt())
|
||||
.append("deletedAt", getDeletedAt())
|
||||
.append("trxBalance", getTrxBalance())
|
||||
.append("ethBalance", getEthBalance())
|
||||
.append("password", getPassword())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.system.domain.UsdtFundFlow;
|
||||
import com.ruoyi.system.domain.UsdtFundFlowPlus;
|
||||
|
||||
/**
|
||||
* 资金流水Mapper接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public interface UsdtFundFlowMapper extends BaseMapper<UsdtFundFlowPlus>
|
||||
{
|
||||
/**
|
||||
* 查询资金流水
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 资金流水
|
||||
*/
|
||||
public UsdtFundFlow selectUsdtFundFlowById(Long id);
|
||||
|
||||
/**
|
||||
* 查询资金流水列表
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 资金流水集合
|
||||
*/
|
||||
public List<UsdtFundFlow> selectUsdtFundFlowList(UsdtFundFlow usdtFundFlow);
|
||||
|
||||
/**
|
||||
* 新增资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUsdtFundFlow(UsdtFundFlow usdtFundFlow);
|
||||
|
||||
/**
|
||||
* 修改资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUsdtFundFlow(UsdtFundFlow usdtFundFlow);
|
||||
|
||||
/**
|
||||
* 删除资金流水
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtFundFlowById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除资金流水
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtFundFlowByIds(Long[] ids);
|
||||
}
|
||||
-65
@@ -1,65 +0,0 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfiguration;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfigurationPlus;
|
||||
|
||||
/**
|
||||
* 商户配置Mapper接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public interface UsdtUserSettlementConfigurationMapper extends BaseMapper<UsdtUserSettlementConfigurationPlus>
|
||||
{
|
||||
/**
|
||||
* 查询商户配置
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 商户配置
|
||||
*/
|
||||
public UsdtUserSettlementConfiguration selectUsdtUserSettlementConfigurationById(Long id);
|
||||
|
||||
/**
|
||||
* 查询商户配置列表
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 商户配置集合
|
||||
*/
|
||||
public List<UsdtUserSettlementConfiguration> selectUsdtUserSettlementConfigurationList(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration);
|
||||
|
||||
/**
|
||||
* 新增商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration);
|
||||
|
||||
/**
|
||||
* 修改商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration);
|
||||
|
||||
/**
|
||||
* 删除商户配置
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtUserSettlementConfigurationById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除商户配置
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtUserSettlementConfigurationByIds(Long[] ids);
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.system.domain.UserAuth;
|
||||
import com.ruoyi.system.domain.UserAuthPlus;
|
||||
|
||||
/**
|
||||
* 【请填写功能名称】Mapper接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-20
|
||||
*/
|
||||
public interface UserAuthMapper extends BaseMapper<UserAuthPlus>
|
||||
{
|
||||
/**
|
||||
* 查询【请填写功能名称】
|
||||
*
|
||||
* @param id 【请填写功能名称】ID
|
||||
* @return 【请填写功能名称】
|
||||
*/
|
||||
public UserAuth selectUserAuthById(Long id);
|
||||
|
||||
/**
|
||||
* 查询【请填写功能名称】列表
|
||||
*
|
||||
* @param userAuth 【请填写功能名称】
|
||||
* @return 【请填写功能名称】集合
|
||||
*/
|
||||
public List<UserAuth> selectUserAuthList(UserAuth userAuth);
|
||||
|
||||
/**
|
||||
* 新增【请填写功能名称】
|
||||
*
|
||||
* @param userAuth 【请填写功能名称】
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUserAuth(UserAuth userAuth);
|
||||
|
||||
/**
|
||||
* 修改【请填写功能名称】
|
||||
*
|
||||
* @param userAuth 【请填写功能名称】
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUserAuth(UserAuth userAuth);
|
||||
|
||||
/**
|
||||
* 删除【请填写功能名称】
|
||||
*
|
||||
* @param id 【请填写功能名称】ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserAuthById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除【请填写功能名称】
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserAuthByIds(Long[] ids);
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
package com.ruoyi.system.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import com.ruoyi.system.domain.Web3Wallet;
|
||||
import com.ruoyi.system.domain.Web3WalletPlus;
|
||||
|
||||
/**
|
||||
* 【请填写功能名称】Mapper接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-21
|
||||
*/
|
||||
public interface Web3WalletMapper extends BaseMapper<Web3WalletPlus>
|
||||
{
|
||||
/**
|
||||
* 查询【请填写功能名称】
|
||||
*
|
||||
* @param id 【请填写功能名称】ID
|
||||
* @return 【请填写功能名称】
|
||||
*/
|
||||
public Web3Wallet selectWeb3WalletById(Long id);
|
||||
|
||||
/**
|
||||
* 查询【请填写功能名称】列表
|
||||
*
|
||||
* @param web3Wallet 【请填写功能名称】
|
||||
* @return 【请填写功能名称】集合
|
||||
*/
|
||||
public List<Web3Wallet> selectWeb3WalletList(Web3Wallet web3Wallet);
|
||||
|
||||
/**
|
||||
* 新增【请填写功能名称】
|
||||
*
|
||||
* @param web3Wallet 【请填写功能名称】
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWeb3Wallet(Web3Wallet web3Wallet);
|
||||
|
||||
/**
|
||||
* 修改【请填写功能名称】
|
||||
*
|
||||
* @param web3Wallet 【请填写功能名称】
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWeb3Wallet(Web3Wallet web3Wallet);
|
||||
|
||||
/**
|
||||
* 删除【请填写功能名称】
|
||||
*
|
||||
* @param id 【请填写功能名称】ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWeb3WalletById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除【请填写功能名称】
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWeb3WalletByIds(Long[] ids);
|
||||
}
|
||||
@@ -1,91 +0,0 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.system.domain.UsdtFundFlow;
|
||||
import com.ruoyi.system.domain.UsdtFundFlowPlus;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
/**
|
||||
* 资金流水Service接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public interface IUsdtFundFlowService extends IService<UsdtFundFlowPlus>
|
||||
{
|
||||
|
||||
List<SelectItem> select(String keyword,boolean isUser);
|
||||
/**
|
||||
* 查询资金流水
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 资金流水
|
||||
*/
|
||||
public UsdtFundFlow selectUsdtFundFlowById(Long id,boolean isUser);
|
||||
|
||||
/**
|
||||
* 查询资金流水列表
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 资金流水集合
|
||||
*/
|
||||
public List<UsdtFundFlow> selectUsdtFundFlowList(UsdtFundFlow usdtFundFlow,boolean isUser);
|
||||
|
||||
/**
|
||||
* 新增资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUsdtFundFlow(UsdtFundFlow usdtFundFlow,boolean isUser);
|
||||
|
||||
/**
|
||||
* 修改资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUsdtFundFlow(UsdtFundFlow usdtFundFlow,boolean isUser);
|
||||
|
||||
/**
|
||||
* 批量删除资金流水
|
||||
*
|
||||
* @param ids 需要删除的资金流水ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtFundFlowByIds(Long[] ids,boolean isUser);
|
||||
|
||||
/**
|
||||
* 删除资金流水信息
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtFundFlowById(Long id,boolean isUser);
|
||||
|
||||
List<UsdtFundFlowPlus> getByIds(List<Long> ids,boolean isUser, SFunction<UsdtFundFlowPlus, ?>... columns);
|
||||
|
||||
UsdtFundFlowPlus getById(Long id, SFunction<UsdtFundFlowPlus, ?>... columns);
|
||||
|
||||
Map<Long, UsdtFundFlowPlus> getMapByIds(List<Long> ids, SFunction<UsdtFundFlowPlus, ?>... columns);
|
||||
|
||||
List<UsdtFundFlowPlus> getByIds(List<Long> ids);
|
||||
|
||||
Map<Long, UsdtFundFlowPlus> getMapByIds(List<Long> ids);
|
||||
|
||||
/**
|
||||
* @param field sum 字段
|
||||
* @param where 条件
|
||||
* @param tClass 返回类型
|
||||
* @param <T>
|
||||
* @return
|
||||
*/
|
||||
<T> T sum(String field, String where, Class<T> tClass);
|
||||
|
||||
Long count(String where);
|
||||
|
||||
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||
}
|
||||
-93
@@ -1,93 +0,0 @@
|
||||
package com.ruoyi.system.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfiguration;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfigurationPlus;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
/**
|
||||
* 商户配置Service接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
public interface IUsdtUserSettlementConfigurationService extends IService<UsdtUserSettlementConfigurationPlus>
|
||||
{
|
||||
|
||||
List<SelectItem> select(String keyword,boolean isUser);
|
||||
/**
|
||||
* 查询商户配置
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 商户配置
|
||||
*/
|
||||
public UsdtUserSettlementConfiguration selectUsdtUserSettlementConfigurationById(Long id,boolean isUser);
|
||||
|
||||
|
||||
UsdtUserSettlementConfigurationPlus getByUserId(Long userId);
|
||||
/**
|
||||
* 查询商户配置列表
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 商户配置集合
|
||||
*/
|
||||
public List<UsdtUserSettlementConfiguration> selectUsdtUserSettlementConfigurationList(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser);
|
||||
|
||||
/**
|
||||
* 新增商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser);
|
||||
|
||||
/**
|
||||
* 修改商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser);
|
||||
|
||||
/**
|
||||
* 批量删除商户配置
|
||||
*
|
||||
* @param ids 需要删除的商户配置ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtUserSettlementConfigurationByIds(Long[] ids,boolean isUser);
|
||||
|
||||
/**
|
||||
* 删除商户配置信息
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUsdtUserSettlementConfigurationById(Long id,boolean isUser);
|
||||
|
||||
List<UsdtUserSettlementConfigurationPlus> getByIds(List<Long> ids,boolean isUser, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns);
|
||||
|
||||
UsdtUserSettlementConfigurationPlus getById(Long id, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns);
|
||||
|
||||
Map<Long, UsdtUserSettlementConfigurationPlus> getMapByIds(List<Long> ids, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns);
|
||||
|
||||
List<UsdtUserSettlementConfigurationPlus> getByIds(List<Long> ids);
|
||||
|
||||
Map<Long, UsdtUserSettlementConfigurationPlus> getMapByIds(List<Long> ids);
|
||||
|
||||
/**
|
||||
* @param field sum 字段
|
||||
* @param where 条件
|
||||
* @param tClass 返回类型
|
||||
* @param <T>
|
||||
* @return
|
||||
*/
|
||||
<T> T sum(String field, String where, Class<T> tClass);
|
||||
|
||||
Long count(String where);
|
||||
|
||||
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||
}
|
||||
@@ -1,89 +0,0 @@
|
||||
package com.ruoyi.system.service;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.UserAuth;
|
||||
import com.ruoyi.system.domain.UserAuthPlus;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
/**
|
||||
* 用户授权Service接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
public interface IUserAuthService extends IService<UserAuthPlus>
|
||||
{
|
||||
|
||||
List<SelectItem> select(String keyword,boolean isUser);
|
||||
/**
|
||||
* 查询用户授权
|
||||
*
|
||||
* @param id 用户授权ID
|
||||
* @return 用户授权
|
||||
*/
|
||||
public UserAuth selectUserAuthById(Long id,boolean isUser);
|
||||
|
||||
/**
|
||||
* 查询用户授权列表
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 用户授权集合
|
||||
*/
|
||||
public List<UserAuth> selectUserAuthList(UserAuth userAuth,boolean isUser);
|
||||
|
||||
/**
|
||||
* 新增用户授权
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertUserAuth(UserAuth userAuth,boolean isUser);
|
||||
|
||||
/**
|
||||
* 修改用户授权
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateUserAuth(UserAuth userAuth,boolean isUser);
|
||||
|
||||
/**
|
||||
* 批量删除用户授权
|
||||
*
|
||||
* @param ids 需要删除的用户授权ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserAuthByIds(Long[] ids,boolean isUser);
|
||||
|
||||
/**
|
||||
* 删除用户授权信息
|
||||
*
|
||||
* @param id 用户授权ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteUserAuthById(Long id,boolean isUser);
|
||||
|
||||
List<UserAuthPlus> getByIds(List<Long> ids,boolean isUser, SFunction<UserAuthPlus, ?>... columns);
|
||||
|
||||
UserAuthPlus getById(Long id, SFunction<UserAuthPlus, ?>... columns);
|
||||
|
||||
Map<Long, UserAuthPlus> getMapByIds(List<Long> ids, SFunction<UserAuthPlus, ?>... columns);
|
||||
|
||||
List<UserAuthPlus> getByIds(List<Long> ids);
|
||||
|
||||
Map<Long, UserAuthPlus> getMapByIds(List<Long> ids);
|
||||
|
||||
/**
|
||||
* @param field sum 字段
|
||||
* @param where 条件
|
||||
* @param tClass 返回类型
|
||||
* @param <T>
|
||||
* @return
|
||||
*/
|
||||
<T> T sum(String field, String where, Class<T> tClass);
|
||||
|
||||
Long count(String where);
|
||||
|
||||
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||
}
|
||||
@@ -77,7 +77,6 @@ public interface IWalletAddressService extends IService<WalletAddressPlus>
|
||||
|
||||
Map<Long, WalletAddressPlus> getMapByIds(List<Long> ids, SFunction<WalletAddressPlus, ?>... columns);
|
||||
|
||||
boolean updateWithdrawUsdtBalanceById(Long id, BigDecimal withdrawUsdtBalance);
|
||||
|
||||
List<WalletAddressPlus> getByIds(List<Long> ids);
|
||||
|
||||
|
||||
@@ -1,88 +0,0 @@
|
||||
package com.ruoyi.system.service;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
import com.ruoyi.system.domain.Web3Wallet;
|
||||
import com.ruoyi.system.domain.Web3WalletPlus;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
/**
|
||||
* 钱包管理Service接口
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
public interface IWeb3WalletService extends IService<Web3WalletPlus>
|
||||
{
|
||||
|
||||
/**
|
||||
* 查询钱包管理
|
||||
*
|
||||
* @param id 钱包管理ID
|
||||
* @return 钱包管理
|
||||
*/
|
||||
public Web3Wallet selectWeb3WalletById(Long id,boolean isUser);
|
||||
|
||||
/**
|
||||
* 查询钱包管理列表
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 钱包管理集合
|
||||
*/
|
||||
public List<Web3Wallet> selectWeb3WalletList(Web3Wallet web3Wallet,boolean isUser);
|
||||
|
||||
/**
|
||||
* 新增钱包管理
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWeb3Wallet(Web3Wallet web3Wallet,boolean isUser);
|
||||
|
||||
/**
|
||||
* 修改钱包管理
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWeb3Wallet(Web3Wallet web3Wallet,boolean isUser);
|
||||
|
||||
/**
|
||||
* 批量删除钱包管理
|
||||
*
|
||||
* @param ids 需要删除的钱包管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWeb3WalletByIds(Long[] ids,boolean isUser);
|
||||
|
||||
/**
|
||||
* 删除钱包管理信息
|
||||
*
|
||||
* @param id 钱包管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWeb3WalletById(Long id,boolean isUser);
|
||||
|
||||
List<Web3WalletPlus> getByIds(List<Long> ids,boolean isUser, SFunction<Web3WalletPlus, ?>... columns);
|
||||
|
||||
Web3WalletPlus getById(Long id, SFunction<Web3WalletPlus, ?>... columns);
|
||||
|
||||
Map<Long, Web3WalletPlus> getMapByIds(List<Long> ids, SFunction<Web3WalletPlus, ?>... columns);
|
||||
|
||||
List<Web3WalletPlus> getByIds(List<Long> ids);
|
||||
|
||||
Map<Long, Web3WalletPlus> getMapByIds(List<Long> ids);
|
||||
|
||||
/**
|
||||
* @param field sum 字段
|
||||
* @param where 条件
|
||||
* @param tClass 返回类型
|
||||
* @param <T>
|
||||
* @return
|
||||
*/
|
||||
<T> T sum(String field, String where, Class<T> tClass);
|
||||
|
||||
Long count(String where);
|
||||
|
||||
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||
}
|
||||
+1
-122
@@ -39,8 +39,6 @@ public class UsdtAggregationTaskServiceImpl extends ServiceImpl<UsdtAggregationT
|
||||
@Autowired
|
||||
private JdbcTemplate jdbcTemplate;
|
||||
@Autowired
|
||||
private IWeb3WalletService web3WalletService;
|
||||
@Autowired
|
||||
private IWalletAddressService walletAddressService;
|
||||
|
||||
@Override
|
||||
@@ -240,126 +238,7 @@ public class UsdtAggregationTaskServiceImpl extends ServiceImpl<UsdtAggregationT
|
||||
usdtAggregationTask.setUpdatedAt(DateUtils.getNowDate());
|
||||
if (isUser) {
|
||||
usdtAggregationTask.setUserId(SecurityUtils.getUserId());
|
||||
if (usdtAggregationTask.getAppId() == null) {
|
||||
throw new RuntimeException("AppId为空");
|
||||
}
|
||||
AppsPlus apps = this.appsService.getById(usdtAggregationTask.getAppId());
|
||||
if (apps == null) {
|
||||
throw new RuntimeException("App为空");
|
||||
}
|
||||
if (SecurityUtils.getUserId() == null) {
|
||||
throw new RuntimeException("没有登入");
|
||||
}
|
||||
if (usdtAggregationTask.getExeTime() == null) {
|
||||
throw new RuntimeException("执行时间为空");
|
||||
}
|
||||
if (apps.getUserId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("没有权限");
|
||||
}
|
||||
Web3WalletPlus web3WalletPlus = web3WalletService.getById(SecurityUtils.getUserId());
|
||||
if (web3WalletPlus.getUsdtBalance().subtract(usdtAggregationTask.getTotalAmount()).longValue() < 0) {
|
||||
throw new RuntimeException("超过账户金额");
|
||||
}
|
||||
if (usdtAggregationTask.getTaskName() == null) {
|
||||
throw new RuntimeException("任务名称为空");
|
||||
}
|
||||
if (usdtAggregationTask.getTotalAmount() == null || usdtAggregationTask.getTotalAmount().longValue() <= 0) {
|
||||
throw new RuntimeException("归集金额为空");
|
||||
}
|
||||
if (usdtAggregationTask.getExeTime() == null) {
|
||||
usdtAggregationTask.setExeTime(DateUtils.getNowDate());
|
||||
}
|
||||
usdtAggregationTask.setUserId(SecurityUtils.getUserId());
|
||||
usdtAggregationTask.setDistTokenAddress(apps.getDistTokenAddress());
|
||||
usdtAggregationTask.setVerifyStatus(1);
|
||||
usdtAggregationTask.setStatus(0);
|
||||
List<WalletAddressPlus> list = walletAddressService.getListByAppId(usdtAggregationTask.getAppId());
|
||||
list.sort(new Comparator<WalletAddressPlus>() {
|
||||
@Override
|
||||
public int compare(WalletAddressPlus p1, WalletAddressPlus p2) {
|
||||
return Double.compare(p2.getWithdrawUsdtBalance().doubleValue(), p1.getWithdrawUsdtBalance().doubleValue()); // 倒序排序
|
||||
}
|
||||
});
|
||||
String willTxAmount = this.sum("total_amount","status = 0 and verify_status=1 and user_id="+usdtAggregationTask.getUserId(),String.class);
|
||||
if(willTxAmount == null){
|
||||
willTxAmount ="0.00";
|
||||
}
|
||||
if(new BigDecimal(willTxAmount).add(usdtAggregationTask.getTotalAmount())
|
||||
.subtract(web3WalletPlus.getUsdtBalance()).doubleValue()>0){
|
||||
throw new RuntimeException("待提现金额超过账户金额");
|
||||
}
|
||||
LambdaQueryWrapper<UsdtAggregationTaskPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtAggregationTaskPlus>()
|
||||
.eq(UsdtAggregationTaskPlus::getAppId, usdtAggregationTask.getAppId())
|
||||
.eq(UsdtAggregationTaskPlus::getUserId,usdtAggregationTask.getUserId())
|
||||
.eq(UsdtAggregationTaskPlus::getStatus,0);
|
||||
if(count(lambdaQueryWrapper) > 0){
|
||||
throw new RuntimeException("存在正在提现的记录");
|
||||
}
|
||||
|
||||
this.usdtAggregationTaskMapper.insertUsdtAggregationTask(usdtAggregationTask);
|
||||
BigDecimal totalAmount = usdtAggregationTask.getTotalAmount();
|
||||
List<UsdtAggregationTaskItemPlus> usdtAggregationTaskItems = new ArrayList<>();
|
||||
BigDecimal hasTxItem = new BigDecimal(0);
|
||||
for (WalletAddressPlus item : list) {
|
||||
if (item.getWithdrawUsdtBalance() == null) {
|
||||
item.setWithdrawUsdtBalance(new BigDecimal(0));
|
||||
}
|
||||
UsdtAggregationTaskItemPlus usdtAggregationTaskItem = new UsdtAggregationTaskItemPlus();
|
||||
usdtAggregationTaskItem.setUserId(SecurityUtils.getUserId());
|
||||
usdtAggregationTaskItem.setAppId(usdtAggregationTask.getAppId());
|
||||
usdtAggregationTaskItem.setCreatedAt(new Date());
|
||||
usdtAggregationTaskItem.setUpdatedAt(new Date());
|
||||
usdtAggregationTaskItem.setStatus(0);
|
||||
usdtAggregationTaskItem.setDistTokenAddress(usdtAggregationTask.getDistTokenAddress());
|
||||
usdtAggregationTaskItem.setParentId(usdtAggregationTask.getId());
|
||||
usdtAggregationTaskItem.setTokenAddress(item.getToken());
|
||||
|
||||
if (item.getEnergyNum() < tronService.defaultEstimateEnergy()) {
|
||||
log.error(item.getToken()+"能量不足,需要手续费");
|
||||
continue;
|
||||
}
|
||||
long bandwidth = tronService.defaultEstimateBandwidth();
|
||||
if (bandwidth > item.getBandwidthNum()) {
|
||||
log.error(item.getToken()+"带宽不足需要手续费");
|
||||
continue;
|
||||
}
|
||||
if(bandwidth > item.getBandwidthStakedNum()
|
||||
&& bandwidth > (item.getBandwidthNum()-item.getBandwidthStakedNum())){
|
||||
log.error("代理|免费带宽不足需要手续费");
|
||||
continue;
|
||||
}
|
||||
|
||||
String tempAmount = usdtAggregationTaskItemService.sum("ope_amount","status = 0 and token_address ='"+item.getToken()+"'",String.class);
|
||||
if(tempAmount ==null){
|
||||
tempAmount = "0.00";
|
||||
}
|
||||
if (item.getWithdrawUsdtBalance().subtract(totalAmount).longValue() > 0) {
|
||||
usdtAggregationTaskItem.setOpeAmount(totalAmount);
|
||||
usdtAggregationTaskItems.add(usdtAggregationTaskItem);
|
||||
hasTxItem = hasTxItem.add(item.getWithdrawUsdtBalance().subtract(new BigDecimal(tempAmount))
|
||||
.subtract(totalAmount));
|
||||
totalAmount = new BigDecimal(0);
|
||||
break;
|
||||
} else {
|
||||
usdtAggregationTaskItem.setOpeAmount(item.getWithdrawUsdtBalance());
|
||||
totalAmount = totalAmount.subtract(item.getWithdrawUsdtBalance());
|
||||
usdtAggregationTaskItems.add(usdtAggregationTaskItem);
|
||||
hasTxItem = hasTxItem.add(item.getWithdrawUsdtBalance().subtract(new BigDecimal(tempAmount))
|
||||
.subtract(item.getWithdrawUsdtBalance()));
|
||||
}
|
||||
}
|
||||
if (hasTxItem.doubleValue() < 0) {
|
||||
throw new RuntimeException("app下的地址可提现金额不足,amount=" + hasTxItem.toString());
|
||||
}
|
||||
if (totalAmount.longValue() > 0) {
|
||||
throw new RuntimeException("app下的地址可提现金额不足,amount=" + totalAmount.toString());
|
||||
}
|
||||
if (!usdtAggregationTaskItems.isEmpty()) {
|
||||
this.usdtAggregationTaskItemService.saveBatch(usdtAggregationTaskItems);
|
||||
}else{
|
||||
throw new RuntimeException("没有可以免费提现的地址");
|
||||
}
|
||||
return 1;
|
||||
return this.usdtAggregationTaskMapper.insertUsdtAggregationTask(usdtAggregationTask);
|
||||
} else {
|
||||
return usdtAggregationTaskMapper.insertUsdtAggregationTask(usdtAggregationTask);
|
||||
}
|
||||
|
||||
-270
@@ -1,270 +0,0 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.UsdtFundFlow;
|
||||
import com.ruoyi.system.domain.UsdtFundFlowPlus;
|
||||
import com.ruoyi.system.mapper.UsdtFundFlowMapper;
|
||||
import com.ruoyi.system.service.IUsdtFundFlowService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.jdbc.core.JdbcTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.*;
|
||||
/**
|
||||
* 资金流水Service业务层处理
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
@Service
|
||||
public class UsdtFundFlowServiceImpl extends ServiceImpl<UsdtFundFlowMapper, UsdtFundFlowPlus> implements IUsdtFundFlowService
|
||||
{
|
||||
@Autowired
|
||||
private UsdtFundFlowMapper usdtFundFlowMapper;
|
||||
@Autowired
|
||||
private JdbcTemplate jdbcTemplate;
|
||||
|
||||
@Override
|
||||
public List<UsdtFundFlowPlus> getByIds(List<Long> ids ,boolean isUser, SFunction<UsdtFundFlowPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UsdtFundFlowPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtFundFlowPlus>()
|
||||
.select(columns).in(UsdtFundFlowPlus::getId, ids);
|
||||
if(isUser){
|
||||
lambdaQueryWrapper.eq(UsdtFundFlowPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtFundFlowPlus> list = this.list(lambdaQueryWrapper);
|
||||
if(isUser){
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
private void checkUserPlus(List<UsdtFundFlowPlus> list) {
|
||||
for (UsdtFundFlowPlus item : list){
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
private void checkUser(List<UsdtFundFlow> list) {
|
||||
for (UsdtFundFlow item : list){
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
private void checkUser(UsdtFundFlowPlus item) {
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
private void checkUser(UsdtFundFlow item) {
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
@Override
|
||||
public List<SelectItem> select(String keyword,boolean isUser) {
|
||||
LambdaQueryWrapper<UsdtFundFlowPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtFundFlowPlus>()
|
||||
.select(UsdtFundFlowPlus::getId,UsdtFundFlowPlus::getUserId, UsdtFundFlowPlus::getRemark)
|
||||
.like(UsdtFundFlowPlus::getRemark, keyword);
|
||||
if(isUser){
|
||||
lambdaQueryWrapper.eq(UsdtFundFlowPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtFundFlowPlus> list = this.list(lambdaQueryWrapper);
|
||||
if(isUser){
|
||||
checkUserPlus(list);
|
||||
}
|
||||
List<SelectItem> result =new ArrayList<>();
|
||||
for (UsdtFundFlowPlus item : list){
|
||||
SelectItem selectItem = new SelectItem();
|
||||
selectItem.setName(item.getRemark());
|
||||
selectItem.setId(item.getId());
|
||||
result.add(selectItem);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@Override
|
||||
public UsdtFundFlowPlus getById(Long id, SFunction<UsdtFundFlowPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UsdtFundFlowPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtFundFlowPlus>()
|
||||
.select(columns).eq(UsdtFundFlowPlus::getId, id);
|
||||
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UsdtFundFlowPlus> getMapByIds(List<Long> ids, SFunction<UsdtFundFlowPlus, ?>... columns) {
|
||||
List<UsdtFundFlowPlus> list = this.getByIds(ids,false, columns);
|
||||
Map<Long, UsdtFundFlowPlus> map = new HashMap<>();
|
||||
for (UsdtFundFlowPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UsdtFundFlowPlus> getMapByIds(List<Long> ids) {
|
||||
List<UsdtFundFlowPlus> list = this.getByIds(ids);
|
||||
Map<Long, UsdtFundFlowPlus> map = new HashMap<>();
|
||||
for (UsdtFundFlowPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<UsdtFundFlowPlus> getByIds(List<Long> ids) {
|
||||
LambdaQueryWrapper<UsdtFundFlowPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtFundFlowPlus>().in(UsdtFundFlowPlus::getId, ids);
|
||||
return this.list(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" sum(" + field + ") as total ");
|
||||
stringBuffer.append(" from usdt_fund_flow ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||
return result;
|
||||
}
|
||||
|
||||
public Long count(String where) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" count(1)");
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" usdt_fund_flow ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||
return result;
|
||||
}
|
||||
|
||||
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(select);
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" usdt_fund_flow ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
stringBuffer.append(" group by ");
|
||||
stringBuffer.append(groupby);
|
||||
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||
return tList;
|
||||
}
|
||||
/**
|
||||
* 查询资金流水
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 资金流水
|
||||
*/
|
||||
@Override
|
||||
public UsdtFundFlow selectUsdtFundFlowById(Long id,boolean isUser)
|
||||
{
|
||||
UsdtFundFlow vo = usdtFundFlowMapper.selectUsdtFundFlowById(id);
|
||||
if(isUser){
|
||||
checkUser(vo);
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询资金流水列表
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 资金流水
|
||||
*/
|
||||
@Override
|
||||
public List<UsdtFundFlow> selectUsdtFundFlowList(UsdtFundFlow usdtFundFlow,boolean isUser)
|
||||
{
|
||||
if(usdtFundFlow == null){
|
||||
usdtFundFlow = new UsdtFundFlow();
|
||||
}
|
||||
if(isUser){
|
||||
usdtFundFlow.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtFundFlow> list = usdtFundFlowMapper.selectUsdtFundFlowList(usdtFundFlow);
|
||||
if(isUser){
|
||||
checkUser(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertUsdtFundFlow(UsdtFundFlow usdtFundFlow,boolean isUser)
|
||||
{
|
||||
usdtFundFlow.setCreatedAt(DateUtils.getNowDate());
|
||||
usdtFundFlow.setUpdatedAt(DateUtils.getNowDate());
|
||||
if(isUser){
|
||||
usdtFundFlow.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
return usdtFundFlowMapper.insertUsdtFundFlow(usdtFundFlow);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改资金流水
|
||||
*
|
||||
* @param usdtFundFlow 资金流水
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateUsdtFundFlow(UsdtFundFlow usdtFundFlow,boolean isUser)
|
||||
{
|
||||
usdtFundFlow.setUpdatedAt(DateUtils.getNowDate());
|
||||
if(isUser){
|
||||
checkUser(usdtFundFlow);
|
||||
}
|
||||
return usdtFundFlowMapper.updateUsdtFundFlow(usdtFundFlow);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除资金流水
|
||||
*
|
||||
* @param ids 需要删除的资金流水ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUsdtFundFlowByIds(Long[] ids,boolean isUser)
|
||||
{
|
||||
if(isUser){
|
||||
List<UsdtFundFlowPlus> list= getByIds(Arrays.asList(ids),false,UsdtFundFlowPlus::getUserId,UsdtFundFlowPlus::getId);
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return usdtFundFlowMapper.deleteUsdtFundFlowByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除资金流水信息
|
||||
*
|
||||
* @param id 资金流水ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUsdtFundFlowById(Long id,boolean isUser)
|
||||
{
|
||||
if(isUser){
|
||||
UsdtFundFlowPlus vo = getById(id,UsdtFundFlowPlus::getUserId,UsdtFundFlowPlus::getId);
|
||||
checkUser(vo);
|
||||
}
|
||||
return usdtFundFlowMapper.deleteUsdtFundFlowById(id);
|
||||
}
|
||||
}
|
||||
-277
@@ -1,277 +0,0 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfiguration;
|
||||
import com.ruoyi.system.domain.UsdtUserSettlementConfigurationPlus;
|
||||
import com.ruoyi.system.mapper.UsdtUserSettlementConfigurationMapper;
|
||||
import com.ruoyi.system.service.IUsdtUserSettlementConfigurationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.jdbc.core.JdbcTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.*;
|
||||
/**
|
||||
* 商户配置Service业务层处理
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-12-04
|
||||
*/
|
||||
@Service
|
||||
public class UsdtUserSettlementConfigurationServiceImpl extends ServiceImpl<UsdtUserSettlementConfigurationMapper, UsdtUserSettlementConfigurationPlus> implements IUsdtUserSettlementConfigurationService
|
||||
{
|
||||
@Autowired
|
||||
private UsdtUserSettlementConfigurationMapper usdtUserSettlementConfigurationMapper;
|
||||
@Autowired
|
||||
private JdbcTemplate jdbcTemplate;
|
||||
|
||||
@Override
|
||||
public List<UsdtUserSettlementConfigurationPlus> getByIds(List<Long> ids ,boolean isUser, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus>()
|
||||
.select(columns).in(UsdtUserSettlementConfigurationPlus::getId, ids);
|
||||
if(isUser){
|
||||
lambdaQueryWrapper.eq(UsdtUserSettlementConfigurationPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtUserSettlementConfigurationPlus> list = this.list(lambdaQueryWrapper);
|
||||
if(isUser){
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
private void checkUserPlus(List<UsdtUserSettlementConfigurationPlus> list) {
|
||||
for (UsdtUserSettlementConfigurationPlus item : list){
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
private void checkUser(List<UsdtUserSettlementConfiguration> list) {
|
||||
for (UsdtUserSettlementConfiguration item : list){
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
private void checkUser(UsdtUserSettlementConfigurationPlus item) {
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
private void checkUser(UsdtUserSettlementConfiguration item) {
|
||||
if(null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()){
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
@Override
|
||||
public List<SelectItem> select(String keyword,boolean isUser) {
|
||||
LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus>()
|
||||
.select(UsdtUserSettlementConfigurationPlus::getId,UsdtUserSettlementConfigurationPlus::getUserId, UsdtUserSettlementConfigurationPlus::getRemark)
|
||||
.like(UsdtUserSettlementConfigurationPlus::getRemark, keyword);
|
||||
if(isUser){
|
||||
lambdaQueryWrapper.eq(UsdtUserSettlementConfigurationPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtUserSettlementConfigurationPlus> list = this.list(lambdaQueryWrapper);
|
||||
if(isUser){
|
||||
checkUserPlus(list);
|
||||
}
|
||||
List<SelectItem> result =new ArrayList<>();
|
||||
for (UsdtUserSettlementConfigurationPlus item : list){
|
||||
SelectItem selectItem = new SelectItem();
|
||||
selectItem.setName(item.getRemark());
|
||||
selectItem.setId(item.getId());
|
||||
result.add(selectItem);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@Override
|
||||
public UsdtUserSettlementConfigurationPlus getById(Long id, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus>()
|
||||
.select(columns).eq(UsdtUserSettlementConfigurationPlus::getId, id);
|
||||
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UsdtUserSettlementConfigurationPlus> getMapByIds(List<Long> ids, SFunction<UsdtUserSettlementConfigurationPlus, ?>... columns) {
|
||||
List<UsdtUserSettlementConfigurationPlus> list = this.getByIds(ids,false, columns);
|
||||
Map<Long, UsdtUserSettlementConfigurationPlus> map = new HashMap<>();
|
||||
for (UsdtUserSettlementConfigurationPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UsdtUserSettlementConfigurationPlus> getMapByIds(List<Long> ids) {
|
||||
List<UsdtUserSettlementConfigurationPlus> list = this.getByIds(ids);
|
||||
Map<Long, UsdtUserSettlementConfigurationPlus> map = new HashMap<>();
|
||||
for (UsdtUserSettlementConfigurationPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<UsdtUserSettlementConfigurationPlus> getByIds(List<Long> ids) {
|
||||
LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus>().in(UsdtUserSettlementConfigurationPlus::getId, ids);
|
||||
return this.list(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" sum(" + field + ") as total ");
|
||||
stringBuffer.append(" from usdt_user_settlement_configuration ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||
return result;
|
||||
}
|
||||
|
||||
public Long count(String where) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" count(1)");
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" usdt_user_settlement_configuration ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||
return result;
|
||||
}
|
||||
|
||||
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(select);
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" usdt_user_settlement_configuration ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
stringBuffer.append(" group by ");
|
||||
stringBuffer.append(groupby);
|
||||
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||
return tList;
|
||||
}
|
||||
/**
|
||||
* 查询商户配置
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 商户配置
|
||||
*/
|
||||
@Override
|
||||
public UsdtUserSettlementConfiguration selectUsdtUserSettlementConfigurationById(Long id,boolean isUser)
|
||||
{
|
||||
UsdtUserSettlementConfiguration vo = usdtUserSettlementConfigurationMapper.selectUsdtUserSettlementConfigurationById(id);
|
||||
if(isUser){
|
||||
checkUser(vo);
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public UsdtUserSettlementConfigurationPlus getByUserId(Long userId) {
|
||||
LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UsdtUserSettlementConfigurationPlus>()
|
||||
.eq(UsdtUserSettlementConfigurationPlus::getUserId, userId);
|
||||
return getOne(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询商户配置列表
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 商户配置
|
||||
*/
|
||||
@Override
|
||||
public List<UsdtUserSettlementConfiguration> selectUsdtUserSettlementConfigurationList(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser)
|
||||
{
|
||||
if(usdtUserSettlementConfiguration == null){
|
||||
usdtUserSettlementConfiguration = new UsdtUserSettlementConfiguration();
|
||||
}
|
||||
if(isUser){
|
||||
usdtUserSettlementConfiguration.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
List<UsdtUserSettlementConfiguration> list = usdtUserSettlementConfigurationMapper.selectUsdtUserSettlementConfigurationList(usdtUserSettlementConfiguration);
|
||||
if(isUser){
|
||||
checkUser(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser)
|
||||
{
|
||||
usdtUserSettlementConfiguration.setCreatedAt(DateUtils.getNowDate());
|
||||
usdtUserSettlementConfiguration.setUpdatedAt(DateUtils.getNowDate());
|
||||
if(isUser){
|
||||
usdtUserSettlementConfiguration.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
return usdtUserSettlementConfigurationMapper.insertUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改商户配置
|
||||
*
|
||||
* @param usdtUserSettlementConfiguration 商户配置
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateUsdtUserSettlementConfiguration(UsdtUserSettlementConfiguration usdtUserSettlementConfiguration,boolean isUser)
|
||||
{
|
||||
usdtUserSettlementConfiguration.setUpdatedAt(DateUtils.getNowDate());
|
||||
if(isUser){
|
||||
checkUser(usdtUserSettlementConfiguration);
|
||||
}
|
||||
return usdtUserSettlementConfigurationMapper.updateUsdtUserSettlementConfiguration(usdtUserSettlementConfiguration);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除商户配置
|
||||
*
|
||||
* @param ids 需要删除的商户配置ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUsdtUserSettlementConfigurationByIds(Long[] ids,boolean isUser)
|
||||
{
|
||||
if(isUser){
|
||||
List<UsdtUserSettlementConfigurationPlus> list= getByIds(Arrays.asList(ids),false,UsdtUserSettlementConfigurationPlus::getUserId,UsdtUserSettlementConfigurationPlus::getId);
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return usdtUserSettlementConfigurationMapper.deleteUsdtUserSettlementConfigurationByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除商户配置信息
|
||||
*
|
||||
* @param id 商户配置ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUsdtUserSettlementConfigurationById(Long id,boolean isUser)
|
||||
{
|
||||
if(isUser){
|
||||
UsdtUserSettlementConfigurationPlus vo = getById(id,UsdtUserSettlementConfigurationPlus::getUserId,UsdtUserSettlementConfigurationPlus::getId);
|
||||
checkUser(vo);
|
||||
}
|
||||
return usdtUserSettlementConfigurationMapper.deleteUsdtUserSettlementConfigurationById(id);
|
||||
}
|
||||
}
|
||||
@@ -1,271 +0,0 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.common.select.SelectItem;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.UserAuth;
|
||||
import com.ruoyi.system.domain.UserAuthPlus;
|
||||
import com.ruoyi.system.mapper.UserAuthMapper;
|
||||
import com.ruoyi.system.service.IUserAuthService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.jdbc.core.JdbcTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* 用户授权Service业务层处理
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
@Service
|
||||
public class UserAuthServiceImpl extends ServiceImpl<UserAuthMapper, UserAuthPlus> implements IUserAuthService {
|
||||
@Autowired
|
||||
private UserAuthMapper userAuthMapper;
|
||||
@Autowired
|
||||
private JdbcTemplate jdbcTemplate;
|
||||
|
||||
@Override
|
||||
public List<UserAuthPlus> getByIds(List<Long> ids, boolean isUser, SFunction<UserAuthPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UserAuthPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UserAuthPlus>()
|
||||
.select(columns).in(UserAuthPlus::getId, ids);
|
||||
if (isUser) {
|
||||
lambdaQueryWrapper.eq(UserAuthPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UserAuthPlus> list = this.list(lambdaQueryWrapper);
|
||||
if (isUser) {
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
private void checkUserPlus(List<UserAuthPlus> list) {
|
||||
for (UserAuthPlus item : list) {
|
||||
if (null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(List<UserAuth> list) {
|
||||
for (UserAuth item : list) {
|
||||
if (null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(UserAuthPlus item) {
|
||||
if (null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(UserAuth item) {
|
||||
if (null != SecurityUtils.getUserId() && item.getUserId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SelectItem> select(String keyword, boolean isUser) {
|
||||
LambdaQueryWrapper<UserAuthPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UserAuthPlus>()
|
||||
.select(UserAuthPlus::getId, UserAuthPlus::getUserId, UserAuthPlus::getName)
|
||||
.like(UserAuthPlus::getName, keyword);
|
||||
if (isUser) {
|
||||
lambdaQueryWrapper.eq(UserAuthPlus::getUserId, SecurityUtils.getUserId());
|
||||
}
|
||||
List<UserAuthPlus> list = this.list(lambdaQueryWrapper);
|
||||
if (isUser) {
|
||||
checkUserPlus(list);
|
||||
}
|
||||
List<SelectItem> result = new ArrayList<>();
|
||||
for (UserAuthPlus item : list) {
|
||||
SelectItem selectItem = new SelectItem();
|
||||
selectItem.setName(item.getName());
|
||||
selectItem.setId(item.getId());
|
||||
result.add(selectItem);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public UserAuthPlus getById(Long id, SFunction<UserAuthPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<UserAuthPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UserAuthPlus>()
|
||||
.select(columns).eq(UserAuthPlus::getId, id);
|
||||
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UserAuthPlus> getMapByIds(List<Long> ids, SFunction<UserAuthPlus, ?>... columns) {
|
||||
List<UserAuthPlus> list = this.getByIds(ids, false, columns);
|
||||
Map<Long, UserAuthPlus> map = new HashMap<>();
|
||||
for (UserAuthPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, UserAuthPlus> getMapByIds(List<Long> ids) {
|
||||
List<UserAuthPlus> list = this.getByIds(ids);
|
||||
Map<Long, UserAuthPlus> map = new HashMap<>();
|
||||
for (UserAuthPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<UserAuthPlus> getByIds(List<Long> ids) {
|
||||
LambdaQueryWrapper<UserAuthPlus> lambdaQueryWrapper = new LambdaQueryWrapper<UserAuthPlus>().in(UserAuthPlus::getId, ids);
|
||||
return this.list(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" sum(" + field + ") as total ");
|
||||
stringBuffer.append(" from user_auth ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||
return result;
|
||||
}
|
||||
|
||||
public Long count(String where) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" count(1)");
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" user_auth ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||
return result;
|
||||
}
|
||||
|
||||
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(select);
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" user_auth ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
stringBuffer.append(" group by ");
|
||||
stringBuffer.append(groupby);
|
||||
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||
return tList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户授权
|
||||
*
|
||||
* @param id 用户授权ID
|
||||
* @return 用户授权
|
||||
*/
|
||||
@Override
|
||||
public UserAuth selectUserAuthById(Long id, boolean isUser) {
|
||||
UserAuth vo = userAuthMapper.selectUserAuthById(id);
|
||||
if (isUser) {
|
||||
checkUser(vo);
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询用户授权列表
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 用户授权
|
||||
*/
|
||||
@Override
|
||||
public List<UserAuth> selectUserAuthList(UserAuth userAuth, boolean isUser) {
|
||||
if (userAuth == null) {
|
||||
userAuth = new UserAuth();
|
||||
}
|
||||
if (isUser) {
|
||||
userAuth.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
List<UserAuth> list = userAuthMapper.selectUserAuthList(userAuth);
|
||||
if (isUser) {
|
||||
checkUser(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增用户授权
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertUserAuth(UserAuth userAuth, boolean isUser) {
|
||||
userAuth.setCreatedAt(DateUtils.getNowDate());
|
||||
userAuth.setUpdatedAt(DateUtils.getNowDate());
|
||||
if (isUser) {
|
||||
userAuth.setUserId(SecurityUtils.getUserId());
|
||||
}
|
||||
return userAuthMapper.insertUserAuth(userAuth);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户授权
|
||||
*
|
||||
* @param userAuth 用户授权
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateUserAuth(UserAuth userAuth, boolean isUser) {
|
||||
userAuth.setUpdatedAt(DateUtils.getNowDate());
|
||||
if (isUser) {
|
||||
checkUser(userAuth);
|
||||
}
|
||||
return userAuthMapper.updateUserAuth(userAuth);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除用户授权
|
||||
*
|
||||
* @param ids 需要删除的用户授权ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUserAuthByIds(Long[] ids, boolean isUser) {
|
||||
if (isUser) {
|
||||
List<UserAuthPlus> list = getByIds(Arrays.asList(ids), false, UserAuthPlus::getUserId, UserAuthPlus::getId);
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return userAuthMapper.deleteUserAuthByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除用户授权信息
|
||||
*
|
||||
* @param id 用户授权ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteUserAuthById(Long id, boolean isUser) {
|
||||
if (isUser) {
|
||||
UserAuthPlus vo = getById(id, UserAuthPlus::getUserId, UserAuthPlus::getId);
|
||||
checkUser(vo);
|
||||
}
|
||||
return userAuthMapper.deleteUserAuthById(id);
|
||||
}
|
||||
}
|
||||
@@ -184,14 +184,6 @@ public class WalletAddressServiceImpl extends ServiceImpl<WalletAddressMapper, W
|
||||
return map;
|
||||
}
|
||||
@Override
|
||||
public boolean updateWithdrawUsdtBalanceById(Long id, BigDecimal withdrawUsdtBalance){
|
||||
WalletAddressPlus walletAddressPlus = new WalletAddressPlus();
|
||||
walletAddressPlus.setWithdrawUsdtBalance(withdrawUsdtBalance);
|
||||
LambdaQueryWrapper<WalletAddressPlus> lambdaQueryWrapper = new LambdaQueryWrapper<WalletAddressPlus>();
|
||||
lambdaQueryWrapper.eq(WalletAddressPlus::getId, id);
|
||||
return this.update(walletAddressPlus,lambdaQueryWrapper);
|
||||
}
|
||||
@Override
|
||||
public Map<Long, WalletAddressPlus> getMapByIds(List<Long> ids) {
|
||||
List<WalletAddressPlus> list = this.getByIds(ids);
|
||||
Map<Long, WalletAddressPlus> map = new HashMap<>();
|
||||
|
||||
@@ -1,261 +0,0 @@
|
||||
package com.ruoyi.system.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.SecurityUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.system.domain.Web3Wallet;
|
||||
import com.ruoyi.system.domain.Web3WalletPlus;
|
||||
import com.ruoyi.system.mapper.Web3WalletMapper;
|
||||
import com.ruoyi.system.service.IWeb3WalletService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.jdbc.core.JdbcTemplate;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* 钱包管理Service业务层处理
|
||||
*
|
||||
* @author luqj
|
||||
* @date 2025-11-25
|
||||
*/
|
||||
@Service
|
||||
public class Web3WalletServiceImpl extends ServiceImpl<Web3WalletMapper, Web3WalletPlus> implements IWeb3WalletService {
|
||||
@Autowired
|
||||
private Web3WalletMapper web3WalletMapper;
|
||||
@Autowired
|
||||
private JdbcTemplate jdbcTemplate;
|
||||
|
||||
@Override
|
||||
public List<Web3WalletPlus> getByIds(List<Long> ids, boolean isUser, SFunction<Web3WalletPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<Web3WalletPlus> lambdaQueryWrapper = null;
|
||||
if (isUser) {
|
||||
lambdaQueryWrapper = new LambdaQueryWrapper<Web3WalletPlus>()
|
||||
.select(columns).eq(Web3WalletPlus::getId, SecurityUtils.getUserId());
|
||||
} else {
|
||||
lambdaQueryWrapper = new LambdaQueryWrapper<Web3WalletPlus>()
|
||||
.select(columns).in(Web3WalletPlus::getId, ids);
|
||||
}
|
||||
List<Web3WalletPlus> list = this.list(lambdaQueryWrapper);
|
||||
if (isUser) {
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
private void checkUserPlus(List<Web3WalletPlus> list) {
|
||||
for (Web3WalletPlus item : list) {
|
||||
if (null != SecurityUtils.getUserId() && item.getId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(List<Web3Wallet> list) {
|
||||
for (Web3Wallet item : list) {
|
||||
if (null != SecurityUtils.getUserId() && item.getId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(Web3WalletPlus item) {
|
||||
if (null != SecurityUtils.getUserId() && item.getId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
|
||||
private void checkUser(Web3Wallet item) {
|
||||
if (null != SecurityUtils.getUserId() && item.getId().longValue() != SecurityUtils.getUserId()) {
|
||||
throw new RuntimeException("无权限");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Web3WalletPlus getById(Long id, SFunction<Web3WalletPlus, ?>... columns) {
|
||||
LambdaQueryWrapper<Web3WalletPlus> lambdaQueryWrapper = new LambdaQueryWrapper<Web3WalletPlus>()
|
||||
.select(columns).eq(Web3WalletPlus::getId, id);
|
||||
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, Web3WalletPlus> getMapByIds(List<Long> ids, SFunction<Web3WalletPlus, ?>... columns) {
|
||||
List<Web3WalletPlus> list = this.getByIds(ids, false, columns);
|
||||
Map<Long, Web3WalletPlus> map = new HashMap<>();
|
||||
for (Web3WalletPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<Long, Web3WalletPlus> getMapByIds(List<Long> ids) {
|
||||
List<Web3WalletPlus> list = this.getByIds(ids);
|
||||
Map<Long, Web3WalletPlus> map = new HashMap<>();
|
||||
for (Web3WalletPlus item : list) {
|
||||
map.put(item.getId(), item);
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Web3WalletPlus> getByIds(List<Long> ids) {
|
||||
LambdaQueryWrapper<Web3WalletPlus> lambdaQueryWrapper = new LambdaQueryWrapper<Web3WalletPlus>().in(Web3WalletPlus::getId, ids);
|
||||
return this.list(lambdaQueryWrapper);
|
||||
}
|
||||
|
||||
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" sum(" + field + ") as total ");
|
||||
stringBuffer.append(" from web3_wallet ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||
return result;
|
||||
}
|
||||
|
||||
public Long count(String where) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(" count(1)");
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" web3_wallet ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||
return result;
|
||||
}
|
||||
|
||||
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||
StringBuffer stringBuffer = new StringBuffer();
|
||||
stringBuffer.append("select ");
|
||||
stringBuffer.append(select);
|
||||
stringBuffer.append(" from ");
|
||||
stringBuffer.append(" web3_wallet ");
|
||||
if (StringUtils.isNotBlank(where)) {
|
||||
stringBuffer.append(" where ");
|
||||
stringBuffer.append(where);
|
||||
}
|
||||
stringBuffer.append(" group by ");
|
||||
stringBuffer.append(groupby);
|
||||
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||
return tList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询钱包管理
|
||||
*
|
||||
* @param id 钱包管理ID
|
||||
* @return 钱包管理
|
||||
*/
|
||||
@Override
|
||||
public Web3Wallet selectWeb3WalletById(Long id, boolean isUser) {
|
||||
Web3Wallet vo = web3WalletMapper.selectWeb3WalletById(id);
|
||||
if (isUser) {
|
||||
checkUser(vo);
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询钱包管理列表
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 钱包管理
|
||||
*/
|
||||
@Override
|
||||
public List<Web3Wallet> selectWeb3WalletList(Web3Wallet web3Wallet, boolean isUser) {
|
||||
if (isUser) {
|
||||
Web3WalletPlus myWallet = this.getById(SecurityUtils.getUserId());
|
||||
if(myWallet == null){
|
||||
myWallet = new Web3WalletPlus();
|
||||
myWallet.setId(SecurityUtils.getUserId());
|
||||
myWallet.setPassword(UUID.randomUUID().toString());
|
||||
myWallet.setEthBalance(new BigDecimal(0));
|
||||
myWallet.setTrxBalance(new BigDecimal(0));
|
||||
myWallet.setUsdtBalance(new BigDecimal(0));
|
||||
myWallet.setCreatedAt(new Date());
|
||||
myWallet.setUpdatedAt(new Date());
|
||||
this.save(myWallet);
|
||||
}
|
||||
web3Wallet.setId(SecurityUtils.getUserId());
|
||||
}
|
||||
List<Web3Wallet> list = web3WalletMapper.selectWeb3WalletList(web3Wallet);
|
||||
if (isUser) {
|
||||
checkUser(list);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增钱包管理
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertWeb3Wallet(Web3Wallet web3Wallet, boolean isUser) {
|
||||
web3Wallet.setCreatedAt(DateUtils.getNowDate());
|
||||
web3Wallet.setUpdatedAt(DateUtils.getNowDate());
|
||||
if (isUser) {
|
||||
web3Wallet.setId(SecurityUtils.getUserId());
|
||||
}
|
||||
return web3WalletMapper.insertWeb3Wallet(web3Wallet);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改钱包管理
|
||||
*
|
||||
* @param web3Wallet 钱包管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateWeb3Wallet(Web3Wallet web3Wallet, boolean isUser) {
|
||||
web3Wallet.setUpdatedAt(DateUtils.getNowDate());
|
||||
if (isUser) {
|
||||
checkUser(web3Wallet);
|
||||
}
|
||||
return web3WalletMapper.updateWeb3Wallet(web3Wallet);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除钱包管理
|
||||
*
|
||||
* @param ids 需要删除的钱包管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWeb3WalletByIds(Long[] ids, boolean isUser) {
|
||||
if (isUser) {
|
||||
List<Web3WalletPlus> list = getByIds(Arrays.asList(ids), false, Web3WalletPlus::getUsdtBalance, Web3WalletPlus::getId);
|
||||
checkUserPlus(list);
|
||||
}
|
||||
return web3WalletMapper.deleteWeb3WalletByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除钱包管理信息
|
||||
*
|
||||
* @param id 钱包管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWeb3WalletById(Long id, boolean isUser) {
|
||||
if (isUser) {
|
||||
Web3WalletPlus vo = getById(id, Web3WalletPlus::getUsdtBalance, Web3WalletPlus::getId);
|
||||
checkUser(vo);
|
||||
}
|
||||
return web3WalletMapper.deleteWeb3WalletById(id);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user