From f294efb8c01ad8b0704a92d51c14dbd55d898874 Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期四, 23 十月 2025 16:49:46 +0800
Subject: [PATCH] 拆分原材料和外购成品的业务流程(报检、下单、检验)
---
src/api/system/user.js | 179 ++++++++++++++++++++++++++++++++++++++++-------------------
1 files changed, 120 insertions(+), 59 deletions(-)
diff --git a/src/api/system/user.js b/src/api/system/user.js
index b5e3edd..ad8d3ce 100644
--- a/src/api/system/user.js
+++ b/src/api/system/user.js
@@ -1,136 +1,197 @@
-import request from '@/utils/request'
+import request from "@/utils/request";
import { parseStrEmpty } from "@/utils/ruoyi";
// 鏌ヨ鐢ㄦ埛鍒楄〃
export function listUser(query) {
return request({
- url: '/system/user/list',
- method: 'get',
- params: query
- })
+ url: "/system/user/list",
+ method: "get",
+ params: query,
+ });
}
// 鏌ヨ鐢ㄦ埛璇︾粏
export function getUser(userId) {
return request({
- url: '/system/user/' + parseStrEmpty(userId),
- method: 'get'
- })
+ url: "/system/user/" + parseStrEmpty(userId),
+ method: "get",
+ });
}
// 鏂板鐢ㄦ埛
export function addUser(data) {
return request({
- url: '/system/user',
- method: 'post',
- data: data
- })
+ url: "/system/user",
+ method: "post",
+ data: data,
+ });
}
// 淇敼鐢ㄦ埛
export function updateUser(data) {
return request({
- url: '/system/user',
- method: 'put',
- data: data
- })
+ url: "/system/user",
+ method: "put",
+ data: data,
+ });
}
// 鍒犻櫎鐢ㄦ埛
export function delUser(userId) {
return request({
- url: '/system/user/' + userId,
- method: 'delete'
- })
+ url: "/system/user/" + userId,
+ method: "delete",
+ });
}
// 鐢ㄦ埛瀵嗙爜閲嶇疆
export function resetUserPwd(userId, password) {
const data = {
userId,
- password
- }
+ password,
+ };
return request({
- url: '/system/user/resetPwd',
- method: 'put',
- data: data
- })
+ url: "/system/user/resetPwd",
+ method: "put",
+ data: data,
+ });
}
// 鐢ㄦ埛鐘舵�佷慨鏀�
export function changeUserStatus(userId, status) {
const data = {
userId,
- status
- }
+ status,
+ };
return request({
- url: '/system/user/changeStatus',
- method: 'put',
- data: data
- })
+ url: "/system/user/changeStatus",
+ method: "put",
+ data: data,
+ });
}
// 鏌ヨ鐢ㄦ埛涓汉淇℃伅
export function getUserProfile() {
return request({
- url: '/system/user/profile',
- method: 'get'
- })
+ url: "/system/user/profile",
+ method: "get",
+ });
}
// 淇敼鐢ㄦ埛涓汉淇℃伅
export function updateUserProfile(data) {
return request({
- url: '/system/user/profile',
- method: 'put',
- data: data
- })
+ url: "/system/user/profile",
+ method: "put",
+ data: data,
+ });
}
// 鐢ㄦ埛瀵嗙爜閲嶇疆
export function updateUserPwd(oldPassword, newPassword) {
const data = {
oldPassword,
- newPassword
- }
+ newPassword,
+ };
return request({
- url: '/system/user/profile/updatePwd',
- method: 'put',
- data: data
- })
+ url: "/system/user/profile/updatePwd",
+ method: "put",
+ data: data,
+ });
}
// 鐢ㄦ埛澶村儚涓婁紶
export function uploadAvatar(data) {
return request({
- url: '/system/user/profile/avatar',
- method: 'post',
- headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
- data: data
- })
+ url: "/system/user/profile/avatar",
+ method: "post",
+ headers: { "Content-Type": "application/x-www-form-urlencoded" },
+ data: data,
+ });
}
// 鏌ヨ鎺堟潈瑙掕壊
export function getAuthRole(userId) {
return request({
- url: '/system/user/authRole/' + userId,
- method: 'get'
- })
+ url: "/system/user/authRole/" + userId,
+ method: "get",
+ });
}
// 淇濆瓨鎺堟潈瑙掕壊
export function updateAuthRole(data) {
return request({
- url: '/system/user/authRole',
- method: 'put',
- params: data
- })
+ url: "/system/user/authRole",
+ method: "put",
+ params: data,
+ });
}
// 鏌ヨ閮ㄩ棬涓嬫媺鏍戠粨鏋�
export function deptTreeSelect() {
return request({
- url: '/system/user/deptTree',
- method: 'get'
- })
+ url: "/system/user/deptTree",
+ method: "get",
+ });
+}
+
+// 鑾峰彇浜轰簨绯荤粺缁勭粐
+export function selectCompaniesList() {
+ return request({
+ url: "/companies/selectCompaniesList",
+ method: "get",
+ });
+}
+// 鑾峰彇浜轰簨绯荤粺缁勭粐涓嬬殑浜哄憳
+export function selectSimpleList(data) {
+ return request({
+ url: "/companies/selectSimpleList",
+ method: "post",
+ params: data,
+ });
+}
+// 鑾峰彇浜轰簨绯荤粺缁勭粐涓嬬殑浜哄憳
+export function addPersonUser(data) {
+ return request({
+ url: "/companies/addPersonUser",
+ method: "post",
+ data: data,
+ });
+}
+// 鑾峰彇瑙掕壊
+export function selectRoleList() {
+ return request({
+ url: "/role/selectRoleList",
+ method: "get",
+ });
+}
+// 鑾峰彇鍗曚綅
+export function selectCustomEnum() {
+ return request({
+ url: "/system/custom/selectCustomEnum",
+ method: "get",
+ });
+}
+// 鎻愪氦娣诲姞鏋舵瀯淇℃伅
+export function addDepartment(data) {
+ return request({
+ url: "/department/addDepartment",
+ method: "post",
+ data: data,
+ });
+}
+// 鑾峰彇褰撳墠鐧诲綍浜哄憳閮ㄩ棬
+export function selectUserDepartmentLimsName(query) {
+ return request({
+ url: "/system/newUser/selectUserDepartmentLimsName",
+ method: "get",
+ });
+}
+// 鑾峰彇鐢ㄦ埛鍒楄〃
+export function selectUserCondition(query) {
+ return request({
+ url: "/system/newUser/selectUserCondition",
+ method: "get",
+ params: query,
+ });
}
--
Gitblit v1.9.3