Merge remote-tracking branch 'origin/main'

This commit is contained in:
sw 2024-11-13 08:33:29 +08:00
commit 4049003f3d
19 changed files with 256 additions and 103 deletions

View File

@ -21,6 +21,8 @@
.app-container{
width: 100%;
background: #f6f8f9;
box-sizing: border-box;
padding: 10px;
}
</style>

View File

@ -11,32 +11,12 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<!-- <el-form-item style="float: right">-->
<!-- <el-form-item label="" prop="bannerName">-->
<!-- <el-select v-model="queryParams.systemPosition" placeholder="请选择系统位置">-->
<!-- <el-option-->
<!-- v-for="item in systemPositionList"-->
<!-- :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value">-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- </el-form-item>-->
<el-form-item label="" prop="bannerName">
<el-select v-model="queryParams.bannerStatus" placeholder="请选择banner图状态">
<el-option label="停用" value="0"></el-option>
<el-option label="启用" value="1"></el-option>
<!-- <el-option-->
<!-- v-for="item in systemPositionList"-->
<!-- :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value">-->
<!-- </el-option>-->
</el-select>
</el-form-item>
<el-form-item style="float: right">
<el-button type="primary" icon="el-icon-search" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
@ -49,13 +29,7 @@
</el-button>
</el-form-item>
</el-form>
<!-- </el-card>-->
<!-- &lt;!&ndash; 列表信息&ndash;&gt;-->
<!-- <el-card style="margin-top: 20px" >-->
<div style="height: 70vh;overflow: auto">
<div style="height: 74vh;overflow: auto">
<el-table :data="tableData" style="width: 100%;" border>
<el-table-column type="index" label="序号"></el-table-column>
<el-table-column prop="bannerName" label="banner名称"></el-table-column>
@ -510,5 +484,10 @@ export default {
align-items: center;
height: 100%;
}
.app-container{
box-sizing: border-box;
padding: 10px ;
}
</style>

View File

@ -37,7 +37,7 @@
</el-form-item>
</el-form>
<div style="height: 70vh;overflow: auto">
<div style="height: 74vh;overflow: auto;scrollbar-width: none">
<el-table :data="tableData" border style="width: 100%">
<el-table-column type="index" label="序号"></el-table-column>
<el-table-column prop="messageId" label="短信模板ID"></el-table-column>
@ -390,5 +390,9 @@ export default {
width: 98px;
height: 98px;
}
.app-container{
box-sizing: border-box;
padding: 10px;
}
</style>

View File

@ -23,10 +23,7 @@
<el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
</el-form-item>
</el-form>
<!-- </el-card>-->
<!-- &lt;!&ndash; &ndash;&gt;-->
<!-- &lt;!&ndash; 列表信息&ndash;&gt;-->
<!-- <el-card style="margin-top: 20px" >-->
<div class="table-box">
<el-table :data="tableData" style="width: 100%" border>
<el-table-column align="center" type="index" label="序号"></el-table-column>
<el-table-column align="center" prop="notificationName" label="通知名称"></el-table-column>
@ -37,6 +34,8 @@
<el-table-column align="center" prop="createTime" label="创建时间"></el-table-column>
<el-table-column align="center" prop="createTime" label="发送时间"></el-table-column>
</el-table>
</div>
<pagination
v-show="total>0"
:total="total"
@ -310,5 +309,14 @@ export default {
height: 50px;
line-height: 60px;
}
.app-container{
padding: 10px;
}
.table-box{
width: 100%;
height: 74vh;
overflow: auto;
scrollbar-width: none;
}
</style>

View File

@ -480,7 +480,7 @@ export default {
}
.table_box{
width: 100%;
height: 69vh;
height: 70vh;
}
</style>

View File

@ -576,7 +576,7 @@ export default {
}
.table_box{
width: 100%;
height: 69vh;
height: 70vh;
}
</style>

View File

@ -124,5 +124,14 @@ public class CardCouponUserController extends BaseController {
return getSuccessResult(maps);
}
/**
* 分页查询已核销记录列表
*/
@GetMapping("/selectVerifiedList")
public ResponseObject selectVerifiedList(Page<CardCouponUser> page,CardCouponUser cardCouponUser) {
return getSuccessResult(this.cardCouponUserService.selectVerifiedList(page, cardCouponUser));
}
}

View File

@ -7,6 +7,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.data.annotation.Transient;
import java.io.Serializable;
@ -59,6 +60,23 @@ public class CardCouponUser extends Model<CardCouponUser> {
//核销码
private String verificationCode;
/**
* 优惠券名称
*/
@Transient
private String name;
/**
* 优惠券类型
*/
@Transient
private String type;
@Transient
@JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
private String begin;
@Transient
@JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
private String end;
}

View File

@ -52,6 +52,6 @@ public interface CardCouponUserMapper extends BaseMapper<CardCouponUser> {
CardCouponUserVo selectOneCardName(Integer id);
IPage<CardCouponUserVo> selectVerifiedList(Page<CardCouponUser> page, @Param("obj")CardCouponUser cardCouponUser);
}

View File

@ -57,12 +57,13 @@
SELECT userCard.id as id,
mtUser.NAME as mobile,
userCard.verification_code as ticketCode,
CONCAT(userCard.start_time, '-', userCard.end_time) as exchangeFrom,
card.name as exchangeName,
card.exchange_content as exchangeContent
FROM (SELECT * FROM card_coupon_user WHERE mobile = #{str} OR verification_code = #{str}) userCard
INNER JOIN card_coupon card ON userCard.card_coupon_id = card.id
LEFT JOIN mt_user mtUser ON mtUser.id = userCard.mt_user_id
WHERE card.type IN (2, 5)
WHERE card.type = '2'
AND userCard.STATUS = 0
AND userCard.start_time &lt;= NOW()
AND userCard.end_time &gt;= NOW()
@ -80,6 +81,49 @@
JOIN card_coupon cc on cu.card_coupon_id = cc.id
where cu.id = #{id}
</select>
<select id="selectVerifiedList"
resultType="com.fuint.business.marketingActivity.cardCoupon.vo.CardCouponUserVo">
SELECT
ccu.mobile mobile,
cc.name couponName,
ccu.update_time verificationTime,
CASE
WHEN cc.type = '1' THEN '代金券'
WHEN cc.type = '2' THEN '兑换券'
WHEN cc.type = '3' THEN '折扣券'
WHEN cc.type = '4' THEN '油品立减券'
WHEN cc.type = '5' THEN '单品代金券'
END as type,
CONCAT(ccu.start_time, '-', ccu.end_time) effectiveTime,
CONCAT(cc.available_period_start, '-', cc.available_period_end) availableTime,
cc.exchange_content exchangeContent,
cc.use_condition userCondition,
ta.real_name createBy
from card_coupon_user ccu
left join card_coupon cc on ccu.card_coupon_id = cc.id
left join t_account ta on ccu.create_by = ta.acct_id
<where>
ccu.STATUS = 1 and cc.type = 2
<if test="obj.name != null and obj.name != ''">
and cc.name = #{obj.name}
</if>
<if test="obj.type != null and obj.type != ''">
and cc.type = #{obj.type}
</if>
<if test="obj.mobile != null and obj.mobile != ''">
and ccu.mobile = #{obj.mobile}
</if>
<if test="obj.createBy != null and obj.createBy != ''">
and ccu.create_by = #{obj.createBy}
</if>
<if test="obj.begin != null and obj.begin != ''">
<![CDATA[and ccu.update_time >= concat(#{obj.begin},' 00:00:00') ]]>
</if>
<if test="obj.end != null and obj.end != ''">
<![CDATA[ and ccu.update_time <= concat(#{obj.end},' 23:59:59') ]]>
</if>
</where>
</select>
</mapper>

View File

@ -3,6 +3,7 @@ package com.fuint.business.marketingActivity.cardCoupon.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.fuint.business.marketingActivity.activeApplet.entity.ActiveApplet;
import com.fuint.business.marketingActivity.cardCoupon.entity.CardCouponUser;
import com.fuint.business.marketingActivity.cardCoupon.vo.CardCouponUserVo;
import com.fuint.business.marketingActivity.cardCoupon.vo.CardCouponVO;
@ -69,5 +70,6 @@ public interface CardCouponUserService extends IService<CardCouponUser> {
List<Map<String, Object>> selectUserCardVerification(String str);
IPage<CardCouponUserVo> selectVerifiedList(Page<CardCouponUser> page, CardCouponUser cardCouponUser);
}

View File

@ -193,5 +193,10 @@ public class CardCouponUserServiceImpl extends ServiceImpl<CardCouponUserMapper,
List<Map<String, Object>> maps = cardCouponUserMapper.selectUserCardVerification(str);
return maps;
}
@Override
public IPage<CardCouponUserVo> selectVerifiedList(Page<CardCouponUser> page, CardCouponUser cardCouponUser) {
return cardCouponUserMapper.selectVerifiedList(page, cardCouponUser);
}
}

View File

@ -14,6 +14,25 @@ public class CardCouponUserVo extends CardCouponUser {
* 卡券类型 1代金券2兑换券3折扣券4油品立减券5单品代金券
*/
private String type;
/**
* 有效期
*/
private String effectiveTime;
/**
* 可用时间
*/
private String availableTime;
/**
* 兑换内容
*/
private String exchangeContent;
/**
* 核销时间
*/
private String verificationTime;
/**
* 使用条件
*/

View File

@ -519,7 +519,7 @@ public class AllOrderInfoController extends BaseController {
this.allOrderInfoService.exportExcelBackOrderMsgsApi(response, allOrderInfoRes);
}
`
/**
* 交易对账
* 交易明细分页查询

View File

@ -60,3 +60,12 @@ export function delRecord(id) {
method: 'delete'
})
}
// 已核销记录列表
export function selectVerifiedList(query) {
return request({
url: '/cardCouponUser/selectVerifiedList',
method: 'get',
params: query
})
}

View File

@ -12,16 +12,22 @@
<div style="font-weight: bold;margin-bottom: 2px">{{ chooseVipUser.name || '匿名' }}</div>
<div class="d-s">
<span>{{ chooseVipUser.mobile }}</span>
<span style="margin: 0px 5px">普通会员</span>
<span style="margin: 0px 5px">{{ chooseVipUser.gradeName }}</span>
<el-popover
placement="bottom"
trigger="hover"
>
<div> 储值卡1000.00</div>
<div> 储值卡1000.00</div>
<div> 储值卡1000.00</div>
<div> 储值卡1000.00</div>
<div> 储值卡1000.00</div>
<div> 储值卡{{ chooseVipUser.cardBalance || 0 }}</div>
<div v-if="chooseVipUser.userFuels">
<div v-for="(item,index) in chooseVipUser.userFuels" :key="index">
囤油卡{{item.oilNumberName}} {{item.fuelAmount}}
</div>
</div>
<div v-if="chooseVipUser.fleetMember">
<div>
车队卡{{ chooseVipUser.fleetMember.remainingCreditLimit }}
</div>
</div>
<img slot="reference" src="./imgs/kbao.png" style="width: 24px;height: 24px;margin-right: 10px">
</el-popover>

View File

@ -5,42 +5,59 @@
<div class="top_new">
<el-form :model="queryParams" ref="queryForm" size="small" style="width: 100%" :inline="true" >
<el-form-item label="" prop="payUser">
<el-form-item label="" prop="name">
<el-input
v-model="queryParams.payUser"
v-model="queryParams.name"
placeholder="请选择优惠券名称"
clearable
/>
</el-form-item>
<el-form-item label="" prop="payUser">
<el-form-item label="" prop="type">
<el-select v-model="queryParams.type" clearable placeholder="请选择优惠券类型">
<el-option label="代金券" value="1"/>
<el-option label="兑换券" value="2"/>
<el-option label="折扣券" value="3"/>
<el-option label="油品立减券" value="4"/>
<el-option label="单品代金券" value="5"/>
</el-select>
</el-form-item>
<el-form-item label="" prop="createBy">
<el-select v-model="queryParams.createBy" clearable placeholder="请选择操作人">
<el-option v-for="item in staffList" :key="item.id" :label="item.realName" :value="item.id"></el-option>
</el-select>
</el-form-item>
<el-form-item label="" prop="mobile">
<el-input
v-model="queryParams.payUser"
v-model="queryParams.mobile"
placeholder="请输入用户手机号"
clearable
/>
</el-form-item>
<el-form-item label="">
<el-form-item prop="begin">
<el-date-picker
v-model="beginTime"
v-model="queryParams.begin"
style="width: 160px"
format="yyyy-MM-dd"
type="date"
placeholder="交易开始日期">
</el-date-picker>
<el-date-picker
v-model="endTime"
style="width: 160px"
type="date"
placeholder="交易结束日期">
placeholder="开始日期">
</el-date-picker>
</el-form-item>
<el-form-item >
<el-form-item prop="end">
<el-date-picker
v-model="queryParams.end"
style="width: 160px"
format="yyyy-MM-dd"
type="date"
placeholder="结束日期">
</el-date-picker>
</el-form-item>
</el-form>
<div style="height: 32px;width: 20%;display: flex;justify-content: flex-end">
<el-button type="primary" icon="el-icon-search" @click="">查询</el-button>
<el-button icon="el-icon-refresh" @click="">重置</el-button>
<el-button type="primary" icon="el-icon-search" @click="handleQuery()">查询</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery()">重置</el-button>
</div>
</div>
@ -50,16 +67,16 @@
border
style="width: 100%">
<el-table-column type="index" width="50" align="center" label="序号"/>
<el-table-column label="优惠券名称" align="center" prop="orderNo" width="220"/>
<el-table-column label="优惠券类型" align="center" prop="terminal"/>
<el-table-column label="用户手机号" align="center" prop="terminal"/>
<el-table-column label="有效日期" align="center" prop="terminal"/>
<el-table-column label="可用时间" align="center" prop="terminal"/>
<el-table-column label="兑换内容" align="center" prop="terminal"/>
<el-table-column label="使用条件" align="center" prop="terminal"/>
<el-table-column label="核销人" align="center" prop="terminal"/>
<el-table-column label="核销时间" align="center" prop="terminal"/>
<el-table-column label="操作" align="center" width="300" class-name="small-padding fixed-width">
<el-table-column label="优惠券名称" align="center" prop="couponName"/>
<el-table-column label="优惠券类型" align="center" prop="type"/>
<el-table-column label="用户手机号" align="center" prop="mobile"/>
<el-table-column label="有效日期" align="center" prop="effectiveTime" width="290"/>
<el-table-column label="可用时间" align="center" prop="availableTime" width="160"/>
<el-table-column label="兑换内容" align="center" prop="exchangeContent"/>
<el-table-column label="使用条件" align="center" prop="useCondition"/>
<el-table-column label="核销人" align="center" prop="createBy"/>
<el-table-column label="核销时间" align="center" prop="verificationTime" width="180"/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button style="color: #fe8c4a"
@click="patchwork(scope.row)"
@ -74,41 +91,72 @@
</el-table-column>
</el-table>
<div class="pagination-box">
<el-pagination
background
layout="prev, pager, next"
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.page"
:page.sync="queryParams.current"
:limit.sync="queryParams.pageSize"
@current-change="getList">
</el-pagination>
</div>
@pagination="getList"
/>
</div>
</div>
</template>
<script>
import { selectVerifiedList } from "@/api/online";
import { queryStaffs } from '@/api/cashier/staff'
export default {
name: "order_Goods",
data() {
return {
list:[],
beginTime:'',
endTime:'',
//
staffList: [],
queryParams: {
page: 1,
pageSize: 10,
begin: '',
end: '',
name: '',
type: '',
mobile: '',
createBy: '',
},
total:0
}
},
created(){
this.getList()
this.getStaffList()
},
methods:{
getList(){
}
selectVerifiedList(this.queryParams).then(res => {
this.list = res.data.records;
this.total = res.data.total
this.queryParams.page = res.data.current
});
},
handleQuery(){
this.queryParams.current = 1;
this.getList();
},
resetQuery(){
this.queryParams.current = 1;
this.queryParams.name = '',
this.queryParams.mobile= '',
this.queryParams.type='',
this.queryParams.begin='',
this.queryParams.end=''
this.queryParams.createBy=''
this.getList();
},
getStaffList() {
queryStaffs().then(response => {
this.staffList = response.data
})
},
}
}
</script>

View File

@ -166,9 +166,9 @@
</el-table-column>
<el-table-column prop="status" align="center" label="订单状态">
<template slot-scope="scope">
<el-tag v-if="scope.row.status === 'unpaid'">支付</el-tag>
<el-tag type="success" v-else-if="scope.row.status === 'paid'">支付</el-tag>
<el-tag type="danger" v-else-if="scope.row.status === 'refund'">退款</el-tag>
<el-tag v-if="scope.row.status === 'unpaid'">支付失败</el-tag>
<el-tag type="success" v-else-if="scope.row.status === 'paid'">支付成功</el-tag>
<el-tag type="danger" v-else-if="scope.row.status === 'refund'">退款成功</el-tag>
<el-tag type="danger" v-else>支付失败</el-tag>
</template>
</el-table-column>

View File

@ -252,7 +252,7 @@
<!-- @click="handleRefund(scope.row.id)" -->
<el-button style="color: #fe8c4a" type="text" @click="refHandleRefund(scope.row.id)"
v-if="scope.row.orderStatus === 'paid' && scope.row.terminal=='applet'" >退款
v-if="scope.row.orderStatus === 'paid' || scope.row.terminal=='applet'" >退款
</el-button>
</template>
</el-table-column>