New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@mshow3/basic-user-api

Package Overview
Dependencies
Maintainers
9
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mshow3/basic-user-api - npm Package Compare versions

Comparing version

to
1.0.66

2

dist/package.json
{
"name": "@mshow3/basic-user-api",
"version": "1.0.62",
"version": "1.0.66",
"description": "你好示例API",

@@ -5,0 +5,0 @@ "main": "dist/src/index.js",

@@ -56,4 +56,8 @@ "use strict";

editUserPassword: (0, api_1.HTTP)(["user"], ""),
// 重置用户密码
resetUserPassword: (0, api_1.HTTP)(["user"], ""),
// 删除用户
deleteUser: (0, api_1.HTTP)(["user"], ""),
// 更新用户信息
editUserMsg: (0, api_1.HTTP)(["user"], ""),
};
{
"name": "@mshow3/basic-user-api",
"version": "1.0.62",
"version": "1.0.66",
"description": "你好示例API",

@@ -5,0 +5,0 @@ "main": "dist/src/index.js",

@@ -116,2 +116,20 @@ import { HTTP } from "@vmm/api";

>(["user"], ""),
// 重置用户密码
resetUserPassword: HTTP<
{
name: string;
},
{
err?: string;
}
>(["user"], ""),
// 删除用户
deleteUser: HTTP<
{
name: string;
},
{
err?: string;
}
>(["user"], ""),
// 更新用户信息

@@ -121,3 +139,6 @@ editUserMsg: HTTP<

name: string;
set: string;
// set: string;
displayName:string;
actor:any[];
group:any[]
},

@@ -124,0 +145,0 @@ {

@@ -1,18 +0,25 @@

import { DB_CRUD, DB_R, DB_RU } from "@vmm/api";
import { schemasUser } from "./DbSchema";
import { DB_CRUD, DB_R, DB_RU } from '@vmm/api';
import { schemasUser } from './DbSchema';
// dbSchemas.
export const DbApi = {
userAdmin: DB_R(schemasUser.user, {}, ["user"], "admin"),
userGroup: DB_CRUD(schemasUser.groups, {}, ["user"], "admin"),
pageGroup: DB_CRUD(schemasUser.pageGroups, {}, ["user"], "admin"),
extBlackList: DB_CRUD(schemasUser.blackList, {}, [], ""),
userAdmin: DB_R(
schemasUser.user,
{
excludeFields: ['pwHash', 'mobile', 'email'],
},
['user'],
'admin',
),
userGroup: DB_CRUD(schemasUser.groups, {}, ['user'], 'admin'),
pageGroup: DB_CRUD(schemasUser.pageGroups, {}, ['user'], 'admin'),
extBlackList: DB_CRUD(schemasUser.blackList, {}, [], ''),
user: DB_R(
schemasUser.user,
{
excludeFields: [],
sessionMatch: { name: "{{user.client.name}}" }
excludeFields: ['pwHash'],
sessionMatch: { name: '{{user.client.name}}' },
},
["user"],
""
['user'],
'',
),

@@ -22,8 +29,8 @@ allUser: DB_R(

{
excludeFields: ["pwHash", "mobile", "email"],
sessionMatch: {}
excludeFields: ['pwHash', 'mobile', 'email'],
sessionMatch: {},
},
["user"],
""
)
['user'],
'',
),
};

@@ -29,3 +29,3 @@ import { DbSchema, createDbSchemas } from '@vmm/api';

pwHash: string; // 用户密码
// actor: string[]; // 用户角色
actor: string[]; // 用户角色
group: string[]; // 用户分组-->actor,menu

@@ -32,0 +32,0 @@ avatar?: string; // 用户头像