five
This commit is contained in:
parent
90f7127318
commit
5a07571cfe
|
@ -75,6 +75,11 @@ const routes = [
|
||||||
name: '审核美甲师',
|
name: '审核美甲师',
|
||||||
component: () => import('../views/employee/verify/index.vue'),
|
component: () => import('../views/employee/verify/index.vue'),
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/qiangdan',
|
||||||
|
name: '抢单',
|
||||||
|
component: () => import('../views/businessBag/qiangdan/qiangdan.vue'),
|
||||||
|
},
|
||||||
{
|
{
|
||||||
path: '/modifyPassword',
|
path: '/modifyPassword',
|
||||||
name: '修改密码',
|
name: '修改密码',
|
||||||
|
|
|
@ -1,11 +1,10 @@
|
||||||
// 引入axios
|
// 引入axios
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import {request} from "axios";
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let baseUrl='http://localhost:8081/api/';
|
// let baseUrl='http://localhost:8081/api/';
|
||||||
//let baseUrl='http://154.8.193.216:1107/api/';
|
let baseUrl='http://154.8.193.216:1107/api/';
|
||||||
// 创建axios实例
|
// 创建axios实例
|
||||||
const httpService = axios.create({
|
const httpService = axios.create({
|
||||||
// url前缀-'http:xxx.xxx'
|
// url前缀-'http:xxx.xxx'
|
||||||
|
|
|
@ -17,3 +17,16 @@ export function DetailformattedDate(timestamp){
|
||||||
const formattedDate = `${year}-${month}-${day} ${hour}:${minute}:${second}`;
|
const formattedDate = `${year}-${month}-${day} ${hour}:${minute}:${second}`;
|
||||||
return formattedDate
|
return formattedDate
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function verifyPerson(){
|
||||||
|
|
||||||
|
let userInfoJson = window.sessionStorage.getItem("USER_LOGIN_STATE");
|
||||||
|
// console.log(userInfoJson)
|
||||||
|
if(JSON.parse(userInfoJson).userRole==1)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}else{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
//console.log(ax.value)
|
||||||
|
}
|
|
@ -22,15 +22,15 @@
|
||||||
<el-form-item label="店铺详细地址" prop="address">
|
<el-form-item label="店铺详细地址" prop="address">
|
||||||
{{form.address}}
|
{{form.address}}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="门店简介" prop="businessProfile">
|
<!-- <el-form-item label="门店简介" prop="businessProfile">-->
|
||||||
{{form.businessProfile}}
|
<!-- {{form.businessProfile}}-->
|
||||||
</el-form-item>
|
<!-- </el-form-item>-->
|
||||||
<el-form-item label="商家相册" prop="businessImages">
|
<!-- <el-form-item label="商家相册" prop="businessImages">-->
|
||||||
{{form.businessImages}}
|
<!-- {{form.businessImages}}-->
|
||||||
</el-form-item>
|
<!-- </el-form-item>-->
|
||||||
<el-form-item label="分类ID" prop="categoryId">
|
<!-- <el-form-item label="分类ID" prop="categoryId">-->
|
||||||
{{form.categoryId}}
|
<!-- {{form.categoryId}}-->
|
||||||
</el-form-item>
|
<!-- </el-form-item>-->
|
||||||
<el-form-item label="店主名" prop="shopkeeper">
|
<el-form-item label="店主名" prop="shopkeeper">
|
||||||
{{form.shopkeeper}}
|
{{form.shopkeeper}}
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
|
@ -29,27 +29,27 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="businessPhone" label="电话号码" width="120" />
|
<el-table-column prop="businessPhone" label="电话号码" width="120" />
|
||||||
<el-table-column prop="state" label="状态" width="80">
|
<!-- <el-table-column prop="state" label="状态" width="80">-->
|
||||||
<template v-slot="scope">
|
<!-- <template v-slot="scope">-->
|
||||||
<div v-if="scope.row.state===0" style="color: red">
|
<!-- <div v-if="scope.row.state===0" style="color: red">-->
|
||||||
禁用
|
<!-- 禁用-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
<div style="color: lawngreen" v-else>
|
<!-- <div style="color: lawngreen" v-else>-->
|
||||||
启用
|
<!-- 启用-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
|
|
||||||
</template>
|
<!-- </template>-->
|
||||||
</el-table-column>
|
<!-- </el-table-column>-->
|
||||||
<el-table-column prop="storeStatus" label="店铺状态" width="80">
|
<!-- <el-table-column prop="storeStatus" label="店铺状态" width="80">-->
|
||||||
<template v-slot="scope">
|
<!-- <template v-slot="scope">-->
|
||||||
<div v-if="scope.row.storeStatus===0" style="color: red">
|
<!-- <div v-if="scope.row.storeStatus===0" style="color: red">-->
|
||||||
休业
|
<!-- 休业-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
<div style="color: lawngreen" v-else>
|
<!-- <div style="color: lawngreen" v-else>-->
|
||||||
营业
|
<!-- 营业-->
|
||||||
</div>
|
<!-- </div>-->
|
||||||
</template>
|
<!-- </template>-->
|
||||||
</el-table-column>
|
<!-- </el-table-column>-->
|
||||||
<el-table-column prop="createTime" label="注册日期" width="200"/>
|
<el-table-column prop="createTime" label="注册日期" width="200"/>
|
||||||
<el-table-column prop="updateTime" label="最后登录日期" width="200"/>
|
<el-table-column prop="updateTime" label="最后登录日期" width="200"/>
|
||||||
|
|
||||||
|
|
13
src/views/businessBag/qiangdan/qiangdan.vue
Normal file
13
src/views/businessBag/qiangdan/qiangdan.vue
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
<template>
|
||||||
|
暂无接口
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: "qiangdan"
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
</style>
|
|
@ -73,9 +73,7 @@ import axios from "@/util/axios";
|
||||||
import {useRouter} from "vue-router"
|
import {useRouter} from "vue-router"
|
||||||
|
|
||||||
|
|
||||||
// const isCollapse=ref(true);
|
|
||||||
// const RCollapse=ref([]);//审核成功
|
|
||||||
// const LCollapse=ref([]);//审核未成功
|
|
||||||
const router=useRouter();
|
const router=useRouter();
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
<el-button type="button" :icon="Search" @click="initEmployeeList">搜索</el-button>
|
<el-button type="button" :icon="Search" @click="initEmployeeList">搜索</el-button>
|
||||||
<el-button type="primary" :icon="DocumentAdd" @click="handleAddDialogValue()" >添加用户</el-button>
|
<el-button type="primary" :icon="DocumentAdd" @click="handleAddDialogValue()" >添加用户</el-button>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-table :data="tableData" stripe style="width: 100%;" showOverflowTooltip>
|
<el-table :data="tempData" stripe style="width: 100%;" showOverflowTooltip>
|
||||||
<el-table-column prop="id" label="#ID" width="80" />
|
<el-table-column prop="id" label="#ID" width="80" />
|
||||||
<el-table-column prop="manicuristName" label="用户昵称" width="200" />
|
<el-table-column prop="manicuristName" label="用户昵称" width="200" />
|
||||||
<el-table-column prop="manicuristAvatar" label="头像" width="200">
|
<el-table-column prop="manicuristAvatar" label="头像" width="200">
|
||||||
|
@ -40,6 +40,15 @@
|
||||||
<img :src="scope.row.manicuristAvatar" width="50" height="50"/>
|
<img :src="scope.row.manicuristAvatar" width="50" height="50"/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column label="性别" prop="gender">
|
||||||
|
<template #default="scope">
|
||||||
|
<div v-if="scope.row.gender==0">女</div>
|
||||||
|
<div v-else>男</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column prop="phone" label="手机号" width="120px"/>
|
||||||
|
<el-table-column prop="email" label="邮箱" width="180px"/>
|
||||||
<el-table-column prop="rating" label="评分" width="200px">
|
<el-table-column prop="rating" label="评分" width="200px">
|
||||||
<template v-slot="scope" style="height: 100px">
|
<template v-slot="scope" style="height: 100px">
|
||||||
<div class="demo-rate-block">
|
<div class="demo-rate-block">
|
||||||
|
@ -74,11 +83,8 @@
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination
|
<el-pagination
|
||||||
v-model:currentPage="queryForm.current"
|
v-model:currentPage="queryForm.current"
|
||||||
v-model:page-size="queryForm.pageSize"
|
layout="total, prev, pager, next, jumper"
|
||||||
:page-sizes="[10, 20, 30, 40,50]"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="total"
|
:total="total"
|
||||||
@size-change="handleSizeChange"
|
|
||||||
@current-change="handleCurrentChange"
|
@current-change="handleCurrentChange"
|
||||||
/>
|
/>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
@ -210,10 +216,12 @@ const handleDelete=(ids)=>{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
watch(query,()=>{
|
// watch(query,()=>{
|
||||||
// console.log(query.value)
|
// // console.log(query.value)
|
||||||
initEmployeeList();
|
// initEmployeeList();
|
||||||
},10000)
|
// },10000)
|
||||||
|
|
||||||
|
const tempData=ref([])
|
||||||
|
|
||||||
const tempstore=()=>{
|
const tempstore=()=>{
|
||||||
const temp=[]
|
const temp=[]
|
||||||
|
@ -232,6 +240,9 @@ const tempstore=()=>{
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
tableData.value=temp
|
tableData.value=temp
|
||||||
|
tempData.value.slice(0,0)
|
||||||
|
tempData.value=tableData.value.slice(0,10)
|
||||||
|
|
||||||
//console.log(res.data.data)
|
//console.log(res.data.data)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -259,9 +270,8 @@ const handleSizeChange = (pageSize) => {
|
||||||
queryForm.value.pageSize=pageSize;
|
queryForm.value.pageSize=pageSize;
|
||||||
initEmployeeList();
|
initEmployeeList();
|
||||||
}
|
}
|
||||||
const handleCurrentChange = (current) => {
|
const handleCurrentChange = (pageNum) => {
|
||||||
queryForm.value.current=current;
|
tempData.value=tableData.value.slice(pageNum*10-10,pageNum*10)
|
||||||
initEmployeeList();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -2,16 +2,16 @@
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-row :gutter="20" class="header">
|
<el-row :gutter="20" class="header">
|
||||||
<el-col :span="7">
|
<el-col :span="7">
|
||||||
<el-input placeholder="请输入用户昵称..." clearable v-model="formPage.businessName"></el-input>
|
<el-input placeholder="请输入美甲师ID..." clearable v-model="query"></el-input>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-button type="button" :icon="Search" @click="initEmployeeList">搜索</el-button>
|
<el-button type="button" :icon="Search" @click="initEmployeeList">搜索</el-button>
|
||||||
|
</el-row>
|
||||||
<!-- <el-radio-group v-model="isCollapse" style="margin-bottom: 20px;margin-left: 20px">-->
|
<!-- <el-radio-group v-model="isCollapse" style="margin-bottom: 20px;margin-left: 20px">-->
|
||||||
<!-- <el-radio-button :value="true" @click="handleCollapse(true)">审核</el-radio-button>-->
|
<!-- <el-radio-button :value="true" @click="handleCollapse(true)">审核</el-radio-button>-->
|
||||||
<!-- <el-radio-button :value="false" @click="handleCollapse(false)">未审核</el-radio-button>-->
|
<!-- <el-radio-button :value="false" @click="handleCollapse(false)">未审核</el-radio-button>-->
|
||||||
<!-- </el-radio-group>-->
|
<!-- </el-radio-group>-->
|
||||||
</el-row>
|
|
||||||
<el-table :data="tableData" stripe style="width: 100%;" showOverflowTooltip>
|
<el-table :data="tempData" stripe style="width: 100%;" showOverflowTooltip>
|
||||||
<el-table-column prop="id" label="#ID" width="80" />
|
<el-table-column prop="id" label="#ID" width="80" />
|
||||||
<el-table-column prop="manicuristName" label="用户昵称" width="200" />
|
<el-table-column prop="manicuristName" label="用户昵称" width="200" />
|
||||||
<el-table-column prop="manicuristAvatar" label="头像" width="200">
|
<el-table-column prop="manicuristAvatar" label="头像" width="200">
|
||||||
|
@ -19,15 +19,24 @@
|
||||||
<img :src="scope.row.manicuristAvatar" width="50" height="50"/>
|
<img :src="scope.row.manicuristAvatar" width="50" height="50"/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="rating" label="评分" width="200px">
|
<el-table-column label="性别" prop="gender">
|
||||||
<template v-slot="scope" style="height: 100px">
|
<template #default="scope">
|
||||||
<div class="demo-rate-block">
|
<div v-if="scope.row.gender==0">女</div>
|
||||||
<el-rate v-model="scope.row.rating" :colors="colors"/>
|
<div v-else>男</div>
|
||||||
{{scope.row.rating}}
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="salary" label="余额" />
|
<el-table-column prop="phone" label="手机号" width="120px"/>
|
||||||
|
<el-table-column prop="email" label="邮箱" width="180px"/>
|
||||||
|
<!-- <el-table-column prop="rating" label="评分" width="200px">-->
|
||||||
|
<!-- <template v-slot="scope" style="height: 100px">-->
|
||||||
|
<!-- <div class="demo-rate-block">-->
|
||||||
|
<!-- <el-rate v-model="scope.row.rating" :colors="colors"/>-->
|
||||||
|
<!-- {{scope.row.rating}}-->
|
||||||
|
<!-- </div>-->
|
||||||
|
<!-- </template>-->
|
||||||
|
<!-- </el-table-column>-->
|
||||||
|
<!-- <el-table-column prop="salary" label="余额" />-->
|
||||||
<el-table-column prop="createTime" label="注册日期" width="200"/>
|
<el-table-column prop="createTime" label="注册日期" width="200"/>
|
||||||
<el-table-column prop="updateTime" label="最后登录日期" width="200"/>
|
<el-table-column prop="updateTime" label="最后登录日期" width="200"/>
|
||||||
<el-table-column prop="action" fixed="right" label="操作" min-width="120" >
|
<el-table-column prop="action" fixed="right" label="操作" min-width="120" >
|
||||||
|
@ -39,13 +48,13 @@
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination
|
<el-pagination
|
||||||
v-model:currentPage="formPage.current"
|
v-model:currentPage="formPage.current"
|
||||||
v-model:page-size="formPage.pageSize"
|
layout="total, prev, pager, next, jumper"
|
||||||
:page-sizes="[10, 20, 30, 40,50]"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="total"
|
:total="total"
|
||||||
@size-change="handleSizeChange"
|
|
||||||
@current-change="handleCurrentChange"
|
@current-change="handleCurrentChange"
|
||||||
/>
|
/>
|
||||||
|
<!-- :page-sizes="[10, 20, 30, 40,50]"-->
|
||||||
|
<!-- v-model:page-size="formPage.pageSize"-->
|
||||||
|
<!-- @size-change="handleSizeChange"-->
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
||||||
|
|
||||||
|
@ -61,10 +70,8 @@ import axios from "@/util/axios";
|
||||||
import { ElNotification } from 'element-plus'
|
import { ElNotification } from 'element-plus'
|
||||||
import Dialog from '@/views/employee/dialog/index.vue'
|
import Dialog from '@/views/employee/dialog/index.vue'
|
||||||
|
|
||||||
import axiosUtil from "@/util/axios";
|
|
||||||
import {ElMessage} from "element-plus";
|
|
||||||
import {useRouter} from "vue-router"
|
import {useRouter} from "vue-router"
|
||||||
import {request} from "axios";
|
|
||||||
|
|
||||||
|
|
||||||
const RCollapse=ref([]);
|
const RCollapse=ref([]);
|
||||||
|
@ -82,7 +89,7 @@ const handleDialogValue=(ids)=>{
|
||||||
edialogVisible.value=true
|
edialogVisible.value=true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const tempData=ref([])
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -100,7 +107,7 @@ const tableData =ref([])
|
||||||
|
|
||||||
|
|
||||||
const handleCollapse=async (temp)=>{
|
const handleCollapse=async (temp)=>{
|
||||||
console.log(temp)
|
// console.log(temp)
|
||||||
const res=await axios.post("manicurist/queryAll");
|
const res=await axios.post("manicurist/queryAll");
|
||||||
RCollapse.value.splice(0,RCollapse.value.length);
|
RCollapse.value.splice(0,RCollapse.value.length);
|
||||||
LCollapse.value.splice(0,LCollapse.value.length);
|
LCollapse.value.splice(0,LCollapse.value.length);
|
||||||
|
@ -116,8 +123,8 @@ const handleCollapse=async (temp)=>{
|
||||||
|
|
||||||
//console.log(item.state);
|
//console.log(item.state);
|
||||||
});
|
});
|
||||||
console.log("RCollapse"+RCollapse.value);
|
// console.log("RCollapse"+RCollapse.value);
|
||||||
console.log("LCollapse"+LCollapse.value);
|
// console.log("LCollapse"+LCollapse.value);
|
||||||
if (temp){
|
if (temp){
|
||||||
tableData.value=RCollapse.value
|
tableData.value=RCollapse.value
|
||||||
total.value=Number(RCollapse.value.length);
|
total.value=Number(RCollapse.value.length);
|
||||||
|
@ -125,23 +132,28 @@ const handleCollapse=async (temp)=>{
|
||||||
tableData.value=LCollapse.value
|
tableData.value=LCollapse.value
|
||||||
total.value=Number(LCollapse.value.length);
|
total.value=Number(LCollapse.value.length);
|
||||||
}
|
}
|
||||||
|
tempData.value.slice(0,0)
|
||||||
|
tempData.value=tableData.value.slice(0,10)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
const initEmployeeList=async()=>{
|
const initEmployeeList=async()=>{
|
||||||
if (!query.value){
|
if (!query.value){
|
||||||
const res=await axios.post("manicurist/queryAll");
|
// const res=await axios.post("manicurist/queryAll");
|
||||||
// console.log(res.data)
|
// // console.log(res.data)
|
||||||
tableData.value=res.data.data;
|
// tableData.value=res.data.data;
|
||||||
total.value=res.data.data.length;
|
// total.value=res.data.data.length;
|
||||||
|
handleCollapse();
|
||||||
}else{
|
}else{
|
||||||
const res = await axios.get("manicurist/queryById", {manicuristId: query.value});
|
const res = await axios.get("manicurist/queryById", {manicuristId: query.value});
|
||||||
// console.log(res.data)
|
// console.log(res.data)
|
||||||
const temp = []
|
const temp = []
|
||||||
temp.push(res.data.data)
|
temp.push(res.data.data)
|
||||||
tableData.value = temp;
|
tempData.value = temp;
|
||||||
total.value = 1;
|
total.value = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -149,14 +161,16 @@ const initEmployeeList=async()=>{
|
||||||
|
|
||||||
|
|
||||||
handleCollapse();
|
handleCollapse();
|
||||||
const handleSizeChange = (pageSize) => {
|
// const handleSizeChange = (pageSize) => {
|
||||||
formPage.value.current=1;
|
// // console.log("pageSize"+pageSize)
|
||||||
formPage.value.pageSize=pageSize;
|
// // formPage.value.current=1;
|
||||||
initBusinessList();
|
// // formPage.value.pageSize=pageSize;
|
||||||
}
|
// tempData.value=tableData.value.slice(pageSize-10,pageSize)
|
||||||
|
// }
|
||||||
const handleCurrentChange = (pageNum) => {
|
const handleCurrentChange = (pageNum) => {
|
||||||
formPage.value.current=pageNum;
|
// console.log("current"+pageNum)
|
||||||
initBusinessList();
|
// formPage.value.current=pageNum;
|
||||||
|
tempData.value=tableData.value.slice(pageNum*10-10,pageNum*10)
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="6">
|
<el-col :span="6" v-if="verifyPerson()==true">
|
||||||
<div class="statistic-card">
|
<div class="statistic-card">
|
||||||
<el-statistic :value="num1">
|
<el-statistic :value="num1">
|
||||||
<template #title>
|
<template #title>
|
||||||
|
@ -115,30 +115,25 @@
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="flex: 1" >
|
|
||||||
|
|
||||||
|
<div style="flex: 1">
|
||||||
<div id="main" style="height: 300px;width: 400px;border: 1px solid #ebebeb;border-radius: 2px;"></div>
|
<div id="main" style="height: 300px;width: 400px;border: 1px solid #ebebeb;border-radius: 2px;"></div>
|
||||||
</div>
|
</div>
|
||||||
<div style="flex: 1" >
|
<div style="flex: 1" >
|
||||||
<div id="main1" style="height: 300px;width: 400px;border: 1px solid #ebebeb;border-radius: 2px;"></div>
|
<div id="main1" style="height: 300px;width: 400px;border: 1px solid #ebebeb;border-radius: 2px;"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<!-- <el-pagination-->
|
|
||||||
<!-- v-model:currentPage="formPage.current"-->
|
|
||||||
<!-- v-model:page-size="formPage.pageSize"-->
|
|
||||||
<!-- :page-sizes="[10, 20, 30, 40,50]"-->
|
|
||||||
<!-- layout="total, sizes, prev, pager, next, jumper"-->
|
|
||||||
<!-- :total="total"-->
|
|
||||||
<!-- @size-change="handleSizeChange"-->
|
|
||||||
<!-- @current-change="handleCurrentChange"-->
|
|
||||||
<!-- />-->
|
|
||||||
|
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import axios from "@/util/axios";
|
import axios from "@/util/axios";
|
||||||
import * as echarts from "echarts";
|
import * as echarts from "echarts";
|
||||||
import {onMounted, ref} from 'vue'
|
import {onMounted, ref, watch} from 'vue'
|
||||||
import {formattedDate} from "@/util/time";
|
import {formattedDate, verifyPerson} from "@/util/time";
|
||||||
|
|
||||||
const num0=ref()
|
const num0=ref()
|
||||||
const num1=ref()
|
const num1=ref()
|
||||||
|
@ -148,10 +143,6 @@ const num3=ref()
|
||||||
const compete=ref([])
|
const compete=ref([])
|
||||||
const Xcompete=ref([])
|
const Xcompete=ref([])
|
||||||
const Ycompete=ref([])
|
const Ycompete=ref([])
|
||||||
// ====================
|
|
||||||
|
|
||||||
|
|
||||||
// ====================
|
|
||||||
|
|
||||||
|
|
||||||
const total=ref(0)
|
const total=ref(0)
|
||||||
|
@ -161,8 +152,17 @@ const formPage=ref({
|
||||||
pageSize:1
|
pageSize:1
|
||||||
})
|
})
|
||||||
|
|
||||||
const initBusinessList=async()=>{
|
const initBusinessList= ()=>{
|
||||||
//console.log(formPage.value)
|
if(verifyPerson()==true){
|
||||||
|
initHome();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
const initHome=async ()=>{
|
||||||
const res1=await axios.post("user/list/page");
|
const res1=await axios.post("user/list/page");
|
||||||
num0.value=res1.data.data.total
|
num0.value=res1.data.data.total
|
||||||
|
|
||||||
|
@ -182,16 +182,12 @@ const initBusinessList=async()=>{
|
||||||
compete.value=res3.data.data.records
|
compete.value=res3.data.data.records
|
||||||
compete.value.map(item=>{item.createTime=formattedDate(item.createTime)})
|
compete.value.map(item=>{item.createTime=formattedDate(item.createTime)})
|
||||||
compete.value.forEach(item=>{Xcompete.value.push(item.createTime);Ycompete.value.push(item.totalPrice)})
|
compete.value.forEach(item=>{Xcompete.value.push(item.createTime);Ycompete.value.push(item.totalPrice)})
|
||||||
// console.log(Xcompete.value)
|
|
||||||
// console.log(Ycompete.value)
|
|
||||||
|
|
||||||
// console.log(num0+" "+num1+" "+num2+" "+num3)
|
|
||||||
setTimeout(() => {hei();shi();}, 500)
|
setTimeout(() => {hei();shi();}, 500)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
initBusinessList();
|
initBusinessList();
|
||||||
|
|
||||||
|
|
||||||
const handleSizeChange = (pageSize) => {
|
const handleSizeChange = (pageSize) => {
|
||||||
formPage.value.current=1;
|
formPage.value.current=1;
|
||||||
formPage.value.pageSize=pageSize;
|
formPage.value.pageSize=pageSize;
|
||||||
|
@ -212,6 +208,7 @@ const handleCurrentChange = (pageNum) => {
|
||||||
// })
|
// })
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const hei=()=>{
|
const hei=()=>{
|
||||||
|
|
||||||
var chartDom = document.getElementById('main1');
|
var chartDom = document.getElementById('main1');
|
||||||
|
@ -279,7 +276,6 @@ const hei=()=>{
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
option && myChart.setOption(option);
|
option && myChart.setOption(option);
|
||||||
|
|
||||||
}
|
}
|
||||||
const shi=()=>{
|
const shi=()=>{
|
||||||
var chartDom = document.getElementById('main');
|
var chartDom = document.getElementById('main');
|
||||||
|
|
|
@ -155,7 +155,7 @@
|
||||||
<el-icon><tickets /></el-icon>
|
<el-icon><tickets /></el-icon>
|
||||||
<span>到店服务</span>
|
<span>到店服务</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item >
|
<el-menu-item index="qiangdan">
|
||||||
<el-icon><tickets /></el-icon>
|
<el-icon><tickets /></el-icon>
|
||||||
<span>抢单</span>
|
<span>抢单</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
|
@ -183,7 +183,7 @@
|
||||||
<el-icon><management /></el-icon>
|
<el-icon><management /></el-icon>
|
||||||
<span>美甲师列表</span>
|
<span>美甲师列表</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
<el-menu-item >
|
<el-menu-item index="employeeVerify">
|
||||||
<el-icon><tickets /></el-icon>
|
<el-icon><tickets /></el-icon>
|
||||||
<span>签约美甲师</span>
|
<span>签约美甲师</span>
|
||||||
</el-menu-item>
|
</el-menu-item>
|
||||||
|
@ -241,18 +241,11 @@ import { useStore } from 'vuex'
|
||||||
import axios from "@/util/axios";
|
import axios from "@/util/axios";
|
||||||
import {ElMessage} from "element-plus";
|
import {ElMessage} from "element-plus";
|
||||||
import {ref} from "vue";
|
import {ref} from "vue";
|
||||||
|
import {verifyPerson} from "@/util/time";
|
||||||
const store=useStore();
|
const store=useStore();
|
||||||
const ax=ref(true)
|
const ax=ref(true)
|
||||||
const initax=()=>{
|
const initax=()=>{
|
||||||
let userInfoJson = window.sessionStorage.getItem("USER_LOGIN_STATE");
|
ax.value=verifyPerson();
|
||||||
console.log(userInfoJson)
|
|
||||||
if(JSON.parse(userInfoJson).userRole==1)
|
|
||||||
{
|
|
||||||
ax.value=true
|
|
||||||
}else{
|
|
||||||
ax.value=false
|
|
||||||
}
|
|
||||||
console.log(ax.value)
|
|
||||||
}
|
}
|
||||||
initax();
|
initax();
|
||||||
const logout=async ()=>{
|
const logout=async ()=>{
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import {ref} from 'vue'
|
import {ref} from 'vue'
|
||||||
import {Lock, User} from '@element-plus/icons-vue'
|
import {Lock, User} from '@element-plus/icons-vue'
|
||||||
import axios, {request} from "axios";
|
|
||||||
import axiosUtil from '@/util/axios'
|
import axiosUtil from '@/util/axios'
|
||||||
import {ElMessage} from "element-plus";
|
import {ElMessage} from "element-plus";
|
||||||
import router from "@/router";
|
import router from "@/router";
|
||||||
|
@ -63,6 +62,7 @@ const handleLogin = () => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
try {
|
try {
|
||||||
let result = await axiosUtil.post("user/login", form.value);
|
let result = await axiosUtil.post("user/login", form.value);
|
||||||
|
let res = await axiosUtil.get("business/current");
|
||||||
let data = result.data;
|
let data = result.data;
|
||||||
// console.log(result)
|
// console.log(result)
|
||||||
// const value = response.data;
|
// const value = response.data;
|
||||||
|
@ -75,6 +75,7 @@ const handleLogin = () => {
|
||||||
ElMessage.success("登录成功");
|
ElMessage.success("登录成功");
|
||||||
window.sessionStorage.setItem("token",JSON.stringify(form.value));
|
window.sessionStorage.setItem("token",JSON.stringify(form.value));
|
||||||
window.sessionStorage.setItem("USER_LOGIN_STATE", JSON.stringify(data.data));
|
window.sessionStorage.setItem("USER_LOGIN_STATE", JSON.stringify(data.data));
|
||||||
|
window.sessionStorage.setItem("BUSINESS_STATE", JSON.stringify(res.data.data));
|
||||||
router.push('/home');
|
router.push('/home');
|
||||||
} else {
|
} else {
|
||||||
ElMessage.error(data.description);
|
ElMessage.error(data.description);
|
||||||
|
|
|
@ -1,13 +1,33 @@
|
||||||
<template>
|
<template>
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-row :gutter="20" class="header">
|
<el-row :gutter="20" class="header">
|
||||||
<el-col :span="7">
|
<el-col :span="5">
|
||||||
<el-input placeholder="请输入订单号..." clearable v-model="queryForm.orderNumber"></el-input>
|
<el-input placeholder="请输入订单号..." clearable v-model="queryForm.orderNumber"></el-input>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="5">
|
||||||
|
<el-input placeholder="请输入用户ID..." clearable v-model="queryForm.userId"></el-input>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-select
|
||||||
|
v-model="queryForm.paymentStatus"
|
||||||
|
size="default"
|
||||||
|
placeholder="支付状态"
|
||||||
|
style="width: 100%"
|
||||||
|
>
|
||||||
|
|
||||||
|
<el-option
|
||||||
|
v-for="(item,index) in payStatus"
|
||||||
|
:key="item.indexOf()"
|
||||||
|
:label="item"
|
||||||
|
:value="index"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-col>
|
||||||
<el-button type="button" :icon="Search" @click="initOrderList">搜索</el-button>
|
<el-button type="button" :icon="Search" @click="initOrderList">搜索</el-button>
|
||||||
|
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-table :data="tableData" stripe style="width: 100%" showOverflowTooltip>
|
<el-table :data="tableData" stripe style="width: 100%" showOverflowTooltip>
|
||||||
<el-table-column prop="id" label="#ID" width="40" fixed/>
|
<el-table-column prop="id" label="#ID" width="60" fixed/>
|
||||||
<el-table-column prop="orderNumber" label="订单号" width="220" fixed/>
|
<el-table-column prop="orderNumber" label="订单号" width="220" fixed/>
|
||||||
<el-table-column prop="userName" label="用户昵称" width="200"/>
|
<el-table-column prop="userName" label="用户昵称" width="200"/>
|
||||||
<el-table-column prop="totalPrice" label="订单总价" width="100"/>
|
<el-table-column prop="totalPrice" label="订单总价" width="100"/>
|
||||||
|
@ -84,6 +104,8 @@ const handleDelete=(id)=>{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
const handleOrderStatus=(id,status)=>{
|
const handleOrderStatus=(id,status)=>{
|
||||||
ElMessageBox.confirm(
|
ElMessageBox.confirm(
|
||||||
'您确认要更新这个订单状态吗?',
|
'您确认要更新这个订单状态吗?',
|
||||||
|
@ -129,6 +151,8 @@ const id=ref(-1);
|
||||||
|
|
||||||
const queryForm=ref({
|
const queryForm=ref({
|
||||||
orderNumber:'',
|
orderNumber:'',
|
||||||
|
paymentStatus: null,
|
||||||
|
userId: null,
|
||||||
current:1,
|
current:1,
|
||||||
pageSize:10
|
pageSize:10
|
||||||
})
|
})
|
||||||
|
@ -137,6 +161,7 @@ const tableData =ref([])
|
||||||
const payStatus=['未支付','已支付','退款中','已退款']
|
const payStatus=['未支付','已支付','退款中','已退款']
|
||||||
|
|
||||||
const initOrderList=async()=>{
|
const initOrderList=async()=>{
|
||||||
|
// console.log(queryForm.value)
|
||||||
const res=await axios.post("orders/list/page",queryForm.value);
|
const res=await axios.post("orders/list/page",queryForm.value);
|
||||||
//console.log(res.data.data)
|
//console.log(res.data.data)
|
||||||
// const temp=[];
|
// const temp=[];
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
<el-button type="button" :icon="Search" @click="initOrderList">搜索</el-button>
|
<el-button type="button" :icon="Search" @click="initOrderList">搜索</el-button>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-table :data="tableData" stripe style="width: 100%" showOverflowTooltip>
|
<el-table :data="tableData" stripe style="width: 100%" showOverflowTooltip>
|
||||||
|
<el-table-column prop="id" label="#ID" width="60" fixed/>
|
||||||
<el-table-column prop="orderNumber" label="订单号" width="220" fixed/>
|
<el-table-column prop="orderNumber" label="订单号" width="220" fixed/>
|
||||||
<el-table-column prop="userName" label="用户昵称" width="200"/>
|
<el-table-column prop="userName" label="用户昵称" width="200"/>
|
||||||
<el-table-column prop="totalPrice" label="订单总价" width="100"/>
|
<el-table-column prop="totalPrice" label="订单总价" width="100"/>
|
||||||
|
|
|
@ -84,7 +84,7 @@
|
||||||
@initEmployeeList="initEmployeeList"></UpdateDialog>
|
@initEmployeeList="initEmployeeList"></UpdateDialog>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import {Search,DocumentAdd,Delete,Edit} from '@element-plus/icons-vue'
|
import {Search,DocumentAdd,Edit} from '@element-plus/icons-vue'
|
||||||
import {ref, watch} from 'vue'
|
import {ref, watch} from 'vue'
|
||||||
import axios from "@/util/axios";
|
import axios from "@/util/axios";
|
||||||
import Dialog from '@/views/permission/dialog/index.vue'
|
import Dialog from '@/views/permission/dialog/index.vue'
|
||||||
|
@ -113,7 +113,6 @@ const edialogVisible=ref(false)
|
||||||
const edialogUpdateVisible=ref(false)
|
const edialogUpdateVisible=ref(false)
|
||||||
|
|
||||||
|
|
||||||
import { Action } from 'element-plus'
|
|
||||||
|
|
||||||
const open = () => {
|
const open = () => {
|
||||||
ElMessageBox.alert('此接口暂无', 'Title', {
|
ElMessageBox.alert('此接口暂无', 'Title', {
|
||||||
|
|
|
@ -8,11 +8,13 @@
|
||||||
<el-col :span="4" v-if="params.product==undefined">
|
<el-col :span="4" v-if="params.product==undefined">
|
||||||
<el-input placeholder="请输入商家ID..." clearable v-model="queryForm.businessId"></el-input>
|
<el-input placeholder="请输入商家ID..." clearable v-model="queryForm.businessId"></el-input>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="4" >
|
<el-col :span="4" >
|
||||||
<el-input placeholder="请输入分类ID..." clearable v-model="queryForm.commoditiesGroupId"></el-input>
|
<el-input placeholder="请输入分类ID..." clearable v-model="queryForm.commoditiesGroupId"></el-input>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-button type="primary" :icon="Search" @click="initProductList" >搜索</el-button>
|
<el-button type="primary" :icon="Search" @click="initProductList" >搜索</el-button>
|
||||||
<el-button v-if="params.product!==undefined" >商家名称:{{JSON.parse(params.product).businessName}}</el-button>
|
<el-button v-if="params.product!==undefined" >商家名称:{{JSON.parse(params.product).businessName}}</el-button>
|
||||||
|
|
||||||
<!-- <el-button type="primary" :icon="DocumentAdd"-->
|
<!-- <el-button type="primary" :icon="DocumentAdd"-->
|
||||||
<!-- @click="handleDialogValue()">添加商品</el-button>-->
|
<!-- @click="handleDialogValue()">添加商品</el-button>-->
|
||||||
</el-row>
|
</el-row>
|
||||||
|
@ -56,6 +58,7 @@ import {ref, watch} from 'vue'
|
||||||
import axios,{getServerUrl} from "@/util/axios";
|
import axios,{getServerUrl} from "@/util/axios";
|
||||||
import { ElMessageBox,ElMessage } from 'element-plus'
|
import { ElMessageBox,ElMessage } from 'element-plus'
|
||||||
import {useRoute} from "vue-router";
|
import {useRoute} from "vue-router";
|
||||||
|
import {verifyPerson} from "@/util/time";
|
||||||
// import Dialog from './components/dialog'
|
// import Dialog from './components/dialog'
|
||||||
|
|
||||||
let params=useRoute().query
|
let params=useRoute().query
|
||||||
|
@ -84,12 +87,21 @@ const queryForm=ref({
|
||||||
// }
|
// }
|
||||||
// dialogVisible.value=true
|
// dialogVisible.value=true
|
||||||
// }
|
// }
|
||||||
|
const businessId=ref()
|
||||||
|
let jk=ref();
|
||||||
const initProductList=async()=>{
|
const initProductList=async()=>{
|
||||||
//console.log(JSON.parse(params.product).id)
|
//console.log(JSON.parse(params.product).id)
|
||||||
|
jk.value=verifyPerson();
|
||||||
|
console.log(jk.value)
|
||||||
if(params.product!=undefined){
|
if(params.product!=undefined){
|
||||||
|
|
||||||
queryForm.value.businessId=JSON.parse(params.product).id
|
queryForm.value.businessId=JSON.parse(params.product).id
|
||||||
|
}else if (jk.value==false){
|
||||||
|
let Info = window.sessionStorage.getItem("BUSINESS_STATE");
|
||||||
|
queryForm.value.businessId=JSON.parse(Info).id
|
||||||
|
console.log(queryForm.value)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const res=await axios.post("commodities/list/page/commodities",queryForm.value);
|
const res=await axios.post("commodities/list/page/commodities",queryForm.value);
|
||||||
// console.log(res.data.data)
|
// console.log(res.data.data)
|
||||||
tableData.value=res.data.data.records;
|
tableData.value=res.data.data.records;
|
||||||
|
@ -97,10 +109,6 @@ const initProductList=async()=>{
|
||||||
|
|
||||||
}
|
}
|
||||||
initProductList();
|
initProductList();
|
||||||
watch(query,()=>{
|
|
||||||
// console.log(id.value)
|
|
||||||
initProductList();
|
|
||||||
},10000)
|
|
||||||
|
|
||||||
const handleSizeChange = (pageSize) => {
|
const handleSizeChange = (pageSize) => {
|
||||||
queryForm.value.current=1;
|
queryForm.value.current=1;
|
||||||
|
|
|
@ -4,6 +4,22 @@
|
||||||
<el-col :span="7">
|
<el-col :span="7">
|
||||||
<el-input placeholder="请输入用户昵称..." clearable v-model="queryForm.username"></el-input>
|
<el-input placeholder="请输入用户昵称..." clearable v-model="queryForm.username"></el-input>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
<el-select
|
||||||
|
v-model="queryForm.userRole"
|
||||||
|
size="default"
|
||||||
|
placeholder="用户角色"
|
||||||
|
style="width: 100%"
|
||||||
|
>
|
||||||
|
|
||||||
|
<el-option
|
||||||
|
v-for="(item,index) in options"
|
||||||
|
:key="item.indexOf()"
|
||||||
|
:label="item"
|
||||||
|
:value="index"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-col>
|
||||||
<el-button type="button" :icon="Search" @click="initUserList" >搜索</el-button>
|
<el-button type="button" :icon="Search" @click="initUserList" >搜索</el-button>
|
||||||
<el-button type="primary" :icon="DocumentAdd" @click="handleAddDialogValue()" >添加用户</el-button>
|
<el-button type="primary" :icon="DocumentAdd" @click="handleAddDialogValue()" >添加用户</el-button>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
@ -96,15 +112,17 @@ import Dialog from '@/views/user/dialog/index.vue'
|
||||||
import AddDialog from '@/views/user/addDialog/index.vue'
|
import AddDialog from '@/views/user/addDialog/index.vue'
|
||||||
import UpdateDialog from '@/views/user/updateDialog/index.vue'
|
import UpdateDialog from '@/views/user/updateDialog/index.vue'
|
||||||
import { ElMessage,ElMessageBox } from "element-plus";
|
import { ElMessage,ElMessageBox } from "element-plus";
|
||||||
import {parseTime} from "element-plus/es/components/time-select/src/utils";
|
|
||||||
|
|
||||||
|
|
||||||
const queryForm=ref({
|
const queryForm=ref({
|
||||||
|
userRole:'',
|
||||||
username: '',
|
username: '',
|
||||||
current:1,
|
current:1,
|
||||||
pageSize:10
|
pageSize:10
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
|
const options = [ '普通用户', '管理员', '商家', '美甲师']
|
||||||
const id=ref('')
|
const id=ref('')
|
||||||
const dialogTitle=ref('');
|
const dialogTitle=ref('');
|
||||||
const UdialogaddVisible=ref(false)
|
const UdialogaddVisible=ref(false)
|
||||||
|
@ -220,6 +238,7 @@ const initUserList=async()=>{
|
||||||
// tableData.value=temp;
|
// tableData.value=temp;
|
||||||
// total.value=1;
|
// total.value=1;
|
||||||
// }
|
// }
|
||||||
|
// console.log(queryForm.value)
|
||||||
const res = await axios.post("user/list/page", queryForm.value);
|
const res = await axios.post("user/list/page", queryForm.value);
|
||||||
|
|
||||||
if (res.data.data) {
|
if (res.data.data) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user