Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CivManage
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ReactWeb5
CivManage
Commits
ff96c01d
Commit
ff96c01d
authored
Feb 06, 2025
by
涂伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: '用户导入导出逻辑优化'
parent
c9796a25
Pipeline
#95420
failed with stages
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
15 deletions
+23
-15
用户导出模板.xls
public/用户导出模板.xls
+0
-0
UserManage.jsx
src/pages/userCenter/userManage/UserManage.jsx
+23
-15
No files found.
public/用户导出模板.xls
0 → 100644
View file @
ff96c01d
File added
src/pages/userCenter/userManage/UserManage.jsx
View file @
ff96c01d
...
...
@@ -79,6 +79,7 @@ import {
ChangeSMSState
,
AddUserAppBindWhiteList
,
ExportUserData
,
ExportUserTemplate
,
ImportUserData
,
GetPasswordRegularization
,
SysConfiguration
...
...
@@ -100,6 +101,8 @@ const TdCell = props => {
return
<
td
{
...
restProps
}
/>;
};
const
path
=
require
(
'path'
);
const
UserManage
=
()
=>
{
const
[
selectValue
,
setSelctValue
]
=
useState
();
// 用户鉴权
...
...
@@ -947,21 +950,26 @@ const UserManage = () => {
/** ***其他操作*** */
// 导出用户
const exportRoles = async (data) => {
// menuID
// searchWord
// pageSize
// currentPage
ExportUserData({
groupId: data.all ? 0 : menuID ? menuID : 0,
key: data.all ? '' : searchWord,
isModel: data.isModal ? true : false,
}).then(res => {
// window.open(`http:192.168.10.167:8088/${res.data}`)
window.open(`${window.origin}/${res.data}`)
console.log(res, '
resssssssssssssssssss
');
})
if(data.isModal){
let downloadLink = document.createElement('
a
');
downloadLink.href = path.join(__dirname, `/civmanage/用户导出模板.xls`);
downloadLink.download = '
用户导出模板
.
xls
';
document.body.appendChild(downloadLink);
downloadLink.click();
document.body.removeChild(downloadLink);
} else {
ExportUserData({
groupId: data.all ? 0 : menuID ? menuID : 0,
key: data.all ? '' : searchWord,
isModel: data.isModal ? true : false,
}).then(res => {
// window.open(`http:192.168.10.167:8088/${res.data}`)
window.open(`${window.origin}/${res.data}`)
console.log(res, '
resssssssssssssssssss
');
})
}
}
// 导入用户
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment