Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jz_Travel
Project
Project
Details
Activity
Releases
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
zhengke
jz_Travel
Commits
56449934
Commit
56449934
authored
Oct 15, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
d2e7b505
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
120 additions
and
70 deletions
+120
-70
jz_LineDetail.vue
pages/jiuzhai/jz_LineDetail.vue
+62
-62
jz_Reserve.vue
pages/jiuzhai/jz_Reserve.vue
+30
-7
utils.js
plugin/utils.js
+28
-1
No files found.
pages/jiuzhai/jz_LineDetail.vue
View file @
56449934
...
...
@@ -1059,68 +1059,68 @@ export default {
this
.
mainColor
=
this
.
$uiConfig
.
mainColor
;
},
methods
:
{
downloadFile
()
{
let
msg
=
{
configId
:
"7274"
,
cityId
:
"0"
,
tcid
:
"11409"
,
orderId
:
"0"
,
FileName
:
"2021-10-11飞猪平台九寨沟3天2晚3日游"
,
isShowBase
:
1
,
isShowFlight
:
1
,
isShowFeature
:
1
,
isShowFee
:
1
,
isShowShop
:
1
,
isShowTip
:
1
,
isShowB2B
:
1
,
isShowTrip
:
1
,
isShowTitle
:
0
,
isShowGuest
:
0
,
isShowMan
:
1
,
isShowTCNUM
:
1
,
isShowTripImage
:
1
,
isShowVisa
:
1
,
isShowVideoImg
:
1
,
isPc
:
2
,
templateId
:
3
,
UId
:
615
,
};
this
.
apipostDownload
(
"GetWebHtmlTwo_V2"
,
msg
,
(
res
)
=>
{
console
.
log
(
res
);
let
url
=
"https://reborn.oytour.com"
+
res
.
data
;
uni
.
downloadFile
({
url
:
url
,
success
:
(
res
)
=>
{
if
(
res
.
statusCode
===
200
)
{
console
.
log
(
"下载成功"
);
}
},
});
});
},
downloadFile2
()
{
let
url
=
"https://reborn.oytour.com/Upload/Temporary/C7274_T11409_CTY0_OD0_MMDD637695432017412893_1_1.pdf"
;
uni
.
downloadFile
({
url
:
url
,
success
:
(
res
)
=>
{
console
.
log
(
"suc"
,
res
);
if
(
res
.
statusCode
===
200
)
{
console
.
log
(
"下载成功"
);
const
tempFilePath
=
res
.
tempFilePath
;
//返回的文件临时地址,用于后面打开本地预览所用
wx
.
openDocument
({
filePath
:
tempFilePath
,
showMenu
:
true
,
fileType
:
"pdf"
,
success
:
function
(
res
)
{},
});
}
},
fail
(
err
)
{
console
.
log
(
"err"
,
err
);
},
});
},
//
downloadFile() {
//
let msg = {
//
configId: "7274",
//
cityId: "0",
//
tcid: "11409",
//
orderId: "0",
//
FileName: "2021-10-11飞猪平台九寨沟3天2晚3日游",
//
isShowBase: 1,
//
isShowFlight: 1,
//
isShowFeature: 1,
//
isShowFee: 1,
//
isShowShop: 1,
//
isShowTip: 1,
//
isShowB2B: 1,
//
isShowTrip: 1,
//
isShowTitle: 0,
//
isShowGuest: 0,
//
isShowMan: 1,
//
isShowTCNUM: 1,
//
isShowTripImage: 1,
//
isShowVisa: 1,
//
isShowVideoImg: 1,
//
isPc: 2,
//
templateId: 3,
//
UId: 615,
//
};
//
this.apipostDownload("GetWebHtmlTwo_V2", msg, (res) => {
//
console.log(res);
//
let url = "https://reborn.oytour.com" + res.data;
//
uni.downloadFile({
//
url: url,
//
success: (res) => {
//
if (res.statusCode === 200) {
//
console.log("下载成功");
//
}
//
},
//
});
//
});
//
},
//
downloadFile2() {
//
let url =
//
"https://reborn.oytour.com/Upload/Temporary/C7274_T11409_CTY0_OD0_MMDD637695432017412893_1_1.pdf";
//
uni.downloadFile({
//
url: url,
//
success: (res) => {
//
console.log("suc", res);
//
if (res.statusCode === 200) {
//
console.log("下载成功");
//
const tempFilePath = res.tempFilePath; //返回的文件临时地址,用于后面打开本地预览所用
//
wx.openDocument({
//
filePath: tempFilePath,
//
showMenu: true,
//
fileType: "pdf",
//
success: function (res) {},
//
});
//
}
//
},
//
fail(err) {
//
console.log("err", err);
//
},
//
});
//
},
reloadUserinfo
()
{
this
.
u
=
uni
.
getStorageSync
(
"mall_UserInfo"
);
},
...
...
pages/jiuzhai/jz_Reserve.vue
View file @
56449934
...
...
@@ -297,7 +297,7 @@
<view
class=
"big-title"
>
<text>
{{
currentPriceInfo
.
startCityName
}}
出发
</text>
</view>
<view
class=
"jz_ReseQue"
>
<view
class=
"jz_ReseQue"
@
click=
"subscribeMsgAli"
>
<img
src=
"https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/CustomizedCar/zuanshi.png"
/>
即时确认:本产品付款后可快速确认,放心期待您的旅行
...
...
@@ -340,7 +340,7 @@
/>
</view>
</view>
<view
class=
"form-items"
style=
"margin-top:
-5px;
"
>
<view
class=
"form-items"
style=
"margin-top:
-5px
"
>
<view
class=
"label"
>
学生
</view>
<view
class=
"val"
>
<!--
<checkbox-group
@
change=
"changecheckbox($event, subIndex, subItem)"
>
...
...
@@ -349,7 +349,12 @@
:checked=
"subItem.IsHightSchool"
/>
</checkbox-group>
-->
<u-switch
v-model=
"subItem.IsHightSchool"
size=
"30"
active-value=
"1"
inactive-value=
"2"
></u-switch>
<u-switch
v-model=
"subItem.IsHightSchool"
size=
"30"
active-value=
"1"
inactive-value=
"2"
></u-switch>
</view>
</view>
</view>
...
...
@@ -519,9 +524,6 @@
</
template
>
<
script
>
// #ifdef MP-ALIPAY
import
{
SubscribeMsgAli
}
from
"../../plugin/utils"
;
// #endif
export
default
{
components
:
{},
data
()
{
...
...
@@ -758,7 +760,9 @@ export default {
TradeWay
:
0
,
PlatformOrder
:
""
,
GuestNum
:
parseInt
(
this
.
orderMsg
.
ManNum
)
+
parseInt
(
this
.
orderMsg
.
ChirdNum
)
+
parseInt
(
this
.
orderMsg
.
BabyNum
),
parseInt
(
this
.
orderMsg
.
ManNum
)
+
parseInt
(
this
.
orderMsg
.
ChirdNum
)
+
parseInt
(
this
.
orderMsg
.
BabyNum
),
IsChildrenTour
:
this
.
currentPriceInfo
.
isSupportChildren
,
IsBirdDiscount
:
this
.
zaoniao
>
0
?
1
:
2
,
PredictRoomNum
:
1
,
...
...
@@ -831,6 +835,14 @@ export default {
(
res
)
=>
{
this
.
orderInfo
=
JSON
.
parse
(
res
.
data
);
console
.
log
(
718
,
res
.
data
);
// let idsArr = uni.getStorageSync("basedata")?.mall?.alimessage ?? [];
// let ids=[]
// if(idsArr.length>0){
// }
// uni.requestSubscribeMessage({
// tmplIds: ids,
// success(res) {},
// });
this
.
Pay
(
OrderId
);
}
);
...
...
@@ -875,6 +887,17 @@ export default {
// #endif
// #ifdef MP-ALIPAY
//支付宝支付
subscribeMsgAli
()
{
let
idsArr
=
uni
.
getStorageSync
(
"basedata"
)?.
mall
?.
alimessage
??
[];
let
ids
=
[];
if
(
idsArr
.
length
>
0
)
{
idsArr
.
map
((
e
)
=>
{
ids
.
push
(
e
.
MessageId
);
});
}
console
.
log
(
"ids"
,
ids
);
this
.
$utils
.
SubscribeMsgAli
(
ids
,
()
=>
{});
},
querenAli
(
data
)
{
let
that
=
this
;
let
url
=
"/api/WeChatPay/GetTravlePayInfo"
;
...
...
plugin/utils.js
View file @
56449934
...
...
@@ -41,10 +41,37 @@ function getretailer() {//判断是否是分销商
// 引入消息模板方法
const
{
requestSubscribeMessage
}
=
requirePlugin
(
"subscribeMsg"
);
function
SubscribeMsgAli
(
ids
,
cb
)
{
//支付宝小程序订阅消息
if
(
ids
.
length
===
0
)
{
my
.
showToast
({
type
:
'fail'
,
content
:
'请传入模板id'
,
duration
:
3000
,
});
return
;
}
requestSubscribeMessage
({
// 触发消息订阅弹框
entityIds
:
ids
,
// 模板消息id,
callback
(
res
)
{
cb
(
res
)
console
.
log
(
'订阅回调'
,
res
);
if
(
res
.
success
)
{
cb
();
}
else
{
switch
(
res
.
errorCode
)
{
case
11
:
{
my
.
call
(
'toast'
,
{
content
:
'用户未订阅关闭弹窗'
,
});
break
;
}
default
:
{
my
.
call
(
'toast'
,
{
content
:
`ErrorCode:
${
res
.
errorCode
}
, ErrorMsg:
${
res
.
errorMessage
}
`
,
});
break
;
}
}
cb
();
}
}
})
}
...
...
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