Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pptist
Project
Project
Details
Activity
Releases
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
viitto
pptist
Commits
745591f8
Commit
745591f8
authored
May 28, 2024
by
黄奎
Browse files
Options
Browse Files
Download
Plain Diff
111
parents
9bc9541a
2e29e609
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
58 additions
and
3 deletions
+58
-3
domainManager.ts
src/utils/domainManager.ts
+4
-2
InviteMember.vue
src/views/components/Team/InviteMember.vue
+54
-1
No files found.
src/utils/domainManager.ts
View file @
745591f8
export
const
domainManager
=
()
=>
{
const
locationName
=
window
.
location
.
hostname
const
obj
=
{
domainUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"https://reborn.oytour.com/api/common/post"
:
"http://192.168.
10.214
/api/common/post"
,
domainUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"https://reborn.oytour.com/api/common/post"
:
"http://192.168.
5.46
/api/common/post"
,
//上传站点
UploadUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"https://upload.oytour.com"
:
"http://192.168.5.46:8120"
,
//文件站点
ViittoFileUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"http://imgfile.oytour.com"
:
'http://192.168.
10.214
:8130'
,
ViittoFileUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"http://imgfile.oytour.com"
:
'http://192.168.
5.46
:8130'
,
// 通知erp
notificationUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"http://yx.oytour.com"
:
"http://localhost:8081"
,
// 文件下载地址
DownloadUrl
:
locationName
.
indexOf
(
'oytour'
)
!==
-
1
?
"https://reborn.oytour.com"
:
"http://192.168.5.46"
,
}
return
obj
}
\ No newline at end of file
src/views/components/Team/InviteMember.vue
View file @
745591f8
<
template
>
<el-dialog
v-model=
"show"
title=
"邀请成员"
style=
"width:744px;"
@
close=
"closed"
class=
"bold-head q-pa-none"
>
<div
class=
"row"
style=
"height: 440px;"
>
<div
class=
"row"
style=
"
min-
height: 440px;"
>
<div
class=
"q-pa-md full-height"
style=
"width:164px; border-right: 1px solid #f1f2f4;"
>
<el-menu
class=
"no-border md-menu"
:default-active=
"currentMenu"
>
<el-menu-item
index=
"1"
@
click=
"currentMenu = '1'"
>
邀请成员
</el-menu-item>
...
...
@@ -75,6 +75,44 @@
</div>
</div>
</el-dialog>
<el-dialog
v-model=
"dialogVisible"
title=
"导入成员名单提示"
width=
"500"
@
close=
"closeUploadRes"
>
<div
class=
"row"
>
<div>
<el-alert
show-icon
title=
"人员总数"
type=
"info"
:closable=
"false"
>
<i
class=
"el-icon-coin"
></i>
<span>
{{UploadResults.totalNum}}
</span>
</el-alert>
</div>
<div
class=
"q-px-md"
>
<el-alert
show-icon
title=
"成功人数"
type=
"success"
:closable=
"false"
>
<i
class=
"el-icon-coin"
></i>
<span>
{{UploadResults.successNum}}
</span>
</el-alert>
</div>
<div>
<el-alert
show-icon
title=
"失败人数"
type=
"warning"
:closable=
"false"
>
<i
class=
"el-icon-coin"
></i>
<span
class=
"row"
>
<span>
{{UploadResults.failNum}}
</span>
<span
class=
"col text-primary row items-center cusor-pointer q-ml-md"
@
click=
"goDownload(1)"
>
<IconToBottom
size=
"16"
class=
"q-mr-sm"
></IconToBottom>
<span>
下载失败数据
</span>
</span>
</span>
</el-alert>
</div>
</div>
<
template
#
footer
>
<div
class=
"dialog-footer"
>
<el-button
@
click=
"dialogVisible = false"
>
关闭
</el-button>
<!--
<el-button
type=
"primary"
@
click=
"dialogVisible = false"
>
确定
</el-button>
-->
</div>
</
template
>
</el-dialog>
</template>
<
script
lang=
"ts"
setup
>
...
...
@@ -87,6 +125,7 @@ import { ElMessage } from "element-plus"
import
{
storeToRefs
}
from
"pinia"
import
{
ref
,
unref
}
from
"vue"
import
{
domainManager
}
from
'@/utils/domainManager'
import
{
ElAlert
}
from
'element-plus'
;
const
props
=
defineProps
({
showType
:
{
...
...
@@ -107,11 +146,20 @@ const popoverRef = ref()
const
copyLoading
=
ref
(
false
)
const
useUser
=
useUserStore
()
const
{
userInfo
}
=
storeToRefs
(
useUser
)
const
dialogVisible
=
ref
(
false
)
const
UploadResults
=
ref
({}
as
any
)
const
closeUploadRes
=
()
=>
{
UploadResults
.
value
=
{}
}
const
closed
=
()
=>
{
emit
(
'close'
)
}
const
goDownload
=
(
type
:
any
)
=>
{
if
(
type
==
1
)
window
.
open
(
UploadResults
.
value
.
DownloadUrl
)
else
window
.
open
(
UploadResults
.
value
.
DownloadUrl
)
}
//导入文件地址
const
getUploadActionUrl
=
()
=>
{
let
uid
=
userInfo
.
value
.
id
;
...
...
@@ -120,11 +168,16 @@ const getUploadActionUrl=()=>{
}
const
handleAvatarSuccess
=
async
(
res
:
any
)
=>
{
if
(
res
.
resultCode
==
0
){
UploadResults
.
value
=
res
.
data
UploadResults
.
value
.
DownloadUrl
=
domainManager
().
DownloadUrl
.
replace
(
"common"
,
"file"
)
+
`
${
res
.
data
.
failUrl
}
`
}
console
.
log
(
"handleAvatarSuccess_res"
,
res
);
}
const
beforeAvatarUpload
=
async
(
res
:
any
)
=>
{
console
.
log
(
"beforeAvatarUpload_res"
,
res
);
dialogVisible
.
value
=
true
}
const
copyInviteUrlHandler
=
async
(
e
:
MouseEvent
)
=>
{
...
...
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