Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-services
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 6dacf546
authored
May 27, 2022
by
张权
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
校验证件号与等待五秒跳转
1 parent
78a6b119
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
11 deletions
src/views/expert/detail.vue
src/views/expert/index.vue
src/views/ghPreSale/editEquity.vue
src/views/expert/detail.vue
View file @
6dacf54
...
@@ -185,6 +185,9 @@ export default {
...
@@ -185,6 +185,9 @@ export default {
item
.
attContent
=
JSON
.
stringify
(
item
.
attContent
)
item
.
attContent
=
JSON
.
stringify
(
item
.
attContent
)
}
}
})
})
preList
=
preList
.
filter
(
item
=>
{
return
item
.
attType
!=
1
||
item
.
attContent
.
trim
()
})
const
targetItem
=
this
.
numberTypeList
.
find
(
item
=>
{
const
targetItem
=
this
.
numberTypeList
.
find
(
item
=>
{
return
item
.
dictLabel
==
this
.
clientType
return
item
.
dictLabel
==
this
.
clientType
})
})
...
...
src/views/expert/index.vue
View file @
6dacf54
...
@@ -33,13 +33,11 @@
...
@@ -33,13 +33,11 @@
<span
slot=
"status"
slot-scope=
"scope"
>
<span
slot=
"status"
slot-scope=
"scope"
>
<!-- <el-switch :value="scope.scope.status == 0" active-color="#5850ff" inactive-color="#eee" @change="changStatus(scope.scope.status, scope.scope.id)"></el-switch>
<!-- <el-switch :value="scope.scope.status == 0" active-color="#5850ff" inactive-color="#eee" @change="changStatus(scope.scope.status, scope.scope.id)"></el-switch>
{{ scope.scope.status == 0 ? '启用' : '停用' }} -->
{{ scope.scope.status == 0 ? '启用' : '停用' }} -->
<GLButton
class=
"switch"
mode=
"el-switch"
fn=
"禁用"
:value=
"scope.scope.status == 0"
active-color=
"#5850ff"
inactive-color=
"#eee"
:active-text=
"scope.scope.status == 0 ? '启用' : '停用'"
@
change=
"changStatus(scope.scope.status, scope.scope.id)"
>
{{ scope.scope.status == 0 ? '启用' : '停用' }}
</GLButton>
<GLButton
v-if=
"userType != 2"
class=
"switch"
mode=
"el-switch"
fn=
"禁用"
:value=
"scope.scope.status == 0"
active-color=
"#5850ff"
inactive-color=
"#eee"
:active-text=
"scope.scope.status == 0 ? '启用' : '停用'"
@
change=
"changStatus(scope.scope.status, scope.scope.id)"
>
{{ scope.scope.status == 0 ? '启用' : '停用' }}
</GLButton>
</span>
</span>
<div
class=
"table-btns"
slot=
"table-btns"
slot-scope=
"scope"
>
<div
class=
"table-btns"
slot=
"table-btns"
slot-scope=
"scope"
>
<GLButton
v-if=
"userType != 2"
fn=
"编辑"
type=
"text"
@
click=
"selectClientType(scope.scope.businessTypeName, scope.scope.id)"
>
编辑
</GLButton>
<GLButton
v-if=
"userType != 2"
fn=
"编辑"
type=
"text"
@
click=
"selectClientType(scope.scope.businessTypeName, scope.scope.id)"
>
编辑
</GLButton>
<GLButton
v-if=
"userType != 2"
fn=
"删除"
type=
"text"
@
click=
"handleDel(scope.scope)"
>
删除
</GLButton>
<GLButton
v-if=
"userType != 2"
fn=
"删除"
type=
"text"
@
click=
"handleDel(scope.scope)"
>
删除
</GLButton>
<!-- <el-button v-if="userType != 2" fn="编辑" type="text" @click="selectClientType(scope.scope.businessTypeName, scope.scope.id)">编辑</el-button>
<el-button v-if="userType != 2" fn="删除" type="text" @click="handleDel(scope.scope)">删除</el-button> -->
</div>
</div>
</GLTable>
</GLTable>
<div
v-if=
"!hasData"
class=
"default-box"
>
<div
v-if=
"!hasData"
class=
"default-box"
>
...
...
src/views/ghPreSale/editEquity.vue
View file @
6dacf54
...
@@ -278,6 +278,13 @@ export default {
...
@@ -278,6 +278,13 @@ export default {
return
value
?
callback
()
:
callback
(
new
Error
(
'请输入证件号码'
))
return
value
?
callback
()
:
callback
(
new
Error
(
'请输入证件号码'
))
},
},
trigger
:
'change'
trigger
:
'change'
},
{
validator
:
(
rule
,
value
,
callback
)
=>
{
let
reg
=
(
this
.
editForm
.
cardType
==
1
||
this
.
editForm
.
cardType
==
2
)
?
(
/
[
a-zA-Z0-9
]{18}
/
).
test
(
value
)
:
(
/
\S\s{0,18}
/
).
test
(
value
)
let
tip
=
(
this
.
editForm
.
cardType
==
1
||
this
.
editForm
.
cardType
==
2
)
?
'请输入18位数字或字母'
:
'请输入证件号码'
return
reg
?
callback
()
:
callback
(
new
Error
(
tip
))
},
trigger
:
'change'
}
}
],
],
customerPhone
:
[
customerPhone
:
[
...
@@ -306,6 +313,7 @@ export default {
...
@@ -306,6 +313,7 @@ export default {
this
.
editForm
.
cardType
=
value
this
.
editForm
.
cardType
=
value
var
idx
=
this
.
editFormDataUser
.
findIndex
(
item
=>
item
.
name
==
'cardNo'
)
var
idx
=
this
.
editFormDataUser
.
findIndex
(
item
=>
item
.
name
==
'cardNo'
)
this
.
editFormDataUser
[
idx
].
label
=
this
.
baseData
.
cardTypeList
.
find
(
item
=>
item
.
confId
==
value
).
confName
this
.
editFormDataUser
[
idx
].
label
=
this
.
baseData
.
cardTypeList
.
find
(
item
=>
item
.
confId
==
value
).
confName
this
.
$refs
.
editFormRefUser
.
$refs
.
editChildRefUser
.
validateField
(
'cardNo'
)
}
}
},
},
{
{
...
@@ -329,7 +337,7 @@ export default {
...
@@ -329,7 +337,7 @@ export default {
label
:
'身份证'
,
label
:
'身份证'
,
name
:
'cardNo'
,
name
:
'cardNo'
,
type
:
'input'
,
type
:
'input'
,
maxlength
:
30
maxlength
:
18
},
},
{
{
label
:
'联系号码'
,
label
:
'联系号码'
,
...
@@ -375,7 +383,7 @@ export default {
...
@@ -375,7 +383,7 @@ export default {
],
],
servicePeriod
:
[{
required
:
true
,
message
:
'请选择服务期限'
,
trigger
:
'change'
}],
servicePeriod
:
[{
required
:
true
,
message
:
'请选择服务期限'
,
trigger
:
'change'
}],
effectiveDate
:
[{
required
:
true
,
message
:
'请选择生效日期'
,
trigger
:
'change'
}],
effectiveDate
:
[{
required
:
true
,
message
:
'请选择生效日期'
,
trigger
:
'change'
}],
actualSalesPersonId
:
[{
required
:
true
,
message
:
'请输入实际销售人'
,
trigger
:
'change'
}]
//
actualSalesPersonId: [{ required: true, message: '请输入实际销售人', trigger: 'change' }]
},
},
editFormDataOther
:
[
editFormDataOther
:
[
{
{
...
@@ -1023,29 +1031,34 @@ export default {
...
@@ -1023,29 +1031,34 @@ export default {
updateEquity
(
params
)
{
updateEquity
(
params
)
{
const
loading
=
this
.
$loading
({
const
loading
=
this
.
$loading
({
lock
:
true
,
lock
:
true
,
text
:
'
Loading
'
,
text
:
'
结果处理中···
'
,
spinner
:
'el-icon-loading'
,
spinner
:
'el-icon-loading'
,
background
:
'rgba(0, 0, 0, 0.3)'
background
:
'rgba(0, 0, 0, 0.3)'
})
})
this
.
$apis
.
ghBeforeSale
.
updateEquityApi
(
params
).
then
(
res
=>
{
this
.
$apis
.
ghBeforeSale
.
updateEquityApi
(
params
).
then
(
res
=>
{
loading
.
close
()
this
.
submit
=
false
this
.
submit
=
false
if
(
res
.
errId
==
'A1307'
)
{
if
(
res
.
errId
==
'A1307'
)
{
loading
.
close
()
this
.
whereToGo
(
'vin'
)
this
.
whereToGo
(
'vin'
)
this
.
$message
({
this
.
$message
({
message
:
res
.
message
,
message
:
res
.
message
,
type
:
'error'
type
:
'error'
})
})
}
else
{
}
else
{
this
.
$message
({
// this.$message({
message
:
res
.
code
==
'0'
?
'提交成功待ERP审核'
:
res
.
message
,
// message: res.code=='0'?'提交成功待ERP审核':res.message,
type
:
res
.
code
==
'0'
?
'success'
:
'error'
// type:res.code=='0'? 'success':'error'
})
// })
setTimeout
(()
=>
{
loading
.
close
()
this
.
$router
.
push
({
this
.
$router
.
push
({
path
:
'/ghPreSale/equityList'
,
path
:
'/ghPreSale/equityList'
,
// name: 'beforeSale',
// name: 'beforeSale',
params
:
res
params
:
res
})
})
},
5000
)
}
}
})
})
},
},
...
...
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