9 files modified
1 files added
| | |
| | | @Override |
| | | public IPage<MemberDataInfoVo> findAllDataInfoListInPage(MemberEntity memberEntity, QueryRequest request) { |
| | | String account = memberEntity.getAccount(); |
| | | String isTest = memberEntity.getIsTest(); |
| | | // String isTest = memberEntity.getIsTest(); |
| | | //如果account为空,查询全部,account不为空查询对应的memberEntity |
| | | if(StrUtil.isNotEmpty(account)) { |
| | | memberEntity = memberMapper.selectMemberByAccount(account); |
| | | }else { |
| | | memberEntity = memberMapper.selectMemberByAccount(MemberEntity.SYSTEM_REFERER); |
| | | } |
| | | memberEntity.setIsTest(isTest); |
| | | // memberEntity.setIsTest(""); |
| | | Page<MemberEntity> page = new Page<>(request.getPageNum(), request.getPageSize()); |
| | | IPage<MemberDataInfoVo> selectMemberListInPage = memberMapper.findMemberDataInfoOneAllRealInPage(page, memberEntity); |
| | | //USDT充币总额+USDT提币总额 |
| | |
| | | return otcService.updateOrderInfo(otcOrderEntity); |
| | | } |
| | | |
| | | /** |
| | | *回款 |
| | | * @return |
| | | */ |
| | | @PostMapping("otcHuiKuan") |
| | | @ControllerEndpoint(operation = "订单列表---付款人", exceptionMessage = "失败") |
| | | public FebsResponse otcHuiKuan(@Valid OtcMarketBussinessEntity otcMarketBussinessEntity) { |
| | | return otcService.otcHuiKuan(otcMarketBussinessEntity); |
| | | } |
| | | |
| | | } |
| | |
| | | import com.xcong.excoin.common.entity.FebsConstant; |
| | | import com.xcong.excoin.common.utils.FebsUtil; |
| | | import com.xcong.excoin.modules.member.vo.MemberAuthenticationVo; |
| | | import com.xcong.excoin.modules.otc.entity.OtcMarketBussinessEntity; |
| | | import com.xcong.excoin.modules.otc.entity.OtcOrderEntity; |
| | | import com.xcong.excoin.modules.otc.service.OtcService; |
| | | import com.xcong.excoin.modules.otc.vo.OtcAppealInfoVo; |
| | |
| | | return FebsUtil.view("modules/otc/otcAppealInfo"); |
| | | } |
| | | |
| | | /** |
| | | * 商户回款 |
| | | */ |
| | | @GetMapping("otcHuiKuan/{id}") |
| | | @RequiresPermissions("otcHuiKuan:update") |
| | | public String otcHuiKuan(@PathVariable long id, Model model) { |
| | | OtcMarketBussinessEntity data = otcService.otcHuiKuan(id); |
| | | model.addAttribute("member", data); |
| | | return FebsUtil.view("modules/otc/otcHuiKuan"); |
| | | } |
| | | |
| | | } |
| | |
| | | //完成率 |
| | | private BigDecimal finishRatio; |
| | | |
| | | //待回款 |
| | | private BigDecimal waitBackMoney; |
| | | |
| | | //已回款 |
| | | private BigDecimal hasBackMoney; |
| | | |
| | | //平均付款时间 |
| | | private Integer avgPayTime; |
| | | |
| | |
| | | |
| | | @TableField(exist = false) |
| | | private String realName; |
| | | /** |
| | | * 本次回款 |
| | | */ |
| | | @TableField(exist = false) |
| | | private BigDecimal coinAmount; |
| | | |
| | | |
| | | } |
| | |
| | | OtcOrderEntity otcOrderInfo(long id); |
| | | |
| | | FebsResponse updateOrderInfo(OtcOrderEntity otcOrderEntity); |
| | | |
| | | OtcMarketBussinessEntity otcHuiKuan(long id); |
| | | |
| | | FebsResponse otcHuiKuan(OtcMarketBussinessEntity otcMarketBussinessEntity); |
| | | } |
| | |
| | | return new FebsResponse().success(); |
| | | } |
| | | |
| | | @Override |
| | | public OtcMarketBussinessEntity otcHuiKuan(long id) { |
| | | return otcMarketBussinessMapper.selectById(id); |
| | | } |
| | | |
| | | @Override |
| | | @Transactional |
| | | public FebsResponse otcHuiKuan(OtcMarketBussinessEntity otcMarketBussinessEntity) { |
| | | Long id = otcMarketBussinessEntity.getId(); |
| | | OtcMarketBussinessEntity otcMarketBussiness = otcMarketBussinessMapper.selectById(id); |
| | | if(ObjectUtil.isNotEmpty(otcMarketBussiness)){ |
| | | return new FebsResponse().fail().message("连接超时,请刷新页面重试"); |
| | | } |
| | | BigDecimal coinAmount = otcMarketBussinessEntity.getCoinAmount(); |
| | | if(coinAmount.compareTo(BigDecimal.ZERO) <= 0){ |
| | | return new FebsResponse().fail().message("请输入正确的回款金额"); |
| | | } |
| | | BigDecimal waitBackMoney = otcMarketBussiness.getWaitBackMoney(); |
| | | if(coinAmount.compareTo(waitBackMoney) > 0){ |
| | | return new FebsResponse().fail().message("请输入正确的回款金额"); |
| | | } |
| | | /** |
| | | * 增加已回款金额 |
| | | * 减少待回款金额 |
| | | * 增加汇款记录 |
| | | */ |
| | | BigDecimal hasBackMoney = otcMarketBussiness.getHasBackMoney(); |
| | | BigDecimal add = hasBackMoney.add(coinAmount); |
| | | otcMarketBussiness.setHasBackMoney(add); |
| | | |
| | | BigDecimal subtract = waitBackMoney.subtract(coinAmount); |
| | | otcMarketBussiness.setWaitBackMoney(subtract); |
| | | otcMarketBussinessMapper.updateById(otcMarketBussiness); |
| | | |
| | | return new FebsResponse().success(); |
| | | } |
| | | |
| | | } |
| | |
| | | <input type="text" placeholder="手机号/邮箱/邀请码" name="account" autocomplete="off" class="layui-input"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <!--<div class="layui-inline"> |
| | | <label class="layui-form-label layui-form-label-sm">账号类型</label> |
| | | <div class="layui-input-inline"> |
| | | <select name="isTest"> |
| | |
| | | <option value="2">测试账号</option> |
| | | </select> |
| | | </div> |
| | | </div> |
| | | </div>--> |
| | | </div> |
| | | </div> |
| | | <div class="layui-col-md2 layui-col-sm12 layui-col-xs12 table-action-area"> |
| | |
| | | totalRow: true, |
| | | cols: [[ |
| | | {field: 'memberCount', title: '注册用户数', minWidth: 120,align:'center'}, |
| | | {field: 'notNullNumber', title: '持仓用户数', minWidth: 120,align:'center'}, |
| | | // {field: 'notNullNumber', title: '持仓用户数', minWidth: 120,align:'center'}, |
| | | {field: 'walletNumber', title: '币币账户有余额个数', minWidth: 200,align:'center'}, |
| | | {field: 'walletNum', title: '币币账户余额', minWidth: 200,align:'center'}, |
| | | {field: 'walletCoinNumber', title: '合约账户有余额个数', minWidth: 200,align:'center'}, |
| | | {field: 'walletCoinNum', title: '合约账户余额', minWidth: 200,align:'center'}, |
| | | {field: 'agentNum', title: '代理账户余额', minWidth: 200,align:'center'}, |
| | | // {field: 'walletCoinNumber', title: '合约账户有余额个数', minWidth: 200,align:'center'}, |
| | | // {field: 'walletCoinNum', title: '合约账户余额', minWidth: 200,align:'center'}, |
| | | // {field: 'agentNum', title: '代理账户余额', minWidth: 200,align:'center'}, |
| | | {field: 'allCoin', title: '平台总资产', minWidth: 200,align:'center'}, |
| | | {field: 'platformProfitAndLoss', title: '平台剩余USDT', |
| | | templet: function (d) { |
| | |
| | | }, minWidth: 200,align:'center'}, |
| | | {field: 'chargeCoin', title: '充币', minWidth: 200,align:'center'}, |
| | | {field: 'appealCoin', title: '提币', minWidth: 200,align:'center'}, |
| | | {field: 'fee', title: '佣金', minWidth: 200,align:'center'}, |
| | | {field: 'closingPrice', title: '开仓手续费', minWidth: 200,align:'center'}, |
| | | {field: 'sellClosingPrice', title: '平仓手续费', minWidth: 200,align:'center'}, |
| | | {field: 'doingPrice', title: '持仓手续费', minWidth: 200,align:'center'}, |
| | | {field: 'yingkui', title: '订单盈亏', |
| | | templet: function (d) { |
| | | if (d.yingkui > '0') { |
| | | return '<span style="color:green;">'+d.yingkui+'</span>' |
| | | } else { |
| | | return '<span style="color:red;">'+d.yingkui+'</span>' |
| | | } |
| | | }, minWidth: 200,align:'center'}, |
| | | // {field: 'fee', title: '佣金', minWidth: 200,align:'center'}, |
| | | // {field: 'closingPrice', title: '开仓手续费', minWidth: 200,align:'center'}, |
| | | // {field: 'sellClosingPrice', title: '平仓手续费', minWidth: 200,align:'center'}, |
| | | // {field: 'doingPrice', title: '持仓手续费', minWidth: 200,align:'center'}, |
| | | // {field: 'yingkui', title: '订单盈亏', |
| | | // templet: function (d) { |
| | | // if (d.yingkui > '0') { |
| | | // return '<span style="color:green;">'+d.yingkui+'</span>' |
| | | // } else { |
| | | // return '<span style="color:red;">'+d.yingkui+'</span>' |
| | | // } |
| | | // }, minWidth: 200,align:'center'}, |
| | | {field: 'chargeUsdt', title: 'usdt充值', minWidth: 200,align:'center'}, |
| | | {field: 'appealUsdt', title: 'usdt提现', minWidth: 200,align:'center'}, |
| | | ]] |
| | |
| | | function getQueryParams() { |
| | | return { |
| | | account: $searchForm.find('input[name="account"]').val().trim(), |
| | | isTest: $searchForm.find("select[name='isTest']").val(), |
| | | // isTest: $searchForm.find("select[name='isTest']").val(), |
| | | }; |
| | | } |
| | | |
New file |
| | |
| | | <style> |
| | | #user-update { |
| | | padding: 20px 25px 25px 0; |
| | | } |
| | | |
| | | #user-update .layui-treeSelect .ztree li a, .ztree li span { |
| | | margin: 0 0 2px 3px !important; |
| | | } |
| | | #user-update #data-permission-tree-block { |
| | | border: 1px solid #eee; |
| | | border-radius: 2px; |
| | | padding: 3px 0; |
| | | } |
| | | #user-add .layui-treeSelect .ztree li span.button.switch { |
| | | top: 1px; |
| | | left: 3px; |
| | | } |
| | | |
| | | </style> |
| | | <div class="layui-fluid" id="user-update"> |
| | | <form class="layui-form" action="" lay-filter="user-update-form"> |
| | | <div class="layui-form-item febs-hide"> |
| | | <label class="layui-form-label febs-form-item-require">id:</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" name="id" data-th-value="${member.id}"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label febs-form-item-require">待回款:</label> |
| | | <div class="layui-input-block"> |
| | | <input type="number" name="waitBackMoney"data-th-id="${member.waitBackMoney}" |
| | | autocomplete="off" class="layui-input" readonly> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label febs-form-item-require">已回款:</label> |
| | | <div class="layui-input-block"> |
| | | <input type="number" name="hasBackMoney"data-th-id="${member.hasBackMoney}" |
| | | autocomplete="off" class="layui-input" readonly> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label febs-form-item-require">交易数量:</label> |
| | | <div class="layui-input-block"> |
| | | <input type="number" name="coinAmount"data-th-id="${member.coinAmount}" |
| | | autocomplete="off" class="layui-input" readonly> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item febs-hide"> |
| | | <button class="layui-btn" lay-submit="" lay-filter="user-update-form-submit" id="submit"></button> |
| | | </div> |
| | | </form> |
| | | </div> |
| | | |
| | | <script data-th-inline="javascript"> |
| | | layui.use(['febs', 'form', 'formSelects', 'validate', 'treeSelect', 'eleTree'], function () { |
| | | var $ = layui.$, |
| | | febs = layui.febs, |
| | | layer = layui.layer, |
| | | formSelects = layui.formSelects, |
| | | treeSelect = layui.treeSelect, |
| | | form = layui.form, |
| | | eleTree = layui.eleTree, |
| | | member = [[${member}]], |
| | | $view = $('#user-update'), |
| | | validate = layui.validate, |
| | | _deptTree; |
| | | |
| | | form.render(); |
| | | |
| | | initUserValue(); |
| | | |
| | | formSelects.render(); |
| | | |
| | | function initUserValue() { |
| | | form.val("user-update-form", { |
| | | "id": member.id, |
| | | "waitBackMoney": member.waitBackMoney, |
| | | "hasBackMoney": member.hasBackMoney, |
| | | "coinAmount": member.coinAmount |
| | | }); |
| | | } |
| | | |
| | | form.on('submit(user-update-form-submit)', function (data) { |
| | | febs.post(ctx + 'otc/otcHuiKuan', data.field, function () { |
| | | layer.closeAll(); |
| | | febs.alert.success('成功'); |
| | | $('#febs-user-shop').find('#reset').click(); |
| | | }); |
| | | return false; |
| | | }); |
| | | }); |
| | | </script> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label layui-form-label-sm">类型</label> |
| | | <label class="layui-form-label layui-form-label-sm">订单状态</label> |
| | | <div class="layui-input-inline"> |
| | | <select name="status"> |
| | | <option value="">请选择</option> |
| | |
| | | {field: 'payTime', title: '付款时间',minWidth: 150,align:'center'}, |
| | | {field: 'finishTime', title: '完成时间',minWidth: 150,align:'center'}, |
| | | {title: '操作',templet: function (d) { |
| | | //return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="dealIng" shiro:hasPermission="user:update">付款</button>' |
| | | // return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="dealIng" shiro:hasPermission="user:update">付款</button>' |
| | | if(d.status === 1){ |
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="dealIng" shiro:hasPermission="user:update">付款</button>' |
| | | }else{ |
| | |
| | | <div class="layui-fluid layui-anim febs-anim" id="febs-user" lay-title="OTC商户"> |
| | | <div class="layui-fluid layui-anim febs-anim" id="febs-user-shop" lay-title="OTC商户"> |
| | | <div class="layui-row febs-container"> |
| | | <div class="layui-col-md12"> |
| | | <div class="layui-card"> |
| | |
| | | febs = layui.febs, |
| | | form = layui.form, |
| | | table = layui.table, |
| | | $view = $('#febs-user'), |
| | | $view = $('#febs-user-shop'), |
| | | $query = $view.find('#query'), |
| | | $reset = $view.find('#reset'), |
| | | $searchForm = $view.find('form'), |
| | |
| | | if (layEvent === 'disagreeShop') { |
| | | febs.modal.confirm('拒绝', '确认拒绝该商户的审核?', function () { |
| | | disagreeShop(data.id); |
| | | }); |
| | | } |
| | | if (layEvent === 'huikuan') { |
| | | febs.modal.open('回款', 'modules/otc/huikuan/' + data.id, { |
| | | btn: ['提交', '取消'], |
| | | yes: function (index, layero) { |
| | | $('#user-update').find('#submit').trigger('click'); |
| | | }, |
| | | btn2: function () { |
| | | layer.closeAll(); |
| | | } |
| | | }); |
| | | } |
| | | }); |
| | |
| | | {field: 'realName', title: '姓名', minWidth: 100,align:'left'}, |
| | | {field: 'inviteId', title: '邀请码', minWidth: 80,align:'center'}, |
| | | {field: 'nikename', title: '昵称', minWidth: 80,align:'center'}, |
| | | {field: 'status', title: '审核状态', |
| | | templet: function (d) { |
| | | if (d.status === 1) { |
| | | return '<span style="color:blue;">待审核</span>' |
| | | } else if (d.status === 2) { |
| | | return '<span style="color:green;">审核通过</span>' |
| | | } else if (d.status === 3) { |
| | | return '<span>拒绝</span>' |
| | | }else{ |
| | | return '' |
| | | } |
| | | }, minWidth: 80,align:'center'}, |
| | | // {field: 'status', title: '审核状态', |
| | | // templet: function (d) { |
| | | // if (d.status === 1) { |
| | | // return '<span style="color:blue;">待审核</span>' |
| | | // } else if (d.status === 2) { |
| | | // return '<span style="color:green;">审核通过</span>' |
| | | // } else if (d.status === 3) { |
| | | // return '<span>拒绝</span>' |
| | | // }else{ |
| | | // return '' |
| | | // } |
| | | // }, minWidth: 80,align:'center'}, |
| | | // {field: 'waitBackMoney', title: '待回款',minWidth: 100,align:'center'}, |
| | | // {field: 'hasBackMoney', title: '已回款',minWidth: 100,align:'center'}, |
| | | {field: 'buyCnt', title: '服务人数',minWidth: 100,align:'center'}, |
| | | {field: 'totalOrderCnt', title: '总单数',minWidth: 100,align:'center'}, |
| | | {field: 'finishRatio', title: '完成率',minWidth: 100,align:'center'}, |
| | | {field: 'avgPayTime', title: '平均付款时间',minWidth: 100,align:'center'}, |
| | | {field: 'avgCoinTime', title: '平均放币时间',minWidth: 100,align:'center'}, |
| | | {field: 'createTime', title: '注册时间', minWidth: 180,align:'center'}, |
| | | {title: '操作',templet: function (d) { |
| | | if(d.status === 1){ |
| | | return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="agreeShop" shiro:hasPermission="user:update">同意</button>' |
| | | +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="disagreeShop" shiro:hasPermission="user:update">拒绝</button>' |
| | | }else{ |
| | | return '' |
| | | } |
| | | },minWidth: 200,align:'center'} |
| | | // {title: '操作',templet: function (d) { |
| | | // return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="huikuan" shiro:hasPermission="user:update">回款</button>' |
| | | // // if(d.status === 1){ |
| | | // // return '<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="agreeShop" shiro:hasPermission="user:update">同意</button>' |
| | | // // +'<button class="layui-btn layui-btn-normal layui-btn-xs" lay-event="disagreeShop" shiro:hasPermission="user:update">拒绝</button>' |
| | | // // }else{ |
| | | // // return '' |
| | | // // } |
| | | // },minWidth: 200,align:'center'} |
| | | ]] |
| | | }); |
| | | } |