Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-life-h5-ailipay
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 ebbb15c4
authored
Jan 21, 2022
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit
1 parent
0d0f29d4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
51 additions
and
10 deletions
src/mixins/shareMixin.js
src/mixins/shareMixin.js
View file @
ebbb15c
...
@@ -52,36 +52,61 @@ export default {
...
@@ -52,36 +52,61 @@ export default {
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-yh-10004.png'
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-yh-10004.png'
if
(
false
)
{
if
(
false
)
{
// if (tabIndex == 0) {
// if (tabIndex == 0) {
let
path
=
'packageMine/pages/boutique/gift/gift'
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
appid
:
shopmall_appid
,
appid
:
shopmall_appid
,
title
:
couponName
,
title
:
couponName
,
imgUrl
,
imgUrl
,
page
:
`/
packageMine/pages/boutique/gift/gift
.html?id=
${
id
}
&userId=
${
userId
}
&employName=
${
this
.
toUnicode
(
i
.
employeeName
)}
&
${
query
}
`
page
:
`/
${
path
}
.html?id=
${
id
}
&userId=
${
userId
}
&employName=
${
this
.
toUnicode
(
i
.
employeeName
)}
&
${
query
}
`
})
})
else
boutiquecouponApi
.
getBoutiqueCoupon
({
id
}).
then
(
url
=>
{
else
wxConfig
.
createMiniprogramUrlLink
({
path
,
query
:
encodeURIComponent
(
query
),
appId
:
shopmall_appid
})
.
then
(
url
=>
{
this
.
shareAppMessage
(
url
,
desc
,
couponName
,
imgUrl
)
this
.
shareAppMessage
(
url
,
desc
,
couponName
,
imgUrl
)
})
})
}
else
{
}
else
{
let
path
=
'packageMall/pages/coupon/coupon'
query
=
`couponId=
${
id
}
&
${
query
}
&issueName=
${
this
.
toUnicode
(
userName
)}
&issueDate=
${
new
Date
().
getTime
()}
`
this
.
couponShare
(
i
,
url
=>
{
this
.
couponShare
(
i
,
url
=>
{
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
appid
:
shopmall_appid
,
appid
:
shopmall_appid
,
title
:
`
${
couponName
}
(
${
window
.
$discountType
[
discountType
]}
券)`
,
title
:
`
${
couponName
}
(
${
window
.
$discountType
[
discountType
]}
券)`
,
imgUrl
,
imgUrl
,
page
:
`/packageMall/pages/coupon/coupon.html?couponId=
${
id
}
&
${
query
}
&issueName=
${
this
.
toUnicode
(
userName
)}
&issueDate=
${
new
Date
().
getTime
()}
`
page
:
`/
${
path
}
.html?
${
query
}
`
})
else
wxConfig
.
createMiniprogramUrlLink
({
path
,
query
:
encodeURIComponent
(
query
),
appId
:
shopmall_appid
})
.
then
(
url
=>
{
this
.
shareAppMessage
(
url
,
desc
,
couponName
,
imgUrl
)
})
})
else
this
.
shareAppMessage
(
url
,
desc
,
couponName
,
imgUrl
)
})
})
}
}
}
else
if
(
name
===
'activity'
)
{
/**活动 */
}
else
if
(
name
===
'activity'
)
{
/**活动 */
if
(
tabIndex
==
0
)
{
if
(
tabIndex
==
0
)
{
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-ms-10004.png'
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-ms-10004.png'
let
path
=
'packageMall/pages/detail/detail'
query
=
`isActivity=true&id=
${
id
}
&
${
query
}
`
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
appid
:
shopmall_appid
,
appid
:
shopmall_appid
,
title
:
activityName
,
title
:
activityName
,
imgUrl
,
imgUrl
,
page
:
`/
packageMall/pages/detail/detail.html?isActivity=true&id=
${
id
}
&
${
query
}
`
page
:
`/
${
path
}
.html?
${
query
}
`
})
})
else
activityApi
.
getShared
({
id
}).
then
(
url
=>
{
else
wxConfig
.
createMiniprogramUrlLink
({
path
,
query
:
encodeURIComponent
(
query
),
appId
:
shopmall_appid
})
.
then
(
url
=>
{
this
.
shareAppMessage
(
url
,
'您有一个秒杀活动可参加'
,
activityName
,
imgUrl
)
this
.
shareAppMessage
(
url
,
'您有一个秒杀活动可参加'
,
activityName
,
imgUrl
)
})
})
}
else
{
}
else
{
...
@@ -107,24 +132,40 @@ export default {
...
@@ -107,24 +132,40 @@ export default {
this
.
shareAppMessage
(
url
,
''
,
merchantName
,
imgUrl
)
this
.
shareAppMessage
(
url
,
''
,
merchantName
,
imgUrl
)
})
})
}
else
if
(
tabIndex
==
1
)
{
}
else
if
(
tabIndex
==
1
)
{
let
path
=
'packageEquity/pages/package/package'
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-qy-10004.png'
let
imgUrl
=
'http://img01.glsx.com.cn/upload/biz/dracMini-qy-10004.png'
query
=
`id=
${
id
}
&
${
query
}
`
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
appid
:
shopmall_appid
,
appid
:
shopmall_appid
,
title
:
packageName
,
title
:
packageName
,
imgUrl
,
imgUrl
,
page
:
`/packageEquity/pages/package/package.html?id=
${
id
}
&
${
query
}
`
page
:
`/
${
path
}
.html?
${
query
}
`
})
else
wxConfig
.
createMiniprogramUrlLink
({
path
,
query
:
encodeURIComponent
(
query
),
appId
:
shopmall_appid
})
})
else
equityApi
.
getEquityShared
({
id
}).
then
(({
url
})
=>
{
.
then
(
url
=>
{
this
.
shareAppMessage
(
url
,
'您的专属客服顾问为您发来了会员套餐,点击查看哦'
,
packageName
,
imgUrl
)
this
.
shareAppMessage
(
url
,
'您的专属客服顾问为您发来了会员套餐,点击查看哦'
,
packageName
,
imgUrl
)
})
})
}
else
{
}
else
{
let
path
=
'packageMall/pages/detail/detail'
query
=
`id=
${
id
}
&
${
query
}
`
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
if
(
entry
!=
'normal'
)
this
.
sendChatMessage
({
appid
:
shopmall_appid
,
appid
:
shopmall_appid
,
title
:
goodsName
,
title
:
goodsName
,
imgUrl
:
goodsImage
,
imgUrl
:
goodsImage
,
page
:
`/packageMall/pages/detail/detail.html?id=
${
id
}
&
${
query
}
`
page
:
`/
${
path
}
.html?
${
query
}
`
})
else
wxConfig
.
createMiniprogramUrlLink
({
path
,
query
:
encodeURIComponent
(
query
),
appId
:
shopmall_appid
})
})
else
shopmallApi
.
getGoodsLink
({
id
})
.
then
(
url
=>
{
.
then
(
url
=>
{
this
.
shareAppMessage
(
url
,
''
,
goodsName
,
goodsImage
)
this
.
shareAppMessage
(
url
,
''
,
goodsName
,
goodsImage
)
})
})
}
}
...
...
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