Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
杨明
/
scrm-micro-config
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 899456e5
authored
Nov 05, 2021
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
提交
1 parent
28f5db39
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
src/views/employee/editEmployee.vue
src/views/employee/glsx-combi-form/index.vue
src/views/employee/editEmployee.vue
View file @
899456e
<
template
>
<div
class=
"config-employee"
>
<div
class=
"container"
style=
"margin-top: 0
;
"
>
<div
class=
"container"
style=
"margin-top: 0"
>
<p
class=
"edit-title"
>
{{
title
}}
</p>
</div>
<div
class=
"container"
>
...
...
@@ -163,7 +163,7 @@ export default {
maxPhotoNum
:
1
,
// wdithLt: 800,
// heightLt: 640,
noPixel
:
tru
e
,
hasPixel
:
fals
e
,
handleUpload
:
(
e
,
file
,
targetItem
)
=>
{
const
imgFile
=
e
.
target
.
result
const
base64
=
file
.
name
.
split
(
'.'
)[
1
]
+
'@'
+
imgFile
.
split
(
','
)[
1
]
...
...
@@ -198,7 +198,7 @@ export default {
merchantTree
:
[],
roleList
:
[]
}
}
;
}
},
watch
:
{
...
...
@@ -366,7 +366,7 @@ export default {
this
.
getAllMerchantList
()
this
.
routeInfo
.
addOrEdit
!=
1
?
this
.
getInfo
()
:
''
}
}
;
}
</
script
>
<
style
>
...
...
src/views/employee/glsx-combi-form/index.vue
View file @
899456e
...
...
@@ -57,7 +57,7 @@
<div
v-if=
"Array.isArray(formObj[item.name]) ? formObj[item.name].length
< item
.
maxPhotoNum
:
!
formObj
[
item
.
name
]"
class=
"activity-img img-w-h"
>
<div
class=
"add"
>
+
</div>
<span
class=
"number"
>
{{
formObj
[
item
.
name
].
length
}}
/
{{
item
.
maxPhotoNum
}}
</span>
<input
type=
"file"
style=
"opacity: 0
;
"
:id=
"item.name + 'file'"
ref=
"file"
class=
"activity-img img-w-h"
accept=
"image/png, image/jpeg, image/gif, image/jpg"
@
change=
"e => handleImgChange(e, item)"
/>
<input
type=
"file"
style=
"opacity: 0"
:id=
"item.name + 'file'"
ref=
"file"
class=
"activity-img img-w-h"
accept=
"image/png, image/jpeg, image/gif, image/jpg"
@
change=
"e => handleImgChange(e, item)"
/>
</div>
</div>
<template>
...
...
@@ -189,7 +189,7 @@ export default {
image
.
onload
=
()
=>
{
var
imgWidth
=
image
.
width
var
imgHeight
=
image
.
height
if
(
!
targetItem
.
noPixel
&&
(
imgWidth
>
wdithLt
||
imgHeight
>
heightLt
))
{
if
(
targetItem
.
hasPixel
&&
(
imgWidth
>
wdithLt
||
imgHeight
>
heightLt
))
{
this
.
$message
.
error
(
'图片尺寸最大为'
+
wdithLt
+
'像素*'
+
heightLt
+
'像素'
)
}
else
{
targetItem
.
handleUpload
(
e
,
file
,
targetItem
)
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment