Merge branch 'multi-store' of https://e.coding.net/g-cphe0354/cashier/cashier-web into wwz
This commit is contained in:
commit
2922de551a
|
|
@ -8,13 +8,7 @@
|
|||
chaozg
|
||||
chaozg123
|
||||
|
||||
## 测试宝塔
|
||||
|
||||
<http://101.37.12.135:19928/mianban>
|
||||
chaozg
|
||||
chaozg123
|
||||
|
||||
## 本地服务器(192.168.1.31)linux部署
|
||||
## 本地测试服务器(192.168.1.31)linux部署
|
||||
|
||||
映射地址
|
||||
<https://fv901fw8033.vicp.fun/>
|
||||
|
|
|
|||
|
|
@ -648,7 +648,7 @@ export const useCartsStore = defineStore("carts", () => {
|
|||
return ElMessage.warning(msg.message || '该商品已存在')
|
||||
}
|
||||
const skuData = getProductDetails({ product_id: msg.data.product_id, sku_id: msg.data.sku_id })
|
||||
if (skuData) {
|
||||
if (skuData || msg.data.is_temporary) {
|
||||
const newGoods = { ...skuData, ...msg.data }
|
||||
console.log('newGoods', newGoods)
|
||||
list.value.push(newGoods)
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ export const useUserStore = defineStore("user", () => {
|
|||
console.log(userInfo)
|
||||
console.log(data)
|
||||
localStorage.setItem("shopId", "" + data.id);
|
||||
Object.assign(userInfo.value, { ...data, roles: [], promissionList: [], shopId: userInfo.value.shopId });
|
||||
Object.assign(userInfo.value, { ...data, roles: [], promissionList: [], shopId: data.id });
|
||||
resolve(userInfo.value);
|
||||
})
|
||||
.catch((error) => {
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@
|
|||
<span>营业</span>
|
||||
</div>
|
||||
<div class="u-flex" style="flex-wrap: wrap">
|
||||
<el-select v-model="storeId" placeholder="选择分店" style="width: 200px; margin-right: 10px;">
|
||||
<el-select v-if="isHeadShop == 1" v-model="shopId" placeholder="选择分店" style="width: 200px; margin-right: 10px;" @change="shopChange">
|
||||
<el-option v-for="item in branchList" :key="item.shopId" :label="item.shopName" :value="item.shopId" />
|
||||
</el-select>
|
||||
<div class="time_wrap u-flex" style="flex-shrink: 0">
|
||||
|
|
@ -67,7 +67,7 @@
|
|||
</el-radio-group>
|
||||
<div class="u-flex">
|
||||
<el-date-picker v-if="timeValue == 'custom'" v-model="query.createdAt" type="daterange"
|
||||
range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="YYYY-MM-DD "
|
||||
range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="YYYY-MM-DD HH:mm:ss"
|
||||
@change="summarytrade" />
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -391,7 +391,7 @@ export default {
|
|||
},
|
||||
],
|
||||
branchList: [],
|
||||
storeId: null,
|
||||
shopId: null,
|
||||
trade: {},
|
||||
formatDecimal,
|
||||
topData: "",
|
||||
|
|
@ -428,6 +428,8 @@ export default {
|
|||
},
|
||||
tradeVip: "",
|
||||
tradeCount: "",
|
||||
isHeadShop: JSON.parse(localStorage.getItem("userInfo")).isHeadShop
|
||||
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
|
|
@ -486,10 +488,18 @@ export default {
|
|||
// this.initCardUserChart();
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 获取分店列表
|
||||
*/
|
||||
async geiShopList() {
|
||||
let res = await ShopApi.getBranchList()
|
||||
this.branchList = res;
|
||||
},
|
||||
shopChange(){
|
||||
this.summarytrade();
|
||||
this.lineChartTypeChange(this.lineChartType)
|
||||
this.dateProduct()
|
||||
},
|
||||
// 切换时间
|
||||
timeChange(e) {
|
||||
const format = ["YYYY-MM-DD 00:00:00", "YYYY-MM-DD 23:59:59"];
|
||||
|
|
@ -539,7 +549,9 @@ export default {
|
|||
break;
|
||||
case "custom":
|
||||
// 自定义
|
||||
this.query.createdAt = [];
|
||||
this.query.createdAt = [
|
||||
dayjs().add(-30, "d").format(format[0]),
|
||||
dayjs().format(format[1]),];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
@ -552,9 +564,13 @@ export default {
|
|||
async summarytrade() {
|
||||
try {
|
||||
this.tradeLoading = true;
|
||||
if( this.query.createdAt[1] ){
|
||||
this.query.createdAt.splice(1,1,this.query.createdAt[1].replace("00:00:00","23:59:59"))
|
||||
}
|
||||
const res = await dataSummaryApi.trade({
|
||||
beginDate: this.query.createdAt[0],
|
||||
endDate: this.query.createdAt[1],
|
||||
shopId: this.shopId
|
||||
});
|
||||
this.trade = res;
|
||||
this.tradeLoading = false;
|
||||
|
|
@ -878,7 +894,7 @@ export default {
|
|||
async dateAmount() {
|
||||
try {
|
||||
this.saleLoading = true;
|
||||
const res = await dataSummaryApi.dateAmount({ day: this.saleActive });
|
||||
const res = await dataSummaryApi.dateAmount({ day: this.saleActive,shopId: this.shopId });
|
||||
const data = res.total.map((item) => {
|
||||
return {
|
||||
orderAmount: item.orderAmount,
|
||||
|
|
@ -907,6 +923,7 @@ export default {
|
|||
day: this.saleTableActive,
|
||||
page: this.saleTablePage,
|
||||
size: this.saleTableSize,
|
||||
shopId: this.shopId
|
||||
});
|
||||
this.saleTable = res.records;
|
||||
this.saleTableTotal = res.totalRow * 1;
|
||||
|
|
@ -922,7 +939,7 @@ export default {
|
|||
async datePayType() {
|
||||
try {
|
||||
this.payChartLoading = true;
|
||||
const res = await dataSummaryApi.datePayType({ day: this.saleActive });
|
||||
const res = await dataSummaryApi.datePayType({ day: this.saleActive,shopId: this.shopId });
|
||||
const data = res.countPayType.map((item) => {
|
||||
return {
|
||||
value: item.count,
|
||||
|
|
|
|||
|
|
@ -11,8 +11,8 @@
|
|||
<el-input placeholder="商品名称" v-model="query.productName" />
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item>
|
||||
<el-select v-model="storeId" placeholder="选择分店" style="width: 200px; margin-right: 10px">
|
||||
<el-form-item v-if="isHeadShop == 1">
|
||||
<el-select v-model="shopId" placeholder="选择分店" style="width: 200px; margin-right: 10px" @change="getCategory">
|
||||
<el-option v-for="item in branchList" :key="item.shopId" :label="item.shopName" :value="item.shopId" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
|
@ -34,7 +34,7 @@
|
|||
<el-radio-button value="custom">自定义</el-radio-button>
|
||||
</el-radio-group>
|
||||
<el-date-picker class="u-m-l-10" v-model="query.createdAt" type="daterange" range-separator="至"
|
||||
start-placeholder="开始日期" end-placeholder="结束日期" value-format="YYYY-MM-DD"
|
||||
start-placeholder="开始日期" end-placeholder="结束日期" value-format="YYYY-MM-DD HH:mm:ss"
|
||||
v-if="timeValue == 'custom'"></el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
|
|
@ -157,6 +157,7 @@
|
|||
<script>
|
||||
import saleSummaryApi from "@/api/order/sale-summary";
|
||||
import categoryApi from "@/api/product/productclassification";
|
||||
import ShopApi from "@/api/account/shop";
|
||||
import dayjs from "dayjs";
|
||||
import { downloadFile } from "@/utils/index";
|
||||
|
||||
|
|
@ -183,7 +184,9 @@ export default {
|
|||
payCount: "",
|
||||
payCountTotal: 0,
|
||||
branchList: [],
|
||||
storeId: null,
|
||||
shopId: null,
|
||||
isHeadShop: JSON.parse(localStorage.getItem("userInfo")).isHeadShop
|
||||
|
||||
};
|
||||
},
|
||||
filters: {
|
||||
|
|
@ -212,10 +215,12 @@ export default {
|
|||
// 获取商品分类
|
||||
async getCategory() {
|
||||
try {
|
||||
this.query.prodCategoryId = ""
|
||||
const res = await categoryApi.getList({
|
||||
page: 1,
|
||||
size: 200,
|
||||
orderBy: "name asc",
|
||||
shopId: this.shopId
|
||||
});
|
||||
this.categorys = res;
|
||||
} catch (error) {
|
||||
|
|
@ -225,12 +230,15 @@ export default {
|
|||
// 获取订单汇总
|
||||
async daycount() {
|
||||
try {
|
||||
if (this.query.createdAt[1]) {
|
||||
this.query.createdAt.splice(1, 1, this.query.createdAt[1].replace("00:00:00", "23:59:59"))
|
||||
}
|
||||
const res = await saleSummaryApi.count({
|
||||
beginDate: this.query.createdAt[0],
|
||||
endDate: this.query.createdAt[1],
|
||||
prodCategoryId: this.query.prodCategoryId,
|
||||
productName: this.query.productName,
|
||||
|
||||
shopId: this.shopId,
|
||||
type: this.orderType,
|
||||
});
|
||||
this.payCount = res;
|
||||
|
|
@ -242,11 +250,15 @@ export default {
|
|||
async downloadHandle() {
|
||||
try {
|
||||
this.downloadLoading = true;
|
||||
if (this.query.createdAt[1]) {
|
||||
this.query.createdAt.splice(1, 1, this.query.createdAt[1].replace("00:00:00", "23:59:59"))
|
||||
}
|
||||
const file = await saleSummaryApi.export({
|
||||
beginDate: this.query.createdAt[0],
|
||||
endDate: this.query.createdAt[1],
|
||||
prodCategoryId: this.query.prodCategoryId,
|
||||
productName: this.query.productName,
|
||||
shopId: this.shopId
|
||||
});
|
||||
downloadFile(file, "数据", "xlsx");
|
||||
this.downloadLoading = false;
|
||||
|
|
@ -276,6 +288,9 @@ export default {
|
|||
this.tableData.loading = true;
|
||||
try {
|
||||
this.daycount();
|
||||
if (this.query.createdAt[1]) {
|
||||
this.query.createdAt.splice(1, 1, this.query.createdAt[1].replace("00:00:00", "23:59:59"))
|
||||
}
|
||||
const res = await saleSummaryApi.page({
|
||||
page: this.tableData.page,
|
||||
size: this.tableData.size,
|
||||
|
|
@ -284,6 +299,7 @@ export default {
|
|||
endDate: this.query.createdAt[1],
|
||||
productName: this.query.productName,
|
||||
prodCategoryId: this.query.prodCategoryId,
|
||||
shopId: this.shopId
|
||||
});
|
||||
this.tableData.loading = false;
|
||||
this.tableData.data = res.records;
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
</el-tabs> -->
|
||||
<div class="head-container">
|
||||
<el-form :model="query" inline label-position="left">
|
||||
<div class="u-flex gap-10">
|
||||
<div class="u-flex gap-10" style="flex-wrap: wrap;">
|
||||
<el-radio-group v-model="timeValue" @change="timeChange">
|
||||
<el-radio-button value="">全部</el-radio-button>
|
||||
<el-radio-button value="0">今天</el-radio-button>
|
||||
|
|
@ -18,14 +18,14 @@
|
|||
<el-radio-button value="custom">自定义</el-radio-button>
|
||||
</el-radio-group>
|
||||
<div>
|
||||
<el-date-picker
|
||||
v-model="query.createdAt"
|
||||
type="daterange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
value-format="YYYY-MM-DD"
|
||||
></el-date-picker>
|
||||
<el-date-picker v-model="query.createdAt" type="daterange" range-separator="至" start-placeholder="开始日期"
|
||||
end-placeholder="结束日期" value-format="YYYY-MM-DD HH:mm:ss"></el-date-picker>
|
||||
</div>
|
||||
<div>
|
||||
<el-select v-model="shopId" v-if="isHeadShop == 1" placeholder="选择分店"
|
||||
style="width: 200px; margin-right: 10px">
|
||||
<el-option v-for="item in branchList" :key="item.shopId" :label="item.shopName" :value="item.shopId" />
|
||||
</el-select>
|
||||
</div>
|
||||
<div>
|
||||
<el-button type="primary" @click="getTableData">查询</el-button>
|
||||
|
|
@ -100,6 +100,7 @@
|
|||
|
||||
<script>
|
||||
import tableSummaryApi from "@/api/order/table-summary";
|
||||
import ShopApi from "@/api/account/shop";
|
||||
import dayjs from "dayjs";
|
||||
import { downloadFile } from "@/utils/index";
|
||||
|
||||
|
|
@ -125,6 +126,9 @@ export default {
|
|||
downloadLoading: false,
|
||||
payCountList: "",
|
||||
payCountTotal: 0,
|
||||
shopId: null,
|
||||
branchList: [],
|
||||
isHeadShop: JSON.parse(localStorage.getItem("userInfo")).isHeadShop
|
||||
};
|
||||
},
|
||||
filters: {
|
||||
|
|
@ -135,8 +139,16 @@ export default {
|
|||
mounted() {
|
||||
this.resetQuery = { ...this.query };
|
||||
this.getTableData();
|
||||
this.geiShopList();
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 获取分店列表
|
||||
*/
|
||||
async geiShopList() {
|
||||
let res = await ShopApi.getBranchList()
|
||||
this.branchList = res;
|
||||
},
|
||||
//携带table id跳转到订单列表页面
|
||||
toTableOrderList(data) {
|
||||
// console.log(data)
|
||||
|
|
@ -152,9 +164,13 @@ export default {
|
|||
async downloadHandle() {
|
||||
try {
|
||||
this.downloadLoading = true;
|
||||
if (this.query.createdAt[1]) {
|
||||
this.query.createdAt.splice(1, 1, this.query.createdAt[1].replace("00:00:00", "23:59:59"))
|
||||
}
|
||||
const file = await tableSummaryApi.export({
|
||||
beginDate: this.query.createdAt[0],
|
||||
endDate: this.query.createdAt[1],
|
||||
shopId: this.shopId
|
||||
});
|
||||
downloadFile(file, "数据", "xlsx");
|
||||
this.downloadLoading = false;
|
||||
|
|
@ -183,11 +199,15 @@ export default {
|
|||
async getTableData() {
|
||||
this.tableData.loading = true;
|
||||
try {
|
||||
if (this.query.createdAt[1]) {
|
||||
this.query.createdAt.splice(1, 1, this.query.createdAt[1].replace("00:00:00", "23:59:59"))
|
||||
}
|
||||
const res = await tableSummaryApi.list({
|
||||
page: this.tableData.page,
|
||||
size: this.tableData.size,
|
||||
beginDate: this.query.createdAt[0],
|
||||
endDate: this.query.createdAt[1],
|
||||
shopId: this.shopId
|
||||
});
|
||||
this.tableData.loading = false;
|
||||
this.tableData.data = res;
|
||||
|
|
|
|||
|
|
@ -6,15 +6,16 @@
|
|||
<el-input v-model="state.form.shopName" placeholder="请输入门店名称"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="店铺类型">
|
||||
<el-radio-group v-model="state.form.shopType" :disabled="state.form.id || state.type == 'addBranch'">
|
||||
<el-radio-group v-model="state.form.shopType" :disabled="state.isEdit || state.type == 'addBranch'">
|
||||
<el-radio-button value="only">单店</el-radio-button>
|
||||
<el-radio-button value="chain">连锁店</el-radio-button>
|
||||
<el-radio-button value="join">加盟店</el-radio-button>
|
||||
</el-radio-group>
|
||||
<div class="tips">请谨慎修改!!!</div>
|
||||
<div class="tips"><el-alert title="请谨慎修改" type="warning" size="7" effect="dark" show-icon :closable="false"/></div>
|
||||
|
||||
</el-form-item>
|
||||
<el-form-item label="是否为主店" prop="isHeadShop" v-if="state.form.shopType != 'only'">
|
||||
<el-radio-group v-model="state.form.isHeadShop" @change=" state.form.mainId = ''" :disabled="state.form.id || state.type == 'addBranch'">
|
||||
<el-radio-group v-model="state.form.isHeadShop" @change=" state.form.mainId = ''" :disabled="state.isEdit || state.type == 'addBranch'">
|
||||
<el-radio :value="1">是</el-radio>
|
||||
<el-radio :value="0">否</el-radio>
|
||||
</el-radio-group>
|
||||
|
|
@ -22,7 +23,7 @@
|
|||
<el-form-item label="选择主店" prop="mainId" v-if="state.form.isHeadShop == '0'&&state.form.shopType != 'only'">
|
||||
<!-- <el-form-item label="主店账号" prop="mainId" v-if="state.form.shopType != 'only'"> -->
|
||||
<el-select v-model="state.form.mainId" placeholder="请选择主店铺" filterable reserve-keyword
|
||||
:remote-method="getTableData" :loading="state.shopListLoading" :disabled="state.form.id || state.type == 'addBranch'">
|
||||
:remote-method="getTableData" :loading="state.shopListLoading" :disabled="state.isEdit || state.type == 'addBranch'">
|
||||
<el-option v-for="item in state.shopList" :label="`${item.shopName}`" :value="item.id"
|
||||
:key="item.id"></el-option>
|
||||
</el-select>
|
||||
|
|
@ -41,14 +42,16 @@
|
|||
<el-radio-button value="before">先付费</el-radio-button>
|
||||
<el-radio-button value="after">后付费</el-radio-button>
|
||||
</el-radio-group>
|
||||
<div class="tips">请谨慎修改!!!</div>
|
||||
<div class="tips"><el-alert title="请谨慎修改" type="warning" size="7" effect="dark" show-icon :closable="false"/></div>
|
||||
|
||||
</el-form-item>
|
||||
<el-form-item label="管理方式" v-if="state.form.shopType != 'only'">
|
||||
<el-radio-group v-model="state.form.tubeType">
|
||||
<el-radio-button :value="0">不可直接管理</el-radio-button>
|
||||
<el-radio-button :value="1">直接管理</el-radio-button>
|
||||
</el-radio-group>
|
||||
<div class="tips">请谨慎修改!!!</div>
|
||||
<div class="tips"><el-alert title="请谨慎修改" type="warning" size="7" effect="dark" show-icon :closable="false"/></div>
|
||||
|
||||
</el-form-item>
|
||||
<el-form-item label="试用/正式">
|
||||
<el-radio-group v-model="state.form.profiles">
|
||||
|
|
@ -297,6 +300,7 @@ const state = reactive({
|
|||
},
|
||||
shopListLoading: false,
|
||||
shopList: [],
|
||||
isEdit: false,
|
||||
});
|
||||
onBeforeMount(async () => {
|
||||
const res = await initMapLoad();
|
||||
|
|
@ -387,7 +391,9 @@ function show(obj,type) {
|
|||
}
|
||||
console.log(state.form);
|
||||
console.log(state.type);
|
||||
|
||||
if( state.form.shopType != 'only'){
|
||||
state.isEdit = true
|
||||
}
|
||||
for (let key in state.rules) {
|
||||
if (key === "accountName") {
|
||||
if (obj.id) {
|
||||
|
|
@ -403,11 +409,12 @@ function close() {
|
|||
state.dialogVisible = false;
|
||||
state.form = { ...state.resetForm };
|
||||
state.type = "";
|
||||
|
||||
state.isEdit = false
|
||||
}
|
||||
function reset() {
|
||||
state.form = { ...state.resetForm };
|
||||
state.type = "";
|
||||
state.isEdit = false
|
||||
}
|
||||
|
||||
let ElMap = undefined;
|
||||
|
|
@ -544,4 +551,7 @@ defineExpose({
|
|||
.amap-sug-result {
|
||||
z-index: 2000;
|
||||
}
|
||||
.tips{
|
||||
margin-left: 10px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ const searchConfig: ISearchConfig = {
|
|||
{
|
||||
type: "select",
|
||||
label: "分店选择",
|
||||
prop: "storeId",
|
||||
prop: "shopId",
|
||||
attrs: {
|
||||
placeholder: "请选择分店",
|
||||
clearable: true,
|
||||
|
|
|
|||
|
|
@ -2,24 +2,12 @@
|
|||
<div class="app-container">
|
||||
<!-- 列表 -->
|
||||
<!-- 搜索 -->
|
||||
<page-search
|
||||
ref="searchRef"
|
||||
:search-config="searchConfig"
|
||||
@query-click="handleQueryClick"
|
||||
@reset-click="handleResetClick"
|
||||
/>
|
||||
<page-search ref="searchRef" :search-config="searchConfig" @query-click="handleQueryClick"
|
||||
@reset-click="handleResetClick" />
|
||||
<!-- 列表 -->
|
||||
<page-content
|
||||
ref="contentRef"
|
||||
:content-config="contentConfig"
|
||||
@add-click="handleAddClick"
|
||||
@edit-click="handleEditClick"
|
||||
@export-click="handleExportClick"
|
||||
@search-click="handleSearchClick"
|
||||
@toolbar-click="handleToolbarClick"
|
||||
@operat-click="handleOperatClick"
|
||||
@filter-change="handleFilterChange"
|
||||
>
|
||||
<page-content ref="contentRef" :content-config="contentConfig" @add-click="handleAddClick"
|
||||
@edit-click="handleEditClick" @export-click="handleExportClick" @search-click="handleSearchClick"
|
||||
@toolbar-click="handleToolbarClick" @operat-click="handleOperatClick" @filter-change="handleFilterChange">
|
||||
<template #status="scope">
|
||||
<el-tag :type="scope.row[scope.prop] == 1 ? 'success' : 'info'">
|
||||
{{ scope.row[scope.prop] == 1 ? "启用" : "禁用" }}
|
||||
|
|
@ -33,11 +21,7 @@
|
|||
</template>
|
||||
<template #mobile="scope">
|
||||
<el-text>{{ scope.row[scope.prop] }}</el-text>
|
||||
<copy-button
|
||||
v-if="scope.row[scope.prop]"
|
||||
:text="scope.row[scope.prop]"
|
||||
style="margin-left: 2px"
|
||||
/>
|
||||
<copy-button v-if="scope.row[scope.prop]" :text="scope.row[scope.prop]" style="margin-left: 2px" />
|
||||
</template>
|
||||
</page-content>
|
||||
|
||||
|
|
@ -47,12 +31,8 @@
|
|||
<h3 style="color: rgb(63, 158, 255)">收银机权限设置</h3>
|
||||
<div>
|
||||
<el-checkbox-group v-model="addPagePathIdList">
|
||||
<el-checkbox
|
||||
v-for="(item, index) in pagePathIdLists"
|
||||
:key="index"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
/>
|
||||
<el-checkbox v-for="(item, index) in pagePathIdLists" :key="index" :value="item.value"
|
||||
:label="item.label" />
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<h3 style="color: rgb(63, 158, 255)">员工权限设置</h3>
|
||||
|
|
@ -62,21 +42,13 @@
|
|||
</page-modal>
|
||||
|
||||
<!-- 编辑 -->
|
||||
<page-modal
|
||||
ref="editModalRef"
|
||||
:modal-config="editModalConfig"
|
||||
@submit-click="handleSubmitClick"
|
||||
>
|
||||
<page-modal ref="editModalRef" :modal-config="editModalConfig" @submit-click="handleSubmitClick">
|
||||
<template #formFooter>
|
||||
<h3 style="color: rgb(63, 158, 255)">收银机权限设置</h3>
|
||||
<div>
|
||||
<el-checkbox-group v-model="editPagePathIdList">
|
||||
<el-checkbox
|
||||
v-for="(item, index) in pagePathIdLists"
|
||||
:key="index"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
/>
|
||||
<el-checkbox v-for="(item, index) in pagePathIdLists" :key="index" :value="item.value"
|
||||
:label="item.label" />
|
||||
</el-checkbox-group>
|
||||
</div>
|
||||
<h3 style="color: rgb(63, 158, 255)">员工权限设置</h3>
|
||||
|
|
@ -143,6 +115,9 @@ const oldeditSubmitFunc = editModalConfig.formAction;
|
|||
// 数据初始化
|
||||
async function init() {
|
||||
// 覆写添加确定方法
|
||||
if (JSON.parse(localStorage.getItem('userInfo') || '{}').isHeadShop == 0) {
|
||||
searchConfig.formItems.splice(0, 1)
|
||||
}
|
||||
addModalConfig.formAction = function (data) {
|
||||
return ShopStaffApi.add({
|
||||
...data,
|
||||
|
|
|
|||
|
|
@ -383,12 +383,18 @@ async function createOrder(key) {
|
|||
// });
|
||||
// return;
|
||||
// }
|
||||
const payArr = ["wx-aiplay", "cash", "to-pay"];
|
||||
const payArr = ["wx-aiplay", "cash", "to-pay", "more-pay"];
|
||||
if (payArr.includes(key) && carts.isEmpty && carts.oldOrder.id) {
|
||||
showOrder.value = true;
|
||||
nextTick(() => {
|
||||
refOrder.value.nowPayClick(key || "");
|
||||
});
|
||||
if (key != "more-pay") {
|
||||
nextTick(() => {
|
||||
if (key == "wx-aiplay") {
|
||||
refOrder.value.nowPayClick("scanCode");
|
||||
} else {
|
||||
refOrder.value.nowPayClick(key || "");
|
||||
}
|
||||
});
|
||||
}
|
||||
return;
|
||||
}
|
||||
try {
|
||||
|
|
|
|||
Loading…
Reference in New Issue