Merge branch 'main' of http://122.51.230.86:3000/dianliang/oil-station into main
This commit is contained in:
commit
74e06e1c11
@ -8,6 +8,14 @@ export function getListApi(query) {
|
||||
params: query
|
||||
})
|
||||
}
|
||||
// 分页查询所有的订单信息
|
||||
export function getList1Api(query) {
|
||||
return request({
|
||||
url: 'sysLog/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
//
|
||||
export function deleteApi(ids) {
|
||||
|
@ -138,7 +138,7 @@
|
||||
size="mini"
|
||||
type="text"
|
||||
@click="returnRecord(scope.row.id)"
|
||||
>170px</el-button>
|
||||
>归还详情</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
@ -96,7 +96,7 @@
|
||||
">
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleQuery">查询</el-button>
|
||||
<el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
|
||||
<el-button type="primary" @click="exportExcelGoodsOrder()">导出订单</el-button>
|
||||
<el-button type="primary" @click="exportExcelGoodsOrder()">导出</el-button>
|
||||
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
@ -131,16 +131,16 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="订单状态" align="center" prop="payType">
|
||||
<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 type="danger" v-else>支付失败</el-tag>
|
||||
<div v-if="scope.row.status == 'unpaid'" style="color: #F44522">未支付</div>
|
||||
<div v-else-if="scope.row.status == 'paid'" style="color: #0DC291">支付成功</div>
|
||||
<div v-else-if="scope.row.status === 'refund'" style="color: #F44522">退款成功</div>
|
||||
<div v-else style="color: #F44522">支付失败</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="订单类型" align="center" prop="type"/>-->
|
||||
<el-table-column label="关联员工" align="center" prop="staffId">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ getRealName(staffList,scope.row.staffId) }}</span>
|
||||
<span>{{ getRealName(staffList, scope.row.staffId) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="订单创建时间" align="center" width="150" prop="payTime">
|
||||
@ -153,17 +153,17 @@
|
||||
<span>{{ parseTime(scope.row.payTime) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="操作" align="center" width="300" class-name="small-padding fixed-width">-->
|
||||
<!-- <template slot-scope="scope">-->
|
||||
<!-- <el-button style="width: 60px" size="mini"-->
|
||||
<!-- @click="patchwork(scope.row)"-->
|
||||
<!-- type="primary" plain round>补打</el-button>-->
|
||||
<!-- <el-button style="width: 60px" size="mini"-->
|
||||
<!-- v-if = "scope.row.status === 'paid'"-->
|
||||
<!-- @click="handleRefund(scope.row.id)"-->
|
||||
<!-- type="danger" plain round>退款</el-button>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<!-- <el-table-column label="操作" align="center" width="300" class-name="small-padding fixed-width">-->
|
||||
<!-- <template slot-scope="scope">-->
|
||||
<!-- <el-button style="width: 60px" size="mini"-->
|
||||
<!-- @click="patchwork(scope.row)"-->
|
||||
<!-- type="primary" plain round>补打</el-button>-->
|
||||
<!-- <el-button style="width: 60px" size="mini"-->
|
||||
<!-- v-if = "scope.row.status === 'paid'"-->
|
||||
<!-- @click="handleRefund(scope.row.id)"-->
|
||||
<!-- type="danger" plain round>退款</el-button>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
|
||||
</el-table>
|
||||
</div>
|
||||
@ -200,9 +200,10 @@
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div>
|
||||
<el-input placeholder="请输入退款原因" v-model="refundRemark" ></el-input>
|
||||
<el-input placeholder="请输入退款原因" v-model="refundRemark"></el-input>
|
||||
<br/>
|
||||
<span style="color: grey;font-size: 12px">退款仅支持全额退款,退款金额将按照支付信息原路退回、优惠券、储值卡等原路退回处理</span>
|
||||
<span
|
||||
style="color: grey;font-size: 12px">退款仅支持全额退款,退款金额将按照支付信息原路退回、优惠券、储值卡等原路退回处理</span>
|
||||
</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogRefund = false">取 消</el-button>
|
||||
@ -226,26 +227,26 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {getGoodsOrder, getOrderGoods, listOrder,orderStatisticsApi} from "@/api/order/goodsorder";
|
||||
import { queryStaffs } from "@/api/order/staff";
|
||||
import { getDicts } from "@/api/order/data";
|
||||
import { exportExcelGoodsOrderApi } from "@/api/order/exportExcel";
|
||||
import {getGoodsOrder, getOrderGoods, listOrder, orderStatisticsApi} from "@/api/order/goodsorder";
|
||||
import {queryStaffs} from "@/api/order/staff";
|
||||
import {getDicts} from "@/api/order/data";
|
||||
import {exportExcelGoodsOrderApi} from "@/api/order/exportExcel";
|
||||
import {getOrderInfoApi, refundApi} from "@/api/order/refund";
|
||||
|
||||
export default {
|
||||
name: "order_Cashier",
|
||||
data(){
|
||||
return{
|
||||
data() {
|
||||
return {
|
||||
// 终端列表
|
||||
terminalList:[],
|
||||
terminalList: [],
|
||||
// 订单状态列表
|
||||
payStatusList:[],
|
||||
payStatusList: [],
|
||||
// 员工列表
|
||||
staffList:[],
|
||||
staffList: [],
|
||||
// 日期范围
|
||||
dateRange: [],
|
||||
beginTime:"",
|
||||
endTime:"",
|
||||
beginTime: "",
|
||||
endTime: "",
|
||||
// 遮罩层
|
||||
loading: false,
|
||||
loadingRes: true,
|
||||
@ -259,7 +260,7 @@ export default {
|
||||
total: 0,
|
||||
// 表格数据
|
||||
list: [],
|
||||
goodsList:[],
|
||||
goodsList: [],
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 默认排序
|
||||
@ -269,25 +270,25 @@ export default {
|
||||
page: 1,
|
||||
pageSize: 10,
|
||||
},
|
||||
orderGoods:'',
|
||||
orderGoods: '',
|
||||
// 支付列表
|
||||
payList:[],
|
||||
payList: [],
|
||||
dialogRefund: false,
|
||||
radio1:"油号选错",
|
||||
goods:{},
|
||||
refundRemark:"",
|
||||
radio1: "油号选错",
|
||||
goods: {},
|
||||
refundRemark: "",
|
||||
|
||||
orderStatistics: {
|
||||
numberOfProducts:'0',
|
||||
theTotalAmount:'0',
|
||||
theTotalNumberOfUnits:'0',
|
||||
discountAmount:'0',
|
||||
wechat:'0',
|
||||
alipay:'0',
|
||||
cash:'0',
|
||||
numberOfProducts: '0',
|
||||
theTotalAmount: '0',
|
||||
theTotalNumberOfUnits: '0',
|
||||
discountAmount: '0',
|
||||
wechat: '0',
|
||||
alipay: '0',
|
||||
cash: '0',
|
||||
},
|
||||
// 是否为当天时间
|
||||
isSysDate:false,
|
||||
isSysDate: false,
|
||||
}
|
||||
},
|
||||
created() {
|
||||
@ -296,7 +297,7 @@ export default {
|
||||
start.setMinutes(0)
|
||||
start.setSeconds(0)
|
||||
start.setMilliseconds(0)
|
||||
this.dateRange = [start,new Date()];
|
||||
this.dateRange = [start, new Date()];
|
||||
this.beginTime = start
|
||||
this.endTime = new Date()
|
||||
this.isSysDate = true
|
||||
@ -305,43 +306,51 @@ export default {
|
||||
this.getStaffList();
|
||||
this.getPayList();
|
||||
},
|
||||
methods:{
|
||||
methods: {
|
||||
exportExcelGoodsOrder() {
|
||||
let dateRange = []
|
||||
if (this.beginTime && this.endTime) {
|
||||
dateRange.push(this.beginTime.toLocaleDateString())
|
||||
dateRange.push(this.endTime.toLocaleDateString())
|
||||
}
|
||||
exportExcelGoodsOrderApi(this.addDateRange(this.queryParams, dateRange)).then(res=>{
|
||||
const blob = new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' });
|
||||
this.$download.saveAs(blob,'商品订单统计.xLsx')
|
||||
})
|
||||
this.$confirm('是否导出列表中的数据!', '提示', {
|
||||
confirmButtonText: '导出',
|
||||
cancelButtonText: '取消'
|
||||
}).then(() => {
|
||||
let dateRange = []
|
||||
if (this.beginTime && this.endTime) {
|
||||
dateRange.push(this.beginTime.toLocaleDateString())
|
||||
dateRange.push(this.endTime.toLocaleDateString())
|
||||
}
|
||||
exportExcelGoodsOrderApi(this.addDateRange(this.queryParams, dateRange)).then(res => {
|
||||
const blob = new Blob([res], {type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'});
|
||||
this.$download.saveAs(blob, '商品订单统计.xLsx')
|
||||
})
|
||||
}).catch(() => {
|
||||
|
||||
});
|
||||
},
|
||||
// 订单统计
|
||||
getOrderStatistics (){
|
||||
getOrderStatistics() {
|
||||
let dateRange = []
|
||||
if (this.beginTime && this.endTime) {
|
||||
dateRange.push(this.beginTime.toLocaleDateString())
|
||||
dateRange.push(this.endTime.toLocaleDateString())
|
||||
}
|
||||
orderStatisticsApi(this.addDateRange(this.queryParams, dateRange)).then(res=>{
|
||||
orderStatisticsApi(this.addDateRange(this.queryParams, dateRange)).then(res => {
|
||||
this.orderStatistics = res.data;
|
||||
|
||||
})
|
||||
},
|
||||
// 补打
|
||||
patchwork(data){
|
||||
patchwork(data) {
|
||||
const orderNo = data.orderNo
|
||||
this.$modal.confirm('确定您要补打当前订单吗?当前订单号[' + orderNo + '],请确保云打印机正在运行中').then(function() {
|
||||
this.$modal.confirm('确定您要补打当前订单吗?当前订单号[' + orderNo + '],请确保云打印机正在运行中').then(function () {
|
||||
// return delUser(row.id);
|
||||
}).then(() => {
|
||||
this.$modal.msgSuccess("打印指令已发送打印机,请查看打印结果");
|
||||
}).catch(() => {});
|
||||
}).catch(() => {
|
||||
});
|
||||
},
|
||||
// 退款
|
||||
async handleRefund(id){
|
||||
async handleRefund(id) {
|
||||
|
||||
await getGoodsOrder({"id":id}).then( response => {
|
||||
await getGoodsOrder({"id": id}).then(response => {
|
||||
this.goods = response.data
|
||||
if (response.data.status === "refund") {
|
||||
this.$message({
|
||||
@ -354,8 +363,10 @@ export default {
|
||||
|
||||
|
||||
let title = '是否将该收银台下的订单全部退款'
|
||||
await getOrderInfoApi({orderNo: this.goods.orderNo,
|
||||
type: 'goods'}).then(res=>{
|
||||
await getOrderInfoApi({
|
||||
orderNo: this.goods.orderNo,
|
||||
type: 'goods'
|
||||
}).then(res => {
|
||||
if (res.code === 200) {
|
||||
if (res.data.type === "1") {
|
||||
title = '该订单下有其它商品订单,是否一并退款'
|
||||
@ -364,7 +375,7 @@ export default {
|
||||
}
|
||||
});
|
||||
|
||||
this.$confirm(title+', 是否继续?', '提示', {
|
||||
this.$confirm(title + ', 是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
@ -383,14 +394,14 @@ export default {
|
||||
async refundConfirmed() {
|
||||
this.dialogRefund = false;
|
||||
this.loadingRes = true;
|
||||
console.log("cashierOrder",this.goods)
|
||||
let map={
|
||||
console.log("cashierOrder", this.goods)
|
||||
let map = {
|
||||
orderNo: this.goods.orderNo,
|
||||
storeId: this.goods.storeId,
|
||||
refundRemark:this.radio1 +"-"+ this.refundRemark,
|
||||
refundRemark: this.radio1 + "-" + this.refundRemark,
|
||||
type: "canRefund"
|
||||
}
|
||||
await refundApi(map).then(res=>{
|
||||
await refundApi(map).then(res => {
|
||||
if (res.code === 200) {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
@ -403,63 +414,63 @@ export default {
|
||||
|
||||
},
|
||||
// 根据员工id查询员工信息
|
||||
queryStaf(list,id){
|
||||
queryStaf(list, id) {
|
||||
let name = "";
|
||||
list.forEach(item => {
|
||||
if (item.id == id){
|
||||
if (item.id == id) {
|
||||
name = `${item.realName}(${item.mobile})`
|
||||
}
|
||||
})
|
||||
return name;
|
||||
},
|
||||
getVal(list,val){
|
||||
getVal(list, val) {
|
||||
let name = "";
|
||||
list.forEach(item => {
|
||||
if (item.dictValue == val){
|
||||
if (item.dictValue == val) {
|
||||
name = item.dictLabel
|
||||
}
|
||||
})
|
||||
return name;
|
||||
},
|
||||
// 获取付款类型列表
|
||||
getPayList(){
|
||||
getDicts("payment_type").then( response => {
|
||||
getPayList() {
|
||||
getDicts("payment_type").then(response => {
|
||||
this.payList = response.data;
|
||||
})
|
||||
getDicts("terminal").then( response => {
|
||||
getDicts("terminal").then(response => {
|
||||
this.terminalList = response.data;
|
||||
})
|
||||
getDicts("pay_status").then( response => {
|
||||
getDicts("pay_status").then(response => {
|
||||
this.payStatusList = response.data;
|
||||
})
|
||||
},
|
||||
// 获取商品详情
|
||||
getGoods(id){
|
||||
getOrderGoods({orderId:id}).then( response => {
|
||||
getGoods(id) {
|
||||
getOrderGoods({orderId: id}).then(response => {
|
||||
this.goodsList = response.data
|
||||
this.open = true;
|
||||
this.title = "商品详情"
|
||||
})
|
||||
},
|
||||
// 获取员工姓名
|
||||
getRealName(list,id){
|
||||
getRealName(list, id) {
|
||||
var name = "";
|
||||
list.forEach(item => {
|
||||
if (item.id == id){
|
||||
if (item.id == id) {
|
||||
name = item.realName;
|
||||
}
|
||||
})
|
||||
return name;
|
||||
},
|
||||
// 获取员工列表
|
||||
getStaffList(){
|
||||
queryStaffs().then( response => {
|
||||
getStaffList() {
|
||||
queryStaffs().then(response => {
|
||||
this.staffList = response.data;
|
||||
})
|
||||
},
|
||||
// 查询订单
|
||||
getList(val){
|
||||
if (val!=undefined){
|
||||
getList(val) {
|
||||
if (val != undefined) {
|
||||
this.queryParams.page = val
|
||||
}
|
||||
|
||||
@ -478,7 +489,7 @@ export default {
|
||||
}
|
||||
|
||||
this.loading = true;
|
||||
listOrder(this.addDateRange(this.queryParams, dateRange)).then( response => {
|
||||
listOrder(this.addDateRange(this.queryParams, dateRange)).then(response => {
|
||||
this.list = response.data.records;
|
||||
this.total = response.data.total;
|
||||
this.loading = false;
|
||||
@ -526,34 +537,39 @@ export default {
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
.app-container{
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #f6f8f9;
|
||||
}
|
||||
.app-top{
|
||||
.app-container {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #f6f8f9;
|
||||
}
|
||||
|
||||
.app-top {
|
||||
width: 100%;
|
||||
|
||||
height: 60px;
|
||||
box-sizing: border-box;
|
||||
padding: 10px;
|
||||
}
|
||||
.clearfix{
|
||||
|
||||
.clearfix {
|
||||
width: 100%;
|
||||
|
||||
}
|
||||
.box-card{
|
||||
|
||||
.box-card {
|
||||
width: 100%;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
.box-gang{
|
||||
|
||||
.box-gang {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
|
||||
}
|
||||
.box{
|
||||
|
||||
.box {
|
||||
//box-sizing: border-box;
|
||||
padding: 5px;
|
||||
//background: #f9f9f9;
|
||||
@ -563,15 +579,17 @@ export default {
|
||||
|
||||
width: 211px;
|
||||
height: 60px;
|
||||
background: rgba(64,158,255,0.05);
|
||||
background: rgba(64, 158, 255, 0.05);
|
||||
border-radius: 6px 6px 6px 6px;
|
||||
border: 1px solid #fe8c4a;
|
||||
|
||||
}
|
||||
|
||||
.el-form--inline .el-form-item {
|
||||
margin-right: 44px;
|
||||
}
|
||||
.size-hui{
|
||||
|
||||
.size-hui {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
//width: 200px;
|
||||
@ -583,11 +601,13 @@ export default {
|
||||
text-align: left;
|
||||
font-style: normal;
|
||||
text-transform: none;
|
||||
|
||||
.nei {
|
||||
width: 150px;
|
||||
}
|
||||
}
|
||||
.size-bole{
|
||||
|
||||
.size-bole {
|
||||
//font-weight: bold;
|
||||
|
||||
//width: 53px;
|
||||
@ -601,7 +621,8 @@ export default {
|
||||
font-style: normal;
|
||||
text-transform: none;
|
||||
}
|
||||
.wgang{
|
||||
|
||||
.wgang {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@ -609,33 +630,40 @@ export default {
|
||||
margin-bottom: 20px;
|
||||
|
||||
}
|
||||
.table-box{
|
||||
|
||||
.table-box {
|
||||
width: 100%;
|
||||
height: 70vh;
|
||||
overflow: auto;
|
||||
}
|
||||
.pagination-box{
|
||||
|
||||
.pagination-box {
|
||||
width: 100%;
|
||||
margin: 10px auto;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
align-items: end;
|
||||
justify-content: end;
|
||||
}
|
||||
.top-app-sou{
|
||||
|
||||
.top-app-sou {
|
||||
width: 20%;
|
||||
}
|
||||
|
||||
.icon-img{
|
||||
.icon-img {
|
||||
//margin-left: 110px;
|
||||
width: 100%;
|
||||
height: 20px;
|
||||
margin-right: 5px;
|
||||
img{
|
||||
|
||||
img {
|
||||
float: right;
|
||||
//width: 100%;
|
||||
width: 20px;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.box1{
|
||||
|
||||
.box1 {
|
||||
//box-sizing: border-box;
|
||||
padding: 5px;
|
||||
//background: #f9f9f9;
|
||||
@ -645,7 +673,7 @@ export default {
|
||||
|
||||
width: 211px;
|
||||
height: 60px;
|
||||
background: rgba(255,150,85,0.05);
|
||||
background: rgba(255, 150, 85, 0.05);
|
||||
border-radius: 6px 6px 6px 6px;
|
||||
border: 1px solid #FF9655;
|
||||
}
|
||||
|
@ -21,19 +21,33 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="" prop="oilGunNum">
|
||||
<el-select
|
||||
v-model="queryParams.oils"
|
||||
filterable
|
||||
clearable
|
||||
placeholder="请选择油品油号"
|
||||
>
|
||||
<el-option v-for="item in oilTypeList"
|
||||
:key="item.oilId"
|
||||
:label="item.oilName"
|
||||
:value="item.oilId">
|
||||
<span style="float: left">{{ item.oilType }}</span>
|
||||
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.oilName }}</span>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="" prop="oilGunNum">
|
||||
<el-select
|
||||
v-model="queryParams.oilGunNum"
|
||||
filterable
|
||||
clearable
|
||||
placeholder="请选择油号油枪"
|
||||
placeholder="请选择油枪"
|
||||
>
|
||||
<el-option v-for="item in oilGunList"
|
||||
:key="item.id"
|
||||
:label="item.gunName"
|
||||
:value="item.id">
|
||||
<span style="float: left">{{ item.oilName }}</span>
|
||||
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.gunName }}</span>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@ -49,8 +63,6 @@
|
||||
:label="item.dictLabel"
|
||||
:value="item.dictValue">
|
||||
</el-option>
|
||||
<el-option label="囤油卡" value="oilCard"/>
|
||||
<el-option label="储值卡" value="balance"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="" prop="staffId">
|
||||
@ -138,17 +150,14 @@
|
||||
<el-table-column prop="payType" label="付款方式" align="center">
|
||||
<template slot-scope="scope">
|
||||
<span>{{getType(payList,scope.row.payType)}}</span>
|
||||
<span v-if="scope.row.payType=='oilCard'">囤油卡</span>
|
||||
<span v-if="scope.row.payType=='balance'">储值卡</span>
|
||||
<span v-if="scope.row.payType=='credit'">挂账</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="orderStatus" label="订单状态" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.orderStatus === 'unpaid'">未支付</el-tag>
|
||||
<el-tag type="success" v-else-if="scope.row.orderStatus === 'paid'">已支付</el-tag>
|
||||
<el-tag type="danger" v-else-if="scope.row.orderStatus === 'refund'">已退款</el-tag>
|
||||
<el-tag type="danger" v-else>支付失败</el-tag>
|
||||
<div v-if="scope.row.orderStatus === 'unpaid'" style="color: #F44522">未支付</div>
|
||||
<div v-else-if="scope.row.orderStatus === 'paid'" style="color: #0DC291">支付成功</div>
|
||||
<div v-else-if="scope.row.orderStatus === 'refund'" style="color: #F44522">已退款</div>
|
||||
<div v-else style="color: #F44522">支付失败</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="orderType" label="订单类型" align="center" > </el-table-column>-->
|
||||
@ -270,7 +279,7 @@
|
||||
<script>
|
||||
import {queryStaffs} from "@/api/order/staff";
|
||||
import {getDicts} from "@/api/order/data";
|
||||
import {getOilNameList, getOilNumGun, oilNumbers} from "@/api/order/oilnumgun";
|
||||
import {getOilNameList, getOilNumGun, oilNumberList1, oilNumbers} from "@/api/order/oilnumgun";
|
||||
import {listOilOrder, oilOrderInfo, orderStatisticsApi} from "@/api/order/oilorder";
|
||||
import {getUser, queryUsers} from "@/api/order/user";
|
||||
import {exportExcelOilOrderApi} from "@/api/order/exportExcel";
|
||||
@ -314,6 +323,8 @@
|
||||
pageSize: 10,
|
||||
},
|
||||
total:0,
|
||||
// 油品油号列表
|
||||
oilTypeList:[],
|
||||
// 油枪列表
|
||||
oilGunList:[],
|
||||
// 用户列表
|
||||
@ -432,15 +443,23 @@
|
||||
|
||||
},
|
||||
exportExcelOilOrder() {
|
||||
let dateRange = []
|
||||
if (this.beginTime && this.endTime) {
|
||||
dateRange.push(this.beginTime.toLocaleDateString())
|
||||
dateRange.push(this.endTime.toLocaleDateString())
|
||||
}
|
||||
exportExcelOilOrderApi(this.addDateRange(this.queryParams, dateRange)).then(res=>{
|
||||
const blob = new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' });
|
||||
this.$download.saveAs(blob,'油品订单统计.xLsx')
|
||||
})
|
||||
this.$confirm('是否导出列表中的数据!', '提示', {
|
||||
confirmButtonText: '导出',
|
||||
cancelButtonText: '取消'
|
||||
}).then(() => {
|
||||
let dateRange = []
|
||||
if (this.beginTime && this.endTime) {
|
||||
dateRange.push(this.beginTime.toLocaleDateString())
|
||||
dateRange.push(this.endTime.toLocaleDateString())
|
||||
}
|
||||
exportExcelOilOrderApi(this.addDateRange(this.queryParams, dateRange)).then(res=>{
|
||||
const blob = new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' });
|
||||
this.$download.saveAs(blob,'油品订单统计.xLsx')
|
||||
})
|
||||
}).catch(() => {
|
||||
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
|
||||
@ -462,6 +481,10 @@
|
||||
}
|
||||
})
|
||||
})
|
||||
// 油品油号信息
|
||||
oilNumberList1().then(res => {
|
||||
this.oilTypeList = res.data.records
|
||||
})
|
||||
},
|
||||
getPayType(){
|
||||
getDicts("payment_type").then(res => {
|
||||
@ -758,13 +781,15 @@
|
||||
}
|
||||
.table-box{
|
||||
width: 100%;
|
||||
height: 70vh;
|
||||
overflow: auto;
|
||||
}
|
||||
.pagination-box{
|
||||
width: 100%;
|
||||
margin: 10px auto;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
align-items: end;
|
||||
justify-content: end;
|
||||
}
|
||||
.top-app-sou{
|
||||
width: 20%;
|
||||
|
@ -44,6 +44,7 @@
|
||||
type="primary"
|
||||
icon="el-icon-plus"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['setting:banner:add']"
|
||||
>新增banner图</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
@ -32,12 +32,13 @@
|
||||
|
||||
<el-form-item label="" prop="systemName">
|
||||
<el-select
|
||||
v-model="queryParams.systemName"
|
||||
v-model="systemName"
|
||||
placeholder="请选择系统终端"
|
||||
clearable
|
||||
@change="chooseSystemName"
|
||||
style="width: 240px"
|
||||
>
|
||||
<el-option label="中台端" value="1"></el-option>
|
||||
<!-- <el-option label=" " value="1"></el-option>-->
|
||||
<el-option label="油站端" value="2"></el-option>
|
||||
<el-option label="收银端" value="3"></el-option>
|
||||
</el-select>
|
||||
@ -153,7 +154,7 @@
|
||||
|
||||
<script>
|
||||
|
||||
import {deleteApi, getListApi, saveApi, updateApi} from "../../api/sys/sysLog";
|
||||
import {deleteApi, getList1Api, getListApi, saveApi, updateApi} from "../../api/sys/sysLog";
|
||||
import {getToken} from '../../utils/auth'
|
||||
import {selectChildByDeptId} from "../../api/system/Site/site";
|
||||
|
||||
@ -194,7 +195,9 @@ export default {
|
||||
bannerName: '',
|
||||
systemPosition: '',
|
||||
bannerStatus: '',
|
||||
systemName: '1'
|
||||
},
|
||||
systemName:"",
|
||||
|
||||
// 上传地址
|
||||
uploadAction: process.env.VUE_APP_BASE_API + 'backendApi/file/upload',
|
||||
@ -234,6 +237,9 @@ export default {
|
||||
this.selectChildByDeptIdApi()
|
||||
},
|
||||
methods: {
|
||||
chooseSystemName(){
|
||||
this.queryParams.systemName = this.systemName
|
||||
},
|
||||
selectChildByDeptIdApi() {
|
||||
selectChildByDeptId().then(res => {
|
||||
this.deptListSelect = res.data
|
||||
@ -270,7 +276,7 @@ export default {
|
||||
},
|
||||
getList() {
|
||||
this.queryParams.current = this.queryParams.page
|
||||
getListApi(this.queryParams).then(res => {
|
||||
getList1Api(this.queryParams).then(res => {
|
||||
this.tableData = res.data.records;
|
||||
this.total = res.data.total
|
||||
})
|
||||
@ -331,8 +337,10 @@ export default {
|
||||
page: 1,
|
||||
pageSize: 10,
|
||||
deviceName: '',
|
||||
},
|
||||
this.getList()
|
||||
systemName: "1"
|
||||
}
|
||||
this.systemName = ""
|
||||
this.getList()
|
||||
},
|
||||
handleAdd(e) {
|
||||
this.clean()
|
||||
|
@ -18,6 +18,9 @@
|
||||
<if test="order.terminal != null and order.terminal != ''">
|
||||
and terminal = #{order.terminal}
|
||||
</if>
|
||||
<if test="order.oils != null and order.oils != ''">
|
||||
and oils = #{order.oils}
|
||||
</if>
|
||||
<if test="order.oilGunNum != null and order.oilGunNum != ''">
|
||||
and oil_gun_num = #{order.oilGunNum}
|
||||
</if>
|
||||
|
@ -68,6 +68,44 @@ public class SysLogController extends BaseController {
|
||||
return getSuccessResult(this.sysLogService.page(page, sysLogLambdaQueryWrapper));
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询所有数据(油站端)
|
||||
*
|
||||
* @param page 分页对象
|
||||
* @param sysLog 查询实体
|
||||
* @return 所有数据
|
||||
*/
|
||||
@GetMapping("list")
|
||||
public ResponseObject selectAll1(@RequestParam(value = "page",defaultValue = "1") Integer pageNo,
|
||||
@RequestParam(value = "pageSize",defaultValue = "10") Integer pageSize, SysLog sysLog) {
|
||||
LambdaQueryWrapper<SysLog> sysLogLambdaQueryWrapper = new LambdaQueryWrapper();
|
||||
Page page =new Page(pageNo,pageSize);
|
||||
if (!StringUtils.isEmpty(sysLog.getCreateName())){
|
||||
sysLogLambdaQueryWrapper.like(SysLog::getCreateName,sysLog.getCreateName());
|
||||
}
|
||||
if (!StringUtils.isEmpty(sysLog.getDeptId())){
|
||||
sysLogLambdaQueryWrapper.eq(SysLog::getDeptId,sysLog.getDeptId());
|
||||
}
|
||||
if (!StringUtils.isEmpty(sysLog.getMoudle())){
|
||||
sysLogLambdaQueryWrapper.like(SysLog::getMoudle,sysLog.getMoudle());
|
||||
}
|
||||
if (!StringUtils.isEmpty(sysLog.getSystemName())){
|
||||
if (sysLog.getSystemName().equals("1")){
|
||||
sysLogLambdaQueryWrapper.ne(SysLog::getSystemName,sysLog.getSystemName());
|
||||
}else {
|
||||
sysLogLambdaQueryWrapper.eq(SysLog::getSystemName,sysLog.getSystemName());
|
||||
}
|
||||
}
|
||||
if (!ObjectUtils.isEmpty(sysLog.getStartTime())){
|
||||
sysLogLambdaQueryWrapper.ge(SysLog::getCreateTime,sysLog.getStartTime());
|
||||
}
|
||||
if (!ObjectUtils.isEmpty(sysLog.getEndTime())){
|
||||
sysLogLambdaQueryWrapper.le(SysLog::getCreateTime, DateUtil.format(sysLog.getEndTime(),"yyyy-MM-dd")+" 23:59:59");
|
||||
}
|
||||
sysLogLambdaQueryWrapper.orderByDesc(SysLog::getCreateTime);
|
||||
return getSuccessResult(this.sysLogService.page(page, sysLogLambdaQueryWrapper));
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过主键查询单条数据
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user