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
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
17 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 {
item
.
attContent
=
JSON
.
stringify
(
item
.
attContent
)
}
})
preList
=
preList
.
filter
(
item
=>
{
return
item
.
attType
!=
1
||
item
.
attContent
.
trim
()
})
const
targetItem
=
this
.
numberTypeList
.
find
(
item
=>
{
return
item
.
dictLabel
==
this
.
clientType
})
...
...
src/views/expert/index.vue
View file @
6dacf54
...
...
@@ -33,13 +33,11 @@
<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>
{{ 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>
<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=
"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>
</GLTable>
<div
v-if=
"!hasData"
class=
"default-box"
>
...
...
src/views/ghPreSale/editEquity.vue
View file @
6dacf54
...
...
@@ -278,6 +278,13 @@ export default {
return
value
?
callback
()
:
callback
(
new
Error
(
'请输入证件号码'
))
},
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
:
[
...
...
@@ -287,7 +294,7 @@ export default {
let
phoneReg
=
/^
(
13
[
0-9
]
|15
[
0-9
]
|16
[
0-9
]
|17
[
0-9
]
|18
[
0-9
]
|19
[
0-9
]
|14
[
0-9
])[
0-9
]{8}
$/
return
phoneReg
.
test
(
value
)
?
callback
()
:
callback
(
new
Error
(
'请输入正确的联系号码'
))
},
trigger
:
'change'
trigger
:
'change'
}
],
customerAddress
:
[{
required
:
true
,
message
:
'请输入联系地址'
,
trigger
:
'change'
}]
...
...
@@ -306,6 +313,7 @@ export default {
this
.
editForm
.
cardType
=
value
var
idx
=
this
.
editFormDataUser
.
findIndex
(
item
=>
item
.
name
==
'cardNo'
)
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 {
label
:
'身份证'
,
name
:
'cardNo'
,
type
:
'input'
,
maxlength
:
30
maxlength
:
18
},
{
label
:
'联系号码'
,
...
...
@@ -375,7 +383,7 @@ export default {
],
servicePeriod
:
[{
required
:
true
,
message
:
'请选择服务期限'
,
trigger
:
'change'
}],
effectiveDate
:
[{
required
:
true
,
message
:
'请选择生效日期'
,
trigger
:
'change'
}],
actualSalesPersonId
:
[{
required
:
true
,
message
:
'请输入实际销售人'
,
trigger
:
'change'
}]
//
actualSalesPersonId: [{ required: true, message: '请输入实际销售人', trigger: 'change' }]
},
editFormDataOther
:
[
{
...
...
@@ -1023,29 +1031,34 @@ export default {
updateEquity
(
params
)
{
const
loading
=
this
.
$loading
({
lock
:
true
,
text
:
'
Loading
'
,
text
:
'
结果处理中···
'
,
spinner
:
'el-icon-loading'
,
background
:
'rgba(0, 0, 0, 0.3)'
})
this
.
$apis
.
ghBeforeSale
.
updateEquityApi
(
params
).
then
(
res
=>
{
loading
.
close
()
this
.
submit
=
false
if
(
res
.
errId
==
'A1307'
)
{
loading
.
close
()
this
.
whereToGo
(
'vin'
)
this
.
$message
({
message
:
res
.
message
,
type
:
'error'
})
}
else
{
this
.
$message
({
message
:
res
.
code
==
'0'
?
'提交成功待ERP审核'
:
res
.
message
,
type
:
res
.
code
==
'0'
?
'success'
:
'error'
})
this
.
$router
.
push
({
path
:
'/ghPreSale/equityList'
,
// name: 'beforeSale',
params
:
res
})
// this.$message({
// message: res.code=='0'?'提交成功待ERP审核':res.message,
// type:res.code=='0'? 'success':'error'
// })
setTimeout
(()
=>
{
loading
.
close
()
this
.
$router
.
push
({
path
:
'/ghPreSale/equityList'
,
// name: 'beforeSale',
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