|
|
|
@ -3,74 +3,72 @@
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<div class="staffRanking_header padding-bottom-xs">
|
|
|
|
<div class="staffRanking_header padding-bottom-xs">
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
当前年/月份{{ month }}
|
|
|
|
|
|
|
|
<el-button size="mini" @click="del" type="primary" v-role="6006001">删除</el-button>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="block">
|
|
|
|
|
|
|
|
<span class="demonstration padding-left-xs">选择日</span>
|
|
|
|
<span class="demonstration padding-left-xs">选择日</span>
|
|
|
|
<el-date-picker v-model="days" :picker-options="pickerOptions" @change="changeMonth" type="daterange" value-format="yyyy-MM-dd HH:mm:ss" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
|
|
|
|
<el-date-picker v-model="days" :picker-options="pickerOptions" @change="changeMonth" type="daterange" value-format="yyyy-MM-dd" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
|
|
|
|
</el-date-picker>
|
|
|
|
</el-date-picker>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="block">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<el-table @row-dblclick="confirm" :data="tableDate" :header-cell-style="{
|
|
|
|
<el-table @row-dblclick="confirm" :data="tableDate" :header-cell-style="{
|
|
|
|
background: 'linear-gradient(#6cb3ff, #1873d4)',
|
|
|
|
background: 'linear-gradient(#6cb3ff, #1873d4)',
|
|
|
|
color: '#eeeeee',
|
|
|
|
color: '#eeeeee',
|
|
|
|
}" :summary-method="getSummaries" show-summary border max-height="700">
|
|
|
|
}" :summary-method="getSummaries" show-summary border max-height="700">
|
|
|
|
<el-table-column align="center" min-width="80" prop="datae" label="日期"></el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="date" label="日期"></el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="kedans" label="客单数">
|
|
|
|
<el-table-column align="center" min-width="80" prop="cashPeopleNum" label="客单数">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.kedans?scope.row.kedans:'--'}}
|
|
|
|
{{scope.row.cashPeopleNum?scope.row.cashPeopleNum:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeyj" label="充值金额">
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeMoney" label="充值金额">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeyj?scope.row.rechargeyj:'--'}}
|
|
|
|
{{scope.row.rechargeMoney?scope.row.rechargeMoney:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
|
|
|
|
|
<el-table-column align="center" min-width="80" prop="courseOfTreatmentYJ" label="充值人数">
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeOrderNum" label="充值人数">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.courseOfTreatmentYJ?scope.row.courseOfTreatmentYJ:'--'}}
|
|
|
|
{{scope.row.rechargeOrderNum?scope.row.rechargeOrderNum:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="lcCardyj" label="服务金额">
|
|
|
|
<el-table-column align="center" min-width="80" prop="cashMoney" label="服务金额">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.lcCardyj?scope.row.lcCardyj:'--'}}
|
|
|
|
{{scope.row.cashMoney?scope.row.cashMoney:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="男客">
|
|
|
|
<el-table-column align="center" min-width="80" prop="man" label="男客">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.man?scope.row.man:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="女客">
|
|
|
|
<el-table-column align="center" min-width="80" prop="woman" label="女客">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.woman?scope.row.woman:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="还款金额">
|
|
|
|
<el-table-column align="center" min-width="80" prop="repayMoney" label="还款金额">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.repayMoney?scope.row.repayMoney:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="退款金额">
|
|
|
|
<el-table-column align="center" min-width="80" prop="refundMoney" label="退款金额">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.refundMoney?scope.row.refundMoney:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="新增会员">
|
|
|
|
<el-table-column align="center" min-width="80" prop="newMemberNum" label="新增会员">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.newMemberNum?scope.row.newMemberNum:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="启用会员">
|
|
|
|
<el-table-column align="center" min-width="80" prop="startMemberNum" label="启用会员">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.startMemberNum?scope.row.startMemberNum:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
<el-table-column align="center" min-width="80" prop="rechargeTurnCourseChia" label="会员总数">
|
|
|
|
<el-table-column align="center" min-width="80" prop="memberNum" label="会员总数">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<template slot-scope="scope">
|
|
|
|
{{scope.row.rechargeTurnCourseChia?scope.row.rechargeTurnCourseChia:'--'}}
|
|
|
|
{{scope.row.memberNum?scope.row.memberNum:'--'}}
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table-column>
|
|
|
|
</el-table>
|
|
|
|
</el-table>
|
|
|
|
@ -79,14 +77,7 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import {
|
|
|
|
import { storeDailys, exportachi, exportachiwhole } from "@/api/statistics.js";
|
|
|
|
selectSalary,
|
|
|
|
|
|
|
|
addSalary,
|
|
|
|
|
|
|
|
delSalary,
|
|
|
|
|
|
|
|
achiCommListsgroup,
|
|
|
|
|
|
|
|
exportachi,
|
|
|
|
|
|
|
|
exportachiwhole,
|
|
|
|
|
|
|
|
} from "@/api/statistics.js";
|
|
|
|
|
|
|
|
import { partten } from "../../../../partten/index";
|
|
|
|
import { partten } from "../../../../partten/index";
|
|
|
|
import perform from "./examine/index";
|
|
|
|
import perform from "./examine/index";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
@ -96,6 +87,7 @@ export default {
|
|
|
|
days: "",
|
|
|
|
days: "",
|
|
|
|
tableDate: [{}],
|
|
|
|
tableDate: [{}],
|
|
|
|
month: partten.months,
|
|
|
|
month: partten.months,
|
|
|
|
|
|
|
|
queryForm: {},
|
|
|
|
pickerOptions: {
|
|
|
|
pickerOptions: {
|
|
|
|
//组件限制方法
|
|
|
|
//组件限制方法
|
|
|
|
onPick: ({ maxDate, minDate }) => {
|
|
|
|
onPick: ({ maxDate, minDate }) => {
|
|
|
|
@ -130,8 +122,8 @@ export default {
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
//导出方法
|
|
|
|
//导出方法
|
|
|
|
exit() {
|
|
|
|
exit() {
|
|
|
|
let date1 = this.formatTime(this.days[0], "YYYY-MM-DD 00:00:00");
|
|
|
|
let date1 = this.formatTime(this.days[0], "YYYY-MM-DD");
|
|
|
|
let date2 = this.formatTime(this.days[1], "YYYY-MM-DD 23:59:59");
|
|
|
|
let date2 = this.formatTime(this.days[1], "YYYY-MM-DD");
|
|
|
|
let form = { startDate: date1, endDate: date2 };
|
|
|
|
let form = { startDate: date1, endDate: date2 };
|
|
|
|
exportachi(form).then((res) => {
|
|
|
|
exportachi(form).then((res) => {
|
|
|
|
let blob = new Blob([res]);
|
|
|
|
let blob = new Blob([res]);
|
|
|
|
@ -145,8 +137,8 @@ export default {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
exits() {
|
|
|
|
exits() {
|
|
|
|
let date1 = this.formatTime(this.days[0], "YYYY-MM-DD 00:00:00");
|
|
|
|
let date1 = this.formatTime(this.days[0], "YYYY-MM-DD");
|
|
|
|
let date2 = this.formatTime(this.days[1], "YYYY-MM-DD 23:59:59");
|
|
|
|
let date2 = this.formatTime(this.days[1], "YYYY-MM-DD");
|
|
|
|
let form = { startDate: date1, endDate: date2 };
|
|
|
|
let form = { startDate: date1, endDate: date2 };
|
|
|
|
exportachiwhole(form).then((res) => {
|
|
|
|
exportachiwhole(form).then((res) => {
|
|
|
|
let blob = new Blob([res]);
|
|
|
|
let blob = new Blob([res]);
|
|
|
|
@ -159,91 +151,15 @@ export default {
|
|
|
|
window.URL.revokeObjectURL(url);
|
|
|
|
window.URL.revokeObjectURL(url);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
handleStaffName(index) {
|
|
|
|
|
|
|
|
let tableDate = Array.from(this.tableDate);
|
|
|
|
|
|
|
|
tableDate[index].show = true;
|
|
|
|
|
|
|
|
this.tableDate = Array.from(tableDate);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
del() {
|
|
|
|
|
|
|
|
this.$confirm("将之前保存数据库的数据进行删除 , 是否继续", "提示", {
|
|
|
|
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
|
|
|
|
cancelButtonText: "取消",
|
|
|
|
|
|
|
|
type: "warning",
|
|
|
|
|
|
|
|
cancelButtonClass: "cancelbtnFalses",
|
|
|
|
|
|
|
|
confirmButtonClass: "confirmbtnFalses",
|
|
|
|
|
|
|
|
}).then(() => {
|
|
|
|
|
|
|
|
delSalary({ type: 3 }).then((res) => {
|
|
|
|
|
|
|
|
if (res.code == "000000") {
|
|
|
|
|
|
|
|
this.$message.success({ message: res.message });
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
this.$alert(res.message, "提示", {
|
|
|
|
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
|
|
|
|
confirmButtonClass: "confirmbtnFalses",
|
|
|
|
|
|
|
|
type: "warning",
|
|
|
|
|
|
|
|
center: true,
|
|
|
|
|
|
|
|
callback: (action) => {},
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
seve() {
|
|
|
|
|
|
|
|
this.$confirm("将当前数据保存到数据库备份 , 是否继续保存", "提示", {
|
|
|
|
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
|
|
|
|
cancelButtonText: "取消",
|
|
|
|
|
|
|
|
type: "warning",
|
|
|
|
|
|
|
|
cancelButtonClass: "cancelbtnFalses",
|
|
|
|
|
|
|
|
confirmButtonClass: "confirmbtnFalses",
|
|
|
|
|
|
|
|
}).then(() => {
|
|
|
|
|
|
|
|
addSalary(this.tableDate).then((res) => {
|
|
|
|
|
|
|
|
if (res.code == "000000") {
|
|
|
|
|
|
|
|
this.$message.success({ message: res.message });
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
this.$alert(res.message, "提示", {
|
|
|
|
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
|
|
|
|
confirmButtonClass: "confirmbtnFalses",
|
|
|
|
|
|
|
|
type: "warning",
|
|
|
|
|
|
|
|
center: true,
|
|
|
|
|
|
|
|
callback: (action) => {},
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
changeMonth(res) {
|
|
|
|
|
|
|
|
console.log(res);
|
|
|
|
|
|
|
|
let date = this.formatTime(res[1], "YYYY-MM-DD 23:59:59");
|
|
|
|
|
|
|
|
var form = { startDate: res[0], endDate: date };
|
|
|
|
|
|
|
|
let month = this.formatTime(this.month, "YYYY-MM");
|
|
|
|
|
|
|
|
achiCommListsgroup(form).then((res) => {
|
|
|
|
|
|
|
|
if (res.code == "000000") {
|
|
|
|
|
|
|
|
res.rows.forEach((item) => {
|
|
|
|
|
|
|
|
item.baseSalary = item.baseSalary == null ? 0 : item.baseSalary * 1;
|
|
|
|
|
|
|
|
item.commSalary = item.commSalary == null ? 0 : item.commSalary * 1;
|
|
|
|
|
|
|
|
item.sumNumber = (item.baseSalary + item.commSalary).toFixed(2) * 1;
|
|
|
|
|
|
|
|
item.startDate = form.startDate;
|
|
|
|
|
|
|
|
item.endDate = form.endDate;
|
|
|
|
|
|
|
|
console.log(item);
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.tableDate = res.rows;
|
|
|
|
changeMonth(res) {
|
|
|
|
} else {
|
|
|
|
this.days = res;
|
|
|
|
this.$alert(res.message, "提示", {
|
|
|
|
this.getData();
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
|
|
|
|
confirmButtonClass: "confirmbtnFalses",
|
|
|
|
|
|
|
|
type: "warning",
|
|
|
|
|
|
|
|
center: true,
|
|
|
|
|
|
|
|
callback: (action) => {},
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
achiCommListsgroup() {
|
|
|
|
getData() {
|
|
|
|
let month = this.formatTime(new Date(), "YYYY-MM-DD hh:mm:ss");
|
|
|
|
this.queryForm.startDate = this.days[0];
|
|
|
|
let date1 = this.formatTime(new Date(), "YYYY-MM-DD 00:00:00");
|
|
|
|
this.queryForm.endDate = this.days[1];
|
|
|
|
let date2 = this.formatTime(new Date(), "YYYY-MM-DD 23:59:59");
|
|
|
|
storeDailys(this.queryForm).then((res) => {
|
|
|
|
let form = { startDate: date1, endDate: date2 };
|
|
|
|
|
|
|
|
achiCommListsgroup(form).then((res) => {
|
|
|
|
|
|
|
|
if (res.code == "000000") {
|
|
|
|
if (res.code == "000000") {
|
|
|
|
res.rows.forEach((item) => {
|
|
|
|
res.rows.forEach((item) => {
|
|
|
|
item.baseSalary = item.baseSalary == null ? 0 : item.baseSalary * 1;
|
|
|
|
item.baseSalary = item.baseSalary == null ? 0 : item.baseSalary * 1;
|
|
|
|
@ -328,10 +244,10 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
created() {
|
|
|
|
created() {
|
|
|
|
let sDate = this.formatTime(new Date(), "YYYY-MM-DD 00:00:00");
|
|
|
|
let sDate = this.formatTime(new Date(), "YYYY-MM-DD");
|
|
|
|
let eDate = this.formatTime(new Date(), "YYYY-MM-DD 23:59:59");
|
|
|
|
let eDate = this.formatTime(new Date(), "YYYY-MM-DD");
|
|
|
|
this.days = [sDate, eDate];
|
|
|
|
this.days = [sDate, eDate];
|
|
|
|
// this.achiCommListsgroup();
|
|
|
|
this.getData();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|
|