mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-05-07 03:20:06 +08:00
运营商VIP
This commit is contained in:
@@ -26,6 +26,7 @@ import com.jsowell.pile.vo.base.LoginUserDetailVO;
|
||||
import com.jsowell.pile.vo.base.MerchantInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberWalletLogVO;
|
||||
import com.jsowell.pile.vo.uniapp.MerchantVipVO;
|
||||
import com.jsowell.pile.vo.web.MemberTransactionVO;
|
||||
import com.jsowell.pile.vo.web.PlatformTesterVO;
|
||||
import com.jsowell.pile.vo.web.UpdateMemberBalanceDTO;
|
||||
@@ -67,6 +68,15 @@ public class MemberBasicInfoController extends BaseController {
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询运营商VIP列表
|
||||
*/
|
||||
@PostMapping("/queryMerchantVipList")
|
||||
public TableDataInfo queryMerchantVipList(@RequestBody QueryMemberInfoDTO dto) {
|
||||
List<MerchantVipVO> list = memberBasicInfoService.queryMerchantVipList(dto);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前会员表中存在的运营商列表
|
||||
* http://localhost:8080/member/info/getMerchantListByAuth
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.jsowell.pile.domain.MemberBasicInfo;
|
||||
import com.jsowell.pile.dto.QueryMemberInfoDTO;
|
||||
import com.jsowell.pile.vo.base.MerchantInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberVO;
|
||||
import com.jsowell.pile.vo.uniapp.MerchantVipVO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
@@ -118,4 +119,5 @@ public interface MemberBasicInfoMapper {
|
||||
*/
|
||||
List<MerchantInfoVO> getMerchantListByAuth(@Param("deptIds") List<String> deptIds);
|
||||
|
||||
List<MerchantVipVO> queryMerchantVipList(@Param("merchantIdList") List<String> merchantIdList);
|
||||
}
|
||||
|
||||
@@ -4,10 +4,7 @@ import com.jsowell.pile.domain.MemberBasicInfo;
|
||||
import com.jsowell.pile.dto.PlatformTesterDTO;
|
||||
import com.jsowell.pile.dto.QueryMemberInfoDTO;
|
||||
import com.jsowell.pile.dto.UniAppQueryMemberBalanceDTO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberBalanceVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberWalletLogVO;
|
||||
import com.jsowell.pile.vo.uniapp.PersonalPileInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.*;
|
||||
import com.jsowell.pile.vo.web.PlatformTesterVO;
|
||||
import com.jsowell.pile.vo.web.UpdateMemberBalanceDTO;
|
||||
|
||||
@@ -148,4 +145,6 @@ public interface IMemberBasicInfoService {
|
||||
* @return
|
||||
*/
|
||||
List<MemberBalanceVO> getMemberRefundAmount(List<String> memberIds);
|
||||
|
||||
List<MerchantVipVO> queryMerchantVipList(QueryMemberInfoDTO dto);
|
||||
}
|
||||
|
||||
@@ -27,10 +27,7 @@ import com.jsowell.pile.service.*;
|
||||
import com.jsowell.pile.util.UserUtils;
|
||||
import com.jsowell.pile.vo.base.LoginUserDetailVO;
|
||||
import com.jsowell.pile.vo.base.MerchantInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberBalanceVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberVO;
|
||||
import com.jsowell.pile.vo.uniapp.MemberWalletLogVO;
|
||||
import com.jsowell.pile.vo.uniapp.PersonalPileInfoVO;
|
||||
import com.jsowell.pile.vo.uniapp.*;
|
||||
import com.jsowell.pile.vo.web.PlatformTesterVO;
|
||||
import com.jsowell.pile.vo.web.UpdateMemberBalanceDTO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@@ -481,4 +478,16 @@ public class MemberBasicInfoServiceImpl implements IMemberBasicInfoService {
|
||||
return memberWalletLogMapper.getMemberRefundAmount(memberIds);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<MerchantVipVO> queryMerchantVipList(QueryMemberInfoDTO dto) {
|
||||
// 获取后管登录用户的权限
|
||||
LoginUserDetailVO loginUserDetail = UserUtils.getLoginUserDetail();
|
||||
List<MerchantInfoVO> merchantInfoVOList = loginUserDetail.getMerchantInfoVOList();
|
||||
List<String> merchantIdList = merchantInfoVOList.stream()
|
||||
.map(MerchantInfoVO::getMerchantId).collect(Collectors.toList());
|
||||
List<MerchantVipVO> resultList = memberBasicInfoMapper.queryMerchantVipList(merchantIdList);
|
||||
|
||||
return resultList;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@ public class LoginUserDetailVO {
|
||||
private List<String> firstMerchantIdList;
|
||||
|
||||
/**
|
||||
* 获取当前会员中的运营商列表
|
||||
* 获取当前登录用户中有权限的运营商列表
|
||||
*/
|
||||
private List<MerchantInfoVO> merchantInfoVOList;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
package com.jsowell.pile.vo.uniapp;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 运营商Vip VO
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Builder
|
||||
public class MerchantVipVO {
|
||||
/**
|
||||
* 会员Id
|
||||
*/
|
||||
private String memberId;
|
||||
|
||||
private String merchantId;
|
||||
|
||||
/**
|
||||
* 运营商名称
|
||||
*/
|
||||
private String merchantName;
|
||||
|
||||
/**
|
||||
* 状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 昵称
|
||||
*/
|
||||
private String nickName;
|
||||
|
||||
/**
|
||||
* 手机号码
|
||||
*/
|
||||
private String mobileNumber;
|
||||
|
||||
/**
|
||||
* 钱包编号,前端也可以显示为卡号
|
||||
*/
|
||||
private String walletCode;
|
||||
|
||||
/**
|
||||
* 本金金额
|
||||
*/
|
||||
private BigDecimal principalBalance;
|
||||
|
||||
/**
|
||||
* 赠送金额
|
||||
*/
|
||||
private BigDecimal giftBalance;
|
||||
|
||||
/**
|
||||
* 总账户余额
|
||||
*/
|
||||
private BigDecimal totalAccountAmount;
|
||||
|
||||
/**
|
||||
* 车牌号
|
||||
*/
|
||||
private List<String> plateNumberList;
|
||||
|
||||
/**
|
||||
* VIN码
|
||||
*/
|
||||
private List<String> vinCodeList;
|
||||
|
||||
/**
|
||||
* 头像地址
|
||||
*/
|
||||
private String avatarUrl;
|
||||
}
|
||||
@@ -253,4 +253,24 @@
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="queryMerchantVipList" resultType="com.jsowell.pile.vo.uniapp.MerchantVipVO">
|
||||
select
|
||||
t1.member_id as memberId,
|
||||
t1.merchant_id as merchantId,
|
||||
t3.merchant_name as merchantName,
|
||||
t2.mobile_number as mobileNumber,
|
||||
t2.nick_name as nickName,
|
||||
t2.avatar_url as avatarUrl,
|
||||
t1.wallet_code as walletCode,
|
||||
t1.principal_balance as principalBalance
|
||||
from member_wallet_info t1
|
||||
JOIN member_basic_info t2 on t2.member_id = t1.member_id and t2.del_flag = '0'
|
||||
JOIN pile_merchant_info t3 ON t1.merchant_id = t3.id and t3.del_flag = '0'
|
||||
where t1.del_flag = '0'
|
||||
AND t1.merchant_id in
|
||||
<foreach collection="merchantIdList" item="merchantId" open="(" separator="," close=")">
|
||||
#{merchantId,jdbcType=VARCHAR}
|
||||
</foreach>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -9,6 +9,15 @@ export function listInfo(data) {
|
||||
})
|
||||
}
|
||||
|
||||
// 查询运营商VIP列表
|
||||
export function queryMerchantVipList(data) {
|
||||
return request({
|
||||
url: '/member/info/queryMerchantVipList',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 查询会员基础信息详细
|
||||
export function getInfo(id) {
|
||||
return request({
|
||||
|
||||
@@ -75,6 +75,7 @@
|
||||
|
||||
<el-table v-loading="loading" :data="infoList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center"/>
|
||||
<el-table-column label="运营商" align="center" prop="merchantName"/>
|
||||
<!--<el-table-column label="" align="center" prop="id" />-->
|
||||
<!-- <el-table-column label="运营商" align="center" prop="merchantName"/>-->
|
||||
<el-table-column label="会员id" align="center" prop="memberId"/>
|
||||
@@ -88,14 +89,15 @@
|
||||
</router-link>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="状态" align="center" prop="status">
|
||||
<!-- <el-table-column label="状态" align="center" prop="status">
|
||||
<template slot-scope="scope">
|
||||
<dict-tag
|
||||
:options="dict.type.member_status"
|
||||
:value="scope.row.status"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table-column>-->
|
||||
|
||||
<el-table-column label="头像" align="center" prop="avatarUrl">
|
||||
<template slot-scope="scope">
|
||||
<!-- <el-image v-if="scope.row.avatarUrl === null" :src="defaultImg" />-->
|
||||
@@ -104,6 +106,7 @@
|
||||
:preview-src-list='[scope.row.avatarUrl === null? defaultImg[0].img :scope.row.avatarUrl]'/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="余额" align="center" prop="principalBalance"/>
|
||||
<el-table-column label="手机号" align="center" prop="mobileNumber"/>
|
||||
<!-- <el-table-column label="本金余额" align="center" prop="principalBalance"/>-->
|
||||
<!-- <el-table-column label="赠送余额" align="center" prop="giftBalance" />-->
|
||||
@@ -214,7 +217,7 @@ import {
|
||||
addInfo,
|
||||
updateInfo,
|
||||
updateMemberBalance,
|
||||
getMerchantList,
|
||||
getMerchantList, queryMerchantVipList,
|
||||
} from "@/api/member/info";
|
||||
|
||||
export default {
|
||||
@@ -277,7 +280,7 @@ export default {
|
||||
created() {
|
||||
this.getList();
|
||||
|
||||
this.getMerchantList();
|
||||
// this.getMerchantList();
|
||||
},
|
||||
methods: {
|
||||
/** 查询会员基础信息列表 */
|
||||
@@ -287,13 +290,10 @@ export default {
|
||||
pageNum: this.queryParams.pageNum,
|
||||
pageSize: this.queryParams.pageSize,
|
||||
memberId: this.queryParams.memberId,
|
||||
nickName: this.queryParams.nickName,
|
||||
mobileNumber: this.queryParams.mobileNumber,
|
||||
merchantId: this.queryParams.merchantId,
|
||||
vinCode: this.queryParams.vinCode,
|
||||
}
|
||||
console.log("params", params)
|
||||
listInfo(params).then(response => {
|
||||
queryMerchantVipList(params).then(response => {
|
||||
this.infoList = response.rows;
|
||||
console.log(this.infoList);
|
||||
this.total = response.total;
|
||||
|
||||
Reference in New Issue
Block a user