mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-09-06 06:35:13 +08:00
feat: 修改props参数类型
This commit is contained in:
parent
2f268d8ee4
commit
0155711c27
4 changed files with 4 additions and 3 deletions
|
@ -85,6 +85,7 @@ export default {
|
|||
post: ' create',
|
||||
update: ' update',
|
||||
delete: ' delete',
|
||||
del: 'delete',
|
||||
},
|
||||
operatoin: 'operatoin',
|
||||
status: 'status',
|
||||
|
|
|
@ -86,6 +86,7 @@ export default {
|
|||
delete: '删除',
|
||||
login: '登录',
|
||||
logout: '退出',
|
||||
del: '删除',
|
||||
},
|
||||
operatoin: '操作',
|
||||
status: '状态',
|
||||
|
|
|
@ -72,7 +72,6 @@ const batchDelete = async (row: User.User | null) => {
|
|||
} else {
|
||||
ids.push(row.id);
|
||||
}
|
||||
console.log(ids);
|
||||
await useDeleteData(deleteUser, { ids: ids }, 'commons.msg.delete');
|
||||
search();
|
||||
};
|
||||
|
|
|
@ -41,7 +41,7 @@ let demoForm = ref<User.User>({
|
|||
|
||||
interface OperateProps {
|
||||
op: string;
|
||||
id: number;
|
||||
id: string;
|
||||
}
|
||||
|
||||
const props = withDefaults(defineProps<OperateProps>(), {
|
||||
|
@ -81,7 +81,7 @@ const getUser = async (id: number) => {
|
|||
onMounted(() => {
|
||||
if (props.op == 'edit') {
|
||||
console.log(props);
|
||||
getUser(props.id).catch(() => {
|
||||
getUser(Number(props.id)).catch(() => {
|
||||
router.back();
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue