Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-marketing
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 f66f4c28
authored
Jun 30, 2022
by
张权
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
第三轮bug回归
1 parent
498064e8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
5 deletions
src/views/giftBag/editGift.vue
src/views/giftBag/giftDetail.vue
src/views/giftBag/editGift.vue
View file @
f66f4c2
<!-- 编辑礼包 -->
<
template
>
<div
v-if=
"isLoaded"
class=
"edit-gift marketing p-t-20 edit-box"
>
<div
class=
"edit-gift marketing p-t-20 edit-box"
>
<div
v-if=
"routeInfo.addOrEdit != 'add'"
class=
"container approval-container"
>
<p
class=
"edit-title"
>
审批信息
</p>
<div
class=
"approval-info"
>
...
...
@@ -17,7 +17,7 @@
</div>
<div
class=
"container edit-container"
>
<p
class=
"edit-title"
>
{{
title
}}
</p>
<glsx-combi-form
class=
"edit-form-container m-r-20"
ref=
"editFormRef"
:isEdit=
"isEdit"
:labelWidth=
"labelWidth"
defaultWidth=
"415px"
:isBlock=
"true"
:formRef=
"editChildRef"
:formObj=
"editForm"
:formData=
"editFormData"
:formRules=
"editRule"
>
<glsx-combi-form
v-loading=
"loading"
class=
"edit-form-container m-r-20"
ref=
"editFormRef"
:isEdit=
"isEdit"
:labelWidth=
"labelWidth"
defaultWidth=
"415px"
:isBlock=
"true"
:formRef=
"editChildRef"
:formObj=
"editForm"
:formData=
"editFormData"
:formRules=
"editRule"
>
<div
slot=
"remarkName"
class=
"edit-tips m-t-8"
>
可根据备注名称进行查找,仅作内部查看,不展示给客户
</div>
<el-button
slot=
"selectGiftBtn"
:disabled=
"routeInfo.receivedStock"
class=
"default-blue-btn"
@
click=
"handleGiftAdd"
>
选择礼包内容
</el-button>
<div
slot=
"couponListBlock"
class=
"gift-block"
:style=
"
{ 'margin-left': labelWidth }" v-show="editForm.couponList
&&
editForm.couponList.length != 0">
...
...
@@ -113,6 +113,7 @@ export default {
return
{
phone
:
''
,
isLoaded
:
true
,
loading
:
false
,
phoneList
:
[],
size
:
'small'
,
title
:
'新增礼包'
,
...
...
@@ -412,7 +413,10 @@ export default {
this
.
editForm
.
stock
=
e
.
replace
(
/^
(
0+
)
|
[^\d]
+/g
,
''
)
},
delPhone
(
val
)
{
let
phone
=
this
.
phone
.
replace
(
new
RegExp
(
'[\n]*'
+
val
+
'[\n]*'
,
'g'
),
'\n'
)
let
phone
=
'\n'
+
this
.
phone
+
'\n'
phone
=
phone
.
replace
(
/
[\n]
/g
,
'\n\n'
)
phone
=
phone
.
replace
(
new
RegExp
(
'[\n]'
+
val
+
'[\n]'
,
'g'
),
'\n'
)
phone
=
phone
.
replace
(
/
[\n]
+/g
,
'\n'
)
phone
=
phone
.
replace
(
/^
[\n]
+/
,
''
)
this
.
phone
=
phone
this
.
formatPhone
()
...
...
@@ -438,6 +442,7 @@ export default {
},
getInfo
()
{
this
.
isLoaded
=
false
this
.
loading
=
true
this
.
$apis
.
giftBag
.
getGiftInfoApi
({
id
:
this
.
routeInfo
.
id
})
.
then
(
res
=>
{
...
...
@@ -604,6 +609,10 @@ export default {
})
if
(
this
.
editForm
.
receiveRule
==
1
)
{
params
.
receiveDetailList
=
this
.
phoneList
.
map
(
item
=>
item
.
tel
)
let
maxLength
=
250
if
(
params
.
receiveDetailList
&&
params
.
receiveDetailList
.
length
>
maxLength
){
return
this
.
$message
.
error
(
`领取
${
this
.
receiveWay
==
1
?
'手机号'
:
'车架号'
}
不能超过
${
maxLength
}
个`
)
}
params
.
receiveWay
=
this
.
receiveWay
}
delete
params
.
staffList
...
...
@@ -641,7 +650,7 @@ export default {
},
// 创建-更新接口
insertHttp
(
params
)
{
this
.
loading
=
true
//
this.loading = true
this
.
$apis
.
giftBag
.
insertGiftApi
(
params
)
.
then
(
res
=>
{
...
...
src/views/giftBag/giftDetail.vue
View file @
f66f4c2
...
...
@@ -46,7 +46,7 @@
<span
v-if=
"editForm.receiveRule == 2 && editForm.receiveWay"
>
{{
`${editForm.receiveWay == '1' ? '手机号:' : '车架号后6位:'
}
${editForm.receiveDetails
}
`
}}
<
/span
>
<
span
v
-
if
=
"editForm.receiveRule == 1"
>
{{
editForm
.
receiveWay
==
'1'
?
'指定手机号'
:
'指定车架号后6位'
}}
:
<
/span
>
<
div
v
-
if
=
"editForm.receiveRule == 1"
class
=
"phone-wrap"
>
<
span
class
=
"phone
"
v
-
for
=
"(item, id) in receiveDetailList"
:
key
=
"id"
>
{{
item
}}
<
/span
>
<
span
:
class
=
"['phone',editForm.receiveWay==1?'realTel':'realNum']
"
v
-
for
=
"(item, id) in receiveDetailList"
:
key
=
"id"
>
{{
item
}}
<
/span
>
<
/div
>
<
/div
>
<
div
slot
=
"staffListBlock"
class
=
"sale-select"
v
-
show
=
"editForm.staffList && editForm.staffList.length != 0"
>
...
...
@@ -343,6 +343,12 @@ export default {
display
:
inline
-
block
;
margin
:
5
px
16
px
5
px
0
;
}
.
realTel
{
width
:
120
px
;
}
.
realNum
{
width
:
80
px
;
}
}
// 发放员工
.
sale
-
select
{
...
...
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