修复优惠券

master
Sigo 3 years ago
parent 3b39a8ff73
commit ac287506cf

@ -4,7 +4,9 @@ import "babel-polyfill";
import "es6-promise/auto";
import ElementUI from "element-ui";
import "element-ui/lib/theme-chalk/index.css";
import { Message } from "element-ui";
import {
Message
} from "element-ui";
Vue.use(ElementUI);
import App from "./App.vue";
import store from "./store";
@ -22,13 +24,17 @@ import "./utils/dialog";
import "./plugins";
// import "./utils/directive/focus";
import echarts from "echarts";
import { getCookie } from "./utils/utils.js";
import {
getCookie
} from "./utils/utils.js";
import apiConfig from "../config/api.config.js";
import vueEsign from "vue-esign";
import animated from "animate.css"; // npm install animate.css --save安装在引入
import formatTime from "./utils/filters.js";
import arrDiff from "./utils/array.js";
import { Loading } from "element-ui";
import {
Loading
} from "element-ui";
import countdown from "./utils/countdown.js";
import "./utils/rem.js";
Vue.use(animated);
@ -38,11 +44,19 @@ import print from "vue-print-nb";
directives: {
print;
}
import { thousands } from "@/utils/index.js";
import {
thousands
} from "@/utils/index.js";
// 引入高精度精算
import { Decimal } from "decimal.js";
import {
Decimal
} from "decimal.js";
import {
parseTime
} from "./utils/index.js";
// 全局定义
Vue.prototype.$Decimal = Decimal;
Vue.prototype.$parseTime = parseTime;
import Vue from "vue";
import Router from "vue-router";
@ -54,7 +68,9 @@ Vue.use(VueAxios, axios);
axios.defaults.baseURL = apiConfig.baseUrl;
Vue.use(Print); //注册
import { message } from "./utils/resetMessage.js"; //现在提示弹窗每次只弹一条
import {
message
} from "./utils/resetMessage.js"; //现在提示弹窗每次只弹一条
// import VueParticles from 'vue-particles'
// Vue.use(VueParticles)
@ -88,7 +104,7 @@ export function noRepeat(arr) {
Vue.prototype.noRepeat = noRepeat;
// 全局过滤器--时间戳格式化时间//.padStart(2 , "0") 不足两位的用0填充
Vue.filter("dateFormat", function(originVal) {
Vue.filter("dateFormat", function (originVal) {
const dt = new Date(originVal);
const y = dt.getFullYear();
const m = (dt.getMonth() + 1 + "").padStart(2, "0");
@ -98,7 +114,7 @@ Vue.filter("dateFormat", function(originVal) {
const ss = (dt.getSeconds() + "").padStart(2, "0");
return `${y}-${m}-${d} ${hh}:${mm}:${ss}`;
});
Vue.filter("dateMonth", function(originVal) {
Vue.filter("dateMonth", function (originVal) {
const dt = new Date(originVal);
const y = dt.getFullYear();
const m = (dt.getMonth() + 1 + "").padStart(2, "0");
@ -108,10 +124,10 @@ Vue.filter("dateMonth", function(originVal) {
const ss = (dt.getSeconds() + "").padStart(2, "0");
return `${y}-${m}-${d}`;
});
Vue.filter("phone", function(phone) {
Vue.filter("phone", function (phone) {
return phone.substring(0, 3) + "****" + phone.substring(phone.length - 4);
});
Vue.filter("identityNum", function(identityNum) {
Vue.filter("identityNum", function (identityNum) {
return (
identityNum.substring(0, 4) +
"**************" +
@ -119,11 +135,11 @@ Vue.filter("identityNum", function(identityNum) {
);
});
Vue.filter("money", function(money) {
Vue.filter("money", function (money) {
return (money * 1).toFixed(2);
});
Vue.prototype.openLoading = function() {
Vue.prototype.openLoading = function () {
const loading = this.$loading({
// 声明一个loading对象
lock: true, // 是否锁屏
@ -134,7 +150,7 @@ Vue.prototype.openLoading = function() {
body: true,
customClass: "mask" // 遮罩层新增类名
});
setTimeout(function() {
setTimeout(function () {
// 设定定时器超时5S后自动关闭遮罩层避免请求失败时遮罩层一直存在的问题
loading.close(); // 关闭遮罩层
}, 5000);

@ -1,5 +1,5 @@
<template>
<el-dialog title="公众号二维码" :visible.sync="dialogFormVisible" :close-on-click-modal="false" width="400px" @close="close" v-dialogDrag>
<el-dialog title="公众号二维码" :visible.sync="dialogFormVisible" :close-on-click-modal="false" width="420px" @close="close" v-dialogDrag>
<div class="box" style="width: 400px; height: 400px; background-color: #FFF;">
<el-image style="width: 100%; height: 100%" :src="qrCode" fit="fill" v-if="codeNumber===1"></el-image>
<div class="img" v-if="codeNumber===2||codeNumber===3">

@ -30,10 +30,10 @@
<el-input class="form-width-ms border-only-bottom border" v-model="form.orderNums"></el-input>
</el-form-item> -->
<el-form-item label="男客:">
<el-input-number class="form-width-xs" size="small" v-model="form.man" @change="handleChange" :min="0" :max="10" label="男客数量"></el-input-number>
<el-input-number class="form-width-xs" size="small" v-model="form.man" :min="0" :max="10" label="男客数量"></el-input-number>
</el-form-item>
<el-form-item label="女客:">
<el-input-number class="form-width-xs" size="small" v-model="form.woman" @change="handleChange" :min="0" :max="10" label="女客数量"></el-input-number>
<el-input-number class="form-width-xs" size="small" v-model="form.woman" :min="0" :max="10" label="女客数量"></el-input-number>
</el-form-item>
</div>
<div>
@ -175,7 +175,7 @@
{{ scope.row.payMoney}}
<i class="el-icon-edit text-cyan"></i>
</div>
<el-input v-else v-focus size="samll" @blur="endEdit(scope.row, scope.$index)" @change="endEdit(scope.row, scope.$index)" v-model="scope.row.payMoney" class="form-input-width-xs" type="number" ></el-input>
<el-input v-else v-focus size="samll" @blur="endEdit(scope.row, scope.$index)" @change="endEdit(scope.row, scope.$index)" v-model="scope.row.payMoney" class="form-input-width-xs" type="number"></el-input>
</template>
</el-table-column>
</el-table>
@ -247,7 +247,6 @@ export default {
).toFixed(2) * 1;
let debtMoney = (item.amount - item.cashAmount).toFixed(2) * 1;
let cardMoney = (form.offsetMoney + form.offsetGiftMoney).toFixed(2) * 1;
console.log();
if (debtMoney > 0) {
if (cardMoney < debtMoney) {
form.spendMoney = form.cardOver;
@ -534,7 +533,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -642,7 +641,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -695,7 +694,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -714,7 +713,6 @@ export default {
this.sumMoney();
},
handleChange() {},
rowClassName({ row, rowIndex }) {
row.index = rowIndex;
},

@ -22,8 +22,7 @@
<el-button @click="openStaffList" size="mini" type="primary" style="margin-left: 16px;"> 员工列表</el-button>
</div>
</div>
<div class="flex justify-start align-start">
</div>
<div class="flex justify-start align-start"></div>
<div class="flex justify-center align-start flex-wrap room-body">
<div class="room margin-right margin-top" v-for="(item,index) in list" :key="index">
<div class="room-header flex justify-between align-center text-bold" :class="item.onState==0?'bg-green':item.onState==1?'bg-blue':item.onState==2?'bg-yellow':item.onState==3?'bg-red':'bg-blue'">
@ -207,6 +206,12 @@ export default {
};
},
methods: {
//
show() {
this.getData();
this.getPage();
this.getStaff();
},
editStaffState(item, number) {
console.log(item);
editsServiceOrder({ id: item.id, state: number }).then((res) => {
@ -219,7 +224,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -285,12 +290,12 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
})
.catch(() => {});
.catch(() => { });
},
openAll(item) {
this.$emit("roomData", item.showList);
@ -306,7 +311,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -324,7 +329,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -341,7 +346,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -383,7 +388,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -408,17 +413,12 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
},
//
show() {
this.getData();
this.getPage();
this.getStaff();
},
openRoom(item) {
if (item.onState == 2) {
} else {
@ -450,7 +450,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -482,7 +482,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
});
@ -562,7 +562,7 @@ export default {
confirmButtonClass: "confirmbtnFalses",
type: "warning",
center: true,
callback: (action) => {},
callback: (action) => { },
});
}
})

@ -2,13 +2,13 @@
<div class="head-room">
<el-tabs v-role="500111" v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="开单" name="开单">
<bing ref="bing" @bingData="bingData"></bing>
<bing ref="bing"></bing>
</el-tab-pane>
<el-tab-pane label="房间" name="房间">
<room ref="room" @roomData="roomData"></room>
</el-tab-pane>
<el-tab-pane label="历史单据" name="历史单据">
<order ref="order" @orderData="orderData"></order>
<order ref="order"></order>
</el-tab-pane>
</el-tabs>
</div>
@ -41,8 +41,6 @@ export default {
this.$refs.order.show();
}
},
bingData(v) {},
orderData(v) {},
roomData(v) {
if (v) {
console.log("kaidan ");

@ -1,6 +1,6 @@
.print-table {
font-size: 14px !important;
height:30px;
height: 30px;
}
.el-table {
@ -12,9 +12,6 @@
width: 100%;
}
.el-table--border th.gutter:last-of-type {
display: block !important;
width: 17px !important;
@ -36,7 +33,7 @@
}
.line-height {
line-height: 100%
line-height: 100%;
}
.border-top {
@ -137,13 +134,11 @@
.form-width-xxl {
width: 530px !important;
cursor: pointer;
}
.form-width-xxxl {
width: 860px !important;
cursor: pointer;
}
.pointer {
@ -265,6 +260,13 @@
border-radius: 25px;
}
/* ==================
==================== */
.width-ms {
width: 210px;
}
/* el-table */
.el-table .el-table__row .el-date-editor {
width: 100%;
@ -284,7 +286,7 @@
background: #74bafc;
}
.el-form .normal .el-radio__input.is-checked+.el-radio__label {
.el-form .normal .el-radio__input.is-checked + .el-radio__label {
color: #74bafc;
}
@ -293,7 +295,7 @@
background: #f56c6c;
}
.el-form .blockUp .el-radio__input.is-checked+.el-radio__label {
.el-form .blockUp .el-radio__input.is-checked + .el-radio__label {
color: #f56c6c;
}
@ -347,7 +349,7 @@ input::-webkit-inner-spin-button {
color: #fff !important;
font-size: 20px !important;
font-weight: 700 !important;
font-family: '幼圆';
font-family: "幼圆";
background-color: #389efd;
}
@ -372,8 +374,6 @@ input::-webkit-inner-spin-button {
height: 70px;
}
.my-pro-bottom {
height: 50px;
width: 100px;
@ -388,7 +388,6 @@ input::-webkit-inner-spin-button {
/*伸缩盒子的子元素排列:从上到下*/
}
.expand-card:hover {
padding-top: 1px;
z-index: 9;
@ -418,7 +417,6 @@ input::-webkit-inner-spin-button {
.el-table--border th.gutter:last-of-type {
/* border-bottom: 1px solid rgb(185, 185, 185) !important; */
/* 横线颜色 */
}
.el-table--border td,
@ -457,7 +455,6 @@ input::-webkit-inner-spin-button {
padding: 0 8px;
}
/* 滑动条 */
::-webkit-scrollbar {
width: 8px;
@ -475,7 +472,6 @@ input::-webkit-inner-spin-button {
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #ededed;
border-radius: 5px;
}
.el-form-item__error {

Loading…
Cancel
Save