feat: add order
This commit is contained in:
@@ -2,7 +2,7 @@ import request from '@/axios';
|
||||
|
||||
export const getList = (current, size, params) => {
|
||||
return request({
|
||||
url: '/kiosk/order/list',
|
||||
url: '/kiosk/order/page',
|
||||
method: 'get',
|
||||
params: {
|
||||
...params,
|
||||
|
||||
@@ -102,7 +102,7 @@ export default {
|
||||
//角色ID
|
||||
roleId: '',
|
||||
//用户名
|
||||
username: 'admin',
|
||||
username: '',
|
||||
//密码
|
||||
password: '',
|
||||
//账号类型
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
<el-button
|
||||
icon="el-icon-setting"
|
||||
@click="handleRole"
|
||||
v-if="userInfo.authority.includes('admin')"
|
||||
v-if="userInfo.authority.includes('admin')||userInfo.authority.includes('manager')"
|
||||
plain
|
||||
>Authority
|
||||
</el-button>
|
||||
@@ -41,7 +41,7 @@
|
||||
type="primary"
|
||||
text
|
||||
icon="el-icon-setting"
|
||||
v-if="userInfo.authority.includes('admin')"
|
||||
v-if="userInfo.authority.includes('admin')||userInfo.authority.includes('manager')"
|
||||
plain
|
||||
style="border: 0; background-color: transparent !important"
|
||||
@click.stop="handleRowRole(row)"
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-operation"
|
||||
v-if="userInfo.authority.includes('admin') && !auditMode"
|
||||
v-if="(userInfo.authority.includes('admin') || userInfo.authority.includes('manager')) && !auditMode"
|
||||
@click="handleAudit"
|
||||
>Audit
|
||||
</el-button>
|
||||
@@ -60,7 +60,7 @@
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-check"
|
||||
v-if="userInfo.authority.includes('admin') && auditMode"
|
||||
v-if="(userInfo.authority.includes('admin') || userInfo.authority.includes('manager'))&& auditMode"
|
||||
@click="handleAuditPass"
|
||||
>Pass
|
||||
</el-button>
|
||||
@@ -68,7 +68,7 @@
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-close"
|
||||
v-if="userInfo.authority.includes('admin') && auditMode"
|
||||
v-if="(userInfo.authority.includes('admin') || userInfo.authority.includes('manager')) && auditMode"
|
||||
@click="handleAuditRefuse"
|
||||
>Reject
|
||||
</el-button>
|
||||
@@ -76,7 +76,7 @@
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-refresh-left"
|
||||
v-if="userInfo.authority.includes('admin') && auditMode"
|
||||
v-if="(userInfo.authority.includes('admin') || userInfo.authority.includes('manager')) && auditMode"
|
||||
@click="handleAuditBack"
|
||||
>Back
|
||||
</el-button>
|
||||
@@ -151,11 +151,16 @@
|
||||
<template #dropdown>
|
||||
<el-dropdown-menu>
|
||||
<el-dropdown-item command="setLeader" v-if="userInfo.authority.includes('admin')">
|
||||
<el-icon><circle-close v-if="row.isLeader === 1" /><user v-else /></el-icon>
|
||||
<el-icon>
|
||||
<circle-close v-if="row.isLeader === 1" />
|
||||
<user v-else />
|
||||
</el-icon>
|
||||
{{ row.isLeader === 1 ? 'Cancel leader' : 'Set leader' }}
|
||||
</el-dropdown-item>
|
||||
<el-dropdown-item command="delete" v-if="this.permission.user_delete">
|
||||
<el-icon><delete /></el-icon>
|
||||
<el-icon>
|
||||
<delete />
|
||||
</el-icon>
|
||||
Delete
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
@@ -250,7 +255,7 @@ import {
|
||||
auditPass,
|
||||
auditRefuse,
|
||||
setLeader,
|
||||
getLeaderList,
|
||||
getLeaderList
|
||||
} from '@/api/system/user';
|
||||
import { exportBlob } from '@/api/common';
|
||||
import { getDeptTree } from '@/api/system/dept';
|
||||
@@ -284,20 +289,20 @@ export default {
|
||||
page: {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
total: 0
|
||||
},
|
||||
platformPage: {
|
||||
pageSize: 10,
|
||||
currentPage: 1,
|
||||
total: 0,
|
||||
total: 0
|
||||
},
|
||||
init: {
|
||||
roleTree: [],
|
||||
deptTree: [],
|
||||
deptTree: []
|
||||
},
|
||||
props: {
|
||||
label: 'title',
|
||||
value: 'key',
|
||||
value: 'key'
|
||||
},
|
||||
roleGrantList: [],
|
||||
roleTreeObj: [],
|
||||
@@ -312,7 +317,7 @@ export default {
|
||||
platformForm: {},
|
||||
platformOption: platformOption,
|
||||
excelForm: {},
|
||||
excelOption: excelOption,
|
||||
excelOption: excelOption
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
@@ -326,7 +331,7 @@ export default {
|
||||
const column = this.findObject(this.excelOption.column, 'excelFile');
|
||||
column.action = `/blade-system/user/import-user?isCovered=${this.excelForm.isCovered}`;
|
||||
}
|
||||
},
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['userInfo', 'permission']),
|
||||
@@ -335,7 +340,7 @@ export default {
|
||||
addBtn: this.validData(this.permission.user_add, false),
|
||||
viewBtn: false,
|
||||
delBtn: false,
|
||||
editBtn: false,
|
||||
editBtn: false
|
||||
};
|
||||
},
|
||||
platformPermissionList() {
|
||||
@@ -343,7 +348,7 @@ export default {
|
||||
addBtn: false,
|
||||
viewBtn: false,
|
||||
delBtn: false,
|
||||
editBtn: this.validData(this.permission.user_edit, false),
|
||||
editBtn: this.validData(this.permission.user_edit, false)
|
||||
};
|
||||
},
|
||||
ids() {
|
||||
@@ -352,7 +357,7 @@ export default {
|
||||
ids.push(ele.id);
|
||||
});
|
||||
return ids.join(',');
|
||||
},
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// 非租户模式默认加载管理组数据
|
||||
@@ -365,7 +370,7 @@ export default {
|
||||
created() {
|
||||
// 创建脱敏工具实例
|
||||
this.sensitiveManager = sensitive.create({
|
||||
fields: ['phone', 'email'], // 配置需要脱敏的字段
|
||||
fields: ['phone', 'email'] // 配置需要脱敏的字段
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
@@ -387,7 +392,7 @@ export default {
|
||||
this.$confirm(tip, {
|
||||
confirmButtonText: 'Confirm',
|
||||
cancelButtonText: 'Cancel',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return setLeader(row.id);
|
||||
@@ -395,7 +400,7 @@ export default {
|
||||
.then(() => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: message,
|
||||
message: message
|
||||
});
|
||||
this.onLoad(this.page);
|
||||
});
|
||||
@@ -424,7 +429,7 @@ export default {
|
||||
this.roleBox = false;
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
this.onLoad(this.page);
|
||||
});
|
||||
@@ -440,7 +445,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
done();
|
||||
},
|
||||
@@ -463,7 +468,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
done();
|
||||
},
|
||||
@@ -477,7 +482,7 @@ export default {
|
||||
this.$confirm('Confirmation for Delete?', {
|
||||
confirmButtonText: 'Confirm',
|
||||
cancelButtonText: 'Cancel',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return remove(row.id);
|
||||
@@ -486,7 +491,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
});
|
||||
},
|
||||
@@ -516,7 +521,7 @@ export default {
|
||||
this.$confirm('Confirmation for DEL?', {
|
||||
confirmButtonText: 'Confirm',
|
||||
cancelButtonText: 'Cancel',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return remove(this.ids);
|
||||
@@ -525,7 +530,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
@@ -542,7 +547,7 @@ export default {
|
||||
this.$confirm('确定将选择数据通过审核?', {
|
||||
confirmButtonText: 'Confirm',
|
||||
cancelButtonText: 'Cancel',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return auditPass(this.ids);
|
||||
@@ -551,7 +556,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
@@ -564,7 +569,7 @@ export default {
|
||||
this.$confirm('确定将选择数据拒绝审核?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return auditRefuse(this.ids);
|
||||
@@ -573,7 +578,7 @@ export default {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: 'Success!',
|
||||
message: 'Success!'
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
@@ -590,7 +595,7 @@ export default {
|
||||
this.$confirm('确定将选择账号密码重置为初始密码?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return resetPassword(this.ids);
|
||||
@@ -598,7 +603,7 @@ export default {
|
||||
.then(() => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
@@ -628,7 +633,7 @@ export default {
|
||||
this.$confirm('确定将选择账号解封?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
})
|
||||
.then(() => {
|
||||
return unlock(this.ids);
|
||||
@@ -636,7 +641,7 @@ export default {
|
||||
.then(() => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
});
|
||||
});
|
||||
},
|
||||
@@ -655,7 +660,7 @@ export default {
|
||||
this.$confirm('是否导出用户数据?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
NProgress.start();
|
||||
exportBlob(
|
||||
@@ -731,7 +736,7 @@ export default {
|
||||
this.platformOnLoad(this.platformPage);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
message: '操作成功!'
|
||||
});
|
||||
done();
|
||||
},
|
||||
@@ -789,8 +794,8 @@ export default {
|
||||
this.platformLoading = false;
|
||||
this.selectionClear();
|
||||
});
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user