Browse Source

ALI商圈交易、WX商圈交易新添字段

master
HolyKnightIX 2 days ago
parent
commit
04439e4c6f
2 changed files with 107 additions and 59 deletions
  1. +29
    -21
      src/components/bill/business/aliCircle.vue
  2. +78
    -38
      src/components/bill/business/wxCircle.vue

+ 29
- 21
src/components/bill/business/aliCircle.vue View File

@@ -74,14 +74,13 @@
</el-form>
<div class="payAllData">
<p>交易金额:</p>
<p style="color: red;">{{sumPayAmount/100}}元</p>
<p style="color: red;">{{ sumPayAmount / 100 }}元</p>
<p>&nbsp; &nbsp;退款金额:</p>
<p style="color: red;">{{sumRefundAmount/100}}元</p>
<p style="color: red;">{{ sumRefundAmount / 100 }}元</p>
</div>
<el-button type="primary" class="builtBtn ml_0" @click="exportData">
<i class="el-icon-upload2"></i>导出数据
</el-button>

<table-list :ref="tk" :options="optionsTable"></table-list>
<alert-dialog ref="alertDialogKey"></alert-dialog>
@@ -105,8 +104,8 @@ export default {
},
data() {
return {
sumPayAmount:0,
sumRefundAmount:0,
sumPayAmount: 0,
sumRefundAmount: 0,
payTypeList: [
{
name: "付款",
@@ -124,7 +123,9 @@ export default {
cUserPhone: "",
merchantName: "",
time: [
moment(new Date()).subtract(29, "days").format("YYYY-MM-DD"),
moment(new Date())
.subtract(29, "days")
.format("YYYY-MM-DD"),
moment(new Date()).format("YYYY-MM-DD"),
],
},
@@ -172,6 +173,10 @@ export default {
key: "merchantName",
val: "门店",
},
{
key: "mallStoreId",
val: "支付宝订单店铺号",
},
{
key: "cuserPhone",
val: "会员手机号",
@@ -235,7 +240,7 @@ export default {
// 将this.setNavData 映射为 this.$store.dispatch('setNavData')
"setNavData",
]),
getPayType(clo, item) {
return this.payTypeList.filter((res) => res.value == item.isRefund)[0]
.name;
@@ -256,16 +261,16 @@ export default {
},
});
},
getMoneyAll(){
let str = this.dealData("statistics")
this.getFetch(str).then(res=>{
getMoneyAll() {
let str = this.dealData("statistics");
this.getFetch(str).then((res) => {
console.log(res.data);
this.sumPayAmount = res.data.sumPayAmount
this.sumRefundAmount = res.data.sumRefundAmount
})
this.sumPayAmount = res.data.sumPayAmount;
this.sumRefundAmount = res.data.sumRefundAmount;
});
},
search: function () {
this.getMoneyAll()
search: function() {
this.getMoneyAll();
let tk = this.$refs[this.tk];
tk.search(tk.getParams().index);
},
@@ -274,7 +279,7 @@ export default {
let merchantName = this.ruleForm.merchantName;
let validStartDate = "";
let validEndDate = "";
let cUserPhone = this.ruleForm.cUserPhone
let cUserPhone = this.ruleForm.cUserPhone;
validStartDate = this.ruleForm.time[0];
validEndDate = this.ruleForm.time[1];
validStartDate = validStartDate
@@ -284,16 +289,19 @@ export default {
? moment(validEndDate).format("YYYY-MM-DD") + " 23:59:59"
: "";
if (urlStr == "list") {
return `/api/aliCircle/${urlStr}?transactionId=${this.ruleForm.transactionId}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
return `/api/aliCircle/${urlStr}?transactionId=${
this.ruleForm.transactionId
}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
} else {
return `/api/aliCircle/${urlStr}?transactionId=${this.ruleForm.transactionId}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
return `/api/aliCircle/${urlStr}?transactionId=${
this.ruleForm.transactionId
}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
}
},
exportData() {
let str = this.dealData("exportData");
console.log(str);
location.href = str;
},
},
activated() {
@@ -481,7 +489,7 @@ export default {
margin: 0 !important;
padding: 0 !important;
}
.payAllData{
.payAllData {
background-color: #fff;
width: 100%;
height: 40px;
@@ -495,4 +503,4 @@ export default {
font-size: 14px;
line-height: 40px;
}
</style>
</style>

+ 78
- 38
src/components/bill/business/wxCircle.vue View File

@@ -1,39 +1,75 @@
<template>
<div>
<div class="layout-content">
<el-form :inline="true" :model="ruleForm" ref="ruleForm" class="demo-form-inline" label-position="right">
<el-form
:inline="true"
:model="ruleForm"
ref="ruleForm"
class="demo-form-inline"
label-position="right"
>
<el-form-item label="订单编号" prop="transactionId" class="fx_title">
<el-input v-model.trim="ruleForm.transactionId" placeholder="请输入" clearable></el-input>
<el-input
v-model.trim="ruleForm.transactionId"
placeholder="请输入"
clearable
></el-input>
</el-form-item>

<el-form-item label="支付/退款日期" prop="time" class="outer_time_item">
<el-date-picker v-model="ruleForm.time[0]" :picker-options="pickerOptions0" type="date"
value-format="yyyy-MM-dd" placeholder="选择开始日期"></el-date-picker>
<el-date-picker
v-model="ruleForm.time[0]"
:picker-options="pickerOptions0"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择开始日期"
></el-date-picker>
</el-form-item>
<el-form-item class="line">-</el-form-item>
<el-form-item prop="time" class="outer_time_item">
<el-date-picker v-model="ruleForm.time[1]" :picker-options="pickerOptions1" type="date"
value-format="yyyy-MM-dd" placeholder="选择结束日期"></el-date-picker>
<el-date-picker
v-model="ruleForm.time[1]"
:picker-options="pickerOptions1"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择结束日期"
></el-date-picker>
</el-form-item>

<el-form-item label="类型" prop="isRefund" class="fx_send">
<el-select v-model="ruleForm.isRefund" placeholder="请输入" clearable>
<el-option v-for="(item, index) in payTypeList" :key="index" :value="item.value"
:label="item.name"></el-option>
<el-option
v-for="(item, index) in payTypeList"
:key="index"
:value="item.value"
:label="item.name"
></el-option>
</el-select>
</el-form-item>

<el-form-item label="门店" prop="merchantName" class="fx_title">
<el-input v-model.trim="ruleForm.merchantName" placeholder="请输入" clearable></el-input>
<el-input
v-model.trim="ruleForm.merchantName"
placeholder="请输入"
clearable
></el-input>
</el-form-item>
<el-form-item label="顾客手机号" prop="cUserPhone" class="fx_send">
<el-input v-model.trim="ruleForm.cUserPhone" placeholder="请输入" clearable></el-input>
<el-input
v-model.trim="ruleForm.cUserPhone"
placeholder="请输入"
clearable
></el-input>
</el-form-item>


<el-form-item>
<el-button class="hoverBtn" type="primary" icon="el-icon-search"
:style="'border:0;background:' + navigationInfo.moduleColor" @click="search"></el-button>
<el-button
class="hoverBtn"
type="primary"
icon="el-icon-search"
:style="'border:0;background:' + navigationInfo.moduleColor"
@click="search"
></el-button>
</el-form-item>
</el-form>
<div class="payAllData">
@@ -73,12 +109,12 @@ export default {
payTypeList: [
{
name: "付款",
value: 0
value: 0,
},
{
name: "退款",
value: 1
}
value: 1,
},
],
tk: "manjianTableKey",
ruleForm: {
@@ -87,7 +123,9 @@ export default {
cUserPhone: "",
merchantName: "",
time: [
moment(new Date()).subtract(29, "days").format("YYYY-MM-DD"),
moment(new Date())
.subtract(29, "days")
.format("YYYY-MM-DD"),
moment(new Date()).format("YYYY-MM-DD"),
],
},
@@ -135,6 +173,10 @@ export default {
key: "merchantName",
val: "门店",
},
{
key: "wxShopName",
val: "微信订单店铺",
},
{
key: "cuserPhone",
val: "会员手机号",
@@ -199,15 +241,14 @@ export default {
"setNavData",
]),
getPayType(clo, item) {
return this.payTypeList.filter(res =>
res.value == item.isRefund
)[0].name
return this.payTypeList.filter((res) => res.value == item.isRefund)[0]
.name;
},
changemoneyNum(col, item) {
if (item.isRefund == 0) {
return item.payAmountStr
return item.payAmountStr;
} else {
return item.refundAmountStr
return item.refundAmountStr;
}
},
godetial(item, row) {
@@ -220,15 +261,15 @@ export default {
});
},
getMoneyAll() {
let str = this.dealData("statistics")
this.getFetch(str).then(res => {
let str = this.dealData("statistics");
this.getFetch(str).then((res) => {
console.log(res.data);
this.sumPayAmount = res.data.sumPayAmount
this.sumRefundAmount = res.data.sumRefundAmount
})
this.sumPayAmount = res.data.sumPayAmount;
this.sumRefundAmount = res.data.sumRefundAmount;
});
},
search: function () {
this.getMoneyAll()
search: function() {
this.getMoneyAll();
let tk = this.$refs[this.tk];
tk.search(tk.getParams().index);
},
@@ -237,7 +278,7 @@ export default {
let merchantName = this.ruleForm.merchantName;
let validStartDate = "";
let validEndDate = "";
let cUserPhone = this.ruleForm.cUserPhone
let cUserPhone = this.ruleForm.cUserPhone;
validStartDate = this.ruleForm.time[0];
validEndDate = this.ruleForm.time[1];
validStartDate = validStartDate
@@ -247,9 +288,13 @@ export default {
? moment(validEndDate).format("YYYY-MM-DD") + " 23:59:59"
: "";
if (urlStr == "list") {
return `/api/wxCircle/${urlStr}?transactionId=${this.ruleForm.transactionId}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
return `/api/wxCircle/${urlStr}?transactionId=${
this.ruleForm.transactionId
}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
} else {
return `/api/wxCircle/${urlStr}?transactionId=${this.ruleForm.transactionId}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
return `/api/wxCircle/${urlStr}?transactionId=${
this.ruleForm.transactionId
}&startTime=${validStartDate}&endTime=${validEndDate}&isRefund=${isRefund}&merchantName=${merchantName}&cUserPhone=${cUserPhone}`;
}
},
exportData() {
@@ -257,13 +302,8 @@ export default {
console.log(str);
location.href = str;
},




},
activated() {

this.search();
this.setNavData(["账单管理", "对账管理", "WX商圈交易"]);
},
@@ -462,4 +502,4 @@ export default {
font-size: 14px;
line-height: 40px;
}
</style>
</style>

Loading…
Cancel
Save