Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
Y
ybf
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xulili
ybf
Commits
f1d838da
Commit
f1d838da
authored
Apr 16, 2020
by
xd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
侧边栏优惠券修改未测试
parent
5fdc149f
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
80 additions
and
63 deletions
+80
-63
index.vue
wx_application/src/views/mainSale/active/main/index.vue
+22
-17
mail.js
ybf_admin/src/api/in/mail.js
+8
-0
editGroup.vue
ybf_admin/src/pages/in/contact/components/editGroup.vue
+8
-3
index.html
ybf_wx/public/qrCode/index.html
+26
-18
index.vue
ybf_wx/src/views/sideNav/discount/index.vue
+16
-25
No files found.
wx_application/src/views/mainSale/active/main/index.vue
View file @
f1d838da
...
...
@@ -149,18 +149,18 @@ export default {
},
manInfo
:
{
bk_logoUrl
:
"https://ezhq.xyz/img/main/logo_sona.jpg"
,
logoUrl
:
"
/photo.png
"
,
barFrom
:
"
alice
"
,
barName
:
"
未配置
"
,
logoUrl
:
""
,
barFrom
:
""
,
barName
:
""
,
icon
:
{
"1"
:
"/mainSale/icon-arrow-right-light.png"
}
},
barInfo
:
{
fans
:
"
0
"
,
personalFans
:
"
0
"
,
newFans
:
"
0
"
,
allNewFans
:
"
0
"
fans
:
""
,
personalFans
:
""
,
newFans
:
""
,
allNewFans
:
""
},
menuInfo
:
{
icon
:
{
...
...
@@ -231,8 +231,8 @@ export default {
};
},
created
()
{
this
.
overlayShow
=
true
this
.
checkNowMenuBar
()
;
console
.
log
(
'created'
)
this
.
checkNowMenuBar
()
if
(
sessionStorage
.
getItem
(
"userId"
))
{
if
(
sessionStorage
.
getItem
(
"avatar"
))
{
this
.
test
.
manInfo
.
logoUrl
=
sessionStorage
.
getItem
(
"avatar"
);
...
...
@@ -256,10 +256,10 @@ export default {
this
.
flag
=
sessionStorage
.
getItem
(
"role"
);
}
}
else
{
this
.
zReadyUserId
()
;
this
.
zTestGetNowUrlInfo
()
;
this
.
zReadyUserId
()
this
.
zTestGetNowUrlInfo
()
}
this
.
GET_CurrentActive
()
;
this
.
GET_CurrentActive
()
},
methods
:
{
// 跳转到 活动详情
...
...
@@ -283,7 +283,7 @@ export default {
GET_CurrentActive
()
{
getCurrentActive
().
then
(
res
=>
{
this
.
currentActives
=
res
.
data
||
[];
})
;
})
},
// 获取用户角色
getDirector
(
userId
)
{
...
...
@@ -319,12 +319,12 @@ export default {
console
.
log
(
err
);
});
},
// 获取个人粉丝
getFans
()
{
let
headerData
=
{
agentId
:
"1000033"
,
corpId
:
"ww4df265003b43fa0d"
};
axios
({
url
:
"http://139.155.48.151:8085/workWx/auth/contact/listExternalContacts?userId="
+
...
...
@@ -340,6 +340,7 @@ export default {
console
.
log
(
err
);
});
},
// 获取店铺所有粉丝
getAllFans
()
{
let
headerData
=
{
agentId
:
"1000033"
,
...
...
@@ -367,9 +368,11 @@ export default {
console
.
log
(
err
)
});
},
// 获取个人新增粉丝
getNewFans
()
{
this
.
getAddFans
(
1
,
this
.
zcache
.
userId
);
},
// 获取店铺所有新增粉丝
getAllNewFans
()
{
let
params
=
{
oyStallCode
:
this
.
oyStallCode
...
...
@@ -473,13 +476,13 @@ export default {
this
.
$router
.
push
(
inData
);
},
menuCase
()
{
this
.
$router
.
push
({
path
:
"/case"
})
;
this
.
$router
.
push
({
path
:
"/case"
})
},
menuProfit
()
{
this
.
$router
.
push
({
path
:
"/profitList"
})
;
this
.
$router
.
push
({
path
:
"/profitList"
})
},
menuTask
()
{
this
.
$router
.
push
({
path
:
"/taskList"
})
;
this
.
$router
.
push
({
path
:
"/taskList"
})
},
// 获取code
zReadyUserId
()
{
...
...
@@ -499,6 +502,8 @@ export default {
this
.
url
=
this
.
zcache
.
nowUrl
;
},
zTestPreAuthCode
()
{
console
.
log
(
'获取code'
)
this
.
overlayShow
=
true
// alert('获取code')
const
basicInfo
=
{
head
:
"https://open.weixin.qq.com/connect/oauth2/authorize?"
,
...
...
ybf_admin/src/api/in/mail.js
View file @
f1d838da
...
...
@@ -156,3 +156,11 @@ export function getHistoryList(data) {
params
})
}
// 获取部门 用于修改
export
function
getEditOrg
(
params
)
{
return
request
({
url
:
'/admin/auth/addressbook/orgnization/getAllForUpdate'
,
method
:
'get'
,
params
})
}
\ No newline at end of file
ybf_admin/src/pages/in/contact/components/editGroup.vue
View file @
f1d838da
...
...
@@ -66,7 +66,7 @@
</
template
>
<
script
>
import
{
editDept
,
getWxAllDeptList
,
getAllMemberList
,
getGroupById
,
getAllPeopleList
,
get
OrgTree
,
getDeptDetail
}
from
"@/api/in/mail"
;
import
{
editDept
,
getWxAllDeptList
,
getAllMemberList
,
getGroupById
,
getAllPeopleList
,
get
DeptDetail
,
getEditOrg
}
from
"@/api/in/mail"
;
import
{
log
}
from
"util"
;
export
default
{
...
...
@@ -208,8 +208,13 @@ export default {
console
.
log
(
val
,
'val'
)
},
getOrgTree
()
{
getOrgTree
().
then
(
res
=>
{
this
.
orgTree
=
[
res
.
data
.
organizations
]
let
params
=
{
deptId
:
this
.
groupId
}
getEditOrg
(
params
).
then
(
res
=>
{
console
.
log
(
res
,
'数据111'
);
this
.
orgTree
=
[
res
.
data
]
})
},
handleParentChange
(
val
)
{
...
...
ybf_wx/public/qrCode/index.html
View file @
f1d838da
...
...
@@ -199,25 +199,33 @@
const
cleanUrlAndPostQRInfo
=
()
=>
{
// alert(`--->qrCode: cleanUrlAndPostQRInfo: IN.`)
let
nowUrl
=
''
let
id
=
''
let
actionid
=
''
let
activeId
=
''
let
voucherId
=
''
let
unionId
=
''
nowUrl
=
document
.
location
.
toString
().
slice
(
42
);
// alert(`--->nowUrl =${nowUrl}`)
id
=
String
(
nowUrl
.
split
(
"?"
)[
1
].
slice
(
3
).
split
(
"&"
)[
0
]);
actionid
=
String
(
nowUrl
.
split
(
"?"
)[
1
].
slice
(
3
).
split
(
"&"
)[
1
].
split
(
"="
)[
1
]);
activeId
=
String
(
nowUrl
.
split
(
"?"
)[
1
].
slice
(
3
).
split
(
"&"
)[
2
].
split
(
"="
)[
1
]);
voucherId
=
String
(
nowUrl
.
split
(
"?"
)[
1
].
slice
(
3
).
split
(
"&"
)[
3
].
split
(
"="
)[
1
]);
unionId
=
String
(
nowUrl
.
split
(
"?"
)[
1
].
slice
(
3
).
split
(
"&"
)[
4
].
split
(
"="
)[
1
]);
// let nowUrl = ''
// let id = ''
// let actionid = ''
// let activeId = ''
// let voucherId = ''
// let unionId = ''
// nowUrl = document.location.toString().slice(42)
// id = String(nowUrl.split("?")[1].slice(3).split("&")[0])
// actionid = String(nowUrl.split("?")[1].slice(3).split("&")[1].split("=")[1])
// activeId = String(nowUrl.split("?")[1].slice(3).split("&")[2].split("=")[1])
// voucherId = String(nowUrl.split("?")[1].slice(3).split("&")[3].split("=")[1])
// unionId = String(nowUrl.split("?")[1].slice(3).split("&")[4].split("=")[1])
// let pageUri = `${nowUrl}&detailid=${voucherId}&actionid=${activeId}&unionid=${unionId}`;
let
pageUri
=
`
${
nowUrl
}
`
;
pageUri
=
pageUri
.
split
(
'&'
).
slice
(
0
,
5
).
join
(
'&'
)
let
pageUrl
=
`http://139.155.48.151:8085/workWx/auth/oauth2/wxMiniQrCode?pageUri=
${
pageUri
}
`
;
function
GetQueryString
(
name
)
{
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
,
"i"
);
var
r
=
window
.
location
.
search
.
substr
(
1
).
match
(
reg
)
var
context
=
""
if
(
r
!=
null
)
context
=
r
[
2
]
reg
=
null
r
=
null
return
context
==
null
||
context
==
""
||
context
==
"undefined"
?
""
:
context
;
}
const
nowUrl
=
GetQueryString
(
'Url'
)
let
pageUrl
=
`http://139.155.48.151:8085/workWx/auth/oauth2/wxMiniQrCode?pageUri=
${
nowUrl
}
`
;
// document.getElementById('uri').innerHTML = 'Uri=' + String(pageUri)
...
...
ybf_wx/src/views/sideNav/discount/index.vue
View file @
f1d838da
...
...
@@ -107,30 +107,30 @@ export default {
if
(
res
.
data
.
length
==
0
)
{
alert
(
'您当前没有绑定店铺'
)
}
else
{
this
.
zcache
.
storeId
=
res
.
data
[
0
].
oyStallCode
// this.zcache.storeId = res.data[0].oyStallCode
res
.
data
.
forEach
(
item
=>
{
this
.
zReadySetVoucherList
(
item
.
id
)
})
this
.
zReadySetVoucherList
()
}
})
.
catch
(
err
=>
{})
},
// 获取优惠券列表
zReadySetVoucherList
()
{
this
.
zReadyDelVoucherList
();
zReadySetVoucherList
(
mdid
)
{
// this.zReadyDelVoucherList()
const
postData
=
{
appCode
:
"0696"
,
// j接口编码
mdid
:
this
.
zcache
.
storeI
d
mdid
:
mdi
d
}
getVoucherList
(
postData
).
then
(
res
=>
{
if
(
res
.
errCode
==
0
)
{
if
(
res
.
result
.
coupons
.
length
!=
0
)
{
this
.
zlist
.
voucher
.
push
(...
res
.
result
.
coupons
)
}
else
{
this
.
zVoucherSet
(
res
.
result
.
coupons
)
console
.
log
(
this
.
zlist
.
voucher
,
'this.zlist.voucher'
)
}
}
})
.
catch
(
err
=>
{
})
...
...
@@ -143,8 +143,7 @@ export default {
zVoucherPick
(
inActiveId
,
inVoucherId
)
{
this
.
zcache
.
now
.
activeId
=
String
(
inActiveId
)
this
.
zcache
.
now
.
voucherId
=
String
(
inVoucherId
)
this
.
zVoucherUrlDel
()
this
.
zlist
.
voucherUrl
=
""
;
const
postData
=
{
appCode
:
"0697"
,
...
...
@@ -152,6 +151,7 @@ export default {
coupon_id
:
Number
(
inVoucherId
)
}
getVoucherWxUrl
(
postData
).
then
(
res
=>
{
console
.
log
(
res
,
'指向小程序的链接'
)
this
.
zVoucherUrlSet
(
res
.
result
.
link
)
});
},
...
...
@@ -185,7 +185,7 @@ export default {
{
msgtype
:
"news"
,
//消息类型,必填
news
:
{
link
:
`http://oysales.oywanhao.com/qrCode?Url=
${
inUrl
}
&activeId=
${
this
.
zcache
.
now
.
activeId
}
&voucherId=
${
this
.
zcache
.
now
.
voucherId
}
&unionId=1234
`
,
//H5消息页面url 必填
link
:
`http://oysales.oywanhao.com/qrCode?Url=
${
inUrl
}
`
,
//H5消息页面url 必填
title
:
"领取优惠券"
,
//H5消息标题
desc
:
inUrl
,
//H5消息摘要
imgUrl
:
inUrl
//H5消息封面图片URL
...
...
@@ -208,11 +208,6 @@ export default {
break
;
}
},
zVoucherSet
(
inArray
)
{
// alert('zVoucherSet')
this
.
zlist
.
voucher
=
inArray
;
},
zVoucherDel
()
{
this
.
zlist
.
voucher
=
[];
},
...
...
@@ -220,10 +215,6 @@ export default {
this
.
zlist
.
voucherUrl
=
String
(
inData
);
this
.
zpick
(
'h5'
,
String
(
inData
))
},
zVoucherUrlDel
()
{
this
.
zlist
.
voucherUrl
=
""
;
},
testEaPost
()
{
let
postData
=
{
appCode
:
"0696"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment