页面菜单按照功能分区代码层面部分重构

pull/520/head
dorion 2024-04-26 01:25:19 +08:00
parent 29a6c0f389
commit 8960877cc7
34 changed files with 983 additions and 157 deletions

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.account;
package com.ruoyi.web.controller.trx2Energy;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -6,6 +6,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.domain.entity.FreezeBalanceInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.IAccountAddressInfoService;
import com.ruoyi.system.service.IFreezeBalanceInfoService;
@ -24,10 +25,10 @@ import java.util.List;
* @date 2024-04-13
*/
@Controller
@RequestMapping("/account/freeze")
@RequestMapping("/trx2Energy/freeze")
public class FreezeBalanceInfoController extends BaseController
{
private String prefix = "account/freeze";
private String prefix = "trx2Energy/freeze";
@Autowired
private IFreezeBalanceInfoService freezeBalanceInfoService;
@ -35,7 +36,7 @@ public class FreezeBalanceInfoController extends BaseController
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("account:freeze:view")
@RequiresPermissions("trx2Energy:freeze:view")
@GetMapping()
public String freeze()
{
@ -45,7 +46,7 @@ public class FreezeBalanceInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:freeze:list")
@RequiresPermissions("trx2Energy:freeze:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(FreezeBalanceInfo freezeBalanceInfo)
@ -58,7 +59,7 @@ public class FreezeBalanceInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:freeze:export")
@RequiresPermissions("trx2Energy:freeze:export")
@Log(title = "抵押流水记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
@ -75,14 +76,15 @@ public class FreezeBalanceInfoController extends BaseController
@GetMapping("/add")
public String add(ModelMap mmap)
{
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll());
String busiType = DictUtils.getDictValue("sys_busi_type", "TRX兑能量");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("account:freeze:add")
@RequiresPermissions("trx2Energy:freeze:add")
@Log(title = "抵押流水记录", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
@ -93,7 +95,7 @@ public class FreezeBalanceInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:freeze:edit")
@RequiresPermissions("trx2Energy:freeze:edit")
@GetMapping("/edit/{idFreezeBalanceInfo}")
public String edit(@PathVariable("idFreezeBalanceInfo") Long idFreezeBalanceInfo, ModelMap mmap)
{
@ -105,7 +107,7 @@ public class FreezeBalanceInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:freeze:edit")
@RequiresPermissions("trx2Energy:freeze:edit")
@Log(title = "抵押流水记录", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
@ -117,7 +119,7 @@ public class FreezeBalanceInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:freeze:remove")
@RequiresPermissions("trx2Energy:freeze:remove")
@Log(title = "抵押流水记录", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.account;
package com.ruoyi.web.controller.trx2Energy;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -26,17 +26,17 @@ import java.util.List;
* @date 2024-04-14
*/
@Controller
@RequestMapping("/account/tenant")
@RequestMapping("/trx2Energy/tenant")
public class TenantInfoController extends BaseController
{
private String prefix = "account/tenant";
private String prefix = "trx2Energy/tenant";
@Autowired
private ITenantInfoService tenantInfoService;
@Autowired
private IMonitorAddressInfoService monitorAddressInfoService;
@RequiresPermissions("account:tenant:view")
@RequiresPermissions("trx2Energy:tenant:view")
@GetMapping()
public String tenant()
{
@ -46,7 +46,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:list")
@RequiresPermissions("trx2Energy:tenant:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(TenantInfo tenantInfo)
@ -59,7 +59,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:export")
@RequiresPermissions("trx2Energy:tenant:export")
@Log(title = "租户", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
@ -85,7 +85,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:add")
@RequiresPermissions("trx2Energy:tenant:add")
@Log(title = "租户", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
@ -97,7 +97,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:edit")
@RequiresPermissions("trx2Energy:tenant:edit")
@GetMapping("/edit/{idTenantInfo}")
public String edit(@PathVariable("idTenantInfo") Long idTenantInfo, ModelMap mmap)
{
@ -112,7 +112,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:edit")
@RequiresPermissions("trx2Energy:tenant:edit")
@Log(title = "租户", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
@ -124,7 +124,7 @@ public class TenantInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:tenant:remove")
@RequiresPermissions("trx2Energy:tenant:remove")
@Log(title = "租户", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
@ -133,7 +133,7 @@ public class TenantInfoController extends BaseController
return toAjax(tenantInfoService.deleteTenantInfoByIdTenantInfos(ids));
}
@RequiresPermissions("account:tenant:add")
@RequiresPermissions("trx2Energy:tenant:add")
@Log(title = "租户", businessType = BusinessType.ACTIVE_DATA)
@PostMapping( "/activeData")
@ResponseBody

View File

@ -0,0 +1,125 @@
package com.ruoyi.web.controller.trx2Energy;
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.domain.entity.AccountAddressInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.IAccountAddressInfoService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* TRXController
*
* @author dorion
* @date 2024-04-13
*/
@Controller
@RequestMapping("/trx2Energy/account")
public class Trx2EnergyAccountAddressInfoController extends BaseController
{
private String prefix = "trx2Energy/account";
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("trx2Energy:account:view")
@GetMapping()
public String transfer()
{
return prefix + "/trx2Energy";
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(AccountAddressInfo accountAddressInfo) throws Exception {
startPage();
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
List<AccountAddressInfo> list = accountAddressInfoService.selectAccountAddressInfoListByResouce(accountAddressInfo);
return getDataTable(list);
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:export")
@Log(title = "TRX出账账户", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(AccountAddressInfo accountAddressInfo) throws Exception {
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
List<AccountAddressInfo> list = accountAddressInfoService.selectAccountAddressInfoListByResouce(accountAddressInfo);
ExcelUtil<AccountAddressInfo> util = new ExcelUtil<AccountAddressInfo>(AccountAddressInfo.class);
return util.exportExcel(list, "TRX出账账户数据");
}
/**
* TRX
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:add")
@Log(title = "TRX出账账户", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(AccountAddressInfo accountAddressInfo) throws Exception {
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
return toAjax(accountAddressInfoService.insertAccountAddressInfo(accountAddressInfo));
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:edit")
@GetMapping("/edit/{idAccoutAddressInfo}")
public String edit(@PathVariable("idAccoutAddressInfo") Long idAccoutAddressInfo, ModelMap mmap)
{
AccountAddressInfo accountAddressInfo = accountAddressInfoService.selectAccountAddressInfoByIdAccoutAddressInfo(idAccoutAddressInfo);
mmap.put("accountAddressInfo", accountAddressInfo);
return prefix + "/edit";
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:edit")
@Log(title = "TRX出账账户", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(AccountAddressInfo accountAddressInfo) throws Exception {
return toAjax(accountAddressInfoService.updateAccountAddressInfo(accountAddressInfo));
}
/**
* TRX
*/
@RequiresPermissions("trx2Energy:account:remove")
@Log(title = "TRX出账账户", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(accountAddressInfoService.deleteAccountAddressInfoByIdAccoutAddressInfos(ids));
}
}

View File

@ -0,0 +1,135 @@
package com.ruoyi.web.controller.trx2Energy;
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.domain.entity.MonitorAddressInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.IAccountAddressInfoService;
import com.ruoyi.system.service.IMonitorAddressInfoService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* Controller
*
* @author dorion
* @date 2024-04-13
*/
@Controller
@RequestMapping("/trx2Energy/monitor")
public class Trx2EnergyMonitorAddressInfoController extends BaseController
{
private String prefix = "trx2Energy/monitor";
@Autowired
private IMonitorAddressInfoService monitorAddressInfoService;
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("trx2Energy:monitor:view")
@GetMapping()
public String monitor()
{
return prefix + "/monitor";
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(MonitorAddressInfo monitorAddressInfo)
{
startPage();
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
List<MonitorAddressInfo> list = monitorAddressInfoService.selectMonitorAddressInfoList(monitorAddressInfo);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:export")
@Log(title = "监听账户入账", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(MonitorAddressInfo monitorAddressInfo)
{
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
List<MonitorAddressInfo> list = monitorAddressInfoService.selectMonitorAddressInfoList(monitorAddressInfo);
ExcelUtil<MonitorAddressInfo> util = new ExcelUtil<MonitorAddressInfo>(MonitorAddressInfo.class);
return util.exportExcel(list, "监听账户入账数据");
}
/**
*
*/
@GetMapping("/add")
public String add(ModelMap mmap)
{
String busiType = DictUtils.getDictValue("sys_busi_type", "TRX兑能量");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:add")
@Log(title = "监听账户入账", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(MonitorAddressInfo monitorAddressInfo)
{
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "TRX兑能量"));
return toAjax(monitorAddressInfoService.insertMonitorAddressInfo(monitorAddressInfo));
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:edit")
@GetMapping("/edit/{idMonitorAddress}")
public String edit(@PathVariable("idMonitorAddress") Long idMonitorAddress, ModelMap mmap)
{
MonitorAddressInfo monitorAddressInfo = monitorAddressInfoService.selectMonitorAddressInfoByIdMonitorAddress(idMonitorAddress);
mmap.put("monitorAddressInfo", monitorAddressInfo);
String busiType = DictUtils.getDictValue("sys_busi_type", "TRX兑能量");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:edit")
@Log(title = "监听账户入账", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(MonitorAddressInfo monitorAddressInfo)
{
return toAjax(monitorAddressInfoService.updateMonitorAddressInfo(monitorAddressInfo));
}
/**
*
*/
@RequiresPermissions("trx2Energy:monitor:remove")
@Log(title = "监听账户入账", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(monitorAddressInfoService.deleteMonitorAddressInfoByIdMonitorAddresss(ids));
}
}

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.exchange;
package com.ruoyi.web.controller.trx2Energy;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -6,6 +6,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.domain.entity.TrxExchangeInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.domain.TrxExchange;
import com.ruoyi.system.service.IAccountAddressInfoService;
@ -25,10 +26,10 @@ import java.util.List;
* @date 2024-04-13
*/
@Controller
@RequestMapping("/exchange/trx")
@RequestMapping("/trx2Energy/exchange")
public class TrxExchangeInfoController extends BaseController
{
private String prefix = "exchange/trx";
private String prefix = "trx2Energy/exchange";
@Autowired
private ITrxExchangeInfoService trxExchangeInfoService;
@ -36,7 +37,7 @@ public class TrxExchangeInfoController extends BaseController
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("exchange:trx:view")
@RequiresPermissions("trx2Energy:exchange:view")
@GetMapping()
public String trx()
{
@ -46,7 +47,7 @@ public class TrxExchangeInfoController extends BaseController
/**
* trx
*/
@RequiresPermissions("exchange:trx:list")
@RequiresPermissions("trx2Energy:exchange:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(TrxExchangeInfo trxExchangeInfo)
@ -59,7 +60,7 @@ public class TrxExchangeInfoController extends BaseController
/**
* trx
*/
@RequiresPermissions("exchange:trx:export")
@RequiresPermissions("trx2Energy:exchange:export")
@Log(title = "trx兑能量记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
@ -75,14 +76,16 @@ public class TrxExchangeInfoController extends BaseController
*/
@GetMapping("/add")
public String add(ModelMap mmap)
{ mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll());
{
String busiType = DictUtils.getDictValue("sys_busi_type", "TRX兑能量");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/add";
}
/**
* trx
*/
@RequiresPermissions("exchange:trx:add")
@RequiresPermissions("trx2Energy:exchange:add")
@Log(title = "trx兑能量记录", businessType = BusinessType.INSERT)
@PostMapping("/delegate")
@ResponseBody
@ -93,7 +96,7 @@ public class TrxExchangeInfoController extends BaseController
/**
* trx
*/
@RequiresPermissions("exchange:trx:edit")
@RequiresPermissions("trx2Energy:exchange:edit")
@GetMapping("/edit/{idTrxExchangeInfo}")
public String edit(@PathVariable("idTrxExchangeInfo") Long idTrxExchangeInfo, ModelMap mmap)
{
@ -105,7 +108,7 @@ public class TrxExchangeInfoController extends BaseController
/**
* trx
*/
@RequiresPermissions("exchange:trx:edit")
@RequiresPermissions("trx2Energy:exchange:edit")
@Log(title = "trx兑能量记录", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
@ -117,7 +120,7 @@ public class TrxExchangeInfoController extends BaseController
/**
* trx
*/
@RequiresPermissions("exchange:trx:remove")
@RequiresPermissions("trx2Energy:exchange:remove")
@Log(title = "trx兑能量记录", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.account;
package com.ruoyi.web.controller.usdt2Trx;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -6,7 +6,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.domain.entity.AccountAddressInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.IAccountAddressInfoService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
@ -18,55 +18,57 @@ import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
* Controller
* USDTController
*
* @author dorion
* @date 2024-04-13
*/
@Controller
@RequestMapping("/account/transfer")
public class AccountAddressInfoController extends BaseController
@RequestMapping("/usdt2Trx/account")
public class Usdt2TrxAccountAddressInfoController extends BaseController
{
private String prefix = "account/transfer";
private String prefix = "usdt2Trx/account";
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("account:transfer:view")
@RequiresPermissions("usdt2Trx:account:view")
@GetMapping()
public String transfer()
{
return prefix + "/transfer";
return prefix + "/usdt2Trx";
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:list")
@RequiresPermissions("usdt2Trx:account:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(AccountAddressInfo accountAddressInfo) throws Exception {
startPage();
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
List<AccountAddressInfo> list = accountAddressInfoService.selectAccountAddressInfoListByResouce(accountAddressInfo);
return getDataTable(list);
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:export")
@Log(title = "出账账户", businessType = BusinessType.EXPORT)
@RequiresPermissions("usdt2Trx:account:export")
@Log(title = "USDT出账账户", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(AccountAddressInfo accountAddressInfo) throws Exception {
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
List<AccountAddressInfo> list = accountAddressInfoService.selectAccountAddressInfoListByResouce(accountAddressInfo);
ExcelUtil<AccountAddressInfo> util = new ExcelUtil<AccountAddressInfo>(AccountAddressInfo.class);
return util.exportExcel(list, "出账账户数据");
return util.exportExcel(list, "USDT出账账户数据");
}
/**
*
* USDT
*/
@GetMapping("/add")
public String add()
@ -75,20 +77,21 @@ public class AccountAddressInfoController extends BaseController
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:add")
@Log(title = "出账账户", businessType = BusinessType.INSERT)
@RequiresPermissions("usdt2Trx:account:add")
@Log(title = "USDT出账账户", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(AccountAddressInfo accountAddressInfo) throws Exception {
accountAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
return toAjax(accountAddressInfoService.insertAccountAddressInfo(accountAddressInfo));
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:edit")
@RequiresPermissions("usdt2Trx:account:edit")
@GetMapping("/edit/{idAccoutAddressInfo}")
public String edit(@PathVariable("idAccoutAddressInfo") Long idAccoutAddressInfo, ModelMap mmap)
{
@ -98,10 +101,10 @@ public class AccountAddressInfoController extends BaseController
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:edit")
@Log(title = "出账账户", businessType = BusinessType.UPDATE)
@RequiresPermissions("usdt2Trx:account:edit")
@Log(title = "USDT出账账户", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(AccountAddressInfo accountAddressInfo) throws Exception {
@ -109,10 +112,10 @@ public class AccountAddressInfoController extends BaseController
}
/**
*
* USDT
*/
@RequiresPermissions("account:transfer:remove")
@Log(title = "出账账户", businessType = BusinessType.DELETE)
@RequiresPermissions("usdt2Trx:account:remove")
@Log(title = "USDT出账账户", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.account;
package com.ruoyi.web.controller.usdt2Trx;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -6,6 +6,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.domain.entity.MonitorAddressInfo;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.DictUtils;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.service.IAccountAddressInfoService;
import com.ruoyi.system.service.IMonitorAddressInfoService;
@ -24,17 +25,17 @@ import java.util.List;
* @date 2024-04-13
*/
@Controller
@RequestMapping("/account/monitor")
public class MonitorAddressInfoController extends BaseController
@RequestMapping("/usdt2Trx/monitor")
public class Usdt2TrxMonitorAddressInfoController extends BaseController
{
private String prefix = "account/monitor";
private String prefix = "usdt2Trx/monitor";
@Autowired
private IMonitorAddressInfoService monitorAddressInfoService;
@Autowired
private IAccountAddressInfoService accountAddressInfoService;
@RequiresPermissions("account:monitor:view")
@RequiresPermissions("usdt2Trx:monitor:view")
@GetMapping()
public String monitor()
{
@ -44,12 +45,13 @@ public class MonitorAddressInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:monitor:list")
@RequiresPermissions("usdt2Trx:monitor:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(MonitorAddressInfo monitorAddressInfo)
{
startPage();
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
List<MonitorAddressInfo> list = monitorAddressInfoService.selectMonitorAddressInfoList(monitorAddressInfo);
return getDataTable(list);
}
@ -57,12 +59,13 @@ public class MonitorAddressInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:monitor:export")
@RequiresPermissions("usdt2Trx:monitor:export")
@Log(title = "监听账户入账", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(MonitorAddressInfo monitorAddressInfo)
{
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
List<MonitorAddressInfo> list = monitorAddressInfoService.selectMonitorAddressInfoList(monitorAddressInfo);
ExcelUtil<MonitorAddressInfo> util = new ExcelUtil<MonitorAddressInfo>(MonitorAddressInfo.class);
return util.exportExcel(list, "监听账户入账数据");
@ -74,39 +77,42 @@ public class MonitorAddressInfoController extends BaseController
@GetMapping("/add")
public String add(ModelMap mmap)
{
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll());
String busiType = DictUtils.getDictValue("sys_busi_type", "USDT兑TRX");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("account:monitor:add")
@RequiresPermissions("usdt2Trx:monitor:add")
@Log(title = "监听账户入账", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(MonitorAddressInfo monitorAddressInfo)
{
monitorAddressInfo.setBusiType(DictUtils.getDictValue("sys_busi_type", "USDT兑TRX"));
return toAjax(monitorAddressInfoService.insertMonitorAddressInfo(monitorAddressInfo));
}
/**
*
*/
@RequiresPermissions("account:monitor:edit")
@RequiresPermissions("usdt2Trx:monitor:edit")
@GetMapping("/edit/{idMonitorAddress}")
public String edit(@PathVariable("idMonitorAddress") Long idMonitorAddress, ModelMap mmap)
{
MonitorAddressInfo monitorAddressInfo = monitorAddressInfoService.selectMonitorAddressInfoByIdMonitorAddress(idMonitorAddress);
mmap.put("monitorAddressInfo", monitorAddressInfo);
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll());
String busiType = DictUtils.getDictValue("sys_busi_type", "USDT兑TRX");
mmap.put("accountAddressList", accountAddressInfoService.selectAccountAddressInfoAll(busiType));
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("account:monitor:edit")
@RequiresPermissions("usdt2Trx:monitor:edit")
@Log(title = "监听账户入账", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
@ -118,7 +124,7 @@ public class MonitorAddressInfoController extends BaseController
/**
*
*/
@RequiresPermissions("account:monitor:remove")
@RequiresPermissions("usdt2Trx:monitor:remove")
@Log(title = "监听账户入账", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody

View File

@ -1,4 +1,4 @@
package com.ruoyi.web.controller.exchange;
package com.ruoyi.web.controller.usdt2Trx;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
@ -23,15 +23,15 @@ import java.util.List;
* @date 2024-04-19
*/
@Controller
@RequestMapping("/exchange/usdt")
@RequestMapping("/usdt2Trx/exchange")
public class UsdtExchangeInfoController extends BaseController
{
private String prefix = "exchange/usdt";
private String prefix = "usdt2Trx/exchange";
@Autowired
private IUsdtExchangeInfoService usdtExchangeInfoService;
@RequiresPermissions("exchange:usdt:view")
@RequiresPermissions("usdt2Trx:exchange:view")
@GetMapping()
public String usdt()
{
@ -41,7 +41,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:list")
@RequiresPermissions("usdt2Trx:exchange:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(UsdtExchangeInfo usdtExchangeInfo)
@ -54,7 +54,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:export")
@RequiresPermissions("usdt2Trx:exchange:export")
@Log(title = "USDT交易明细", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
@ -77,7 +77,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:add")
@RequiresPermissions("usdt2Trx:exchange:add")
@Log(title = "USDT交易明细", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
@ -88,7 +88,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:edit")
@RequiresPermissions("usdt2Trx:exchange:edit")
@GetMapping("/edit/{idUsdtExchangeInfo}")
public String edit(@PathVariable("idUsdtExchangeInfo") Long idUsdtExchangeInfo, ModelMap mmap)
{
@ -100,7 +100,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:edit")
@RequiresPermissions("usdt2Trx:exchange:edit")
@Log(title = "USDT交易明细", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
@ -112,7 +112,7 @@ public class UsdtExchangeInfoController extends BaseController
/**
* USDT
*/
@RequiresPermissions("exchange:usdt:remove")
@RequiresPermissions("usdt2Trx:exchange:remove")
@Log(title = "USDT交易明细", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody

View File

@ -0,0 +1,47 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增出账账户')" />
<th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-transfer-add">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">地址:</label>
<div class="col-sm-8">
<input name="address" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">秘钥:</label>
<div class="col-sm-8">
<input name="encryptPrivateKey" class="form-control" type="text" required>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "trx2Energy/account"
$("#form-transfer-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-transfer-add').serialize());
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,49 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改出账账户')" />
<th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-transfer-edit" th:object="${accountAddressInfo}">
<input name="idAccoutAddressInfo" th:field="*{idAccoutAddressInfo}" type="hidden">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{busiType}"></option>
</select>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">地址:</label>
<div class="col-sm-8">
<input name="address" th:field="*{address}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">秘钥:</label>
<div class="col-sm-8">
<input name="encryptPrivateKey" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "trx2Energy/account";
$("#form-transfer-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-transfer-edit').serialize());
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,137 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('出账账户列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>地址:</label>
<input type="text" name="address"/>
</li>
<li>
<label>创建时间:</label>
<input type="text" class="time-input" placeholder="请选择创建时间" name="fcd"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="trx2Energy:account:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="trx2Energy:account:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="trx2Energy:account:remove">
<i class="fa fa-remove"></i> 删除
</a>
<!-- <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="account:transfer:export">
<i class="fa fa-download"></i> 导出
</a>-->
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('trx2Energy:account:edit')}]];
var removeFlag = [[${@permission.hasPermi('trx2Energy:account:remove')}]];
var prefix = ctx + "trx2Energy/account";
var datas = [[${@dict.getType('sys_yes_no')}]];
var busiTypeDatas = [[${@dict.getType('sys_busi_type')}]];
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "出账账户",
columns: [{
checkbox: true
},
{
field: 'idAccoutAddressInfo',
title: '主键',
visible: false
},
{
field: 'address',
title: '地址'
}, {
field: 'busiType',
title: '业务类型',
formatter: function(value, row, index) {
return $.table.selectDictLabel(busiTypeDatas, value);
},
visible: false
},
/* {
field: 'encryptPrivateKey',
title: '秘钥'
},*/
{
field: 'isValid',
title: '是否有效',
formatter: function(value, item, index) {
return $.table.selectDictLabel(datas, item.isValid);
}
},{
field: 'netResource',
title: '带宽资源',
},{
field: 'energyResource',
title: '能量资源',
},{
field: 'totalFrozen',
title: '抵押资产TRX',
},{
field: 'trxBalance',
title: 'TRX余额',
},
{
field: 'fcd',
title: '创建时间'
},/*
{
field: 'fcu',
title: '创建用户'
},
{
field: 'lcd',
title: '更新时间'
},
{
field: 'lcu',
title: '更新用户'
},*/
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.idAccoutAddressInfo + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.idAccoutAddressInfo + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

View File

@ -112,7 +112,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "exchange/trx"
var prefix = ctx + "trx2Energy/exchange"
$("#form-trx-add").validate({
focusCleanup: true
});

View File

@ -23,7 +23,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "exchange/trx";
var prefix = ctx + "trx2Energy/exchange";
$("#form-trx-edit").validate({
focusCleanup: true
});

View File

@ -60,16 +60,16 @@
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="exchange:trx:add">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="trx2Energy:exchange:add">
<i class="fa fa-plus"></i> 手动委托资源
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="exchange:trx:edit">
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="trx2Energy:exchange:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="exchange:trx:remove">
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="trx2Energy:exchange:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="exchange:trx:export">
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="trx2Energy:exchange:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
@ -80,9 +80,9 @@
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('exchange:trx:edit')}]];
var removeFlag = [[${@permission.hasPermi('exchange:trx:remove')}]];
var prefix = ctx + "exchange/trx";
var editFlag = [[${@permission.hasPermi('trx2Energy:exchange:edit')}]];
var removeFlag = [[${@permission.hasPermi('trx2Energy:exchange:remove')}]];
var prefix = ctx + "trx2Energy/exchange";
var datas = [[${@dict.getType('sys_delegate_status')}]];
var tranferCountDatas = [[${@dict.getType('sys_transfer_number')}]];
var sysEnergyBusiTypeDatas = [[${@dict.getType('sys_energy_busi_type')}]];

View File

@ -37,7 +37,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/freeze"
var prefix = ctx + "trx2Energy/freeze"
$("#form-freeze-add").validate({
focusCleanup: true
});

View File

@ -49,7 +49,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/freeze";
var prefix = ctx + "trx2Energy/freeze";
$("#form-freeze-edit").validate({
focusCleanup: true
});

View File

@ -41,16 +41,16 @@
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="account:freeze:add">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="trx2Energy:freeze:add">
<i class="fa fa-plus"></i> 添加
</a>
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="account:freeze:edit">
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="trx2Energy:freeze:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="account:freeze:remove">
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="trx2Energy:freeze:remove">
<i class="fa fa-remove"></i> 删除
</a>-->
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="account:freeze:export">
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="trx2Energy:freeze:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
@ -61,9 +61,9 @@
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('account:freeze:edit')}]];
var removeFlag = [[${@permission.hasPermi('account:freeze:remove')}]];
var prefix = ctx + "account/freeze";
var editFlag = [[${@permission.hasPermi('trx2Energy:freeze:edit')}]];
var removeFlag = [[${@permission.hasPermi('trx2Energy:freeze:remove')}]];
var prefix = ctx + "trx2Energy/freeze";
var datas = [[${@dict.getType('sys_trx_exchange')}]];
$(function() {
var options = {

View File

@ -0,0 +1,73 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
<th:block th:include="include :: header('新增监听账户入账')"/>
<th:block th:include="include :: datetimepicker-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-monitor-add">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">监听地址:</label>
<div class="col-sm-8">
<input name="monitorAddress" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">出账地址:</label>
<div class="col-sm-8">
<!-- <input name="accountAddress" class="form-control" type="text">-->
<select id="accountAddress" name="accountAddress" class="form-control " >
<option th:each="accountAddress:${accountAddressList}" th:value="${accountAddress.address}" th:text="${accountAddress.address}" ></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">单价:</label>
<div class="col-sm-8">
<input name="price" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">监听类型:</label>
<div class="col-sm-8">
<select class="form-control" name="monitorType" th:with="type=${@dict.getType('sys_monitor_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">API_KEY</label>
<div class="col-sm-8">
<select name="apiKey" class="form-control m-b" th:with="type=${@dict.getType('sys_tron_api_key')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer"/>
<th:block th:include="include :: datetimepicker-js"/>
<script th:inline="javascript">
var prefix = ctx + "trx2Energy/monitor"
$("#form-monitor-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-monitor-add').serialize());
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,88 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改监听账户入账')" />
<th:block th:include="include :: datetimepicker-css" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-monitor-edit" th:object="${monitorAddressInfo}">
<input name="idMonitorAddress" th:field="*{idMonitorAddress}" type="hidden">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{busiType}"></option>
</select>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">监听地址:</label>
<div class="col-sm-8">
<input name="monitorAddress" th:field="*{monitorAddress}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">出账地址:</label>
<div class="col-sm-8">
<!-- <input name="accountAddress" th:field="*{accountAddress}" class="form-control" type="text">-->
<select id="accountAddress" name="accountAddress" class="form-control " >
<option th:each="accountAddressInfo:${accountAddressList}" th:value="${accountAddressInfo.address}" th:text="${accountAddressInfo.address}" th:field="*{accountAddress}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">单价:</label>
<div class="col-sm-8">
<input name="price" th:field="*{price}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">是否有效:</label>
<div class="col-sm-8">
<select class="form-control" name="isValid" th:with="type=${@dict.getType('sys_yes_no')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{isValid}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">监听类型:</label>
<div class="col-sm-8">
<select class="form-control" name="monitorType" th:with="type=${@dict.getType('sys_monitor_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{monitorType}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">API_KEY</label>
<div class="col-sm-8">
<select name="apiKey" class="form-control m-b" th:with="type=${@dict.getType('sys_tron_api_key')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{apiKey}"></option>
</select>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "trx2Energy/monitor";
$("#form-monitor-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-monitor-edit').serialize());
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,172 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('监听账户入账列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>监听地址:</label>
<input type="text" name="monitorAddress"/>
</li>
<li>
<label>出账地址:</label>
<input type="text" name="accountAddress"/>
</li>
<!-- <li>
<label>单位:</label>
<input type="text" name="price"/>
</li>-->
<li>
<label>是否有效:</label>
<select class="form-control" name="isValid" th:with="type=${@dict.getType('sys_yes_no')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>监听类型:</label>
<select class="form-control" name="monitorType" th:with="type=${@dict.getType('sys_monitor_type')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>创建时间:</label>
<input type="text" class="time-input" placeholder="请选择创建时间" name="fcd"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="trx2Energy:monitor:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="trx2Energy:monitor:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="trx2Energy:monitor:remove">
<i class="fa fa-remove"></i> 删除
</a>
<!--<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="trx2Energy:monitor:export">
<i class="fa fa-download"></i> 导出
</a>-->
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('trx2Energy:monitor:edit')}]];
var removeFlag = [[${@permission.hasPermi('trx2Energy:monitor:remove')}]];
var prefix = ctx + "trx2Energy/monitor";
var datas = [[${@dict.getType('sys_yes_no')}]];
var monitorTypeDatas = [[${@dict.getType('sys_monitor_type')}]];
var apiKeyDatas = [[${@dict.getType('sys_tron_api_key')}]];
var busiTypeDatas = [[${@dict.getType('sys_busi_type')}]];
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "监听账户入账",
columns: [{
checkbox: true
},
{
field: 'idMonitorAddress',
title: '主键',
visible: false
},
{
field: 'monitorAddress',
title: '监听地址'
}, {
field: 'busiType',
title: '业务类型',
formatter: function(value, row, index) {
return $.table.selectDictLabel(busiTypeDatas, value);
},
visible: false
},
{
field: 'accountAddress',
title: '出账地址'
},
{
field: 'price',
title: '单价'
},
{
field: 'monitorType',
title: '监听类型',
formatter: function(value, item, index) {
return $.table.selectDictLabel(monitorTypeDatas, item.monitorType);
}
},
{
field: 'apiKey',
title: 'API_KEY',
formatter: function(value, row, index) {
return $.table.selectDictLabel(apiKeyDatas, value);
}
},
{
field: 'isValid',
title: '是否有效',
formatter: function(value, item, index) {
return $.table.selectDictLabel(datas, item.isValid);
}
},
{
field: 'fcd',
title: '创建时间',
visible: false
},
{
field: 'fcu',
title: '创建用户',
visible: false
},
{
field: 'lcd',
title: '更新时间',
visible: false
},
{
field: 'lcu',
title: '更新用户',
visible: false
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.idMonitorAddress + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.idMonitorAddress + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

View File

@ -58,7 +58,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/tenant"
var prefix = ctx + "trx2Energy/tenant"
$("#form-tenant-add").validate({
focusCleanup: true
});

View File

@ -83,7 +83,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/tenant";
var prefix = ctx + "trx2Energy/tenant";
$("#form-tenant-edit").validate({
focusCleanup: true
});

View File

@ -66,7 +66,7 @@
var isPaidDatas = [[${@dict.getType('sys_is_paid')}]];
var periodDatas = [[${@dict.getType('sys_lock_period_day')}]];
var statusDatas = [[${@dict.getType('sys_tenant_status')}]];
var prefix = ctx + "account/tenant";
var prefix = ctx + "trx2Energy/tenant";
$(function() {
var options = {

View File

@ -7,14 +7,14 @@
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-transfer-add">
<div class="form-group">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">地址:</label>
<div class="col-sm-8">
@ -32,7 +32,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/transfer"
var prefix = ctx + "usdt2Trx/account"
$("#form-transfer-add").validate({
focusCleanup: true
});

View File

@ -8,14 +8,14 @@
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-transfer-edit" th:object="${accountAddressInfo}">
<input name="idAccoutAddressInfo" th:field="*{idAccoutAddressInfo}" type="hidden">
<div class="form-group">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{busiType}"></option>
</select>
</div>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">地址:</label>
<div class="col-sm-8">
@ -33,7 +33,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/transfer";
var prefix = ctx + "usdt2Trx/account";
$("#form-transfer-edit").validate({
focusCleanup: true
});

View File

@ -14,26 +14,10 @@
<label>地址:</label>
<input type="text" name="address"/>
</li>
<!-- <li>
<label>加密之后的账户秘钥:</label>
<input type="text" name="encryptPrivateKey"/>
</li>
<li>
<label>用于解密加密之后的账户秘钥的秘钥:</label>
<input type="text" name="encryptKey"/>
</li>
<li>
<label>是否有效,用于逻辑删除:</label>
<input type="text" name="isValid"/>
</li>-->
<li>
<label>创建时间:</label>
<input type="text" class="time-input" placeholder="请选择创建时间" name="fcd"/>
</li>
<!-- <li>
<label>更新时间:</label>
<input type="text" class="time-input" placeholder="请选择更新时间" name="lcd"/>
</li>-->
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
@ -44,13 +28,13 @@
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="account:transfer:add">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="usdt2Trx:account:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="account:transfer:edit">
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="usdt2Trx:account:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="account:transfer:remove">
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="usdt2Trx:account:remove">
<i class="fa fa-remove"></i> 删除
</a>
<!-- <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="account:transfer:export">
@ -64,9 +48,9 @@
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('account:transfer:edit')}]];
var removeFlag = [[${@permission.hasPermi('account:transfer:remove')}]];
var prefix = ctx + "account/transfer";
var editFlag = [[${@permission.hasPermi('usdt2Trx:account:edit')}]];
var removeFlag = [[${@permission.hasPermi('usdt2Trx:account:remove')}]];
var prefix = ctx + "usdt2Trx/account";
var datas = [[${@dict.getType('sys_yes_no')}]];
var busiTypeDatas = [[${@dict.getType('sys_busi_type')}]];
$(function() {
@ -93,7 +77,8 @@
title: '业务类型',
formatter: function(value, row, index) {
return $.table.selectDictLabel(busiTypeDatas, value);
}
},
visible: false
},
/* {
field: 'encryptPrivateKey',

View File

@ -27,7 +27,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "exchange/usdt"
var prefix = ctx + "usdt2Trx/exchange"
$("#form-usdt-add").validate({
focusCleanup: true
});

View File

@ -91,7 +91,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "exchange/usdt";
var prefix = ctx + "usdt2Trx/exchange";
$("#form-usdt-edit").validate({
focusCleanup: true
});

View File

@ -38,16 +38,16 @@
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="exchange:usdt:add">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="usdt2Trx:exchange:add">
<i class="fa fa-plus"></i> 添加
</a>
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="exchange:usdt:edit">
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="usdt2Trx:exchange:edit">
<i class="fa fa-edit"></i> 修改
</a>-->
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="exchange:usdt:remove">
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="usdt2Trx:exchange:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="exchange:usdt:export">
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="usdt2Trx:exchange:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
@ -58,9 +58,9 @@
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('exchange:usdt:edit')}]];
var removeFlag = [[${@permission.hasPermi('exchange:usdt:remove')}]];
var prefix = ctx + "exchange/usdt";
var editFlag = [[${@permission.hasPermi('usdt2Trx:exchange:edit')}]];
var removeFlag = [[${@permission.hasPermi('usdt2Trx:exchange:remove')}]];
var prefix = ctx + "usdt2Trx/exchange";
$(function() {
var options = {

View File

@ -7,14 +7,14 @@
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-monitor-add">
<div class="form-group">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">监听地址:</label>
<div class="col-sm-8">
@ -58,7 +58,7 @@
<th:block th:include="include :: footer"/>
<th:block th:include="include :: datetimepicker-js"/>
<script th:inline="javascript">
var prefix = ctx + "account/monitor"
var prefix = ctx + "usdt2Trx/monitor"
$("#form-monitor-add").validate({
focusCleanup: true
});

View File

@ -8,14 +8,14 @@
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-monitor-edit" th:object="${monitorAddressInfo}">
<input name="idMonitorAddress" th:field="*{idMonitorAddress}" type="hidden">
<div class="form-group">
<!-- <div class="form-group">
<label class="col-sm-3 control-label">业务类型:</label>
<div class="col-sm-8">
<select name="busiType" class="form-control m-b" th:with="type=${@dict.getType('sys_busi_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{busiType}"></option>
</select>
</div>
</div>
</div>-->
<div class="form-group">
<label class="col-sm-3 control-label">监听地址:</label>
<div class="col-sm-8">
@ -71,7 +71,7 @@
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "account/monitor";
var prefix = ctx + "usdt2Trx/monitor";
$("#form-monitor-edit").validate({
focusCleanup: true
});

View File

@ -50,16 +50,16 @@
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="account:monitor:add">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="usdt2Trx:monitor:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="account:monitor:edit">
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="usdt2Trx:monitor:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="account:monitor:remove">
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="usdt2Trx:monitor:remove">
<i class="fa fa-remove"></i> 删除
</a>
<!--<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="account:monitor:export">
<!--<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="usdt2Trx:monitor:export">
<i class="fa fa-download"></i> 导出
</a>-->
</div>
@ -70,9 +70,9 @@
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('account:monitor:edit')}]];
var removeFlag = [[${@permission.hasPermi('account:monitor:remove')}]];
var prefix = ctx + "account/monitor";
var editFlag = [[${@permission.hasPermi('usdt2Trx:monitor:edit')}]];
var removeFlag = [[${@permission.hasPermi('usdt2Trx:monitor:remove')}]];
var prefix = ctx + "usdt2Trx/monitor";
var datas = [[${@dict.getType('sys_yes_no')}]];
var monitorTypeDatas = [[${@dict.getType('sys_monitor_type')}]];
var apiKeyDatas = [[${@dict.getType('sys_tron_api_key')}]];
@ -101,7 +101,7 @@
title: '业务类型',
formatter: function(value, row, index) {
return $.table.selectDictLabel(busiTypeDatas, value);
}
},visible: false
},
{
field: 'accountAddress',

View File

@ -61,7 +61,7 @@ public interface IAccountAddressInfoService
*/
public int deleteAccountAddressInfoByIdAccoutAddressInfo(Long idAccoutAddressInfo);
Object selectAccountAddressInfoAll();
Object selectAccountAddressInfoAll(String busiType);
String getDecryptPrivateKey(String address) throws Exception;

View File

@ -116,9 +116,10 @@ public class AccountAddressInfoServiceImpl implements IAccountAddressInfoService
}
@Override
public List<AccountAddressInfo> selectAccountAddressInfoAll() {
public List<AccountAddressInfo> selectAccountAddressInfoAll(String busiType) {
AccountAddressInfo accountAddressInfo = new AccountAddressInfo();
accountAddressInfo.setIsValid(UserConstants.YES);
accountAddressInfo.setBusiType(busiType);
return accountAddressInfoMapper.selectAccountAddressInfoList(accountAddressInfo);
}