Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
9
91isoft_web_vue
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
张伯涛
91isoft_web_vue
Commits
438f004c
Commit
438f004c
authored
Jun 07, 2024
by
张伯涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
表单管理-图片菜单
parent
eb683ce6
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
105 additions
and
0 deletions
+105
-0
index.js
src/router/index.js
+15
-0
imgForm.vue
src/views/formManage/imgForm.vue
+90
-0
No files found.
src/router/index.js
View file @
438f004c
...
...
@@ -81,6 +81,21 @@ export const constantRoutes = [
meta
:
{
title
:
'修改密码'
,
icon
:
'dashboard'
}
}]
},
{
path
:
'/formManage'
,
component
:
Layout
,
name
:
'formManage'
,
redirect
:
'/formManage/imgForm'
,
meta
:
{
title
:
'表单管理'
,
icon
:
'dashboard'
},
showFather
:
'true'
,
children
:
[{
path
:
'/formManage/imgForm'
,
name
:
'imgForm'
,
component
:
()
=>
import
(
'@/views/formManage/imgForm'
),
meta
:
{
title
:
'图片菜单'
,
icon
:
'dashboard'
}
}
]
},
{
path
:
'/onlyOffice'
,
component
:
(
resolve
)
=>
require
([
'@/views/onlyOffice.vue'
],
resolve
),
...
...
src/views/formManage/imgForm.vue
0 → 100644
View file @
438f004c
<
template
>
<div
class=
"imgForm_module"
>
<el-table
border
:data=
"dataList"
>
<el-table-column
type=
"index"
label=
"序号"
width=
"60px"
align=
"center"
/>
<el-table-column
label=
"图片"
prop=
"url"
:show-overflow-tooltip=
"true"
width=
"150px"
>
<template
slot-scope=
"scope"
>
<div
:id=
"step(scope.$index)"
>
<el-image
style=
"width:100%;height:100%;"
:src=
"scope.row.url"
:preview-src-list=
"[scope.row.url]"
@
click=
"handleClickStop(scope.$index)"
>
<div
slot=
"error"
class=
"image-slot"
>
<i
class=
"el-icon-picture-outline"
/>
</div>
</el-image>
</div>
</
template
>
</el-table-column>
<el-table-column
label=
"名称"
prop=
"name"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
name
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"年龄"
prop=
"age"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
age
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"性别"
prop=
"sex"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
sex
||
'-'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"education"
prop=
"education"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
{{
scope
.
row
.
education
||
'-'
}}
</
template
>
</el-table-column>
</el-table>
</div>
</template>
<
script
>
export
default
{
name
:
'ImgForm'
,
data
()
{
return
{
dataList
:
[
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
},
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
},
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
},
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
},
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
},
{
url
:
require
(
'@/assets/image/profile.jpg'
),
name
:
'张三'
,
sex
:
'男'
,
age
:
'18'
,
education
:
'大专'
}
]
}
},
created
()
{
},
mounted
()
{
},
methods
:
{
/** 列表图片唯一标识*/
step
(
index
)
{
return
'step'
+
index
},
/** 点击蒙版关闭预览图片*/
handleClickStop
(
imageId
)
{
this
.
$nextTick
(()
=>
{
var
domImageView
=
document
.
querySelector
(
`#
${
this
.
step
(
imageId
)}
.el-image-viewer__mask`
)
if
(
!
domImageView
)
{
return
}
var
closeButton
=
document
.
querySelector
(
`#
${
this
.
step
(
imageId
)}
.el-image-viewer__close`
)
domImageView
.
addEventListener
(
'click'
,
()
=>
{
closeButton
.
click
()
})
})
}
}
}
</
script
>
<
style
scoped
lang=
"scss"
>
.imgForm_module
{
}
</
style
>
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