mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 02:55:04 +08:00
后管运营商vip会员页面新增导出功能
This commit is contained in:
@@ -7,6 +7,7 @@ import com.jsowell.common.annotation.Log;
|
|||||||
import com.jsowell.common.constant.Constants;
|
import com.jsowell.common.constant.Constants;
|
||||||
import com.jsowell.common.core.controller.BaseController;
|
import com.jsowell.common.core.controller.BaseController;
|
||||||
import com.jsowell.common.core.domain.AjaxResult;
|
import com.jsowell.common.core.domain.AjaxResult;
|
||||||
|
import com.jsowell.common.core.domain.vo.AuthorizedDeptVO;
|
||||||
import com.jsowell.common.core.page.TableDataInfo;
|
import com.jsowell.common.core.page.TableDataInfo;
|
||||||
import com.jsowell.common.enums.BusinessType;
|
import com.jsowell.common.enums.BusinessType;
|
||||||
import com.jsowell.common.enums.uniapp.BalanceChangesEnum;
|
import com.jsowell.common.enums.uniapp.BalanceChangesEnum;
|
||||||
@@ -14,12 +15,11 @@ import com.jsowell.common.enums.ykc.ReturnCodeEnum;
|
|||||||
import com.jsowell.common.exception.BusinessException;
|
import com.jsowell.common.exception.BusinessException;
|
||||||
import com.jsowell.common.response.RestApiResponse;
|
import com.jsowell.common.response.RestApiResponse;
|
||||||
import com.jsowell.common.util.StringUtils;
|
import com.jsowell.common.util.StringUtils;
|
||||||
|
import com.jsowell.common.util.poi.ExcelUtil;
|
||||||
import com.jsowell.pile.domain.MemberBasicInfo;
|
import com.jsowell.pile.domain.MemberBasicInfo;
|
||||||
import com.jsowell.pile.domain.MemberPlateNumberRelation;
|
import com.jsowell.pile.domain.MemberPlateNumberRelation;
|
||||||
import com.jsowell.pile.dto.CreateMerchantVipDTO;
|
import com.jsowell.pile.domain.PileMerchantInfo;
|
||||||
import com.jsowell.pile.dto.PlatformTesterDTO;
|
import com.jsowell.pile.dto.*;
|
||||||
import com.jsowell.pile.dto.QueryMemberInfoDTO;
|
|
||||||
import com.jsowell.pile.dto.UniAppQueryMemberBalanceDTO;
|
|
||||||
import com.jsowell.pile.service.MemberBasicInfoService;
|
import com.jsowell.pile.service.MemberBasicInfoService;
|
||||||
import com.jsowell.pile.service.MemberPlateNumberRelationService;
|
import com.jsowell.pile.service.MemberPlateNumberRelationService;
|
||||||
import com.jsowell.pile.service.MemberTransactionRecordService;
|
import com.jsowell.pile.service.MemberTransactionRecordService;
|
||||||
@@ -29,6 +29,7 @@ import com.jsowell.pile.vo.uniapp.customer.MemberVO;
|
|||||||
import com.jsowell.pile.vo.uniapp.customer.MemberWalletLogVO;
|
import com.jsowell.pile.vo.uniapp.customer.MemberWalletLogVO;
|
||||||
import com.jsowell.pile.vo.uniapp.customer.MerchantVipVO;
|
import com.jsowell.pile.vo.uniapp.customer.MerchantVipVO;
|
||||||
import com.jsowell.pile.vo.web.MemberTransactionVO;
|
import com.jsowell.pile.vo.web.MemberTransactionVO;
|
||||||
|
import com.jsowell.pile.vo.web.OrderListVO;
|
||||||
import com.jsowell.pile.vo.web.PlatformTesterVO;
|
import com.jsowell.pile.vo.web.PlatformTesterVO;
|
||||||
import com.jsowell.pile.vo.web.UpdateMemberBalanceDTO;
|
import com.jsowell.pile.vo.web.UpdateMemberBalanceDTO;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
@@ -36,6 +37,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@@ -262,6 +264,24 @@ public class MemberBasicInfoController extends BaseController {
|
|||||||
return toAjax(i);
|
return toAjax(i);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出会员钱包列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('member:info:export')")
|
||||||
|
@Log(title = "钱包数据", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/exportWalletList")
|
||||||
|
public void exportWalletList(HttpServletResponse response, UniAppQueryMemberBalanceDTO dto) {
|
||||||
|
// 权限过滤
|
||||||
|
AuthorizedDeptVO authorizedMap = UserUtils.getAuthorizedMap();
|
||||||
|
if (authorizedMap == null) {
|
||||||
|
// 为空表示没有权限,返回空数组
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
List<MemberWalletLogVO> list = memberBasicInfoService.getMemberWalletDetail(dto);
|
||||||
|
ExcelUtil<MemberWalletLogVO> util = new ExcelUtil<MemberWalletLogVO>(MemberWalletLogVO.class);
|
||||||
|
util.exportExcel(response, list, "会员钱包数据");
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 修改平台测试员状态
|
* 修改平台测试员状态
|
||||||
* http://localhost:8080/member/info/updatePlatformTester
|
* http://localhost:8080/member/info/updatePlatformTester
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ public class UniAppQueryMemberBalanceDTO extends BaseMemberDTO{
|
|||||||
*/
|
*/
|
||||||
private String walletCode;
|
private String walletCode;
|
||||||
|
|
||||||
|
private String memberId;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return new ToStringBuilder(this, ToStringStyle.JSON_STYLE)
|
return new ToStringBuilder(this, ToStringStyle.JSON_STYLE)
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package com.jsowell.pile.vo.uniapp.customer;
|
package com.jsowell.pile.vo.uniapp.customer;
|
||||||
|
|
||||||
|
import com.jsowell.common.annotation.Excel;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Builder;
|
import lombok.Builder;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
@@ -18,6 +19,7 @@ public class MemberWalletLogVO {
|
|||||||
/**
|
/**
|
||||||
* 会员id
|
* 会员id
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "会员id")
|
||||||
private String memberId;
|
private String memberId;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -28,6 +30,7 @@ public class MemberWalletLogVO {
|
|||||||
/**
|
/**
|
||||||
* 子类型 10-充值, 11-赠送, 12-订单结算退款,20-后管扣款, 21-订单付款, 22-用户退款
|
* 子类型 10-充值, 11-赠送, 12-订单结算退款,20-后管扣款, 21-订单付款, 22-用户退款
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "操作类型(10-充值, 11-赠送, 12-订单结算退款,20-后管扣款, 21-订单付款, 22-用户退款)")
|
||||||
private String subType;
|
private String subType;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -38,6 +41,7 @@ public class MemberWalletLogVO {
|
|||||||
/**
|
/**
|
||||||
* 交易时间
|
* 交易时间
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "交易时间")
|
||||||
private String transactionTime;
|
private String transactionTime;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -53,16 +57,19 @@ public class MemberWalletLogVO {
|
|||||||
/**
|
/**
|
||||||
* 支付金额
|
* 支付金额
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "支付金额")
|
||||||
private BigDecimal payAmount;
|
private BigDecimal payAmount;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 订单金额
|
* 订单金额
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "订单金额")
|
||||||
private BigDecimal orderAmount;
|
private BigDecimal orderAmount;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 退款金额
|
* 退款金额
|
||||||
*/
|
*/
|
||||||
|
@Excel(name = "退款金额")
|
||||||
private BigDecimal refundAmount;
|
private BigDecimal refundAmount;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -490,11 +490,23 @@
|
|||||||
t1.create_time as transactionTime
|
t1.create_time as transactionTime
|
||||||
from member_wallet_log t1
|
from member_wallet_log t1
|
||||||
left join order_basic_info t2 on t1.related_order_code = t2.order_code
|
left join order_basic_info t2 on t1.related_order_code = t2.order_code
|
||||||
where t1.member_id = #{dto.memberId,jdbcType=VARCHAR}
|
where t1.sub_type != '12'
|
||||||
|
<if test="dto.memberId != null and dto.memberId != ''">
|
||||||
|
and t1.member_id = #{dto.memberId,jdbcType=VARCHAR}
|
||||||
|
</if>
|
||||||
|
<if test="dto.walletCode != null and dto.walletCode != ''">
|
||||||
and t1.wallet_code = #{dto.walletCode,jdbcType=VARCHAR}
|
and t1.wallet_code = #{dto.walletCode,jdbcType=VARCHAR}
|
||||||
|
</if>
|
||||||
|
<if test="dto.tradeDate != null and dto.tradeDate != ''">
|
||||||
and t1.create_time <![CDATA[ >= ]]> #{dto.tradeDate,jdbcType=VARCHAR}
|
and t1.create_time <![CDATA[ >= ]]> #{dto.tradeDate,jdbcType=VARCHAR}
|
||||||
|
</if>
|
||||||
|
<if test="dto.endDate != null and dto.endDate != ''">
|
||||||
and t1.create_time <![CDATA[ < ]]> #{dto.endDate,jdbcType=VARCHAR}
|
and t1.create_time <![CDATA[ < ]]> #{dto.endDate,jdbcType=VARCHAR}
|
||||||
and t1.sub_type != '12'
|
</if>
|
||||||
|
<!-- where t1.member_id = #{dto.memberId,jdbcType=VARCHAR}-->
|
||||||
|
<!-- and t1.wallet_code = #{dto.walletCode,jdbcType=VARCHAR}-->
|
||||||
|
<!-- and t1.create_time <![CDATA[ >= ]]> #{dto.tradeDate,jdbcType=VARCHAR}-->
|
||||||
|
<!-- and t1.create_time <![CDATA[ < ]]> #{dto.endDate,jdbcType=VARCHAR}-->
|
||||||
order by t1.create_time desc
|
order by t1.create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|||||||
@@ -148,3 +148,12 @@ export function getMemberBalanceChangesV2(data) {
|
|||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 导出会员钱包明细
|
||||||
|
export function exportWalletList(data) {
|
||||||
|
return request({
|
||||||
|
url: '/member/info/exportWalletList',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|||||||
@@ -175,6 +175,12 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item style="margin-left: 10px;">
|
<el-form-item style="margin-left: 10px;">
|
||||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="getDetails">搜索</el-button>
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="getDetails">搜索</el-button>
|
||||||
|
<el-button
|
||||||
|
type="warning"
|
||||||
|
plain
|
||||||
|
icon="Download"
|
||||||
|
@click="handleExport"
|
||||||
|
>导出</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-col :span="24">
|
<el-col :span="24">
|
||||||
<el-form-item label="充值余额:"> {{ totalRechargeAmount }} </el-form-item>
|
<el-form-item label="充值余额:"> {{ totalRechargeAmount }} </el-form-item>
|
||||||
@@ -473,7 +479,7 @@ export default {
|
|||||||
},
|
},
|
||||||
/** 导出按钮操作 */
|
/** 导出按钮操作 */
|
||||||
handleExport() {
|
handleExport() {
|
||||||
this.download('member/info/export', {
|
this.download('member/info/exportWalletList', {
|
||||||
...this.queryParams
|
...this.queryParams
|
||||||
}, `info_${new Date().getTime()}.xlsx`)
|
}, `info_${new Date().getTime()}.xlsx`)
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user