From b65c0ec3695a9ddd6972e2671ae3059f8fd5de6d Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Tue, 30 May 2023 15:58:55 +0800
Subject: [PATCH] twoCoin项目修改
---
src/main/java/cc/mrbird/febs/dapp/controller/ViewController.java | 88 ++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 88 insertions(+), 0 deletions(-)
diff --git a/src/main/java/cc/mrbird/febs/dapp/controller/ViewController.java b/src/main/java/cc/mrbird/febs/dapp/controller/ViewController.java
index 82a9167..2a873ad 100644
--- a/src/main/java/cc/mrbird/febs/dapp/controller/ViewController.java
+++ b/src/main/java/cc/mrbird/febs/dapp/controller/ViewController.java
@@ -4,14 +4,20 @@
import cc.mrbird.febs.common.entity.FebsConstant;
import cc.mrbird.febs.common.utils.FebsUtil;
import cc.mrbird.febs.common.utils.RedisUtils;
+import cc.mrbird.febs.dapp.entity.DappMemberEntity;
+import cc.mrbird.febs.dapp.entity.DappSystemProfit;
import cc.mrbird.febs.dapp.entity.DataDictionaryCustom;
import cc.mrbird.febs.dapp.enumerate.DataDictionaryEnum;
+import cc.mrbird.febs.dapp.mapper.DappMemberDao;
+import cc.mrbird.febs.dapp.mapper.DappSystemProfitDao;
import cc.mrbird.febs.dapp.mapper.DataDictionaryCustomMapper;
import cc.mrbird.febs.dapp.service.DappMemberService;
+import cc.mrbird.febs.dapp.vo.AdminAgentLevelSetInfoVo;
import cc.mrbird.febs.dapp.vo.AdminSystemFeeVo;
import cn.hutool.core.util.ObjectUtil;
import lombok.RequiredArgsConstructor;
import org.apache.shiro.authz.annotation.RequiresPermissions;
+import org.checkerframework.checker.units.qual.A;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
@@ -31,6 +37,8 @@
private final RedisUtils redisUtils;
private final DataDictionaryCustomMapper dataDictionaryCustomMapper;
+ private final DappSystemProfitDao dappSystemProfitDao;
+ private final DappMemberDao dappMemberDao;
@GetMapping(value = "admin")
@RequiresPermissions("admin:view")
@@ -148,7 +156,87 @@
String value = symbolPrice.getValue() == null ? "0" : symbolPrice.getValue();
adminSystemFeeVo.setSymbolPrice(value);
}
+
+ DataDictionaryCustom directProfitDic = dataDictionaryCustomMapper.selectDicDataByTypeAndCode(
+ DataDictionaryEnum.DIRECT_PROFIT.getType(), DataDictionaryEnum.DIRECT_PROFIT.getCode());
+ if (ObjectUtil.isNotEmpty(directProfitDic)) {
+ String value = directProfitDic.getValue() == null ? "0" : directProfitDic.getValue();
+ adminSystemFeeVo.setDirectProfit(value);
+ }
model.addAttribute("systemFee", adminSystemFeeVo);
return FebsUtil.view("dapp/system-fee-set");
}
+
+ /**
+ * 动能列表
+ * @return
+ */
+ @GetMapping(value = "systemProfit")
+ @RequiresPermissions("systemProfit:view")
+ public String systemProfit() {
+ return FebsUtil.view("dapp/system-profit");
+ }
+
+
+ public static long systemProfitId;
+ /**
+ * 动能列表-流水详情
+ * @param id
+ * @param model
+ * @return
+ */
+ @GetMapping("/systemProfitFlow/{id}")
+ @RequiresPermissions("systemProfitFlow:view")
+ public String systemProfitFlow(@PathVariable long id, Model model) {
+ systemProfitId = id;
+ return FebsUtil.view("dapp/system-profit-flow");
+ }
+
+ public static long teamInfoMemberId;
+ /**
+ * 用户列表-团队详情
+ * @param id
+ * @param model
+ * @return
+ */
+ @GetMapping("/teamInfo/{id}")
+ @RequiresPermissions("teamInfo:view")
+ public String teamInfo(@PathVariable long id, Model model) {
+ teamInfoMemberId = id;
+ return FebsUtil.view("dapp/member-teamInfo");
+ }
+
+
+
+ public static long memberNodeInfoMemberId;
+ /**
+ * 用户列表-购买记录
+ * @param id
+ * @param model
+ * @return
+ */
+ @GetMapping("/memberNodeInfo/{id}")
+ @RequiresPermissions("memberNodeInfo:view")
+ public String memberNodeInfo(@PathVariable long id, Model model) {
+ memberNodeInfoMemberId = id;
+ return FebsUtil.view("dapp/member-node-Info");
+ }
+
+
+ /**
+ * 代理级别-设置代理
+ * @param id
+ * @param model
+ * @return
+ */
+ @GetMapping("agentLevel/{id}")
+ @RequiresPermissions("agentLevel:view")
+ public String agentLevelSet(@PathVariable long id, Model model) {
+ DappMemberEntity dappMemberEntity = dappMemberDao.selectById(id);
+ AdminAgentLevelSetInfoVo data = new AdminAgentLevelSetInfoVo();
+ data.setId(id);
+ data.setLevelCode(dappMemberEntity.getAccountType());
+ model.addAttribute("agentLevelSet", data);
+ return FebsUtil.view("dapp/member-agent-level");
+ }
}
--
Gitblit v1.9.1