Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-drainage
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 ae7c5c21
authored
Sep 09, 2022
by
xuyl
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修复上传头像校验,tab切换,访问量为0跳转问题
1 parent
5f7d6af5
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
4 deletions
src/mixins/upload.js
src/views/businessCard/addCode.vue
src/views/businessCard/components/cardList.vue
src/views/businessCard/components/recordList.vue
src/mixins/upload.js
View file @
ae7c5c2
...
...
@@ -35,6 +35,7 @@ export default {
if
(
res
)
{
if
(
!
this
.
addCodeForm
.
headerSrc
)
{
this
.
addCodeForm
.
image
=
res
this
.
hasImage
=
true
}
else
{
this
.
addCodeForm
.
headerSrc
=
res
}
...
...
src/views/businessCard/addCode.vue
View file @
ae7c5c2
...
...
@@ -41,8 +41,11 @@
<div
class=
"upload-text"
>
上传头像
</div>
<input
type=
"file"
style=
"opacity: 0"
ref=
"avatar"
accept=
"*"
@
change=
"uploadAvatar"
/>
</div>
<div
class=
"el-form-item__error"
v-if=
"!hasImage"
>
请上传头像
</div>
</div>
</div>
<!--
<el-form-item
label=
"联系电话:"
prop=
"agentPhone"
>
-->
<!--
<el-input
size=
"small"
v-model
.
trim=
"addCodeForm.agentPhone"
placeholder=
"请输入联系电话"
maxlength=
"30"
></el-input>
-->
<!--
</el-form-item>
-->
...
...
@@ -113,6 +116,7 @@ export default {
components
:
{
selectEmpRadio
,
selectTag
},
data
()
{
return
{
hasImage
:
true
,
dialogSrc
:
''
,
dialogVisibleImg
:
false
,
dialogVisible
:
false
,
...
...
@@ -132,7 +136,7 @@ export default {
previewListStart
:
[],
codeRules
:
{
cardName
:
[{
required
:
true
,
message
:
'请输入渠道名称'
,
trigger
:
'blur'
}],
// agentPhone: [{ required: true, message: '请输入联系电话', trigger: 'blur
' }],
image
:
[{
required
:
true
,
message
:
'请上传头像'
,
trigger
:
'change
'
}],
operation
:
[{
required
:
true
,
message
:
'请输入对外职务'
,
trigger
:
'blur'
}]
}
}
...
...
@@ -222,6 +226,10 @@ export default {
this
.
staffStatus
=
true
return
}
if
(
this
.
addCodeForm
&&
!
this
.
addCodeForm
.
image
)
{
this
.
hasImage
=
false
return
}
this
.
$refs
[
'codeForm'
].
validate
(
valid
=>
{
if
(
valid
)
{
let
param
=
Object
.
assign
({
id
:
this
.
codeId
},
this
.
addCodeForm
)
...
...
src/views/businessCard/components/cardList.vue
View file @
ae7c5c2
...
...
@@ -13,7 +13,7 @@
<GLTableButton
:buttonList=
"tableButtonList"
:buttonItem=
"scope.scope"
:buttonNum=
"3"
></GLTableButton>
</div>
<div
slot=
"visitCont"
slot-scope=
"scope"
>
<div
class=
"visitCont"
@
click=
"visitCisitCont(scope.scope
.cardName
)"
>
{{
scope
.
scope
.
visitCont
||
'--'
}}
</div>
<div
class=
"visitCont"
@
click=
"visitCisitCont(scope.scope)"
>
{{
scope
.
scope
.
visitCont
||
'--'
}}
</div>
</div>
<div
slot=
"qrCode"
slot-scope=
"scope"
>
<el-popover
placement=
"bottom"
width=
"400"
trigger=
"hover"
>
...
...
@@ -179,7 +179,9 @@ export default {
},
methods
:
{
// 跳转访问量
visitCisitCont
(
cardName
)
{
visitCisitCont
(
scope
)
{
const
{
cardName
,
visitCont
}
=
scope
if
(
!
visitCont
)
return
this
.
$parent
.
query
=
{
cardName
}
this
.
$parent
.
activeName
=
'2'
},
...
...
src/views/businessCard/components/recordList.vue
View file @
ae7c5c2
...
...
@@ -153,7 +153,7 @@ export default {
}
},
mounted
()
{
if
(
this
.
$parent
.
query
)
{
if
(
this
.
$parent
.
query
&&
this
.
$parent
.
query
.
cardName
)
{
let
{
cardName
}
=
this
.
$parent
.
query
this
.
timeRadio
=
this
.
dateInterval
=
4
this
.
$set
(
this
.
tableSearchForm
,
'cardName'
,
cardName
)
...
...
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